Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Merged by Bors] - Fix sync generator yield expressions #2838

Closed
wants to merge 1 commit into from

Conversation

raskad
Copy link
Member

@raskad raskad commented Apr 18, 2023

Depends on #2837.

This Pull Request changes the following:

  • Fix the remaining language/expressions/yield tests.
  • Align the sync generator execution more to the spec.

This breaks one async generator test. We can ignore that one as async generators are currently very broken. I will try to fix async generators next.

@raskad raskad added bug Something isn't working execution Issues or PRs related to code execution labels Apr 18, 2023
@raskad raskad added this to the v0.17.0 milestone Apr 18, 2023
@github-actions
Copy link

Test262 conformance changes

Test result main count PR count difference
Total 94,591 94,591 0
Passed 71,630 71,640 +10
Ignored 17,634 17,634 0
Failed 5,327 5,317 -10
Panics 0 0 0
Conformance 75.73% 75.74% +0.01%
Fixed tests (12):
test/language/expressions/yield/star-rhs-iter-nrml-res-done-no-value.js [strict mode] (previously Failed)
test/language/expressions/yield/star-rhs-iter-nrml-res-done-no-value.js (previously Failed)
test/language/expressions/yield/star-rhs-iter-rtrn-no-rtrn.js [strict mode] (previously Failed)
test/language/expressions/yield/star-rhs-iter-rtrn-no-rtrn.js (previously Failed)
test/language/expressions/yield/star-rhs-iter-rtrn-res-value-final.js [strict mode] (previously Failed)
test/language/expressions/yield/star-rhs-iter-rtrn-res-value-final.js (previously Failed)
test/language/expressions/yield/star-iterable.js [strict mode] (previously Failed)
test/language/expressions/yield/star-iterable.js (previously Failed)
test/language/expressions/yield/star-rhs-iter-rtrn-res-done-no-value.js [strict mode] (previously Failed)
test/language/expressions/yield/star-rhs-iter-rtrn-res-done-no-value.js (previously Failed)
test/language/expressions/yield/star-rhs-iter-thrw-res-done-no-value.js [strict mode] (previously Failed)
test/language/expressions/yield/star-rhs-iter-thrw-res-done-no-value.js (previously Failed)
Broken tests (2):
test/language/statements/async-generator/yield-star-normal-notdone-iter-value-throws.js [strict mode] (previously Passed)
test/language/statements/async-generator/yield-star-normal-notdone-iter-value-throws.js (previously Passed)

@codecov
Copy link

codecov bot commented Apr 18, 2023

Codecov Report

Merging #2838 (dadda0c) into main (20f4a82) will increase coverage by 0.00%.
The diff coverage is 5.66%.

@@           Coverage Diff           @@
##             main    #2838   +/-   ##
=======================================
  Coverage   51.39%   51.39%           
=======================================
  Files         417      417           
  Lines       41328    41328           
=======================================
+ Hits        21239    21241    +2     
+ Misses      20089    20087    -2     
Impacted Files Coverage Δ
boa_engine/src/builtins/generator/mod.rs 31.84% <0.00%> (-0.21%) ⬇️
boa_engine/src/vm/opcode/generator/mod.rs 25.00% <0.00%> (+0.86%) ⬆️
boa_engine/src/vm/opcode/generator/yield_stm.rs 100.00% <100.00%> (ø)

... and 1 file with indirect coverage changes

Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here.

Copy link
Member

@HalidOdat HalidOdat left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice catch! This looks good to me! :)

@nekevss
Copy link
Member

nekevss commented Apr 19, 2023

Nice work! I like the changes overall, any idea why yield-star-normal-notdone-iter-value-throws.js broke?

@raskad
Copy link
Member Author

raskad commented Apr 19, 2023

Nice work! I like the changes overall, any idea why yield-star-normal-notdone-iter-value-throws.js broke?

I did not look into it too much, because yield* in async generators is currently completely broken. But I think it's probably just the changes to where we create the iterator result objects.

I'm currently working on a fix for async generators and proper async generator yield*. My branch has 1000+ tests passing currently and I think I may be on a good way to actually fix all async generator tests.

Copy link
Member

@nekevss nekevss left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM 😄

@nekevss
Copy link
Member

nekevss commented Apr 20, 2023

bors r+

bors bot pushed a commit that referenced this pull request Apr 20, 2023
Depends on #2837.

This Pull Request changes the following:

- Fix the remaining `language/expressions/yield` tests.
- Align the sync generator execution more to the spec.

This breaks one async generator test. We can ignore that one as async generators are currently very broken. I will try to fix async generators next.
@bors
Copy link

bors bot commented Apr 20, 2023

Pull request successfully merged into main.

Build succeeded:

@bors bors bot changed the title Fix sync generator yield expressions [Merged by Bors] - Fix sync generator yield expressions Apr 20, 2023
@bors bors bot closed this Apr 20, 2023
@bors bors bot deleted the fix-sync-generator-yield branch April 20, 2023 00:45
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working execution Issues or PRs related to code execution
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants