jsdom / webidl2js

Auto-generate JS class structures for Web IDL specifications
MIT License
79 stars 30 forks source link

Implement async iterables #224

Closed domenic closed 4 years ago

domenic commented 4 years ago

This starts to implement async iterables, #215, by following the spec as much as posisble.

This is missing:

I would appreciate help here, especially on the former.

domenic commented 4 years ago

OK, this is ready for review. I've integration-tested it with https://github.com/whatwg/streams/pull/1035 so the generated code works. But the source code could still benefit from review, and maybe we could pretty up the generated code. And if anyone has better ideas than [WebIDL2JSHasReturnSteps], please let me know.

I put this on top of #225, but I don't think that's a strict dependency. I also tried to separate this out into semi-logical commits to show my progress and separate the parts I'm sure of from the parts I wasn't, but rebaselining the snapshot file is a pain, so that kind of stopped; it's probably best to just review the whole thing.

domenic commented 4 years ago

OK, this is ready for review. It continues to test well with the corresponding whatwg/streams PR.