original_string: private function setDir($rel_path){
  		$path = $this->temp_dir.DIRECTORY_SEPARATOR.ltrim($rel_path, DIRECTORY_SEPARATOR);
  		$dir = dirname($path);
  		if( !is_dir($dir) ){
  			if( !mkdir($dir, 0755, true) ){
  				return false;
  			}
  		}
  		return $path;
  	}
code: private function setDir($rel_path){
  		$path = $this->temp_dir.DIRECTORY_SEPARATOR.ltrim($rel_path, DIRECTORY_SEPARATOR);
  		$dir = dirname($path);
  		if( !is_dir($dir) ){
  			if( !mkdir($dir, 0755, true) ){
  				return false;
  			}
  		}
  		return $path;
  	}
code_tokens: private function setDir ( $ rel_path ) { $ path = $ this -> temp_dir . DIRECTORY_SEPARATOR . ltrim ( $ rel_path , DIRECTORY_SEPARATOR ) ; $ dir = dirname ( $ path ) ; if ( ! is_dir ( $ dir ) ) { if ( ! mkdir ( $ dir , 0755 , true ) ) { return false ; } } return $ path ; }
docstring: Ensure parent directory is ready and writable
  
  @param string $rel_path
  
  @return false|string
docstring_tokens: Ensure parent directory is ready and writable