Files
swift-mirror/test/Concurrency/Inputs/StrictModule.swift
Doug Gregor 94a2529609 Teach diagnostic about non-Sendable global lets to respect @preconcurrency
The diagnostic for non-Sendable globa/static `let` properties was checking
for a Sendable conformance without considering `@preconcurrency`. Emit
this diagnostic via a `@preconcurrency`-sensitive path.

Fixes rdar://121889248.
2024-05-16 11:24:22 -07:00

14 lines
296 B
Swift

public struct StrictStruct: Hashable {
public init() {}
}
open class StrictClass {
open func send(_ body: @Sendable () -> Void) {}
open func dontSend(_ body: () -> Void) {}
}
public protocol StrictProtocol {
func send(_ body: @Sendable () -> Void)
func dontSend(_ body: () -> Void)
}