Skip to content

Commit 297276b

Browse files
authored
Merge pull request #6137 from xedin/crasher-28282
[QoI] Add return after coercing to TupleElementExpr in ExprRewriter
2 parents ce9c6ff + f1be35c commit 297276b

File tree

2 files changed

+2
-1
lines changed

2 files changed

+2
-1
lines changed

lib/Sema/CSApply.cpp

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5469,6 +5469,7 @@ Expr *ExprRewriter::coerceToType(Expr *expr, Type toType,
54695469
expr->getLoc(),
54705470
fromTuple->getElementType(0));
54715471
expr->setImplicit(true);
5472+
return expr;
54725473
}
54735474
}
54745475

validation-test/compiler_crashers/28282-swift-constraints-solution-coercetotype.swift renamed to validation-test/compiler_crashers_fixed/28282-swift-constraints-solution-coercetotype.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,6 @@
55
// See https://swift.org/LICENSE.txt for license information
66
// See https://swift.org/CONTRIBUTORS.txt for the list of Swift project authors
77

8-
// RUN: not --crash %target-swift-frontend %s -typecheck
8+
// RUN: not %target-swift-frontend %s -typecheck
99
class a{let e=(T:{var f:a
1010
let _=(T:f

0 commit comments

Comments
 (0)