[PATCH] clang-format: Add support for SEH __try / __except / __finally blocks.
Nico Weber
thakis at chromium.org
Tue Feb 3 11:50:53 PST 2015
Hi djasper,
This lets clang-format format
__try {
} __except(0) {
}
and
__try {
} __finally {
}
correctly. __try and __finally are keywords if `LangOpts.MicrosoftExt` is set, so this turns this on. This also enables a few other keywords, but it shouldn't overly perturb regular clang-format operation. __except is a context-sensitive keyword, so `AdditionalKeywords` needs to be passed around to a few more places.
http://reviews.llvm.org/D7386
Files:
lib/Format/Format.cpp
lib/Format/FormatToken.h
lib/Format/TokenAnnotator.cpp
lib/Format/UnwrappedLineFormatter.cpp
lib/Format/UnwrappedLineFormatter.h
lib/Format/UnwrappedLineParser.cpp
unittests/Format/FormatTest.cpp
EMAIL PREFERENCES
http://reviews.llvm.org/settings/panel/emailpreferences/
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D7386.19256.patch
Type: text/x-patch
Size: 7829 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20150203/2e1bf6e8/attachment.bin>
More information about the cfe-commits
mailing list