-
-
Notifications
You must be signed in to change notification settings - Fork 518
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(ast): use atom
for Directive
and Hashbang
#701
Conversation
Directive
and Hashbang
atom
for Directive
and Hashbang
b106d52
to
a641495
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
cargo fmt
failed :-(
Codecov ReportPatch coverage:
Additional details and impacted files@@ Coverage Diff @@
## main #701 +/- ##
=======================================
Coverage 89.52% 89.52%
=======================================
Files 205 205
Lines 42229 42229
=======================================
Hits 37804 37804
Misses 4425 4425
☔ View full report in Codecov by Sentry. |
No, it's not. It should be fixed in another PR(if you think this should be fixed), but that PR requires the changes in this PR.
Yes. Probably something like |
Thank you! |
Benchmark ResultsLinux
Windows
|
This PR contains the following updates: | Package | Type | Update | Change | |---|---|---|---| | [compact_str](https://redirect.github.com/ParkMyCar/compact_str) | workspace.dependencies | patch | `0.8.0` -> `0.8.1` | | [handlebars](https://redirect.github.com/sunng87/handlebars-rust) | workspace.dependencies | minor | `6.2.0` -> `6.3.0` | | [insta](https://insta.rs/) ([source](https://redirect.github.com/mitsuhiko/insta)) | workspace.dependencies | minor | `1.41.1` -> `1.42.0` | | [itertools](https://redirect.github.com/rust-itertools/itertools) | workspace.dependencies | minor | `0.13.0` -> `0.14.0` | | [petgraph](https://redirect.github.com/petgraph/petgraph) | workspace.dependencies | minor | `0.6.5` -> `0.7.0` | | [prettyplease](https://redirect.github.com/dtolnay/prettyplease) | workspace.dependencies | patch | `0.2.25` -> `0.2.27` | | [syn](https://redirect.github.com/dtolnay/syn) | workspace.dependencies | patch | `2.0.93` -> `2.0.95` | | [tempfile](https://stebalien.com/projects/tempfile-rs/) ([source](https://redirect.github.com/Stebalien/tempfile)) | workspace.dependencies | minor | `3.14.0` -> `3.15.0` | --- ### Release Notes <details> <summary>ParkMyCar/compact_str (compact_str)</summary> ### [`v0.8.1`](https://redirect.github.com/ParkMyCar/compact_str/compare/v0.8.0...v0.8.1) [Compare Source](https://redirect.github.com/ParkMyCar/compact_str/compare/v0.8.0...v0.8.1) </details> <details> <summary>sunng87/handlebars-rust (handlebars)</summary> ### [`v6.3.0`](https://redirect.github.com/sunng87/handlebars-rust/blob/HEAD/CHANGELOG.md#630---2025-01-05) [Compare Source](https://redirect.github.com/sunng87/handlebars-rust/compare/v6.2.0...v6.3.0) - \[Added] Builders for some non-exhaustive structs \[[#​688](https://redirect.github.com/sunng87/handlebars-rust/issues/688)] - \[Changed] `and` and `or` helper now accepts multiple parameters \[[#​687](https://redirect.github.com/sunng87/handlebars-rust/issues/687)] - \[Changed] MSRV is now 1.73 </details> <details> <summary>mitsuhiko/insta (insta)</summary> ### [`v1.42.0`](https://redirect.github.com/mitsuhiko/insta/blob/HEAD/CHANGELOG.md#1420) [Compare Source](https://redirect.github.com/mitsuhiko/insta/compare/1.41.1...1.42.0) - Text snapshots no longer contain `snapshot_type: text` in their metadata. For context, we originally added this in the prior release (1.41.0) to support binary snapshots, but some folks disliked the diff noise on any snapshot changes, and the maintainers' weighted votes favored reverting. I apologize that this will cause some additional churn for those who used `cargo test --force-update-snapshots` to update their snapshots to the 1.41 format; running this again with 1.42 will remove those metadata entries. To confirm: this doesn't affect whether snapshot tests pass or fail — the worst impact is some additional diffs in metadata. [#​690](https://redirect.github.com/mitsuhiko/insta/issues/690) - Pending snapshots are no longer removed throughout the workspace by `cargo-insta` before running tests. Instead, running a test will overwrite or remove its own pending snapshot. To remove all pending snapshots, use `cargo insta reject` or run tests with `--unreferenced=delete`. [#​651](https://redirect.github.com/mitsuhiko/insta/issues/651) - `insta::internals::SettingsBindDropGuard` (returned from `Settings::bind_to_scope`) no longer implements `Send`. This was incorrect and any tests relying on this behavior where not working properly. Fixes [#​694](https://redirect.github.com/mitsuhiko/insta/issues/694) in [#​695](https://redirect.github.com/mitsuhiko/insta/issues/695) by [@​jalil-salame](https://redirect.github.com/jalil-salame) </details> <details> <summary>rust-itertools/itertools (itertools)</summary> ### [`v0.14.0`](https://redirect.github.com/rust-itertools/itertools/blob/HEAD/CHANGELOG.md#0140) [Compare Source](https://redirect.github.com/rust-itertools/itertools/compare/v0.13.0...v0.14.0) ##### Breaking - Increased MSRV to 1.63.0 ([#​960](https://redirect.github.com/rust-itertools/itertools/issues/960)) - Removed generic parameter from `cons_tuples` ([#​988](https://redirect.github.com/rust-itertools/itertools/issues/988)) ##### Added - Added `array_combinations` ([#​991](https://redirect.github.com/rust-itertools/itertools/issues/991)) - Added `k_smallest_relaxed` and variants ([#​925](https://redirect.github.com/rust-itertools/itertools/issues/925)) - Added `next_array` and `collect_array` ([#​560](https://redirect.github.com/rust-itertools/itertools/issues/560)) - Implemented `DoubleEndedIterator` for `FilterOk` ([#​948](https://redirect.github.com/rust-itertools/itertools/issues/948)) - Implemented `DoubleEndedIterator` for `FilterMapOk` ([#​950](https://redirect.github.com/rust-itertools/itertools/issues/950)) ##### Changed - Allow `Q: ?Sized` in `Itertools::contains` ([#​971](https://redirect.github.com/rust-itertools/itertools/issues/971)) - Improved hygiene of `chain!` ([#​943](https://redirect.github.com/rust-itertools/itertools/issues/943)) - Improved `into_group_map_by` documentation ([#​1000](https://redirect.github.com/rust-itertools/itertools/issues/1000)) - Improved `tree_reduce` documentation ([#​955](https://redirect.github.com/rust-itertools/itertools/issues/955)) - Improved discoverability of `merge_join_by` ([#​966](https://redirect.github.com/rust-itertools/itertools/issues/966)) - Improved discoverability of `take_while_inclusive` ([#​972](https://redirect.github.com/rust-itertools/itertools/issues/972)) - Improved documentation of `find_or_last` and `find_or_first` ([#​984](https://redirect.github.com/rust-itertools/itertools/issues/984)) - Prevented exponentially large type sizes in `tuple_combinations` ([#​945](https://redirect.github.com/rust-itertools/itertools/issues/945)) - Added `track_caller` attr for `asser_equal` ([#​976](https://redirect.github.com/rust-itertools/itertools/issues/976)) ##### Notable Internal Changes - Fixed clippy lints ([#​956](https://redirect.github.com/rust-itertools/itertools/issues/956), [#​987](https://redirect.github.com/rust-itertools/itertools/issues/987), [#​1008](https://redirect.github.com/rust-itertools/itertools/issues/1008)) - Addressed warnings within doctests ([#​964](https://redirect.github.com/rust-itertools/itertools/issues/964)) - CI: Run most tests with miri ([#​961](https://redirect.github.com/rust-itertools/itertools/issues/961)) - CI: Speed up "cargo-semver-checks" action ([#​938](https://redirect.github.com/rust-itertools/itertools/issues/938)) - Changed an instance of `default_features` in `Cargo.toml` to `default-features` ([#​985](https://redirect.github.com/rust-itertools/itertools/issues/985)) </details> <details> <summary>petgraph/petgraph (petgraph)</summary> ### [`v0.7.0`](https://redirect.github.com/petgraph/petgraph/blob/HEAD/RELEASES.rst#Version-070-2024-12-31) [Compare Source](https://redirect.github.com/petgraph/petgraph/compare/[email protected]@v0.7.0) \========================== - Re-released version 0.6.6 with the correct version number, as it included a major update to an exposed crate (`#664`\_). ### [`v0.6.6`](https://redirect.github.com/petgraph/petgraph/blob/HEAD/RELEASES.rst#Version-066-2024-12-31---yanked) [Compare Source](https://redirect.github.com/petgraph/petgraph/compare/[email protected]@v0.6.6) \=================================== - Add graph6 format encoder and decoder (`#658`\_) - Dynamic Topological Sort algorithm support (`#675`\_) - Add `UndirectedAdaptor` (`#695`\_) - Add `LowerHex` and `UpperHex` implementations for `Dot` (`#687`\_) - Make `serde` support more complete (`#550`\_) - Process multiple edges in the Floyd-Warshall implementation (`#685`\_) - Update `fixedbitset` to 0.5.7 (`#664`\_) - Fix `immediately_dominated_by` function called on root of graph returns root itself (`#670`\_) - Fix adjacency matrix for `Csr` and `List` (`#648`\_) - Fix clippy warnings (`#701`\_) - Add performance note to the `all_simple_paths` function documentation (`#693`\_) .. \_`#658`: [https://github.com/petgraph/petgraph/pull/658](https://redirect.github.com/petgraph/petgraph/pull/658) .. \_`#675`: [https://github.com/petgraph/petgraph/pull/675](https://redirect.github.com/petgraph/petgraph/pull/675) .. \_`#695`: [https://github.com/petgraph/petgraph/pull/695](https://redirect.github.com/petgraph/petgraph/pull/695) .. \_`#687`: [https://github.com/petgraph/petgraph/pull/687](https://redirect.github.com/petgraph/petgraph/pull/687) .. \_`#550`: [https://github.com/petgraph/petgraph/pull/550](https://redirect.github.com/petgraph/petgraph/pull/550) .. \_`#685`: [https://github.com/petgraph/petgraph/pull/685](https://redirect.github.com/petgraph/petgraph/pull/685) .. \_`#664`: [https://github.com/petgraph/petgraph/pull/664](https://redirect.github.com/petgraph/petgraph/pull/664) .. \_`#670`: [https://github.com/petgraph/petgraph/pull/670](https://redirect.github.com/petgraph/petgraph/pull/670) .. \_`#648`: [https://github.com/petgraph/petgraph/pull/648](https://redirect.github.com/petgraph/petgraph/pull/648) .. \_`#701`: [https://github.com/petgraph/petgraph/pull/701](https://redirect.github.com/petgraph/petgraph/pull/701) .. \_`#693`: [https://github.com/petgraph/petgraph/pull/693](https://redirect.github.com/petgraph/petgraph/pull/693) </details> <details> <summary>dtolnay/prettyplease (prettyplease)</summary> ### [`v0.2.27`](https://redirect.github.com/dtolnay/prettyplease/releases/tag/0.2.27) [Compare Source](https://redirect.github.com/dtolnay/prettyplease/compare/0.2.26...0.2.27) - Avoid trailing '.' on non-macro float literals ([#​89](https://redirect.github.com/dtolnay/prettyplease/issues/89)) ### [`v0.2.26`](https://redirect.github.com/dtolnay/prettyplease/releases/tag/0.2.26) [Compare Source](https://redirect.github.com/dtolnay/prettyplease/compare/0.2.25...0.2.26) - Synthesize parentheses for precedence ([#​88](https://redirect.github.com/dtolnay/prettyplease/issues/88)) </details> <details> <summary>dtolnay/syn (syn)</summary> ### [`v2.0.95`](https://redirect.github.com/dtolnay/syn/releases/tag/2.0.95) [Compare Source](https://redirect.github.com/dtolnay/syn/compare/2.0.94...2.0.95) - Fix parenthesization of struct literals in let-chains ([#​1832](https://redirect.github.com/dtolnay/syn/issues/1832)) ### [`v2.0.94`](https://redirect.github.com/dtolnay/syn/releases/tag/2.0.94) [Compare Source](https://redirect.github.com/dtolnay/syn/compare/2.0.93...2.0.94) - Expression precedence fixes ([#​1811](https://redirect.github.com/dtolnay/syn/issues/1811), [#​1812](https://redirect.github.com/dtolnay/syn/issues/1812), [#​1813](https://redirect.github.com/dtolnay/syn/issues/1813), [#​1814](https://redirect.github.com/dtolnay/syn/issues/1814), [#​1815](https://redirect.github.com/dtolnay/syn/issues/1815), [#​1816](https://redirect.github.com/dtolnay/syn/issues/1816), [#​1818](https://redirect.github.com/dtolnay/syn/issues/1818), [#​1819](https://redirect.github.com/dtolnay/syn/issues/1819), [#​1820](https://redirect.github.com/dtolnay/syn/issues/1820), [#​1825](https://redirect.github.com/dtolnay/syn/issues/1825), [#​1826](https://redirect.github.com/dtolnay/syn/issues/1826), [#​1827](https://redirect.github.com/dtolnay/syn/issues/1827), [#​1828](https://redirect.github.com/dtolnay/syn/issues/1828), [#​1829](https://redirect.github.com/dtolnay/syn/issues/1829), [#​1830](https://redirect.github.com/dtolnay/syn/issues/1830)) </details> <details> <summary>Stebalien/tempfile (tempfile)</summary> ### [`v3.15.0`](https://redirect.github.com/Stebalien/tempfile/blob/HEAD/CHANGELOG.md#3150) [Compare Source](https://redirect.github.com/Stebalien/tempfile/compare/v3.14.0...v3.15.0) Re-seed the per-thread RNG from system randomness when we repeatedly fail to create temporary files ([#​314](https://redirect.github.com/Stebalien/tempfile/issues/314)). This resolves a potential DoS vector ([#​178](https://redirect.github.com/Stebalien/tempfile/issues/178)) while avoiding `getrandom` in the common case where it's necessary. The feature is optional but enabled by default via the `getrandom` feature. For libc-free builds, you'll either need to disable this feature or opt-in to a different [`getrandom` backend](https://redirect.github.com/rust-random/getrandom?tab=readme-ov-file#opt-in-backends). </details> --- ### Configuration 📅 **Schedule**: Branch creation - "before 11am on monday" in timezone Asia/Shanghai, Automerge - "before 11am on monday" in timezone Asia/Shanghai. 🚦 **Automerge**: Enabled. ♻ **Rebasing**: Whenever PR is behind base branch, or you tick the rebase/retry checkbox. 👻 **Immortal**: This PR will be recreated if closed unmerged. Get [config help](https://redirect.github.com/renovatebot/renovate/discussions) if that's undesired. --- - [ ] <!-- rebase-check -->If you want to rebase/retry this PR, check this box --- This PR was generated by [Mend Renovate](https://mend.io/renovate/). View the [repository job log](https://developer.mend.io/github/oxc-project/oxc). <!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiIzOS44NS4wIiwidXBkYXRlZEluVmVyIjoiMzkuODUuMCIsInRhcmdldEJyYW5jaCI6Im1haW4iLCJsYWJlbHMiOltdfQ==-->
The main reason is using Atom to remove the lifetime for convenience.
And after removing the lifetime of these nodes, the
Program<'a>
doesn't rely on&'a source
anymore, which allows us to specify more accurate lifetimes.https://github.com/web-infra-dev/oxc/blob/f5b8690309c97f17e979dc232417006ffd75fbab/crates/oxc_parser/src/lib.rs#L135
https://github.com/web-infra-dev/oxc/blob/f5b8690309c97f17e979dc232417006ffd75fbab/crates/oxc_parser/src/lib.rs#L95