forked from qt-creator/qt-creator
Clang: Fix excluded Clang path regular expression
Cover cases like /usr/lib64/clang/6.0.0/include Change-Id: I015ea3535637376eeab6f737752ad13d33887190 Reviewed-by: Marco Bubke <marco.bubke@qt.io>
This commit is contained in:
@@ -505,7 +505,7 @@ bool CompilerOptionsBuilder::excludeHeaderPath(const QString &headerPath) const
|
||||
// For example GCC on macOS uses system clang include path which makes clang code model
|
||||
// include incorrect system headers.
|
||||
static QRegularExpression clangIncludeDir(
|
||||
QLatin1String("\\A.*/lib/clang/\\d+\\.\\d+(\\.\\d+)?/include\\z"));
|
||||
QLatin1String("\\A.*[\\/\\\\]lib\\d*[\\/\\\\]clang[\\/\\\\]\\d+\\.\\d+(\\.\\d+)?[\\/\\\\]include\\z"));
|
||||
return clangIncludeDir.match(headerPath).hasMatch();
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user