Files
swift-mirror/validation-test/compiler_crashers_2_fixed/0106-rdar32700180.swift
Doug Gregor 01b45a245c Fold ConstraintSolver::coerceToRValue() into TypeChecker::coerceToRValue()
ConstraintSolver::coerceToRValue() missed a bunch of cases where we
should be dealing with lvalues, e.g., tuples, "try" expressions, and
so on. Extend TypeChecker::coerceToRValue() to deal with the
expression type side-tables and ConstraintSolver::coerceToRValue() to
it.

Fixes rdar://problem/32700180, a crash-on-valid.
2017-06-14 22:44:32 -07:00

20 lines
246 B
Swift

// RUN: %target-swift-frontend %s -emit-ir
// REQUIRES: objc_interop
func f(_: AnyObject?) { }
class C {
private var a: Int
private var b: Int
func test() {
f((self.a, self.b) as AnyObject)
}
init() {
a = 0
b = 0
}
}