-
Notifications
You must be signed in to change notification settings - Fork 1.9k
C++: Silence alerts coming from CMake test compilation files #18408
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
adf824a to
2472f76
Compare
2472f76 to
6d0d6b2
Compare
6d0d6b2 to
b6f412b
Compare
redsun82
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sounds good to me!
geoffw0
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Couple of tiny points, otherwise LGTM.
| parent.getParentContainer().getBaseName() = "CMakeFiles" | ||
| ) | ||
| } | ||
| } |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Do we need to worry about files in subdirectories of the TryCompile-* directory? i.e. CMakeFiles/CMAkeScratch/TryCompile-foo/bar?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
No. My understanding is that CMake creates each directory on-the-fly and only uses it for one test compilation.
...Likely Typos/ExprHasNoEffect/CMakeFiles/CMakeScratch/TryCompile-abcdef/CheckFunctionExists.c
Outdated
Show resolved
Hide resolved
…ct/CMakeFiles/CMakeScratch/TryCompile-abcdef/CheckFunctionExists.c Co-authored-by: Jeroen Ketema <93738568+jketema@users.noreply.github.com>
This silences alert wobble, as the suffix of CMake
TryCompile-directories is random and changes each time a project is built.There's probably other queries where this makes sense, but for now I've limited myself to queries for which I concretely observed
TryCompile-files showing up.DCA nightly shows that the neovim alerts on
TryCompile-files disappears, and similarly for DCA autobuild posix and .NET diagnostics.Pull Request checklist
All query authors
.qhelp. See the documentation in this repository.Internal query authors only
.ql,.qll, or.qhelpfiles. See the documentation (internal access required).