[PATCH] D63538: [CFG] Add a new function to get the proper condition of a CFGBlock

2019-07-05 Thread Simon Pilgrim via Phabricator via cfe-commits
RKSimon added a comment. In D63538#1571454 , @Szelethus wrote: > In D63538#1571451 , @Szelethus wrote: > > > Since the followup patches test this roughly anyways, and the fact that the > > AST's lifetime ends right

[PATCH] D63538: [CFG] Add a new function to get the proper condition of a CFGBlock

2019-07-05 Thread Kristóf Umann via Phabricator via cfe-commits
Szelethus added a comment. In D63538#1571451 , @Szelethus wrote: > Since the followup patches test this roughly anyways, and the fact that the > AST's lifetime ends right after the CFG's construction makes the remaining > tests pretty much pointless, if

[PATCH] D63538: [CFG] Add a new function to get the proper condition of a CFGBlock

2019-07-05 Thread Kristóf Umann via Phabricator via cfe-commits
Szelethus added a comment. In D63538#1571418 , @RKSimon wrote: > @Szelethus This is causing problems on windows buildbots > http://lab.llvm.org:8011/builders/llvm-clang-lld-x86_64-scei-ps4-windows10pro-fast > - revert? Apologies, I thought my followup

[PATCH] D63538: [CFG] Add a new function to get the proper condition of a CFGBlock

2019-07-05 Thread Simon Pilgrim via Phabricator via cfe-commits
RKSimon added a comment. @Szelethus This is causing problems on windows buildbots http://lab.llvm.org:8011/builders/llvm-clang-lld-x86_64-scei-ps4-windows10pro-fast - revert? Repository: rL LLVM CHANGES SINCE LAST ACTION https://reviews.llvm.org/D63538/new/ https://reviews.llvm.org/D6353

[PATCH] D63538: [CFG] Add a new function to get the proper condition of a CFGBlock

2019-07-05 Thread Kristóf Umann via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL365177: [CFG] Add a new function to get the proper condition of a CFGBlock (authored by Szelethus, committed by ). Changed prior to commit: https://reviews.llvm.org/D63538?vs=207904&id=208130#toc Repos

[PATCH] D63538: [CFG] Add a new function to get the proper condition of a CFGBlock

2019-07-04 Thread Artem Dergachev via Phabricator via cfe-commits
NoQ accepted this revision. NoQ added a comment. This revision is now accepted and ready to land. Looks great, thanks! CHANGES SINCE LAST ACTION https://reviews.llvm.org/D63538/new/ https://reviews.llvm.org/D63538 ___ cfe-commits mailing list cfe

[PATCH] D63538: [CFG] Add a new function to get the proper condition of a CFGBlock

2019-07-03 Thread Kristóf Umann via Phabricator via cfe-commits
Szelethus updated this revision to Diff 207904. Szelethus added a comment. Add one more assert to `GetExprText`. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D63538/new/ https://reviews.llvm.org/D63538 Files: clang/include/clang/Analysis/CFG.h clang/lib/Analysis/CFG.cpp clang/uni

[PATCH] D63538: [CFG] Add a new function to get the proper condition of a CFGBlock

2019-07-03 Thread Kristóf Umann via Phabricator via cfe-commits
Szelethus updated this revision to Diff 207902. Szelethus added a comment. - Bail out if the actual terminator isn't a branch - Bail out if the number of successors is less than 2 - LLVM-ify the code as suggested! - Add some unit tests (I mean, you can kinda see how it was duct taped together, bu

[PATCH] D63538: [CFG] Add a new function to get the proper condition of a CFGBlock

2019-07-03 Thread Gábor Horváth via Phabricator via cfe-commits
xazax.hun added inline comments. Comment at: clang/lib/Analysis/CFG.cpp:5619-5625 + // If the terminator is a temporary dtor or a virtual base, etc, we can't + // retrieve a meaningful condition, bail out. + if (rbegin()->getKind() != CFGElement::Kind::Statement) +return n

[PATCH] D63538: [CFG] Add a new function to get the proper condition of a CFGBlock

2019-07-03 Thread Artem Dergachev via Phabricator via cfe-commits
NoQ added inline comments. Comment at: clang/lib/Analysis/CFG.cpp:5619-5625 + // If the terminator is a temporary dtor or a virtual base, etc, we can't + // retrieve a meaningful condition, bail out. + if (rbegin()->getKind() != CFGElement::Kind::Statement) +return nullptr

[PATCH] D63538: [CFG] Add a new function to get the proper condition of a CFGBlock

2019-07-03 Thread Kristóf Umann via Phabricator via cfe-commits
Szelethus updated this revision to Diff 207833. Szelethus retitled this revision from "[analyzer][CFG] Return the correct terminator condition" to "[CFG] Add a new function to get the proper condition of a CFGBlock". Szelethus edited the summary of this revision. Szelethus added a comment. Let's