Yeah, this is a fair concern. I think there are a few directions we could go in to make this transition less painful:
- Add a warning group for this diagnostic so that anybody building with
-warnings-as-errors
can opt out of this specific warning becoming an error. - Implement automatic migration tooling for enabling
AsyncCallerExecution
via [Pitch] Adoption tooling for upcoming features. This would effectively give people a way to opt into such a warning, instead of enabling a warning by default for everybody. - Surface implicit
@execution(caller)
and@execution(concurrent)
attributes in SourceKit's cursor info request, so the attributes are made explicit in editor inspection tools like QuickHelp.
I'm completely open to being convinced that a warning on every nonisolated async function is a bad idea, and that the other ideas above are sufficient for easing the transition to the new semantics. I'm sympathetic to the confusion the intermediate state could cause on what an async function means in a project, but there's a real risk of causing too much code churn and annoyance by introducing a warning.