Exemple #1
0
 void visitExpr(Expression *Expr) {
   if (BinaryOp *Op = dyn_cast<BinaryOp>(Expr)) {
     visitBinaryOp(Op);
   } else if (FieldRef *Ref = dyn_cast<FieldRef>(Expr)) {
     visitFieldRef(Ref);
   } else if (ConstantExpr *C = dyn_cast<ConstantExpr>(Expr)) {
     // Do nothing
   } else if (FunctionCall *FC = dyn_cast<FunctionCall>(Expr)) {
     visitFunctionCall(FC);
   } else if (PlaceHolderExpr *PH = dyn_cast<PlaceHolderExpr>(Expr)) {
     // Do nothing
   } else {
     report_fatal_error("Unhandled expression type");
   }
 }
Exemple #2
0
void IRRewriter::visit(const Xor *op) {
  expr = visitBinaryOp(op, this);
}