Missing await warning

Shouldn't there be a warning here?

func foo() async -> Int {

func bar() {
    Task {
        await foo() // no warning here for unused result

The result of the call to foo is the return value of the closure passed to the Task initializer. This initializer is annotated with @discardableResult.

1 Like

Indeed that was it, thank you.