Skip to content

Commit 5e6428b

Browse files
committed
[clangd] Use the normalized file path to do the filtering.
This is an oversight, where we normalized the path, but we didn't use it in the filtering.
1 parent c77bd1f commit 5e6428b

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

clang-tools-extra/clangd/IncludeCleaner.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -292,7 +292,7 @@ static bool mayConsiderUnused(const Inclusion &Inc, ParsedAST &AST,
292292
// Convert the path to Unix slashes and try to match against the filter.
293293
llvm::SmallString<64> Path(Inc.Resolved);
294294
llvm::sys::path::native(Path, llvm::sys::path::Style::posix);
295-
if (Filter(Inc.Resolved)) {
295+
if (Filter(Path)) {
296296
dlog("{0} header is filtered out by the configuration", FE->getName());
297297
return false;
298298
}

0 commit comments

Comments
 (0)