Open saagarjha opened 1 year ago
As far as my problems with this bug go, it's as simple as, "synchronous overloads are not available in an async context."
func scope() async {
func ƒ() async { }
await ƒ()
func ƒ() { }
ƒ() // ❌ Expression is 'async' but is not marked with 'await'
}
Description I have two functions; one that takes an async closure and one that doesn't. Then they invoke it, so the first is async itself and the second is not. I would expect that passing in an async closure or not would allow the compiler to select between them, but this does not seem the case.
Steps to reproduce
Expected behavior This should compile without issues
Environment
Additional context