mirror of
https://github.com/apple/swift.git
synced 2025-12-14 20:36:38 +01:00
Gracefully handle `LocatableType` types if they show up during
serialization. This is a temporary fix until we can remove
`TransitivelyConformsTo` constraint from the solver which is
the underlying cause of the issue (see https://github.com/swiftlang/swift/pull/82541).
Resolves: rdar://153461854
(cherry picked from commit 907606ef28)
33 lines
498 B
Swift
33 lines
498 B
Swift
// RUN: %target-swift-frontend(mock-sdk: %clang-importer-sdk) -emit-module %s -o %t
|
|
|
|
// REQUIRES: objc_interop
|
|
|
|
// rdar://153461854
|
|
|
|
import CoreGraphics
|
|
|
|
@resultBuilder
|
|
public struct Builder {
|
|
public static func buildBlock<T1>(_ t1: T1) -> (T1) {
|
|
return (t1)
|
|
}
|
|
}
|
|
|
|
protocol P {
|
|
}
|
|
|
|
struct Proxy: P {
|
|
let to: (CGFloat?) -> Void
|
|
}
|
|
|
|
struct Test {
|
|
@Builder var proxy: some P {
|
|
Proxy { point in
|
|
if let point {
|
|
let _: SIMD2<Double>? = SIMD2(point, point)
|
|
}
|
|
}
|
|
}
|
|
}
|
|
|