@@ -369,14 +369,6 @@ template <> struct ScalarEnumerationTraits<FormatStyle::JavaScriptQuoteStyle> {
369369 }
370370};
371371
372- template <> struct MappingTraits <FormatStyle::KeepEmptyLinesStyle> {
373- static void mapping (IO &IO, FormatStyle::KeepEmptyLinesStyle &Value) {
374- IO.mapOptional (" AtEndOfFile" , Value.AtEndOfFile );
375- IO.mapOptional (" AtStartOfBlock" , Value.AtStartOfBlock );
376- IO.mapOptional (" AtStartOfFile" , Value.AtStartOfFile );
377- }
378- };
379-
380372template <> struct ScalarEnumerationTraits <FormatStyle::LanguageKind> {
381373 static void enumeration (IO &IO, FormatStyle::LanguageKind &Value) {
382374 IO.enumCase (Value, " Cpp" , FormatStyle::LK_Cpp);
@@ -877,9 +869,6 @@ template <> struct MappingTraits<FormatStyle> {
877869 OnCurrentLine);
878870 IO.mapOptional (" DeriveLineEnding" , DeriveLineEnding);
879871 IO.mapOptional (" DerivePointerBinding" , Style.DerivePointerAlignment );
880- IO.mapOptional (" KeepEmptyLinesAtEOF" , Style.KeepEmptyLines .AtEndOfFile );
881- IO.mapOptional (" KeepEmptyLinesAtTheStartOfBlocks" ,
882- Style.KeepEmptyLines .AtStartOfBlock );
883872 IO.mapOptional (" IndentFunctionDeclarationAfterType" ,
884873 Style.IndentWrappedFunctionNames );
885874 IO.mapOptional (" IndentRequires" , Style.IndentRequiresClause );
@@ -1015,7 +1004,9 @@ template <> struct MappingTraits<FormatStyle> {
10151004 IO.mapOptional (" JavaImportGroups" , Style.JavaImportGroups );
10161005 IO.mapOptional (" JavaScriptQuotes" , Style.JavaScriptQuotes );
10171006 IO.mapOptional (" JavaScriptWrapImports" , Style.JavaScriptWrapImports );
1018- IO.mapOptional (" KeepEmptyLines" , Style.KeepEmptyLines );
1007+ IO.mapOptional (" KeepEmptyLinesAtTheStartOfBlocks" ,
1008+ Style.KeepEmptyLinesAtTheStartOfBlocks );
1009+ IO.mapOptional (" KeepEmptyLinesAtEOF" , Style.KeepEmptyLinesAtEOF );
10191010 IO.mapOptional (" LambdaBodyIndentation" , Style.LambdaBodyIndentation );
10201011 IO.mapOptional (" LineEnding" , Style.LineEnding );
10211012 IO.mapOptional (" MacroBlockBegin" , Style.MacroBlockBegin );
@@ -1526,11 +1517,8 @@ FormatStyle getLLVMStyle(FormatStyle::LanguageKind Language) {
15261517 /* Hex=*/ 0 , /* HexMinDigits=*/ 0 };
15271518 LLVMStyle.JavaScriptQuotes = FormatStyle::JSQS_Leave;
15281519 LLVMStyle.JavaScriptWrapImports = true ;
1529- LLVMStyle.KeepEmptyLines = {
1530- /* AtEndOfFile=*/ false ,
1531- /* AtStartOfBlock=*/ true ,
1532- /* AtStartOfFile=*/ true ,
1533- };
1520+ LLVMStyle.KeepEmptyLinesAtEOF = false ;
1521+ LLVMStyle.KeepEmptyLinesAtTheStartOfBlocks = true ;
15341522 LLVMStyle.LambdaBodyIndentation = FormatStyle::LBI_Signature;
15351523 LLVMStyle.Language = Language;
15361524 LLVMStyle.LineEnding = FormatStyle::LE_DeriveLF;
@@ -1653,7 +1641,7 @@ FormatStyle getGoogleStyle(FormatStyle::LanguageKind Language) {
16531641 {" .*" , 3 , 0 , false }};
16541642 GoogleStyle.IncludeStyle .IncludeIsMainRegex = " ([-_](test|unittest))?$" ;
16551643 GoogleStyle.IndentCaseLabels = true ;
1656- GoogleStyle.KeepEmptyLines . AtStartOfBlock = false ;
1644+ GoogleStyle.KeepEmptyLinesAtTheStartOfBlocks = false ;
16571645 GoogleStyle.ObjCBinPackProtocolList = FormatStyle::BPS_Never;
16581646 GoogleStyle.ObjCSpaceAfterProperty = false ;
16591647 GoogleStyle.ObjCSpaceBeforeProtocolList = true ;
0 commit comments