Szelethus closed this revision.
Szelethus added a comment.
Woohoo, it seems to be fine! ^-^
I thought the evaluation order in braced initializer lists are from left to
right, but apparently not. Certainly not on windows.
Repository:
rL LLVM
https://reviews.llvm.org/D52794
Szelethus reopened this revision.
Szelethus added a comment.
This revision is now accepted and ready to land.
Here's to losing a couple more handfuls of hair, tests break on many platforms,
so I reverted it.
Repository:
rL LLVM
https://reviews.llvm.org/D52794
This revision was automatically updated to reflect the committed changes.
Closed by commit rL346095: [analyzer][PlistMacroExpansion] Part 2.: Retrieving
the macro name and… (authored by Szelethus, committed by ).
Herald added a subscriber: llvm-commits.
Changed prior to commit:
Szelethus updated this revision to Diff 172459.
Szelethus marked an inline comment as done.
Szelethus added a comment.
- Fixes according to @xazax.hun's observations
Thanks! I'll commit when I have time watch buildbots.
https://reviews.llvm.org/D52794
Files:
xazax.hun accepted this revision.
xazax.hun added a comment.
One question and one nit otherwise looks good. Feel free to commit once those
are resolved without another round of reviews.
Comment at: lib/StaticAnalyzer/Core/PlistDiagnostics.cpp:805
+// macro.
+if (const
NoQ accepted this revision.
NoQ added a comment.
This revision is now accepted and ready to land.
Because i don't know much about macros, i shouldn't be blocking this review on
waiting for myself to understand the code :) I guess we'll eventually figure
out if something is wrong with it.
Szelethus marked 10 inline comments as done.
Szelethus added inline comments.
Comment at: lib/StaticAnalyzer/Core/PlistDiagnostics.cpp:667
+
+//===--===//
+// Declarations of helper functions and data structures
Szelethus updated this revision to Diff 171962.
Szelethus added a comment.
Fixes according to @xazax.hun's remarks. Thanks for catching that, it was a
non-trivial cornercase!
- Now I'm acquiring the macro directive history, and choosing the appropriate
macro definition in `getMacroNameAndInfo`
Szelethus planned changes to this revision.
Szelethus added a comment.
I'll put this patch on hold while I'm investigating the issue @xazax.hun
mentioned.
Mind you, again, other patches don't depend strictly on this part, I'll only
need to change the for loop. Hopefully. You never know.
xazax.hun added a comment.
Please add a test case where a bug path goes through a macro definition and
this macro is undefed at the end of the translation unit.
Comment at: lib/StaticAnalyzer/Core/PlistDiagnostics.cpp:667
+
Szelethus added inline comments.
Comment at: lib/StaticAnalyzer/Core/PlistDiagnostics.cpp:787-791
+ // Acquire the macro's name.
+ Token TheTok;
+ RawLexer.LexFromRawLexer(TheTok);
+
+ std::string MacroName = PP.getSpelling(TheTok);
NoQ wrote:
> Not sure,
NoQ added inline comments.
Comment at: lib/StaticAnalyzer/Core/PlistDiagnostics.cpp:727
+
+static std::string getExpandedMacroImpl(TokenPrinter ,
+SourceLocation MacroLoc,
Whoa, that's so easy!
Comment
Szelethus updated this revision to Diff 169862.
Szelethus added a comment.
Herald added a subscriber: donat.nagy.
- Removed the version entry from the plist file,
- Now using `TokenConcatenation` to print spaces only when needed (this needed
for https://reviews.llvm.org/D52988),
- A bit more
Szelethus updated this revision to Diff 168334.
https://reviews.llvm.org/D52794
Files:
lib/StaticAnalyzer/Core/PlistDiagnostics.cpp
test/Analysis/Inputs/expected-plists/plist-macros-with-expansion.cpp.plist
test/Analysis/plist-macros-with-expansion.cpp
Index:
Szelethus created this revision.
Szelethus added reviewers: george.karpenkov, NoQ, rnkovacs, dkrupp, whisperity,
martong, baloghadamsoftware.
Herald added subscribers: cfe-commits, mikhail.ramalho, a.sidorin, szepet,
xazax.hun.
Szelethus added a dependency: D52742:
15 matches
Mail list logo