-
-
Notifications
You must be signed in to change notification settings - Fork 727
refactor(linter): duplicate RawTransferMetadata in oxc_linter crate
#12382
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
graphite-app
merged 1 commit into
main
from
07-17-refactor_linter_duplicate_rawtransfermetadata_in_oxc_linter_crate
Jul 18, 2025
Merged
refactor(linter): duplicate RawTransferMetadata in oxc_linter crate
#12382
graphite-app
merged 1 commit into
main
from
07-17-refactor_linter_duplicate_rawtransfermetadata_in_oxc_linter_crate
Jul 18, 2025
+366
−268
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This was referenced Jul 18, 2025
Member
Author
CodSpeed Instrumentation Performance ReportMerging #12382 will not alter performanceComparing Summary
|
This was referenced Jul 18, 2025
Contributor
Merge activity
|
…te (#12382) `RawTransferMetadata` is used to store basic info about the data in the buffer which is used on JS side to locate `Program` in the buffer etc. This struct lives in `napi/parser` crate but we're going to need it in `napi/oxlint2` too. So make a 2nd copy of it in `napi/oxlint2` and use `oxc_ast_tools` to enforce that the 2 copies are identical. This is a bit of a hack, but it doesn't seem worthwhile creating a new crate just to hold this one struct, and it doesn't really fit in `oxc_allocator`, or any of our other existing crates.
90fb884 to
b0db2d7
Compare
8e04804 to
5e3b415
Compare
Base automatically changed from
07-17-feat_allocator_fixedsizeallocator_store_flag_recording_if_owned_by_both_rust_and_js
to
main
July 18, 2025 09:13
This was referenced Jul 20, 2025
camc314
added a commit
that referenced
this pull request
Jul 22, 2025
## [1.8.0] - 2025-07-22 ### 🚀 Features - 6d2b549 napi/oxlint: Pass AST in buffer to JS (#12350) (overlookmotel) - 14f0159 linter/exhaustive-deps: Add auto-fixer (#12354) (Don Isaac) ### 🐛 Bug Fixes - 99e105f linter: Correct autofix in `unicorn/prefer-number-properties` for Infinity (#12445) (yefan) - 0b539e3 linter: `unicorn/catch-error-name` wasn't using the ignore property (#12446) (Parbez) - 05fba9b linter: Don't panic on `TSNonNullExpression` in `unicorn/prefer-array-find` (#12400) (Sysix) - 46e33d5 linter: Improve error handling in config file lookup (#12391) (camc314) - 4621872 linter: Parse second script block for `svelte` files (#12390) (Sysix) - fbe7eb4 linter/filename-case: Fix default config when no config is provided (#12389) (camc314) - fea9df4 linter: Report errors with the correct severity for custom plugins (#12362) (camc314) - 652c038 linter: Mark correctly enabled default rules for `--rules` (#12163) (Sysix) - eadc359 linter: Correct source text for vue files having script attributes containig ">" char inside (#12375) (Sysix) - 54d143a linter/exhaustive-deps: More descriptive messages for always-rerender violations (#12336) (Don Isaac) - dac4db9 linter/exhaustive-deps: Better diagnostics for missing dependencies (#12337) (Don Isaac) - 119d23a linter/prefer-array-flat-map: Error for `.flat(1.0)` (#12360) (overlookmotel) ### 🚜 Refactor - 2d9291c linter/prefer-number-properties: Simplify fixer logic (#12451) (camc314) - c5dff1e linter, napi/parser: Add `source_len` field to `RawTransferMetadata` (#12383) (overlookmotel) - 5e3b415 linter: Duplicate `RawTransferMetadata` in `oxc_linter` crate (#12382) (overlookmotel) - 773fd88 linter: Pass `&Allocator` into `Linter::run_external_rules` (#12374) (overlookmotel) - b10ed11 linter: Make unwrap unconditional (#12371) (overlookmotel) - a0631d4 linter: Move running external rules into feature-gated function (#12370) (overlookmotel) - 4fc4e7c linter: Make feature gates for `oxlint2` feature consistent (#12369) (overlookmotel) - 50b1786 linter: Clarify usage of `Allocator` and `AllocatorGuard` (#12332) (overlookmotel) - 26d3a39 linter: Remove `ModuleContentOwner` abstraction (#12331) (overlookmotel) ### 📚 Documentation - 3c21d94 linter: Correct comment on `RawTransferMetadata2` type (#12428) (overlookmotel) Co-authored-by: camc314 <18101008+camc314@users.noreply.github.com>
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Labels
A-ast-tools
Area - AST tools
A-linter
Area - Linter
C-cleanup
Category - technical debt or refactoring. Solution not expected to change behavior
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.

RawTransferMetadatais used to store basic info about the data in the buffer which is used on JS side to locateProgramin the buffer etc.This struct lives in
napi/parsercrate but we're going to need it innapi/oxlint2too. So make a 2nd copy of it innapi/oxlint2and useoxc_ast_toolsto enforce that the 2 copies are identical.This is a bit of a hack, but it doesn't seem worthwhile creating a new crate just to hold this one struct, and it doesn't really fit in
oxc_allocator, or any of our other existing crates.