File tree Expand file tree Collapse file tree 1 file changed +7
-2
lines changed Expand file tree Collapse file tree 1 file changed +7
-2
lines changed Original file line number Diff line number Diff line change @@ -117,8 +117,11 @@ unsigned TupleType::getNumScalarElements() const {
117
117
}
118
118
119
119
bool TupleType::containsPackExpansionType () const {
120
+ assert (!hasTypeVariable ());
120
121
for (auto elt : getElements ()) {
121
- if (elt.getType ()->is <PackExpansionType>())
122
+ auto eltTy = elt.getType ();
123
+ assert (!eltTy->hasTypeVariable ());
124
+ if (eltTy->is <PackExpansionType>())
122
125
return true ;
123
126
}
124
127
@@ -144,7 +147,9 @@ bool TupleType::isSingleUnlabeledPackExpansion() const {
144
147
145
148
bool AnyFunctionType::containsPackExpansionType (ArrayRef<Param> params) {
146
149
for (auto param : params) {
147
- if (param.getPlainType ()->is <PackExpansionType>())
150
+ auto paramTy = param.getPlainType ();
151
+ assert (!paramTy->hasTypeVariable ());
152
+ if (paramTy->is <PackExpansionType>())
148
153
return true ;
149
154
}
150
155
You can’t perform that action at this time.
0 commit comments