Skip to main content

pattern_path_root

Function pattern_path_root 

Source
pub fn pattern_path_root(first_component: &str) -> Option<PathBuf>
Expand description

Returns the root path for an absolute pattern, if the first component indicates one.

On Unix, an empty first component (from splitting a path like /foo) indicates an absolute path rooted at /.