Subject: | String eval not handled (and misleading error message) |
Date: | Fri, 10 Aug 2018 11:43:48 +0100 |
To: | bug-Future-AsyncAwait [...] rt.cpan.org |
From: | ilmari [...] ilmari.org (Dagfinn Ilmari Mannsåker) |
Calling await inside a string eval doesn't work, and complains that it's
not inside an 'async sub', even if the string eval is:
$ perl -MFuture::AsyncAwait -wE 'async sub foo { 42 }' \
-e 'async sub bar { eval q{ await foo } or die $@ }' \
-e 'say bar->get'
Cannot 'await' outside of an 'async sub' at (eval 8) line 1.
- ilmari
--
- Twitter seems more influential [than blogs] in the 'gets reported in
the mainstream press' sense at least. - Matt McLeod
- That'd be because the content of a tweet is easier to condense down
to a mainstream media article. - Calle Dybedahl