Subject: | Compiletime detection of unsupported constructs |
The following cannot be supported at runtime, but currently aren't detected at compiletime. Perhaps they should be:
foreach our $var { await func() }
map { await func() } LIST
grep { await func() } LIST
At runtime, if they operate only on immediate futures then the fact they're nested inside constructs that can't be suspended/resumed from isn't detected.
This can lead to a false sense of correctness in e.g. unit tests, which are more likely to be working on entirely immediate futures.
--
Paul Evans