鉴于 UUID 类型是一个结构,我认为它会是Sendable
. 但是编译器会生成一个警告:
struct S: Sendable {
var int: Int
var id: UUID // <-- Stored property 'id' of 'Sendable'-conforming struct 'S' has non-sendable type 'UUID'
}
鉴于 UUID 类型是一个结构,我认为它会是Sendable
. 但是编译器会生成一个警告:
struct S: Sendable {
var int: Int
var id: UUID // <-- Stored property 'id' of 'Sendable'-conforming struct 'S' has non-sendable type 'UUID'
}