clang-format: Format enum struct/class like enum.
Patch by Joe Hermaszewski. Thank you!
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@188794 91177308-0d34-0410-b5e6-96231b3b80d8
diff --git a/lib/Format/UnwrappedLineParser.cpp b/lib/Format/UnwrappedLineParser.cpp
index 56fe81f..d77f931 100644
--- a/lib/Format/UnwrappedLineParser.cpp
+++ b/lib/Format/UnwrappedLineParser.cpp
@@ -918,6 +918,10 @@
void UnwrappedLineParser::parseEnum() {
nextToken();
+ // Eat up enum class ...
+ if (FormatTok->Tok.is(tok::kw_class) ||
+ FormatTok->Tok.is(tok::kw_struct))
+ nextToken();
if (FormatTok->Tok.is(tok::identifier) ||
FormatTok->Tok.is(tok::kw___attribute) ||
FormatTok->Tok.is(tok::kw___declspec)) {