[PATCH] D50666: Fix Stmt::ignoreImplicit

Richard Smith - zygoloid via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Mon Aug 13 15:14:31 PDT 2018


rsmith accepted this revision.
rsmith added inline comments.
This revision is now accepted and ready to land.


================
Comment at: lib/AST/Stmt.cpp:121-122
 
-  if (auto *bte = dyn_cast<CXXBindTemporaryExpr>(s))
-    s = bte->getSubExpr();
+    if (auto *ewc = dyn_cast<ExprWithCleanups>(s))
+      s = ewc->getSubExpr();
 
----------------
`ExprWithCleanups` can only appear at the top level. But... maybe it's not worth treating that as a special case.


Repository:
  rC Clang

https://reviews.llvm.org/D50666





More information about the cfe-commits mailing list