Avatar
@swift-main @swift-5.5.3 -warn-concurrency @MainActor protocol P { } struct S: P {} Task { await MainActor.run { let p: P = S() let optionalP: P! = nil let s: S = S() Task { print(String(describing: p)) print(String(describing: optionalP)) print(String(describing: s)) } } } (edited)