[PATCH] D140543: [clang-format] Add an option to format integer literal separators
Owen Pan via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Thu Dec 29 19:07:51 PST 2022
owenpan requested review of this revision.
owenpan added inline comments.
================
Comment at: clang/lib/Format/IntegerLiteralSeparatorFixer.cpp:81-82
+
+ llvm::SpecificBumpPtrAllocator<Token> Allocator;
+ auto Tok = new (Allocator.Allocate()) Token;
+ Lex->LexFromRawLexer(*Tok);
----------------
HazardyKnusperkeks wrote:
> owenpan wrote:
> > I should allocate memory for the `Token` object as shown but instead had `Token Tok;` before.
> But why? What is different?
Thanks for asking! It made me find the real cause.
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D140543/new/
https://reviews.llvm.org/D140543
More information about the cfe-commits
mailing list