Skip to content

Commit c9e2e8e

Browse files
committed
[Test] Add regression test.
For swiftlang#73525 .
1 parent f97134c commit c9e2e8e

File tree

1 file changed

+26
-0
lines changed

1 file changed

+26
-0
lines changed
Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,26 @@
1+
// RUN: %target-swift-frontend \
2+
// RUN: -emit-sil -verify \
3+
// RUN: %s \
4+
// RUN: -sil-verify-all
5+
6+
////////////////////////////////////////////////////////////////////////////////
7+
// https://github.com/apple/swift/issues/73525 {{
8+
////////////////////////////////////////////////////////////////////////////////
9+
protocol K {
10+
var a: Int { get }
11+
}
12+
13+
protocol B {
14+
init(k: any K)
15+
}
16+
17+
struct A: B {
18+
let a: Int
19+
20+
init(k: borrowing K) {
21+
self.a = k.a
22+
}
23+
}
24+
////////////////////////////////////////////////////////////////////////////////
25+
// https://github.com/apple/swift/issues/73525 }}
26+
////////////////////////////////////////////////////////////////////////////////

0 commit comments

Comments
 (0)