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 panic on AST dump in JSON format #1959

Closed
wants to merge 1 commit into from
Closed

[Merged by Bors] - Fix panic on AST dump in JSON format #1959

wants to merge 1 commit into from

Conversation

kilotaras
Copy link
Contributor

Some of the fields in AST structs were both

  1. Arrays
  2. Marked as 'flatten'

This is illegal per serde docs (and doesn't really make sense).
The fix is to remove the attribute.

See: https://serde.rs/attr-flatten.html
Fixes: #1920

Some of the fields in AST structs were both

1. Arrays
2. Marked as 'flatten'

This is illegal per serde docs (and doesn't really make sense).
The fix is to remove the attribute.

See: https://serde.rs/attr-flatten.html
Fixes: #1920
@codecov
Copy link

codecov bot commented Mar 20, 2022

Codecov Report

Merging #1959 (484362b) into main (3b4708c) will not change coverage.
The diff coverage is n/a.

@@           Coverage Diff           @@
##             main    #1959   +/-   ##
=======================================
  Coverage   45.87%   45.87%           
=======================================
  Files         206      206           
  Lines       17102    17102           
=======================================
  Hits         7846     7846           
  Misses       9256     9256           
Impacted Files Coverage Δ
boa_engine/src/syntax/ast/node/array/mod.rs 33.33% <ø> (ø)
...a_engine/src/syntax/ast/node/statement_list/mod.rs 50.00% <ø> (ø)

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 3b4708c...484362b. Read the comment docs.

@jedel1043 jedel1043 changed the title Fixed dumping AST to Json not working Fix panic on AST dump in JSON format Mar 20, 2022
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.

Thank you! 😁

@raskad raskad added bug Something isn't working cli Issues and PRs related to the Boa command line interface. Internal Category for changelog labels Mar 20, 2022
@raskad raskad added this to the v0.15.0 milestone Mar 20, 2022
Copy link
Member

@raskad raskad 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, thank you for the contribution!

@raskad
Copy link
Member

raskad commented Mar 20, 2022

bors r+

bors bot pushed a commit that referenced this pull request Mar 20, 2022
Some of the fields in AST structs were both

1. Arrays
2. Marked as 'flatten'

This is illegal per serde docs (and doesn't really make sense).
The fix is to remove the attribute.

See: https://serde.rs/attr-flatten.html
Fixes: #1920

Co-authored-by: Taras Boiko <[email protected]>
@bors
Copy link

bors bot commented Mar 20, 2022

Pull request successfully merged into main.

Build succeeded:

@bors bors bot changed the title Fix panic on AST dump in JSON format [Merged by Bors] - Fix panic on AST dump in JSON format Mar 20, 2022
@bors bors bot closed this Mar 20, 2022
Razican pushed a commit that referenced this pull request Jun 8, 2022
Some of the fields in AST structs were both

1. Arrays
2. Marked as 'flatten'

This is illegal per serde docs (and doesn't really make sense).
The fix is to remove the attribute.

See: https://serde.rs/attr-flatten.html
Fixes: #1920

Co-authored-by: Taras Boiko <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working cli Issues and PRs related to the Boa command line interface. Internal Category for changelog
Projects
None yet
Development

Successfully merging this pull request may close these issues.

The cli parameter --dump-ast Json panics
3 participants