mirror of
https://github.com/apple/swift.git
synced 2025-12-21 12:14:44 +01:00
I need to determine when top-level code contains an `await` to determine whether to make the source file an async context. This logic is perfectly encapsulated in the `FindInnerAsync` AST walker. Unfortunately, that is pushed down in Sema/ConstraintSystem and isn't available at the AST level. I've pulled it up into the brace statement so that I can use that as part of determining whether the source file is async in `DeclContext::isAsyncContext`. Unfortunately, statements don't have an AST context or evaluator or I would make this a request.
220 KiB
220 KiB