about summary refs log tree commit diff homepage
path: root/lib/Expr/ExprVisitor.cpp
diff options
context:
space:
mode:
authorDaniel Dunbar <daniel@zuster.org>2009-06-04 08:08:21 +0000
committerDaniel Dunbar <daniel@zuster.org>2009-06-04 08:08:21 +0000
commit44e3d58b59099f5fd0e6f88893ce431171b3fef6 (patch)
tree12d7d9af1493e650a42f570de49401776cabde3b /lib/Expr/ExprVisitor.cpp
parentc4a0e57c082e567e81ad3609a32ee492d41f03f9 (diff)
downloadklee-44e3d58b59099f5fd0e6f88893ce431171b3fef6.tar.gz
Start removing uses of Expr::isConstant.
 - These should use cast<>, isa<>, or dyn_cast<> as appropriate (or better yet,
   changed to use ref<ConstantExpr> when the type is known).


git-svn-id: https://llvm.org/svn/llvm-project/klee/trunk@72857 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Expr/ExprVisitor.cpp')
-rw-r--r--lib/Expr/ExprVisitor.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/lib/Expr/ExprVisitor.cpp b/lib/Expr/ExprVisitor.cpp
index 5e9d0a81..c81199d7 100644
--- a/lib/Expr/ExprVisitor.cpp
+++ b/lib/Expr/ExprVisitor.cpp
@@ -22,7 +22,7 @@ namespace {
 using namespace klee;
 
 ref<Expr> ExprVisitor::visit(const ref<Expr> &e) {
-  if (!UseVisitorHash || e->isConstant()) {
+  if (!UseVisitorHash || isa<ConstantExpr>(e)) {
     return visitActual(e);
   } else {
     visited_ty::iterator it = visited.find(e);
@@ -38,7 +38,7 @@ ref<Expr> ExprVisitor::visit(const ref<Expr> &e) {
 }
 
 ref<Expr> ExprVisitor::visitActual(const ref<Expr> &e) {
-  if (e->isConstant()) {    
+  if (isa<ConstantExpr>(e)) {    
     return e;
   } else {
     Expr &ep = *e.get();
@@ -106,7 +106,7 @@ ref<Expr> ExprVisitor::visitActual(const ref<Expr> &e) {
         if (recursive)
           e = visit(e);
       }
-      if (!e->isConstant()) {
+      if (!isa<ConstantExpr>(e)) {
         res = visitExprPost(*e.get());
         if (res.kind==Action::ChangeTo)
           e = res.argument;