Legitimate uses of IIFEs?
ultcombo at gmail.com
Sat Dec 19 22:46:26 UTC 2015
On Sat, Dec 19, 2015 at 8:10 PM, <bread at mailed.me.uk> wrote:
> I believe await* has gone from the spec. The correct form would be (at the
True, I guess `await*` never made it to the proposal's formal text. It
still worked in Babel the last time I checked, though. FWIW, `await* `
would desugar to `await Promise.all()`.
> The mistake in Dimitry's example is that the async body was not resolved,
> not that anonymous async functions are in some way invalid - they're just
I'm not sure if I understand what you mean. I see that the outer
synchronous function would not await until the async function finished—i.e.
the outer function would return before the promise was resolved/settled—,
but that is still valid syntax—you could be running the async code for
side-effects that the caller context does not need to be aware of. You
mentioned this was invalid syntax, and that was the initial point I
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the es-discuss