From 423d54cb7409e2c88fc52c589e0d70261d877bde Mon Sep 17 00:00:00 2001 From: Boshen <1430279+Boshen@users.noreply.github.com> Date: Thu, 24 Oct 2024 13:57:18 +0000 Subject: [PATCH] refactor(rust): remove the annoying `clippy::wildcard_imports` (#6860) --- Cargo.toml | 2 ++ crates/oxc_ast/src/ast_builder_impl.rs | 1 - crates/oxc_ast/src/generated/assert_layouts.rs | 2 -- crates/oxc_ast/src/generated/ast_builder.rs | 1 - crates/oxc_ast/src/generated/ast_kind.rs | 1 - crates/oxc_ast/src/generated/derive_clone_in.rs | 5 ----- crates/oxc_ast/src/generated/derive_content_eq.rs | 5 ----- crates/oxc_ast/src/generated/derive_content_hash.rs | 5 ----- crates/oxc_ast/src/generated/derive_estree.rs | 4 ---- crates/oxc_ast/src/generated/derive_get_span.rs | 4 ---- crates/oxc_ast/src/generated/derive_get_span_mut.rs | 4 ---- crates/oxc_ast/src/generated/visit.rs | 1 - crates/oxc_ast/src/generated/visit_mut.rs | 1 - crates/oxc_ast/src/lib.rs | 1 - crates/oxc_codegen/src/gen.rs | 1 - .../src/constant_evaluation/is_litral_value.rs | 1 - crates/oxc_ecmascript/src/constant_evaluation/mod.rs | 1 - .../src/side_effects/check_for_state_change.rs | 1 - crates/oxc_ecmascript/src/to_number.rs | 1 - crates/oxc_ecmascript/src/to_string.rs | 1 - crates/oxc_index/src/idxslice.rs | 1 - crates/oxc_isolated_declarations/src/class.rs | 1 - crates/oxc_isolated_declarations/src/declaration.rs | 1 - crates/oxc_isolated_declarations/src/enum.rs | 1 - crates/oxc_isolated_declarations/src/function.rs | 1 - crates/oxc_isolated_declarations/src/lib.rs | 1 - crates/oxc_isolated_declarations/src/module.rs | 1 - crates/oxc_isolated_declarations/src/scope.rs | 2 -- crates/oxc_linter/src/ast_util.rs | 1 - .../src/rules/eslint/no_constant_binary_expression.rs | 1 - .../oxc_linter/src/rules/eslint/no_unused_vars/allowed.rs | 1 - .../src/rules/eslint/no_unused_vars/binding_pattern.rs | 1 - .../src/rules/eslint/no_unused_vars/fixers/fix_symbol.rs | 1 - crates/oxc_linter/src/rules/eslint/no_unused_vars/usage.rs | 1 - crates/oxc_minifier/src/lib.rs | 2 -- crates/oxc_module_lexer/src/lib.rs | 1 - crates/oxc_parser/src/lib.rs | 1 - crates/oxc_prettier/src/format/class.rs | 5 ++--- crates/oxc_prettier/src/lib.rs | 3 +-- crates/oxc_regular_expression/src/ast_impl/display.rs | 1 - crates/oxc_regular_expression/src/ast_impl/visit.rs | 6 +++--- .../oxc_regular_expression/src/generated/derive_clone_in.rs | 1 - .../src/generated/derive_content_eq.rs | 1 - .../src/generated/derive_content_hash.rs | 1 - .../oxc_regular_expression/src/generated/derive_estree.rs | 1 - crates/oxc_semantic/src/binder.rs | 1 - crates/oxc_semantic/src/builder.rs | 1 - crates/oxc_semantic/src/checker/javascript.rs | 1 - crates/oxc_semantic/src/checker/typescript.rs | 1 - crates/oxc_semantic/src/module_record/builder.rs | 2 -- crates/oxc_semantic/src/module_record/mod.rs | 1 - crates/oxc_span/src/generated/derive_estree.rs | 2 -- crates/oxc_syntax/src/generated/derive_clone_in.rs | 2 -- crates/oxc_syntax/src/generated/derive_content_eq.rs | 2 -- crates/oxc_syntax/src/generated/derive_content_hash.rs | 2 -- crates/oxc_syntax/src/generated/derive_estree.rs | 1 - crates/oxc_transformer/src/lib.rs | 2 -- crates/oxc_traverse/scripts/lib/ancestor.mjs | 1 - crates/oxc_traverse/scripts/lib/scopes_collector.mjs | 1 - crates/oxc_traverse/scripts/lib/traverse.mjs | 1 - crates/oxc_traverse/scripts/lib/walk.mjs | 1 - crates/oxc_traverse/src/ast_operations/gather_node_parts.rs | 1 - crates/oxc_traverse/src/context/scoping.rs | 1 - crates/oxc_traverse/src/generated/ancestor.rs | 1 - crates/oxc_traverse/src/generated/scopes_collector.rs | 1 - crates/oxc_traverse/src/generated/traverse.rs | 1 - crates/oxc_traverse/src/generated/walk.rs | 1 - tasks/ast_tools/src/derives/mod.rs | 1 - tasks/ast_tools/src/generators/assert_layouts.rs | 2 -- tasks/ast_tools/src/generators/ast_builder.rs | 1 - tasks/ast_tools/src/generators/ast_kind.rs | 1 - tasks/ast_tools/src/generators/visit.rs | 1 - tasks/transform_checker/src/lib.rs | 1 - 73 files changed, 8 insertions(+), 108 deletions(-) diff --git a/Cargo.toml b/Cargo.toml index acd98be228381..9fc445da80153 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -62,6 +62,8 @@ too_many_lines = "allow" # except nagging the programmer to add a `#[must_use]` after clippy has been run. # Having `#[must_use]` everywhere also hinders readability. must_use_candidate = "allow" +# Too annoying, we import by name anyway. +wildcard_imports = "allow" # used_underscore_binding= "allow" doc_markdown = "allow" # nursery diff --git a/crates/oxc_ast/src/ast_builder_impl.rs b/crates/oxc_ast/src/ast_builder_impl.rs index 47d98436579ce..84c7c06fce74a 100644 --- a/crates/oxc_ast/src/ast_builder_impl.rs +++ b/crates/oxc_ast/src/ast_builder_impl.rs @@ -12,7 +12,6 @@ use oxc_allocator::{Allocator, Box, FromIn, String, Vec}; use oxc_span::{Atom, GetSpan, Span}; use oxc_syntax::{number::NumberBase, operator::UnaryOperator}; -#[allow(clippy::wildcard_imports)] use crate::ast::*; use crate::AstBuilder; diff --git a/crates/oxc_ast/src/generated/assert_layouts.rs b/crates/oxc_ast/src/generated/assert_layouts.rs index df250fa8229ab..4ef53a7dc5b43 100644 --- a/crates/oxc_ast/src/generated/assert_layouts.rs +++ b/crates/oxc_ast/src/generated/assert_layouts.rs @@ -3,10 +3,8 @@ use std::mem::{align_of, offset_of, size_of}; -#[allow(clippy::wildcard_imports)] use crate::ast::*; -#[allow(clippy::wildcard_imports)] use oxc_regular_expression::ast::*; #[cfg(target_pointer_width = "64")] diff --git a/crates/oxc_ast/src/generated/ast_builder.rs b/crates/oxc_ast/src/generated/ast_builder.rs index e0a637bc52bab..2876b8d53ddf0 100644 --- a/crates/oxc_ast/src/generated/ast_builder.rs +++ b/crates/oxc_ast/src/generated/ast_builder.rs @@ -13,7 +13,6 @@ use std::cell::Cell; use oxc_allocator::{Allocator, Box, IntoIn, Vec}; use oxc_syntax::{reference::ReferenceId, scope::ScopeId, symbol::SymbolId}; -#[allow(clippy::wildcard_imports)] use crate::ast::*; /// AST builder for creating AST nodes diff --git a/crates/oxc_ast/src/generated/ast_kind.rs b/crates/oxc_ast/src/generated/ast_kind.rs index 3254547d4a9fb..5942241a45c15 100644 --- a/crates/oxc_ast/src/generated/ast_kind.rs +++ b/crates/oxc_ast/src/generated/ast_kind.rs @@ -6,7 +6,6 @@ use oxc_span::{GetSpan, Span}; -#[allow(clippy::wildcard_imports)] use crate::ast::*; #[derive(Debug, Clone, Copy)] diff --git a/crates/oxc_ast/src/generated/derive_clone_in.rs b/crates/oxc_ast/src/generated/derive_clone_in.rs index e60a6643d3b87..0fc290be9981a 100644 --- a/crates/oxc_ast/src/generated/derive_clone_in.rs +++ b/crates/oxc_ast/src/generated/derive_clone_in.rs @@ -5,19 +5,14 @@ use oxc_allocator::{Allocator, CloneIn}; -#[allow(clippy::wildcard_imports)] use crate::ast::comment::*; -#[allow(clippy::wildcard_imports)] use crate::ast::js::*; -#[allow(clippy::wildcard_imports)] use crate::ast::jsx::*; -#[allow(clippy::wildcard_imports)] use crate::ast::literal::*; -#[allow(clippy::wildcard_imports)] use crate::ast::ts::*; impl<'alloc> CloneIn<'alloc> for BooleanLiteral { diff --git a/crates/oxc_ast/src/generated/derive_content_eq.rs b/crates/oxc_ast/src/generated/derive_content_eq.rs index 2ea7edb1e6cdb..7ab94066e3660 100644 --- a/crates/oxc_ast/src/generated/derive_content_eq.rs +++ b/crates/oxc_ast/src/generated/derive_content_eq.rs @@ -5,19 +5,14 @@ use oxc_span::cmp::ContentEq; -#[allow(clippy::wildcard_imports)] use crate::ast::comment::*; -#[allow(clippy::wildcard_imports)] use crate::ast::js::*; -#[allow(clippy::wildcard_imports)] use crate::ast::jsx::*; -#[allow(clippy::wildcard_imports)] use crate::ast::literal::*; -#[allow(clippy::wildcard_imports)] use crate::ast::ts::*; impl ContentEq for BooleanLiteral { diff --git a/crates/oxc_ast/src/generated/derive_content_hash.rs b/crates/oxc_ast/src/generated/derive_content_hash.rs index e7f5d3196c4de..72bf9c441178f 100644 --- a/crates/oxc_ast/src/generated/derive_content_hash.rs +++ b/crates/oxc_ast/src/generated/derive_content_hash.rs @@ -7,19 +7,14 @@ use std::{hash::Hasher, mem::discriminant}; use oxc_span::hash::ContentHash; -#[allow(clippy::wildcard_imports)] use crate::ast::comment::*; -#[allow(clippy::wildcard_imports)] use crate::ast::js::*; -#[allow(clippy::wildcard_imports)] use crate::ast::jsx::*; -#[allow(clippy::wildcard_imports)] use crate::ast::literal::*; -#[allow(clippy::wildcard_imports)] use crate::ast::ts::*; impl ContentHash for BooleanLiteral { diff --git a/crates/oxc_ast/src/generated/derive_estree.rs b/crates/oxc_ast/src/generated/derive_estree.rs index 085ec0e2fc07c..c5e9ef443d820 100644 --- a/crates/oxc_ast/src/generated/derive_estree.rs +++ b/crates/oxc_ast/src/generated/derive_estree.rs @@ -5,16 +5,12 @@ use serde::{ser::SerializeMap, Serialize, Serializer}; -#[allow(clippy::wildcard_imports)] use crate::ast::js::*; -#[allow(clippy::wildcard_imports)] use crate::ast::jsx::*; -#[allow(clippy::wildcard_imports)] use crate::ast::literal::*; -#[allow(clippy::wildcard_imports)] use crate::ast::ts::*; impl Serialize for BooleanLiteral { diff --git a/crates/oxc_ast/src/generated/derive_get_span.rs b/crates/oxc_ast/src/generated/derive_get_span.rs index 55420066dc119..9f2de7d1294db 100644 --- a/crates/oxc_ast/src/generated/derive_get_span.rs +++ b/crates/oxc_ast/src/generated/derive_get_span.rs @@ -5,16 +5,12 @@ use oxc_span::{GetSpan, Span}; -#[allow(clippy::wildcard_imports)] use crate::ast::js::*; -#[allow(clippy::wildcard_imports)] use crate::ast::jsx::*; -#[allow(clippy::wildcard_imports)] use crate::ast::literal::*; -#[allow(clippy::wildcard_imports)] use crate::ast::ts::*; impl GetSpan for BooleanLiteral { diff --git a/crates/oxc_ast/src/generated/derive_get_span_mut.rs b/crates/oxc_ast/src/generated/derive_get_span_mut.rs index 0bd65ab7bac8a..38b0041f11ede 100644 --- a/crates/oxc_ast/src/generated/derive_get_span_mut.rs +++ b/crates/oxc_ast/src/generated/derive_get_span_mut.rs @@ -5,16 +5,12 @@ use oxc_span::{GetSpanMut, Span}; -#[allow(clippy::wildcard_imports)] use crate::ast::js::*; -#[allow(clippy::wildcard_imports)] use crate::ast::jsx::*; -#[allow(clippy::wildcard_imports)] use crate::ast::literal::*; -#[allow(clippy::wildcard_imports)] use crate::ast::ts::*; impl GetSpanMut for BooleanLiteral { diff --git a/crates/oxc_ast/src/generated/visit.rs b/crates/oxc_ast/src/generated/visit.rs index 6d7745cb066dd..91e923be85be8 100644 --- a/crates/oxc_ast/src/generated/visit.rs +++ b/crates/oxc_ast/src/generated/visit.rs @@ -21,7 +21,6 @@ use std::cell::Cell; use oxc_allocator::Vec; use oxc_syntax::scope::{ScopeFlags, ScopeId}; -#[allow(clippy::wildcard_imports)] use crate::ast::*; use crate::ast_kind::AstKind; diff --git a/crates/oxc_ast/src/generated/visit_mut.rs b/crates/oxc_ast/src/generated/visit_mut.rs index 71b2e38338526..c25b16321c3ef 100644 --- a/crates/oxc_ast/src/generated/visit_mut.rs +++ b/crates/oxc_ast/src/generated/visit_mut.rs @@ -21,7 +21,6 @@ use std::cell::Cell; use oxc_allocator::Vec; use oxc_syntax::scope::{ScopeFlags, ScopeId}; -#[allow(clippy::wildcard_imports)] use crate::ast::*; use crate::ast_kind::AstType; diff --git a/crates/oxc_ast/src/lib.rs b/crates/oxc_ast/src/lib.rs index 6299d92712911..27e138c6795bf 100644 --- a/crates/oxc_ast/src/lib.rs +++ b/crates/oxc_ast/src/lib.rs @@ -1,4 +1,3 @@ -#![allow(clippy::wildcard_imports)] // TODO: I'm not sure if it is a but or intentional but clippy needs this allowed both on this // module and the generated one. #![allow(clippy::self_named_module_files)] diff --git a/crates/oxc_codegen/src/gen.rs b/crates/oxc_codegen/src/gen.rs index b15abc4982270..975c2a03c6963 100644 --- a/crates/oxc_codegen/src/gen.rs +++ b/crates/oxc_codegen/src/gen.rs @@ -1,7 +1,6 @@ use std::ops::Not; use cow_utils::CowUtils; -#[allow(clippy::wildcard_imports)] use oxc_ast::ast::*; use oxc_span::GetSpan; use oxc_syntax::{ diff --git a/crates/oxc_ecmascript/src/constant_evaluation/is_litral_value.rs b/crates/oxc_ecmascript/src/constant_evaluation/is_litral_value.rs index 67ebe1459cb53..16157f4ed666a 100644 --- a/crates/oxc_ecmascript/src/constant_evaluation/is_litral_value.rs +++ b/crates/oxc_ecmascript/src/constant_evaluation/is_litral_value.rs @@ -1,4 +1,3 @@ -#[allow(clippy::wildcard_imports)] use oxc_ast::ast::*; /// Returns true if this is a literal value. We define a literal value as any node that evaluates diff --git a/crates/oxc_ecmascript/src/constant_evaluation/mod.rs b/crates/oxc_ecmascript/src/constant_evaluation/mod.rs index b7e59f02c1470..79c47522e3125 100644 --- a/crates/oxc_ecmascript/src/constant_evaluation/mod.rs +++ b/crates/oxc_ecmascript/src/constant_evaluation/mod.rs @@ -7,7 +7,6 @@ use std::{borrow::Cow, cmp::Ordering}; use num_bigint::BigInt; use num_traits::{One, Zero}; -#[allow(clippy::wildcard_imports)] use oxc_ast::ast::*; use crate::{side_effects::MayHaveSideEffects, ToBigInt, ToInt32, ToJsString}; diff --git a/crates/oxc_ecmascript/src/side_effects/check_for_state_change.rs b/crates/oxc_ecmascript/src/side_effects/check_for_state_change.rs index 374aa6300fa6b..8e9b1a0d4ffbd 100644 --- a/crates/oxc_ecmascript/src/side_effects/check_for_state_change.rs +++ b/crates/oxc_ecmascript/src/side_effects/check_for_state_change.rs @@ -1,4 +1,3 @@ -#[allow(clippy::wildcard_imports)] use oxc_ast::ast::*; use oxc_syntax::operator::UnaryOperator; diff --git a/crates/oxc_ecmascript/src/to_number.rs b/crates/oxc_ecmascript/src/to_number.rs index 6aa905a404f92..927f90693cb86 100644 --- a/crates/oxc_ecmascript/src/to_number.rs +++ b/crates/oxc_ecmascript/src/to_number.rs @@ -1,4 +1,3 @@ -#[allow(clippy::wildcard_imports)] use oxc_ast::ast::*; /// `ToNumber` diff --git a/crates/oxc_ecmascript/src/to_string.rs b/crates/oxc_ecmascript/src/to_string.rs index f48824974b999..76f317e720693 100644 --- a/crates/oxc_ecmascript/src/to_string.rs +++ b/crates/oxc_ecmascript/src/to_string.rs @@ -1,6 +1,5 @@ use std::borrow::Cow; -#[allow(clippy::wildcard_imports)] use oxc_ast::ast::*; use oxc_syntax::operator::UnaryOperator; diff --git a/crates/oxc_index/src/idxslice.rs b/crates/oxc_index/src/idxslice.rs index ab5f9d2c4e0a8..dd01f02ca6fa1 100644 --- a/crates/oxc_index/src/idxslice.rs +++ b/crates/oxc_index/src/idxslice.rs @@ -1,4 +1,3 @@ -#[allow(clippy::wildcard_imports)] use super::*; /// A slice that only accepts indices of a specific type. Note that the intended diff --git a/crates/oxc_isolated_declarations/src/class.rs b/crates/oxc_isolated_declarations/src/class.rs index 109a293b6e297..9218380f10d28 100644 --- a/crates/oxc_isolated_declarations/src/class.rs +++ b/crates/oxc_isolated_declarations/src/class.rs @@ -1,7 +1,6 @@ use std::borrow::Cow; use oxc_allocator::{Box, CloneIn}; -#[allow(clippy::wildcard_imports)] use oxc_ast::{ast::*, NONE}; use oxc_span::{GetSpan, SPAN}; use rustc_hash::FxHashMap; diff --git a/crates/oxc_isolated_declarations/src/declaration.rs b/crates/oxc_isolated_declarations/src/declaration.rs index 2c4d2eb49050d..c5ef8fcb842c8 100644 --- a/crates/oxc_isolated_declarations/src/declaration.rs +++ b/crates/oxc_isolated_declarations/src/declaration.rs @@ -3,7 +3,6 @@ use std::cell::Cell; use oxc_allocator::Box; use oxc_allocator::CloneIn; use oxc_allocator::Vec; -#[allow(clippy::wildcard_imports)] use oxc_ast::ast::*; use oxc_ast::visit::walk_mut::walk_ts_signatures; use oxc_ast::{Visit, VisitMut}; diff --git a/crates/oxc_isolated_declarations/src/enum.rs b/crates/oxc_isolated_declarations/src/enum.rs index 8ff44ed085319..fee3d84c910a9 100644 --- a/crates/oxc_isolated_declarations/src/enum.rs +++ b/crates/oxc_isolated_declarations/src/enum.rs @@ -1,6 +1,5 @@ use rustc_hash::FxHashMap; -#[allow(clippy::wildcard_imports)] use oxc_ast::ast::*; use oxc_ecmascript::ToInt32; use oxc_span::{Atom, GetSpan, SPAN}; diff --git a/crates/oxc_isolated_declarations/src/function.rs b/crates/oxc_isolated_declarations/src/function.rs index d506ef367693d..bfcf00beced15 100644 --- a/crates/oxc_isolated_declarations/src/function.rs +++ b/crates/oxc_isolated_declarations/src/function.rs @@ -1,5 +1,4 @@ use oxc_allocator::Box; -#[allow(clippy::wildcard_imports)] use oxc_ast::{ast::*, NONE}; use oxc_span::{Span, SPAN}; diff --git a/crates/oxc_isolated_declarations/src/lib.rs b/crates/oxc_isolated_declarations/src/lib.rs index 06a7ea70e3ec0..cc703f91b15ca 100644 --- a/crates/oxc_isolated_declarations/src/lib.rs +++ b/crates/oxc_isolated_declarations/src/lib.rs @@ -23,7 +23,6 @@ use std::{cell::RefCell, mem}; use diagnostics::function_with_assigning_properties; use oxc_allocator::{Allocator, CloneIn}; -#[allow(clippy::wildcard_imports)] use oxc_ast::{ast::*, AstBuilder, Visit, NONE}; use oxc_diagnostics::OxcDiagnostic; use oxc_span::{Atom, GetSpan, SourceType, SPAN}; diff --git a/crates/oxc_isolated_declarations/src/module.rs b/crates/oxc_isolated_declarations/src/module.rs index a048f6fe6d459..5746c37dc6c96 100644 --- a/crates/oxc_isolated_declarations/src/module.rs +++ b/crates/oxc_isolated_declarations/src/module.rs @@ -1,6 +1,5 @@ use oxc_allocator::Box; use oxc_allocator::Vec; -#[allow(clippy::wildcard_imports)] use oxc_ast::ast::*; use oxc_span::{Atom, GetSpan, SPAN}; diff --git a/crates/oxc_isolated_declarations/src/scope.rs b/crates/oxc_isolated_declarations/src/scope.rs index cc7dde16896f9..51e5cf0dd03fd 100644 --- a/crates/oxc_isolated_declarations/src/scope.rs +++ b/crates/oxc_isolated_declarations/src/scope.rs @@ -3,9 +3,7 @@ use std::cell::Cell; use bitflags::bitflags; use rustc_hash::FxHashMap; -#[allow(clippy::wildcard_imports)] use oxc_ast::ast::*; -#[allow(clippy::wildcard_imports)] use oxc_ast::{visit::walk::*, Visit}; use oxc_span::Atom; use oxc_syntax::scope::{ScopeFlags, ScopeId}; diff --git a/crates/oxc_linter/src/ast_util.rs b/crates/oxc_linter/src/ast_util.rs index 14ecb35908948..66321cb364531 100644 --- a/crates/oxc_linter/src/ast_util.rs +++ b/crates/oxc_linter/src/ast_util.rs @@ -4,7 +4,6 @@ use oxc_semantic::{AstNode, IsGlobalReference, NodeId, Semantic, SymbolId}; use oxc_span::{GetSpan, Span}; use oxc_syntax::operator::{AssignmentOperator, BinaryOperator, LogicalOperator, UnaryOperator}; -#[allow(clippy::wildcard_imports)] use oxc_ast::ast::*; /// Test if an AST node is a boolean value that never changes. Specifically we diff --git a/crates/oxc_linter/src/rules/eslint/no_constant_binary_expression.rs b/crates/oxc_linter/src/rules/eslint/no_constant_binary_expression.rs index 4eb87cc8ec542..db8f5f22c9ad6 100644 --- a/crates/oxc_linter/src/rules/eslint/no_constant_binary_expression.rs +++ b/crates/oxc_linter/src/rules/eslint/no_constant_binary_expression.rs @@ -1,4 +1,3 @@ -#[allow(clippy::wildcard_imports)] use oxc_ast::{ast::*, AstKind}; use oxc_diagnostics::OxcDiagnostic; use oxc_macros::declare_oxc_lint; diff --git a/crates/oxc_linter/src/rules/eslint/no_unused_vars/allowed.rs b/crates/oxc_linter/src/rules/eslint/no_unused_vars/allowed.rs index fa66712085d63..0f72c80bf286a 100644 --- a/crates/oxc_linter/src/rules/eslint/no_unused_vars/allowed.rs +++ b/crates/oxc_linter/src/rules/eslint/no_unused_vars/allowed.rs @@ -1,6 +1,5 @@ //! This module checks if an unused variable is allowed. Note that this does not //! consider variables ignored by name pattern, but by where they are declared. -#[allow(clippy::wildcard_imports)] use oxc_ast::{ast::*, AstKind}; use oxc_semantic::{AstNode, NodeId, Semantic}; use oxc_span::GetSpan; diff --git a/crates/oxc_linter/src/rules/eslint/no_unused_vars/binding_pattern.rs b/crates/oxc_linter/src/rules/eslint/no_unused_vars/binding_pattern.rs index 73b2e26d0e9a5..3f9157eb8bdd5 100644 --- a/crates/oxc_linter/src/rules/eslint/no_unused_vars/binding_pattern.rs +++ b/crates/oxc_linter/src/rules/eslint/no_unused_vars/binding_pattern.rs @@ -1,4 +1,3 @@ -#[allow(clippy::wildcard_imports)] use oxc_ast::ast::*; use oxc_semantic::{Semantic, SymbolId}; diff --git a/crates/oxc_linter/src/rules/eslint/no_unused_vars/fixers/fix_symbol.rs b/crates/oxc_linter/src/rules/eslint/no_unused_vars/fixers/fix_symbol.rs index b37af6435788f..332f51c86c7d1 100644 --- a/crates/oxc_linter/src/rules/eslint/no_unused_vars/fixers/fix_symbol.rs +++ b/crates/oxc_linter/src/rules/eslint/no_unused_vars/fixers/fix_symbol.rs @@ -1,4 +1,3 @@ -#[allow(clippy::wildcard_imports)] use oxc_ast::{ast::*, AstKind}; use oxc_span::{CompactStr, GetSpan, Span}; diff --git a/crates/oxc_linter/src/rules/eslint/no_unused_vars/usage.rs b/crates/oxc_linter/src/rules/eslint/no_unused_vars/usage.rs index 10203c55a44a5..46dc3bca48fdc 100644 --- a/crates/oxc_linter/src/rules/eslint/no_unused_vars/usage.rs +++ b/crates/oxc_linter/src/rules/eslint/no_unused_vars/usage.rs @@ -1,7 +1,6 @@ //! This module contains logic for checking if any [`Reference`]s to a //! [`Symbol`] are considered a usage. -#[allow(clippy::wildcard_imports)] use oxc_ast::{ast::*, AstKind}; use oxc_semantic::{AstNode, NodeId, Reference, ScopeId, SymbolFlags, SymbolId}; use oxc_span::{GetSpan, Span}; diff --git a/crates/oxc_minifier/src/lib.rs b/crates/oxc_minifier/src/lib.rs index da7841a567aed..d1d4ca961dc13 100644 --- a/crates/oxc_minifier/src/lib.rs +++ b/crates/oxc_minifier/src/lib.rs @@ -1,5 +1,3 @@ -#![allow(clippy::wildcard_imports)] - //! ECMAScript Minifier mod ast_passes; diff --git a/crates/oxc_module_lexer/src/lib.rs b/crates/oxc_module_lexer/src/lib.rs index c02bfda2667ef..c10cbbe41a6e6 100644 --- a/crates/oxc_module_lexer/src/lib.rs +++ b/crates/oxc_module_lexer/src/lib.rs @@ -6,7 +6,6 @@ use oxc_ast::visit::walk::{ walk_export_all_declaration, walk_export_named_declaration, walk_import_declaration, walk_import_expression, walk_meta_property, walk_module_declaration, walk_statement, }; -#[allow(clippy::wildcard_imports)] use oxc_ast::{ast::*, Visit}; use oxc_ecmascript::BoundNames; use oxc_span::{Atom, GetSpan}; diff --git a/crates/oxc_parser/src/lib.rs b/crates/oxc_parser/src/lib.rs index 08163b37d6e71..8a8b705681d9a 100644 --- a/crates/oxc_parser/src/lib.rs +++ b/crates/oxc_parser/src/lib.rs @@ -64,7 +64,6 @@ //! //! See [full linter example](https://github.com/Boshen/oxc/blob/ab2ef4f89ba3ca50c68abb2ca43e36b7793f3673/crates/oxc_linter/examples/linter.rs#L38-L39) -#![allow(clippy::wildcard_imports)] // allow for use `oxc_ast::ast::*` #![warn(missing_docs)] mod context; diff --git a/crates/oxc_prettier/src/format/class.rs b/crates/oxc_prettier/src/format/class.rs index de259f0ef4e56..35cd449b1d298 100644 --- a/crates/oxc_prettier/src/format/class.rs +++ b/crates/oxc_prettier/src/format/class.rs @@ -6,10 +6,9 @@ use oxc_span::GetSpan; use super::assignment::AssignmentLikeNode; use crate::{ array, - doc::{Doc, DocBuilder, Group, IfBreak, Line}, + doc::{Doc, DocBuilder, Group, IfBreak}, format::{assignment, Separator}, - group, hardline, if_break, indent, indent_if_break, line, softline, space, ss, Format, - Prettier, + group, hardline, indent, line, softline, space, ss, Format, Prettier, }; pub(super) fn print_class<'a>(p: &mut Prettier<'a>, class: &Class<'a>) -> Doc<'a> { diff --git a/crates/oxc_prettier/src/lib.rs b/crates/oxc_prettier/src/lib.rs index af18238df132a..d82ecfddf139f 100644 --- a/crates/oxc_prettier/src/lib.rs +++ b/crates/oxc_prettier/src/lib.rs @@ -1,9 +1,8 @@ +#![allow(unused, clippy::unused_self)] //! Prettier //! //! A port of -#![allow(unused, clippy::wildcard_imports, clippy::unused_self)] - mod binaryish; mod comments; mod doc; diff --git a/crates/oxc_regular_expression/src/ast_impl/display.rs b/crates/oxc_regular_expression/src/ast_impl/display.rs index e48f95136d906..b74a205f91a64 100644 --- a/crates/oxc_regular_expression/src/ast_impl/display.rs +++ b/crates/oxc_regular_expression/src/ast_impl/display.rs @@ -4,7 +4,6 @@ use std::{ iter::Peekable, }; -#[allow(clippy::wildcard_imports)] use crate::ast::*; use crate::surrogate_pair::{combine_surrogate_pair, is_lead_surrogate, is_trail_surrogate}; diff --git a/crates/oxc_regular_expression/src/ast_impl/visit.rs b/crates/oxc_regular_expression/src/ast_impl/visit.rs index 88b9ff4caf79a..7cf9ca0452676 100644 --- a/crates/oxc_regular_expression/src/ast_impl/visit.rs +++ b/crates/oxc_regular_expression/src/ast_impl/visit.rs @@ -1,7 +1,6 @@ // NOTE: For now, this file is implemented by hand for convenience. // But like `oxc_ast`, this should be generated by `tasks/ast_tools` in the future. -#![allow(unused_variables, clippy::wildcard_imports)] use oxc_span::{GetSpan, Span}; use walk::walk_pattern; @@ -68,9 +67,10 @@ impl<'a> GetSpan for RegExpAstKind<'a> { /// RegEx syntax tree traversal pub trait Visit<'a>: Sized { #[inline] - fn enter_node(&mut self, kind: RegExpAstKind<'a>) {} + fn enter_node(&mut self, _kind: RegExpAstKind<'a>) {} + #[inline] - fn leave_node(&mut self, kind: RegExpAstKind<'a>) {} + fn leave_node(&mut self, _kind: RegExpAstKind<'a>) {} #[inline] fn alloc(&self, t: &T) -> &'a T { diff --git a/crates/oxc_regular_expression/src/generated/derive_clone_in.rs b/crates/oxc_regular_expression/src/generated/derive_clone_in.rs index 9160d00b409a8..bc7c9c9f78858 100644 --- a/crates/oxc_regular_expression/src/generated/derive_clone_in.rs +++ b/crates/oxc_regular_expression/src/generated/derive_clone_in.rs @@ -5,7 +5,6 @@ use oxc_allocator::{Allocator, CloneIn}; -#[allow(clippy::wildcard_imports)] use crate::ast::*; impl<'old_alloc, 'new_alloc> CloneIn<'new_alloc> for Pattern<'old_alloc> { diff --git a/crates/oxc_regular_expression/src/generated/derive_content_eq.rs b/crates/oxc_regular_expression/src/generated/derive_content_eq.rs index bb8e4861f0b47..2455b7f13db5b 100644 --- a/crates/oxc_regular_expression/src/generated/derive_content_eq.rs +++ b/crates/oxc_regular_expression/src/generated/derive_content_eq.rs @@ -5,7 +5,6 @@ use oxc_span::cmp::ContentEq; -#[allow(clippy::wildcard_imports)] use crate::ast::*; impl<'a> ContentEq for Pattern<'a> { diff --git a/crates/oxc_regular_expression/src/generated/derive_content_hash.rs b/crates/oxc_regular_expression/src/generated/derive_content_hash.rs index 67219af7653a5..1631eb1470141 100644 --- a/crates/oxc_regular_expression/src/generated/derive_content_hash.rs +++ b/crates/oxc_regular_expression/src/generated/derive_content_hash.rs @@ -7,7 +7,6 @@ use std::{hash::Hasher, mem::discriminant}; use oxc_span::hash::ContentHash; -#[allow(clippy::wildcard_imports)] use crate::ast::*; impl<'a> ContentHash for Pattern<'a> { diff --git a/crates/oxc_regular_expression/src/generated/derive_estree.rs b/crates/oxc_regular_expression/src/generated/derive_estree.rs index 4303e708af996..958d426de43e0 100644 --- a/crates/oxc_regular_expression/src/generated/derive_estree.rs +++ b/crates/oxc_regular_expression/src/generated/derive_estree.rs @@ -5,7 +5,6 @@ use serde::{ser::SerializeMap, Serialize, Serializer}; -#[allow(clippy::wildcard_imports)] use crate::ast::*; impl<'a> Serialize for Pattern<'a> { diff --git a/crates/oxc_semantic/src/binder.rs b/crates/oxc_semantic/src/binder.rs index c6a72e5784926..750e3442688e7 100644 --- a/crates/oxc_semantic/src/binder.rs +++ b/crates/oxc_semantic/src/binder.rs @@ -2,7 +2,6 @@ use std::{borrow::Cow, ptr}; -#[allow(clippy::wildcard_imports)] use oxc_ast::{ast::*, AstKind}; use oxc_ecmascript::{BoundNames, IsSimpleParameterList}; use oxc_span::{GetSpan, SourceType}; diff --git a/crates/oxc_semantic/src/builder.rs b/crates/oxc_semantic/src/builder.rs index b42ada7e998f6..37b520e77c7a2 100644 --- a/crates/oxc_semantic/src/builder.rs +++ b/crates/oxc_semantic/src/builder.rs @@ -8,7 +8,6 @@ use std::{ use rustc_hash::FxHashMap; -#[allow(clippy::wildcard_imports)] use oxc_ast::{ast::*, AstKind, Visit}; use oxc_cfg::{ ControlFlowGraphBuilder, CtxCursor, CtxFlags, EdgeType, ErrorEdgeKind, diff --git a/crates/oxc_semantic/src/checker/javascript.rs b/crates/oxc_semantic/src/checker/javascript.rs index 0e24cbfc8c7e0..135d74826209f 100644 --- a/crates/oxc_semantic/src/checker/javascript.rs +++ b/crates/oxc_semantic/src/checker/javascript.rs @@ -1,7 +1,6 @@ use phf::{phf_set, Set}; use rustc_hash::FxHashMap; -#[allow(clippy::wildcard_imports)] use oxc_ast::{ast::*, AstKind}; use oxc_diagnostics::{LabeledSpan, OxcDiagnostic}; use oxc_ecmascript::{IsSimpleParameterList, PropName}; diff --git a/crates/oxc_semantic/src/checker/typescript.rs b/crates/oxc_semantic/src/checker/typescript.rs index 97dfe91269ab2..e4da781b2d0ed 100644 --- a/crates/oxc_semantic/src/checker/typescript.rs +++ b/crates/oxc_semantic/src/checker/typescript.rs @@ -2,7 +2,6 @@ use std::borrow::Cow; use rustc_hash::FxHashMap; -#[allow(clippy::wildcard_imports)] use oxc_ast::{ast::*, AstKind}; use oxc_diagnostics::OxcDiagnostic; use oxc_ecmascript::{BoundNames, PropName}; diff --git a/crates/oxc_semantic/src/module_record/builder.rs b/crates/oxc_semantic/src/module_record/builder.rs index 765b2ff03f10f..3e6ea9a33b5ca 100644 --- a/crates/oxc_semantic/src/module_record/builder.rs +++ b/crates/oxc_semantic/src/module_record/builder.rs @@ -1,10 +1,8 @@ use std::path::PathBuf; -#[allow(clippy::wildcard_imports)] use oxc_ast::ast::*; use oxc_ecmascript::BoundNames; use oxc_span::{CompactStr, GetSpan, Span}; -#[allow(clippy::wildcard_imports)] use oxc_syntax::module_record::*; #[derive(Default)] diff --git a/crates/oxc_semantic/src/module_record/mod.rs b/crates/oxc_semantic/src/module_record/mod.rs index 388d664dcd258..3ab5ab0a71ff1 100644 --- a/crates/oxc_semantic/src/module_record/mod.rs +++ b/crates/oxc_semantic/src/module_record/mod.rs @@ -9,7 +9,6 @@ mod module_record_tests { use oxc_allocator::Allocator; use oxc_parser::Parser; use oxc_span::{SourceType, Span}; - #[allow(clippy::wildcard_imports)] use oxc_syntax::module_record::*; use crate::SemanticBuilder; diff --git a/crates/oxc_span/src/generated/derive_estree.rs b/crates/oxc_span/src/generated/derive_estree.rs index 9009da579fb76..de9824d1c3413 100644 --- a/crates/oxc_span/src/generated/derive_estree.rs +++ b/crates/oxc_span/src/generated/derive_estree.rs @@ -5,10 +5,8 @@ use serde::{ser::SerializeMap, Serialize, Serializer}; -#[allow(clippy::wildcard_imports)] use crate::source_type::*; -#[allow(clippy::wildcard_imports)] use crate::span::types::*; impl Serialize for Span { diff --git a/crates/oxc_syntax/src/generated/derive_clone_in.rs b/crates/oxc_syntax/src/generated/derive_clone_in.rs index 739219d9359d2..9af592332c53f 100644 --- a/crates/oxc_syntax/src/generated/derive_clone_in.rs +++ b/crates/oxc_syntax/src/generated/derive_clone_in.rs @@ -5,10 +5,8 @@ use oxc_allocator::{Allocator, CloneIn}; -#[allow(clippy::wildcard_imports)] use crate::number::*; -#[allow(clippy::wildcard_imports)] use crate::operator::*; impl<'alloc> CloneIn<'alloc> for NumberBase { diff --git a/crates/oxc_syntax/src/generated/derive_content_eq.rs b/crates/oxc_syntax/src/generated/derive_content_eq.rs index f3ef3fa74726b..d8bce369ae880 100644 --- a/crates/oxc_syntax/src/generated/derive_content_eq.rs +++ b/crates/oxc_syntax/src/generated/derive_content_eq.rs @@ -5,10 +5,8 @@ use oxc_span::cmp::ContentEq; -#[allow(clippy::wildcard_imports)] use crate::number::*; -#[allow(clippy::wildcard_imports)] use crate::operator::*; impl ContentEq for NumberBase { diff --git a/crates/oxc_syntax/src/generated/derive_content_hash.rs b/crates/oxc_syntax/src/generated/derive_content_hash.rs index 9fa9350d36388..15d7242ff322b 100644 --- a/crates/oxc_syntax/src/generated/derive_content_hash.rs +++ b/crates/oxc_syntax/src/generated/derive_content_hash.rs @@ -7,10 +7,8 @@ use std::{hash::Hasher, mem::discriminant}; use oxc_span::hash::ContentHash; -#[allow(clippy::wildcard_imports)] use crate::number::*; -#[allow(clippy::wildcard_imports)] use crate::operator::*; impl ContentHash for NumberBase { diff --git a/crates/oxc_syntax/src/generated/derive_estree.rs b/crates/oxc_syntax/src/generated/derive_estree.rs index 1a21d445d7c3e..6f13c8607fd16 100644 --- a/crates/oxc_syntax/src/generated/derive_estree.rs +++ b/crates/oxc_syntax/src/generated/derive_estree.rs @@ -5,7 +5,6 @@ use serde::{ser::SerializeMap, Serialize, Serializer}; -#[allow(clippy::wildcard_imports)] use crate::operator::*; impl Serialize for AssignmentOperator { diff --git a/crates/oxc_transformer/src/lib.rs b/crates/oxc_transformer/src/lib.rs index 3d8b6259fb22e..2f5399b0bee2a 100644 --- a/crates/oxc_transformer/src/lib.rs +++ b/crates/oxc_transformer/src/lib.rs @@ -1,5 +1,3 @@ -#![allow(clippy::wildcard_imports)] - //! Transformer / Transpiler //! //! References: diff --git a/crates/oxc_traverse/scripts/lib/ancestor.mjs b/crates/oxc_traverse/scripts/lib/ancestor.mjs index f7e868e7de5d5..5f6f8a9da7bc9 100644 --- a/crates/oxc_traverse/scripts/lib/ancestor.mjs +++ b/crates/oxc_traverse/scripts/lib/ancestor.mjs @@ -115,7 +115,6 @@ export default function generateAncestorsCode(types) { use memoffset::offset_of; use oxc_allocator::{Box, Vec}; - #[allow(clippy::wildcard_imports)] use oxc_ast::ast::*; use oxc_syntax::scope::ScopeId; diff --git a/crates/oxc_traverse/scripts/lib/scopes_collector.mjs b/crates/oxc_traverse/scripts/lib/scopes_collector.mjs index a471fdb1983c8..b1b7b9f0eaf9a 100644 --- a/crates/oxc_traverse/scripts/lib/scopes_collector.mjs +++ b/crates/oxc_traverse/scripts/lib/scopes_collector.mjs @@ -20,7 +20,6 @@ export default function generateScopesCollectorCode(types) { return ` use std::cell::Cell; - #[allow(clippy::wildcard_imports)] use oxc_ast::{ast::*, visit::Visit}; use oxc_syntax::scope::{ScopeFlags, ScopeId}; diff --git a/crates/oxc_traverse/scripts/lib/traverse.mjs b/crates/oxc_traverse/scripts/lib/traverse.mjs index 3abece41bc4f0..f13e1481a292b 100644 --- a/crates/oxc_traverse/scripts/lib/traverse.mjs +++ b/crates/oxc_traverse/scripts/lib/traverse.mjs @@ -20,7 +20,6 @@ export default function generateTraverseTraitCode(types) { return ` use oxc_allocator::Vec; - #[allow(clippy::wildcard_imports)] use oxc_ast::ast::*; use crate::TraverseCtx; diff --git a/crates/oxc_traverse/scripts/lib/walk.mjs b/crates/oxc_traverse/scripts/lib/walk.mjs index b9b5499cf0b10..a70f5b543c2d8 100644 --- a/crates/oxc_traverse/scripts/lib/walk.mjs +++ b/crates/oxc_traverse/scripts/lib/walk.mjs @@ -37,7 +37,6 @@ export default function generateWalkFunctionsCode(types) { use std::{cell::Cell, marker::PhantomData}; use oxc_allocator::Vec; - #[allow(clippy::wildcard_imports)] use oxc_ast::ast::*; use oxc_syntax::scope::ScopeId; diff --git a/crates/oxc_traverse/src/ast_operations/gather_node_parts.rs b/crates/oxc_traverse/src/ast_operations/gather_node_parts.rs index 8a41060a60c78..aa4ef25cf7aa8 100644 --- a/crates/oxc_traverse/src/ast_operations/gather_node_parts.rs +++ b/crates/oxc_traverse/src/ast_operations/gather_node_parts.rs @@ -4,7 +4,6 @@ //! //! This trait is used to gather all the parts of a node that are identifiers. -#[allow(clippy::wildcard_imports)] use oxc_ast::ast::*; use oxc_ecmascript::BoundNames; diff --git a/crates/oxc_traverse/src/context/scoping.rs b/crates/oxc_traverse/src/context/scoping.rs index e2511bf1fac4a..0b2e7d6f44c44 100644 --- a/crates/oxc_traverse/src/context/scoping.rs +++ b/crates/oxc_traverse/src/context/scoping.rs @@ -4,7 +4,6 @@ use compact_str::CompactString; use itoa::Buffer as ItoaBuffer; use rustc_hash::FxHashSet; -#[allow(clippy::wildcard_imports)] use oxc_ast::{ast::*, visit::Visit}; use oxc_semantic::{NodeId, Reference, ScopeTree, SymbolTable}; use oxc_span::{CompactStr, SPAN}; diff --git a/crates/oxc_traverse/src/generated/ancestor.rs b/crates/oxc_traverse/src/generated/ancestor.rs index cab875efe5e3e..04f2a0352ba28 100644 --- a/crates/oxc_traverse/src/generated/ancestor.rs +++ b/crates/oxc_traverse/src/generated/ancestor.rs @@ -15,7 +15,6 @@ use std::{cell::Cell, marker::PhantomData}; use memoffset::offset_of; use oxc_allocator::{Box, Vec}; -#[allow(clippy::wildcard_imports)] use oxc_ast::ast::*; use oxc_syntax::scope::ScopeId; diff --git a/crates/oxc_traverse/src/generated/scopes_collector.rs b/crates/oxc_traverse/src/generated/scopes_collector.rs index 3bd472c9e4f78..cbd8dc2303734 100644 --- a/crates/oxc_traverse/src/generated/scopes_collector.rs +++ b/crates/oxc_traverse/src/generated/scopes_collector.rs @@ -4,7 +4,6 @@ use std::cell::Cell; -#[allow(clippy::wildcard_imports)] use oxc_ast::{ast::*, visit::Visit}; use oxc_syntax::scope::{ScopeFlags, ScopeId}; diff --git a/crates/oxc_traverse/src/generated/traverse.rs b/crates/oxc_traverse/src/generated/traverse.rs index 71c83553264ea..6ab2a0d844a9d 100644 --- a/crates/oxc_traverse/src/generated/traverse.rs +++ b/crates/oxc_traverse/src/generated/traverse.rs @@ -3,7 +3,6 @@ // To alter this generated file you have to edit the codegen. use oxc_allocator::Vec; -#[allow(clippy::wildcard_imports)] use oxc_ast::ast::*; use crate::TraverseCtx; diff --git a/crates/oxc_traverse/src/generated/walk.rs b/crates/oxc_traverse/src/generated/walk.rs index 97a34c9e76ce2..0e849819c0c6c 100644 --- a/crates/oxc_traverse/src/generated/walk.rs +++ b/crates/oxc_traverse/src/generated/walk.rs @@ -17,7 +17,6 @@ use std::{cell::Cell, marker::PhantomData}; use oxc_allocator::Vec; -#[allow(clippy::wildcard_imports)] use oxc_ast::ast::*; use oxc_syntax::scope::ScopeId; diff --git a/tasks/ast_tools/src/derives/mod.rs b/tasks/ast_tools/src/derives/mod.rs index de9c11a95d9fa..fe401473e79fa 100644 --- a/tasks/ast_tools/src/derives/mod.rs +++ b/tasks/ast_tools/src/derives/mod.rs @@ -59,7 +59,6 @@ macro_rules! define_derive { syn::parse_str(format!("use {local_path};").as_str()).unwrap(); quote::quote! { ///@@line_break - #[allow(clippy::wildcard_imports)] #use_module } }); diff --git a/tasks/ast_tools/src/generators/assert_layouts.rs b/tasks/ast_tools/src/generators/assert_layouts.rs index 153ce1a4a7042..33b19a011709d 100644 --- a/tasks/ast_tools/src/generators/assert_layouts.rs +++ b/tasks/ast_tools/src/generators/assert_layouts.rs @@ -36,11 +36,9 @@ impl Generator for AssertLayouts { use std::mem::{align_of, offset_of, size_of}; ///@@line_break - #[allow(clippy::wildcard_imports)] use crate::ast::*; ///@@line_break - #[allow(clippy::wildcard_imports)] use oxc_regular_expression::ast::*; ///@@line_break diff --git a/tasks/ast_tools/src/generators/ast_builder.rs b/tasks/ast_tools/src/generators/ast_builder.rs index 45cc00de015f6..88bf3c1722ce0 100644 --- a/tasks/ast_tools/src/generators/ast_builder.rs +++ b/tasks/ast_tools/src/generators/ast_builder.rs @@ -54,7 +54,6 @@ impl Generator for AstBuilderGenerator { use oxc_syntax::{scope::ScopeId, symbol::SymbolId, reference::ReferenceId}; ///@@line_break - #[allow(clippy::wildcard_imports)] use crate::ast::*; ///@@line_break diff --git a/tasks/ast_tools/src/generators/ast_kind.rs b/tasks/ast_tools/src/generators/ast_kind.rs index 1a463397374e5..fff3aedb1b363 100644 --- a/tasks/ast_tools/src/generators/ast_kind.rs +++ b/tasks/ast_tools/src/generators/ast_kind.rs @@ -137,7 +137,6 @@ impl Generator for AstKindGenerator { use oxc_span::{GetSpan, Span}; ///@@line_break - #[allow(clippy::wildcard_imports)] use crate::ast::*; ///@@line_break diff --git a/tasks/ast_tools/src/generators/visit.rs b/tasks/ast_tools/src/generators/visit.rs index 1c27a11f72fca..3e9bcc7f33376 100644 --- a/tasks/ast_tools/src/generators/visit.rs +++ b/tasks/ast_tools/src/generators/visit.rs @@ -98,7 +98,6 @@ fn generate_visit(ctx: &LateCtx) -> TokenStream { use oxc_syntax::scope::{ScopeFlags, ScopeId}; ///@@line_break - #[allow(clippy::wildcard_imports)] use crate::ast::*; use crate::ast_kind::#ast_kind_type; diff --git a/tasks/transform_checker/src/lib.rs b/tasks/transform_checker/src/lib.rs index 329235e295a91..bda78937394ac 100644 --- a/tasks/transform_checker/src/lib.rs +++ b/tasks/transform_checker/src/lib.rs @@ -95,7 +95,6 @@ use indexmap::IndexMap; use rustc_hash::FxHasher; use oxc_allocator::{Allocator, CloneIn}; -#[allow(clippy::wildcard_imports, clippy::allow_attributes)] use oxc_ast::{ast::*, visit::walk, Visit}; use oxc_diagnostics::OxcDiagnostic; use oxc_semantic::{ScopeTree, SemanticBuilder, SymbolTable};