@@ -64,7 +64,7 @@ deriveBodyComparable_enum_noAssociatedValues_lt(AbstractFunctionDecl *ltDecl,
64
64
auto enumDecl = cast<EnumDecl>(aParam->getType ()->getAnyNominal ());
65
65
66
66
// Generate the conversion from the enums to integer indices.
67
- SmallVector<ASTNode, 6 > statements;
67
+ SmallVector<ASTNode, 8 > statements;
68
68
DeclRefExpr *aIndex = DerivedConformance::convertEnumToIndex (statements, parentDC, enumDecl,
69
69
aParam, ltDecl, " index_a" );
70
70
DeclRefExpr *bIndex = DerivedConformance::convertEnumToIndex (statements, parentDC, enumDecl,
@@ -123,7 +123,7 @@ deriveBodyComparable_enum_hasAssociatedValues_lt(AbstractFunctionDecl *ltDecl, v
123
123
Type enumType = aParam->getType ();
124
124
auto enumDecl = cast<EnumDecl>(aParam->getType ()->getAnyNominal ());
125
125
126
- SmallVector<ASTNode, 6 > statements;
126
+ SmallVector<ASTNode, 8 > statements;
127
127
SmallVector<ASTNode, 4 > cases;
128
128
unsigned elementCount = 0 ; // need this as `getAllElements` returns a generator
129
129
@@ -134,7 +134,7 @@ deriveBodyComparable_enum_hasAssociatedValues_lt(AbstractFunctionDecl *ltDecl, v
134
134
elementCount++;
135
135
136
136
// .<elt>(let l0, let l1, ...)
137
- SmallVector<VarDecl*, 3 > lhsPayloadVars;
137
+ SmallVector<VarDecl*, 4 > lhsPayloadVars;
138
138
auto lhsSubpattern = DerivedConformance::enumElementPayloadSubpattern (elt, ' l' , ltDecl,
139
139
lhsPayloadVars);
140
140
auto lhsElemPat = new (C) EnumElementPattern (TypeLoc::withoutLoc (enumType),
@@ -144,7 +144,7 @@ deriveBodyComparable_enum_hasAssociatedValues_lt(AbstractFunctionDecl *ltDecl, v
144
144
lhsElemPat->setImplicit ();
145
145
146
146
// .<elt>(let r0, let r1, ...)
147
- SmallVector<VarDecl*, 3 > rhsPayloadVars;
147
+ SmallVector<VarDecl*, 4 > rhsPayloadVars;
148
148
auto rhsSubpattern = DerivedConformance::enumElementPayloadSubpattern (elt, ' r' , ltDecl,
149
149
rhsPayloadVars);
150
150
auto rhsElemPat = new (C) EnumElementPattern (TypeLoc::withoutLoc (enumType),
@@ -182,7 +182,7 @@ deriveBodyComparable_enum_hasAssociatedValues_lt(AbstractFunctionDecl *ltDecl, v
182
182
// Generate a guard statement for each associated value in the payload,
183
183
// breaking out early if any pair is unequal. (same as Equatable synthesis.)
184
184
// the else statement performs the lexicographic comparison.
185
- SmallVector<ASTNode, 6 > statementsInCase;
185
+ SmallVector<ASTNode, 8 > statementsInCase;
186
186
for (size_t varIdx = 0 ; varIdx < lhsPayloadVars.size (); varIdx++) {
187
187
auto lhsVar = lhsPayloadVars[varIdx];
188
188
auto lhsExpr = new (C) DeclRefExpr (lhsVar, DeclNameLoc (),
0 commit comments