Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 6 additions & 2 deletions test/ClangImporter/objc_async.swift
Original file line number Diff line number Diff line change
@@ -1,10 +1,12 @@
// RUN: %target-swift-frontend(mock-sdk: %clang-importer-sdk) -typecheck -I %S/Inputs/custom-modules -disable-availability-checking %s -verify -verify-additional-file %swift_src_root/test/Inputs/clang-importer-sdk/usr/include/ObjCConcurrency.h -warn-concurrency
// RUN: %target-swift-frontend(mock-sdk: %clang-importer-sdk) -typecheck -I %S/Inputs/custom-modules %s -verify -verify-additional-file %swift_src_root/test/Inputs/clang-importer-sdk/usr/include/ObjCConcurrency.h -warn-concurrency

// REQUIRES: objc_interop
// REQUIRES: concurrency
import Foundation
import ObjCConcurrency

if #available(SwiftStdlib 5.5, *) {

@MainActor func onlyOnMainActor() { }

func testSlowServer(slowServer: SlowServer) async throws {
Expand Down Expand Up @@ -120,7 +122,7 @@ func testSendableAttrs(
func takesSendable<T: Sendable>(_: T) {}

takesSendable(sendableClass) // no-error
takesSendable(nonSendableClass) // expected-FIXME-warning{{something about missing conformance}}
takesSendable(nonSendableClass) // expected-warning{{conformance of 'NonSendableClass' to 'Sendable' is unavailable}}

doSomethingConcurrently {
print(sendableClass) // no-error
Expand Down Expand Up @@ -213,3 +215,5 @@ func testMirrored(instance: ClassWithAsync) async {
}
}
}

} // SwiftStdlib 5.5