Skip to content

Commit 485e4b0

Browse files
committed
Sema: Set TVO_CanBindToPack on type variables when generating constraints for PackExpansionExpr
1 parent 46e7822 commit 485e4b0

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

lib/Sema/CSGen.cpp

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2888,6 +2888,7 @@ namespace {
28882888

28892889
auto elementResultType = CS.getType(expr->getPatternExpr());
28902890
auto patternTy = CS.createTypeVariable(CS.getConstraintLocator(expr),
2891+
TVO_CanBindToPack |
28912892
TVO_CanBindToHole);
28922893
CS.addConstraint(ConstraintKind::PackElementOf, elementResultType,
28932894
patternTy, CS.getConstraintLocator(expr));

0 commit comments

Comments
 (0)