Skip to content

Commit 3c6567d

Browse files
committed
RequirementMachine: Don't crash if we cannot desugar a same-shape requirement
1 parent 09e8a17 commit 3c6567d

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

lib/AST/RequirementMachine/RequirementLowering.cpp

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -451,6 +451,7 @@ static void desugarSameShapeRequirement(
451451
!req.getSecondType()->isParameterPack()) {
452452
errors.push_back(RequirementError::forInvalidShapeRequirement(
453453
req, loc));
454+
return;
454455
}
455456

456457
result.emplace_back(RequirementKind::SameShape,

0 commit comments

Comments
 (0)