diff options
author | Birunthan Mohanathas <birunthan@mohanathas.com> | 2015-07-03 17:25:16 +0000 |
---|---|---|
committer | Birunthan Mohanathas <birunthan@mohanathas.com> | 2015-07-03 17:25:16 +0000 |
commit | b001a0ba5e10937c3e1a6489bbd47889182cef69 (patch) | |
tree | 0b2d5b7fe9dae8714e0618094feedf1b414db98b /llvm/lib/Object/Object.cpp | |
parent | 15b86155c9e6d2eb6721eb4c613480fa8fe09f86 (diff) | |
download | bcm5719-llvm-b001a0ba5e10937c3e1a6489bbd47889182cef69.tar.gz bcm5719-llvm-b001a0ba5e10937c3e1a6489bbd47889182cef69.zip |
clang-format: Add MacroBlock{Begin,End} options
The MacroBlockBegin and MacroBlockEnd options make matching macro identifiers
behave like '{' and '}', respectively, in terms of indentation.
Mozilla code, for example, uses several macros that begin and end a scope.
Previously, Clang-Format removed the indentation resulting in:
MACRO_BEGIN(...)
MACRO_ENTRY(...)
MACRO_ENTRY(...)
MACRO_END
Now, using the options
MacroBlockBegin: "^[A-Z_]+_BEGIN$"
MacroBlockEnd: "^[A-Z_]+_END$"
will yield the expected result:
MACRO_BEGIN(...)
MACRO_ENTRY(...)
MACRO_ENTRY(...)
MACRO_END
Differential Revision: http://reviews.llvm.org/D10840
llvm-svn: 241363
Diffstat (limited to 'llvm/lib/Object/Object.cpp')
0 files changed, 0 insertions, 0 deletions