[PATCH] D47122: [clang-tidy] SimplifyBoolenExpr doesn't add parens if unary negotiation is of ExprWithCleanups type

Malcolm Parsons via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Tue May 22 11:17:50 PDT 2018


malcolm.parsons added inline comments.


================
Comment at: clang-tools-extra/trunk/clang-tidy/readability/SimplifyBooleanExprCheck.cpp:198
   E = E->ignoreParenBaseCasts();
+  if (const auto *EC = dyn_cast<ExprWithCleanups>(E))
+    E = EC->getSubExpr();
----------------
`E->IgnoreImplicit()` can be used to ignore `ExprWithCleanups`


Repository:
  rL LLVM

https://reviews.llvm.org/D47122





More information about the llvm-commits mailing list