mirror of
https://github.com/apple/swift.git
synced 2025-12-14 20:36:38 +01:00
13 lines
301 B
Swift
13 lines
301 B
Swift
// Check that ASTScope lookup works for a construction found in GRDB's Row.swift
|
|
// RUN: %target-swift-frontend -typecheck %s
|
|
|
|
protocol P1 {}
|
|
protocol P2 {}
|
|
|
|
struct S<Value> {
|
|
// Next line is the problematic one, finding P2
|
|
subscript<Value: P1 & P2>(_ index: Int) -> Value? {
|
|
return nil
|
|
}
|
|
}
|