[PATCH] D139705: [clang] fix zero-initialization fix-it for variable template
Shafik Yaghmour via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Fri Dec 9 11:53:57 PST 2022
shafik added inline comments.
================
Comment at: clang/lib/Sema/SemaInit.cpp:3870-3872
+ }
+ if (const ASTTemplateArgumentListInfo *Info = VTSD->getTemplateArgsInfo())
+ EndLoc = Info->getRAngleLoc();
----------------
If I understand correctly we either have a `VarTemplatePartialSpecializationDecl` or `ASTTemplateArgumentListInfo ` so we should use an `else if` and if we do then we should add a brace to [make the else if consistent with the else](https://llvm.org/docs/CodingStandards.html#don-t-use-braces-on-simple-single-statement-bodies-of-if-else-loop-statements)
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D139705/new/
https://reviews.llvm.org/D139705
More information about the cfe-commits
mailing list