[PATCH] D22910: Add support for CXXOperatorCallExpr in Expr::HasSideEffects

Aaron Ballman via cfe-commits cfe-commits at lists.llvm.org
Wed Sep 21 06:10:40 PDT 2016

aaron.ballman added a comment.

The other thing this patch is missing are tests, btw.

Comment at: lib/AST/Expr.cpp:2869
@@ +2868,3 @@
+    // assignment operator is intended to have a side-effect and other overloaded
+    // operators are not. Otherwise fall through the logic of call expression.
+    OverloadedOperatorKind Op = cast<CXXOperatorCallExpr>(this)->getOperator();
I think that `operator++()` and `operator--()` should be handled as well as the assignment operators. @rsmith, thoughts?


More information about the cfe-commits mailing list