Added support for GNU named variadic macros in
macro expansion for plist generation.
Details
Diff Detail
- Repository
- rG LLVM Github Monorepo
Event Timeline
clang/test/Analysis/plist-macros-with-expansion.cpp | ||
---|---|---|
536 | Seems the do {} while (0) idiom is a problem, because the plist output gets formatted differently on windows than it does on Linux. (Extra space). |
The fix is great, thank you so much! The test seems to be annoying, it might be worth looking into it some other time, but that is definitely orthogonal to this patch.
clang/lib/StaticAnalyzer/Core/PlistDiagnostics.cpp | ||
---|---|---|
1211–1213 | That looks so much better. | |
clang/test/Analysis/plist-macros-with-expansion.cpp | ||
529–545 | These FileCheck lines are great, because the plist file on its own is not very readable, could you include them for the new test as well? Side note, we're already thinking that removing the plist file might be a good idea (its a mess to keep up-to-date, and doesn't test all that much). | |
536 | Oh that is a real shame, we absolutely shouldn't do that! Can we somehow provoke a warning through some other way? (null pointer dereference) |
Thanks for the quick feedback, Kristof! I changed the macro to be just a decrement operator, and triggered DBZ with that. Added the checks as you suggested.
That looks so much better.