Merge pull request #85588 from swiftlang/jepa-main2

[test] Add tracking test for https://github.com/swiftlang/swift/issues/85587
This commit is contained in:
Anthony Latsis
2025-12-02 17:31:18 +00:00
committed by GitHub

View File

@@ -0,0 +1,21 @@
// RUN: %target-typecheck-verify-swift
// https://github.com/swiftlang/swift/issues/85587
do {
struct Mootex<T> {
func withLock<Result>(_: (T) -> Result) -> Result {}
}
func never() -> Never {}
struct Test {
let _i = Mootex<Int>()
var i: Int {
// expected-error@+1:10 {{failed to produce diagnostic for expression}}
_i.withLock { _ in
never()
}
}
}
}