[all-commits] [llvm/llvm-project] f7617f: [clang-format] Recognize TableGen paste operator o...
sstwcw via All-commits
all-commits at lists.llvm.org
Thu Apr 10 05:52:24 PDT 2025
Branch: refs/heads/main
Home: https://github.com/llvm/llvm-project
Commit: f7617f7f909102080f1a0cee46f8ca75ec8d14ff
https://github.com/llvm/llvm-project/commit/f7617f7f909102080f1a0cee46f8ca75ec8d14ff
Author: sstwcw <su3e8a96kzlver at posteo.net>
Date: 2025-04-10 (Thu, 10 Apr 2025)
Changed paths:
M clang/lib/Format/TokenAnnotator.cpp
M clang/lib/Format/UnwrappedLineParser.cpp
M clang/unittests/Format/FormatTestTableGen.cpp
M clang/unittests/Format/TokenAnnotatorTest.cpp
Log Message:
-----------
[clang-format] Recognize TableGen paste operator on separate line (#133722)
Formatting this piece of code made the program crash.
```
class TypedVecListRegOperand<RegisterClass Reg, int lanes, string eltsize>
: RegisterOperand<Reg, "printTypedVectorList<" # lanes # ", '"
# eltsize # "'>">;
```
The line starting with the `#` was treated as a separate preprocessor
directive line. Then the code dereferenced a null pointer when it tried
to continue parsing the first line that did not end in a semicolon.
Now the 2 problems are fixed.
To unsubscribe from these emails, change your notification settings at https://github.com/llvm/llvm-project/settings/notifications
More information about the All-commits
mailing list