@@ -314,7 +314,7 @@ AlignTokenSequence(const FormatStyle &Style, unsigned Start, unsigned End,
314314
315315 for (unsigned i = Start; i != End; ++i) {
316316 auto &CurrentChange = Changes[i];
317- if (ScopeStack.size () != 0 &&
317+ if (! ScopeStack.empty () &&
318318 CurrentChange.indentAndNestingLevel () <
319319 Changes[ScopeStack.back ()].indentAndNestingLevel ()) {
320320 ScopeStack.pop_back ();
@@ -332,7 +332,7 @@ AlignTokenSequence(const FormatStyle &Style, unsigned Start, unsigned End,
332332 ScopeStack.push_back (i);
333333 }
334334
335- bool InsideNestedScope = ScopeStack.size () != 0 ;
335+ bool InsideNestedScope = ! ScopeStack.empty () ;
336336 bool ContinuedStringLiteral = i > Start &&
337337 CurrentChange.Tok ->is (tok::string_literal) &&
338338 Changes[i - 1 ].Tok ->is (tok::string_literal);
@@ -1048,7 +1048,7 @@ void WhitespaceManager::alignChainedConditionals() {
10481048 return C.Tok ->is (TT_ConditionalExpr) &&
10491049 ((C.Tok ->is (tok::question) && !C.NewlinesBefore ) ||
10501050 (C.Tok ->is (tok::colon) && C.Tok ->Next &&
1051- (C.Tok ->Next ->FakeLParens .size () == 0 ||
1051+ (C.Tok ->Next ->FakeLParens .empty () ||
10521052 C.Tok ->Next ->FakeLParens .back () != prec::Conditional)));
10531053 },
10541054 Changes, /* StartAt=*/ 0 );
@@ -1057,7 +1057,7 @@ void WhitespaceManager::alignChainedConditionals() {
10571057 FormatToken *Previous = C.Tok ->getPreviousNonComment ();
10581058 return C.NewlinesBefore && Previous && Previous->is (TT_ConditionalExpr) &&
10591059 (Previous->is (tok::colon) &&
1060- (C.Tok ->FakeLParens .size () == 0 ||
1060+ (C.Tok ->FakeLParens .empty () ||
10611061 C.Tok ->FakeLParens .back () != prec::Conditional));
10621062 };
10631063 // Ensure we keep alignment of wrapped operands with non-wrapped operands
0 commit comments