================
@@ -2390,7 +2390,35 @@ void StmtProfiler::VisitMaterializeTemporaryExpr(
 }
 
 void StmtProfiler::VisitCXXFoldExpr(const CXXFoldExpr *S) {
-  VisitExpr(S);
+  // For CXXFoldExpr, not profile the call expression as it may
+  // be affected by the context. e.g.,
----------------
ChuanqiXu9 wrote:

It's the call to possible "operator &&()". You can look at the test for 
example. I met the problem before, roughly 2~3 years ago. But I thought this is 
 problem of user codes that time.

But now I realized it was super weird to override the behavior of '&&' or '||' 
in fold expression. So I decide to send this.

https://github.com/llvm/llvm-project/pull/190732
_______________________________________________
cfe-commits mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to