Files
swift-mirror/test/decl/protocol/req/recursion.swift
Doug Gregor 03b1afce06 Don't revert the generic parameter list unless we're going to fill it in.
Fixes the crasher in rdar://problem/20000145 and 14 other compiler
crashers.

Swift SVN r29973
2015-07-08 13:13:17 +00:00

14 lines
323 B
Swift

// RUN: %target-parse-verify-swift
protocol SomeProtocol {
typealias T
}
extension SomeProtocol where T == Optional<T> { } // expected-error{{same-type constraint '`Self`.T' == 'Optional<`Self`.T>' is recursive}}
// rdar://problem/20000145
public protocol P {
typealias T
}
public struct S<A: P where A.T == S<A>> {}