diff --git a/src/lib.rs b/src/lib.rs index 73e76f5..1ba8fa7 100644 --- a/src/lib.rs +++ b/src/lib.rs @@ -179,7 +179,13 @@ pub fn glob_with(pattern: &str, options: MatchOptions) -> Result bool { match p.components().next() { Some(Component::Prefix(ref p)) => { - p.kind().is_verbatim() && !matches!(p.kind(), std::path::Prefix::VerbatimDisk(_)) + // Allow VerbatimDisk paths. std canonicalize() generates them, and they work fine + p.kind().is_verbatim() + && if let std::path::Prefix::VerbatimDisk(_) = p.kind() { + false + } else { + true + } } _ => false, }