mirror of
https://github.com/apple/swift.git
synced 2025-12-14 20:36:38 +01:00
20 lines
422 B
Swift
20 lines
422 B
Swift
// RUN: %target-swift-frontend -emit-ir %s
|
|
|
|
public struct LowerModel {
|
|
public typealias Index = Int
|
|
}
|
|
|
|
public protocol LowerChildA {
|
|
typealias Model = LowerModel
|
|
typealias ModelIndex = Model.Index
|
|
}
|
|
|
|
public protocol LowerChildB {
|
|
typealias Model = LowerModel
|
|
typealias ModelIndex = Model.Index
|
|
}
|
|
|
|
public protocol Parent: LowerChildA & LowerChildB {}
|
|
|
|
public func foo<T : Parent>(_: T, _: T.Model, _: T.ModelIndex) {}
|