mirror of
https://github.com/apple/swift.git
synced 2025-12-14 20:36:38 +01:00
Merge pull request #85088 from slavapestov/test-issue-85084
Add regression test for fixed crasher
This commit is contained in:
19
test/Generics/issue-85084.swift
Normal file
19
test/Generics/issue-85084.swift
Normal file
@@ -0,0 +1,19 @@
|
||||
// RUN: %target-typecheck-verify-swift
|
||||
|
||||
protocol P1 {}
|
||||
|
||||
protocol P2 {
|
||||
associatedtype U
|
||||
}
|
||||
|
||||
protocol P3<T> {
|
||||
associatedtype T: P2
|
||||
}
|
||||
|
||||
struct S1<T: P2>: P3 where T.U: P1 {}
|
||||
|
||||
extension P3 where Self == S1<T> { // expected-error {{same-type constraint 'Self' == 'S1<Self.T>' is recursive}}
|
||||
static var a: S1<T> {
|
||||
S1<T>()
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user