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 some HoistableDeclaration parsing errors #2532

Closed
wants to merge 1 commit into from

Conversation

raskad
Copy link
Member

@raskad raskad commented Jan 15, 2023

This Pull Request hanges the following:

  • Add early errors for invalid yield and await usage in function parameters.
  • Add missing function types to hoistable ordering.
  • Do not attempt to parse async with a following line terminator as an async function.

@raskad raskad added bug Something isn't working parser Issues surrounding the parser labels Jan 15, 2023
@raskad raskad added this to the v0.17.0 milestone Jan 15, 2023
@github-actions
Copy link

Test262 conformance changes

Test result main count PR count difference
Total 94,205 94,205 0
Passed 70,616 70,624 +8
Ignored 18,622 18,622 0
Failed 4,967 4,959 -8
Panics 0 0 0
Conformance 74.96% 74.97% +0.01%
Fixed tests (8):
test/language/statements/generators/cptn-decl.js [strict mode] (previously Failed)
test/language/statements/generators/cptn-decl.js (previously Failed)
test/language/statements/generators/param-dflt-yield.js [strict mode] (previously Failed)
test/language/statements/generators/param-dflt-yield.js (previously Failed)
test/language/statements/async-function/cptn-decl.js [strict mode] (previously Failed)
test/language/statements/async-function/cptn-decl.js (previously Failed)
test/language/statements/async-function/syntax-declaration-no-line-terminator.js [strict mode] (previously Failed)
test/language/statements/async-function/syntax-declaration-no-line-terminator.js (previously Failed)

@codecov
Copy link

codecov bot commented Jan 15, 2023

Codecov Report

Merging #2532 (8e161ea) into main (f52d1d3) will decrease coverage by 0.00%.
The diff coverage is 55.35%.

@@            Coverage Diff             @@
##             main    #2532      +/-   ##
==========================================
- Coverage   50.16%   50.15%   -0.01%     
==========================================
  Files         377      377              
  Lines       37469    37506      +37     
==========================================
+ Hits        18795    18810      +15     
- Misses      18674    18696      +22     
Impacted Files Coverage Δ
boa_parser/src/parser/statement/expression/mod.rs 25.53% <0.00%> (-3.74%) ⬇️
.../src/parser/statement/declaration/hoistable/mod.rs 69.23% <60.00%> (-2.20%) ⬇️
boa_parser/src/parser/expression/primary/mod.rs 55.58% <75.00%> (+0.77%) ⬆️
boa_ast/src/statement_list.rs 92.15% <100.00%> (-0.16%) ⬇️
...t/declaration/hoistable/async_function_decl/mod.rs 91.66% <100.00%> (+0.49%) ⬆️
.../declaration/hoistable/async_generator_decl/mod.rs 92.30% <100.00%> (+0.87%) ⬆️
...tement/declaration/hoistable/generator_decl/mod.rs 89.65% <100.00%> (+0.76%) ⬆️
boa_parser/src/parser/statement/mod.rs 66.75% <100.00%> (+0.70%) ⬆️
boa_engine/src/vm/code_block.rs 32.22% <0.00%> (-1.25%) ⬇️
boa_engine/src/vm/mod.rs 48.71% <0.00%> (-1.03%) ⬇️
... and 2 more

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

@jedel1043 jedel1043 left a comment

Choose a reason for hiding this comment

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

Nice fix!

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.

Looks good to me!

@jedel1043
Copy link
Member

bors r+

bors bot pushed a commit that referenced this pull request Jan 20, 2023
This Pull Request hanges the following:

- Add early errors for invalid `yield` and `await` usage in function parameters.
- Add missing function types to hoistable ordering.
- Do not attempt to parse `async` with a following line terminator as an async function.
@bors
Copy link

bors bot commented Jan 20, 2023

Pull request successfully merged into main.

Build succeeded:

@bors bors bot changed the title Fix some HoistableDeclaration parsing errors [Merged by Bors] - Fix some HoistableDeclaration parsing errors Jan 20, 2023
@bors bors bot closed this Jan 20, 2023
@bors bors bot deleted the fix-hoistable-parsing branch January 20, 2023 16:27
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working parser Issues surrounding the parser
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants