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

feat(parser): Generate Serialize impls in ast_tools #6404

Merged
merged 35 commits into from
Oct 19, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
35 commits
Select commit Hold shift + click to select a range
49fa04a
Flatten Spans on regex AST nodes
ottomated Oct 9, 2024
7fc8653
Merge branch 'main' of https://github.com/ottomated/oxc
ottomated Oct 9, 2024
0515e43
create estree derive generator
ottomated Oct 9, 2024
3084869
Merge branch 'main' into manual-serialize
ottomated Oct 10, 2024
149e86e
begin parse #[serde(...)] attributes
ottomated Oct 10, 2024
9e2266b
generate_derive on EVERYTHING
ottomated Oct 10, 2024
a478dea
Finished
ottomated Oct 10, 2024
d989448
comment on ESTree trait
ottomated Oct 10, 2024
c0c960e
camelCase fields
ottomated Oct 10, 2024
efbdae6
remove comments
ottomated Oct 10, 2024
6462e6b
Merge branch 'main' into manual-serialize
ottomated Oct 10, 2024
fb02a4c
[autofix.ci] apply automated fixes
autofix-ci[bot] Oct 10, 2024
0b6732b
regenerate
ottomated Oct 10, 2024
c151467
Merge branch 'manual-serialize' of github.com:ottomated/oxc into manu…
ottomated Oct 10, 2024
6f9857e
Merge branch 'main' of https://github.com/oxc-project/oxc
ottomated Oct 11, 2024
69884df
begin tsify work
ottomated Oct 11, 2024
c859d86
handle some macro attributes
ottomated Oct 15, 2024
6246824
flatten fields
ottomated Oct 16, 2024
08c3731
Use wasm-bindgen for now
ottomated Oct 16, 2024
6db2a1c
no type on Span
ottomated Oct 17, 2024
bc66fa9
Merge branch 'main' of https://github.com/oxc-project/oxc
ottomated Oct 17, 2024
724e87b
Merge branch 'main' into manual-serialize
ottomated Oct 17, 2024
422e4dc
remove tsify from ast features
ottomated Oct 17, 2024
284d736
remove tsify dep from oxc_syntax
ottomated Oct 17, 2024
9e4332f
[autofix.ci] apply automated fixes
autofix-ci[bot] Oct 17, 2024
544dead
add CompactStr type
ottomated Oct 17, 2024
9e22bfe
fix: restore `features = ["derive"]` for `serde` in `oxc_ast` crate
overlookmotel Oct 19, 2024
5065bf3
style: restore `Cargo.toml` formatting
overlookmotel Oct 19, 2024
6a3fb3e
style: order `#[generate_derive]` after `#[derive]`
overlookmotel Oct 19, 2024
6db7396
style: fix indentation
overlookmotel Oct 19, 2024
566eb50
refactor: remove unused `TypescriptGenerator`
overlookmotel Oct 19, 2024
5f9d398
refactor: revert `GeneratorOutput`
overlookmotel Oct 19, 2024
4d71118
fix: correct comments
overlookmotel Oct 19, 2024
b78e854
fix: `type` field in TS defs on structs with `#[estree(custom_seriali…
overlookmotel Oct 19, 2024
7639831
fix: use `| null` to match other type defs for `FormalParameterRest`
overlookmotel Oct 19, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions .github/.generated_ast_watch_list.yml
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,10 @@ src:
- 'crates/oxc_ast/src/generated/derive_content_hash.rs'
- 'crates/oxc_regular_expression/src/generated/derive_content_hash.rs'
- 'crates/oxc_syntax/src/generated/derive_content_hash.rs'
- 'crates/oxc_ast/src/generated/derive_estree.rs'
- 'crates/oxc_regular_expression/src/generated/derive_estree.rs'
- 'crates/oxc_span/src/generated/derive_estree.rs'
- 'crates/oxc_syntax/src/generated/derive_estree.rs'
- 'crates/oxc_ast/src/generated/assert_layouts.rs'
- 'crates/oxc_ast/src/generated/ast_kind.rs'
- 'crates/oxc_ast/src/generated/ast_builder.rs'
Expand Down
12 changes: 8 additions & 4 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -85,6 +85,7 @@ oxc_codegen = { version = "0.31.0", path = "crates/oxc_codegen" }
oxc_data_structures = { version = "0.31.0", path = "crates/oxc_data_structures" }
oxc_diagnostics = { version = "0.31.0", path = "crates/oxc_diagnostics" }
oxc_ecmascript = { version = "0.31.0", path = "crates/oxc_ecmascript" }
oxc_estree = { version = "0.31.0", path = "crates/oxc_estree" }
oxc_index = { version = "0.31.0", path = "crates/oxc_index" }
oxc_isolated_declarations = { version = "0.31.0", path = "crates/oxc_isolated_declarations" }
oxc_mangler = { version = "0.31.0", path = "crates/oxc_mangler" }
Expand Down
4 changes: 1 addition & 3 deletions crates/oxc_ast/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@ doctest = false
[dependencies]
oxc_allocator = { workspace = true }
oxc_ast_macros = { workspace = true }
oxc_estree = { workspace = true }
oxc_regular_expression = { workspace = true }
oxc_span = { workspace = true }
oxc_syntax = { workspace = true }
Expand All @@ -30,16 +31,13 @@ num-bigint = { workspace = true }

serde = { workspace = true, features = ["derive"], optional = true }
serde_json = { workspace = true, optional = true }

tsify = { workspace = true, optional = true }
wasm-bindgen = { workspace = true, optional = true }

[features]
default = []
serialize = [
"dep:serde",
"dep:serde_json",
"dep:tsify",
"dep:wasm-bindgen",
"oxc_allocator/serialize",
"oxc_regular_expression/serialize",
Expand Down
Loading
Loading