Files
swift-mirror/validation-test/compiler_crashers_2_fixed/0158-rdar40165062.swift
2018-05-17 01:49:20 -07:00

15 lines
277 B
Swift

// RUN: %target-typecheck-verify-swift
struct Foo<T, U> {
var value: U
func bar() -> Foo<T, U> {
return Foo(value) // expected-error {{generic parameter 'T' could not be inferred}}
}
}
extension Foo where T == U {
init(_ value: U) {
self.value = value
}
}