Error in try await URLSession.shared.data

I tried to compile the async/await on swift-5.5-DEVELOPMENT-SNAPSHOT-2021-05-30-a-ubuntu20.04 but get this error. Is async/await available on Linux?

url.swift: error: type of expression is ambiguous without more context let (data, response) = try await URLSession.shared.data(from: url) ~~~~^~~~~~~~~~~~~~~~~~~~~

The new Foundation APIs don't exist on Linux yet.

1 Like

Is this still the case? When will that change?

1 Like

I just tested it today with Swift 5.5.2 and those still don't seem to exist yet for Linux.