Skip to content

Commit

Permalink
refactor(traverse): remove unnecessary imports (#5116)
Browse files Browse the repository at this point in the history
`Atom`, `SourceType` and `Span` from `oxc_span`, and operators from `oxc_syntax` are now re-exported from `oxc_ast` crate. Remove unnecessary `use` statements by importing them all from `oxc_ast`.
  • Loading branch information
overlookmotel committed Aug 23, 2024
1 parent c6590ae commit f771d7c
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 14 deletions.
8 changes: 1 addition & 7 deletions crates/oxc_traverse/scripts/lib/ancestor.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -113,13 +113,7 @@ export default function generateAncestorsCode(types) {
use oxc_allocator::{Box, Vec};
#[allow(clippy::wildcard_imports)]
use oxc_ast::ast::*;
use oxc_span::{Atom, SourceType, Span};
use oxc_syntax::{
operator::{
AssignmentOperator, BinaryOperator, LogicalOperator, UnaryOperator, UpdateOperator,
},
scope::ScopeId,
};
use oxc_syntax::scope::ScopeId;
/// Type of [\`Ancestor\`].
/// Used in [\`crate::TraverseCtx::retag_stack\`].
Expand Down
8 changes: 1 addition & 7 deletions crates/oxc_traverse/src/generated/ancestor.rs
Original file line number Diff line number Diff line change
Expand Up @@ -17,13 +17,7 @@ use memoffset::offset_of;
use oxc_allocator::{Box, Vec};
#[allow(clippy::wildcard_imports)]
use oxc_ast::ast::*;
use oxc_span::{Atom, SourceType, Span};
use oxc_syntax::{
operator::{
AssignmentOperator, BinaryOperator, LogicalOperator, UnaryOperator, UpdateOperator,
},
scope::ScopeId,
};
use oxc_syntax::scope::ScopeId;

/// Type of [`Ancestor`].
/// Used in [`crate::TraverseCtx::retag_stack`].
Expand Down

0 comments on commit f771d7c

Please sign in to comment.