On Wed, Oct 9, 2019 at 12:08 AM Andrea Giammarchi
wrote:
> I don't know why this went in a completely unrelated direction so ... I'll
> try to explain again what is `await?` about.
Nah, we got it. Our complaint was still about the semantics.
> ```js
> const value = await? callback();
>
> // as
Hi!
First, experiences of this guy
https://medium.com/@bluepnume/intentionally-unleashing-zalgo-with-promises-ab3f63ead2fd
seem to refute the problematicity of zalgo.
Second, I actually have the use case of this pattern (though actually
it's not a use case for a new syntax). In Amber
I had a similar example in real-world code, but it was just to merge
sync and async into the same code path. I handled it by using
generators and basically running them myself:
https://github.com/isiahmeadows/mithril-node-render/blob/v2/index.js#L195-L206
In either case, I'm not sure it's worth
I don't know why this went in a completely unrelated direction so ... I'll
try to explain again what is `await?` about.
My first two examples show a relevant performance difference between the
async code and the sync one.
The async code though, has zero reasons to be async and so much slower.
4 matches
Mail list logo