Skip to content

Commit 6a908ff

Browse files
committed
RequirementMachine: Don't allow PackExpansionType to sneak in
1 parent ddd662a commit 6a908ff

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

lib/AST/RequirementMachine/InterfaceType.cpp

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -559,6 +559,7 @@ RewriteContext::getRelativeSubstitutionSchemaFromType(
559559
ArrayRef<Term> substitutions,
560560
SmallVectorImpl<Term> &result) {
561561
assert(!concreteType->isTypeParameter() && "Must have a concrete type here");
562+
assert(!concreteType->is<PackExpansionType>());
562563

563564
if (!concreteType->hasTypeParameter())
564565
return concreteType;
@@ -604,6 +605,7 @@ RewriteContext::getSubstitutionSchemaFromType(CanType concreteType,
604605
const ProtocolDecl *proto,
605606
SmallVectorImpl<Term> &result) {
606607
assert(!concreteType->isTypeParameter() && "Must have a concrete type here");
608+
assert(!concreteType->is<PackExpansionType>());
607609

608610
if (!concreteType->hasTypeParameter())
609611
return concreteType;

0 commit comments

Comments
 (0)