mirror of
https://github.com/MaskRay/ccls.git
synced 2025-04-16 05:42:17 +00:00
Match directory before looking at included files.
This commit is contained in:
parent
4c32c2bf77
commit
47a8f20b20
@ -161,6 +161,10 @@ void IncludeComplete::InsertIncludesFromDirectory(std::string directory,
|
|||||||
bool use_angle_brackets) {
|
bool use_angle_brackets) {
|
||||||
directory = NormalizePath(directory);
|
directory = NormalizePath(directory);
|
||||||
EnsureEndsInSlash(directory);
|
EnsureEndsInSlash(directory);
|
||||||
|
if (match_ && !match_->IsMatch(directory)) {
|
||||||
|
// Don't even enter the directory if it fails the patterns.
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
std::vector<CompletionCandidate> results;
|
std::vector<CompletionCandidate> results;
|
||||||
GetFilesInFolder(
|
GetFilesInFolder(
|
||||||
|
Loading…
Reference in New Issue
Block a user