This revision was landed with ongoing or failed builds.
This revision was automatically updated to reflect the committed changes.
Closed by commit rGd1a59eefd3a0: [Clang] Remove redundant init-parens in AST
print (authored by lichray).
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACT
lichray updated this revision to Diff 411843.
lichray marked 2 inline comments as done.
lichray added a comment.
Nit
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D120608/new/
https://reviews.llvm.org/D120608
Files:
clang/lib/AST/StmtPrinter.cpp
aaron.ballman added inline comments.
Comment at: clang/lib/AST/StmtPrinter.cpp:2155
- CXXNewExpr::InitializationStyle InitStyle = E->getInitializationStyle();
- if (InitStyle) {
-if (InitStyle == CXXNewExpr::CallInit)
+ auto InitStyle = E->getInitializationStyle();
+ if
lichray added inline comments.
Comment at: clang/lib/AST/StmtPrinter.cpp:2155
- CXXNewExpr::InitializationStyle InitStyle = E->getInitializationStyle();
- if (InitStyle) {
-if (InitStyle == CXXNewExpr::CallInit)
+ auto InitStyle = E->getInitializationStyle();
+ if (Init
aaron.ballman accepted this revision.
aaron.ballman added a comment.
This revision is now accepted and ready to land.
LGTM aside from a nit.
Comment at: clang/lib/AST/StmtPrinter.cpp:2155
- CXXNewExpr::InitializationStyle InitStyle = E->getInitializationStyle();
- if (InitS
lichray created this revision.
lichray requested review of this revision.
Herald added a project: clang.
Herald added a subscriber: cfe-commits.
Given a dependent `T` (maybe an undeduced `auto`),
Before:
new T(z) --> new T((z)) # changes meaning with more args
new T{z} --> new T{z}