Skip to content

Commit 34b45cb

Browse files
authored
Add a crash reproducer for rdar://85843677 (#40327)
1 parent 19f95eb commit 34b45cb

File tree

1 file changed

+15
-0
lines changed

1 file changed

+15
-0
lines changed
Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
// RUN: %target-typecheck-verify-swift
2+
3+
func callClosure(closure: () -> ()) {
4+
closure()
5+
}
6+
7+
callClosure {
8+
struct MyStruct {
9+
let s = "hello"
10+
lazy var sn: String = { s }()
11+
}
12+
13+
let s = MyStruct()
14+
print(s)
15+
}

0 commit comments

Comments
 (0)