[Webkit-unassigned] [Bug 166695] [ESNext] Async iteration - Implement Async Generator

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Mon Mar 27 12:24:52 PDT 2017


https://bugs.webkit.org/show_bug.cgi?id=166695

--- Comment #47 from GSkachkov <gskachkov at gmail.com> ---
Comment on attachment 305431
  --> https://bugs.webkit.org/attachment.cgi?id=305431
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=305431&action=review

>>> Source/JavaScriptCore/builtins/AsyncGeneratorPrototype.js:77
>>> +    @asyncGeneratorResumeNext(generator);
>> 
>> I think it might be wise to make AsyncGeneratorResumeNext() behave as a loop, so that this recursion can be avoided when there are multiple yields and multiple requests in the queue, unless the spec is changed to get rid of the "evaluate the next item in queue after a yield immediately".
>> 
>> I'm sure I've said this in this bug before, but I see that we're still doing this recursively, and without PTC (though I'm not sure if PTC would help much in this case).
> 
> Thanks for quick feedback!
> 
> Yeah, I remember your comment https://bugs.webkit.org/show_bug.cgi?id=166695#c39, however I've tried to be close to spec as much as I can, so I implemented (p 6.4.3.3.11).
> But you are right, using loop is better in this place, so I'll try to switch to approach with loop.

I added loop into AsyncGeneratorResumeNext in new patch, hope it decrees recursion level. Could you please take a look if it make sense?

-- 
You are receiving this mail because:
You are the assignee for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.webkit.org/pipermail/webkit-unassigned/attachments/20170327/5f1d0583/attachment.html>


More information about the webkit-unassigned mailing list