diff options
Diffstat (limited to 'src/expr-visitor.cc')
-rw-r--r-- | src/expr-visitor.cc | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/src/expr-visitor.cc b/src/expr-visitor.cc index 9d0d211d..8975a43d 100644 --- a/src/expr-visitor.cc +++ b/src/expr-visitor.cc @@ -25,6 +25,23 @@ ExprVisitor::ExprVisitor(Delegate* delegate) : delegate_(delegate) {} Result ExprVisitor::VisitExpr(Expr* expr) { switch (expr->type()) { + case ExprType::AtomicLoad: + CHECK_RESULT(delegate_->OnAtomicLoadExpr(cast<AtomicLoadExpr>(expr))); + break; + + case ExprType::AtomicStore: + CHECK_RESULT(delegate_->OnAtomicStoreExpr(cast<AtomicStoreExpr>(expr))); + break; + + case ExprType::AtomicRmw: + CHECK_RESULT(delegate_->OnAtomicRmwExpr(cast<AtomicRmwExpr>(expr))); + break; + + case ExprType::AtomicRmwCmpxchg: + CHECK_RESULT( + delegate_->OnAtomicRmwCmpxchgExpr(cast<AtomicRmwCmpxchgExpr>(expr))); + break; + case ExprType::Binary: CHECK_RESULT(delegate_->OnBinaryExpr(cast<BinaryExpr>(expr))); break; |