summaryrefslogtreecommitdiffstats
path: root/clang/lib/Analysis/LiveVariables.cpp
diff options
context:
space:
mode:
authorArtem Dergachev <artem.dergachev@gmail.com>2019-05-24 01:34:22 +0000
committerArtem Dergachev <artem.dergachev@gmail.com>2019-05-24 01:34:22 +0000
commit4e53032d9bdb2b24e465aa934e083fc507b58a61 (patch)
tree75f07a0b6d533de656e7ec2fa16406b4444b3bda /clang/lib/Analysis/LiveVariables.cpp
parentb7a78c7dff18485e5ac85aa8c902571da4b06a33 (diff)
downloadbcm5719-llvm-4e53032d9bdb2b24e465aa934e083fc507b58a61.tar.gz
bcm5719-llvm-4e53032d9bdb2b24e465aa934e083fc507b58a61.zip
[CFG] NFC: Remove implicit conversion from CFGTerminator to Stmt *.
Turn it into a variant class instead. This conversion does indeed save some code but there's a plan to add support for more kinds of terminators that aren't necessarily based on statements, and with those in mind it becomes more and more confusing to have CFGTerminators implicitly convertible to a Stmt *. Differential Revision: https://reviews.llvm.org/D61814 llvm-svn: 361586
Diffstat (limited to 'clang/lib/Analysis/LiveVariables.cpp')
-rw-r--r--clang/lib/Analysis/LiveVariables.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/clang/lib/Analysis/LiveVariables.cpp b/clang/lib/Analysis/LiveVariables.cpp
index e435ff2ee17..2cd607d8a49 100644
--- a/clang/lib/Analysis/LiveVariables.cpp
+++ b/clang/lib/Analysis/LiveVariables.cpp
@@ -501,7 +501,7 @@ LiveVariablesImpl::runOnBlock(const CFGBlock *block,
TransferFunctions TF(*this, val, obs, block);
// Visit the terminator (if any).
- if (const Stmt *term = block->getTerminator())
+ if (const Stmt *term = block->getTerminatorStmt())
TF.Visit(const_cast<Stmt*>(term));
// Apply the transfer function for all Stmts in the block.
OpenPOWER on IntegriCloud