diff --git a/crates/oxc_ast/src/ast/ts.rs b/crates/oxc_ast/src/ast/ts.rs index 5e3d6cf41e7c5..c8e25d6aa4870 100644 --- a/crates/oxc_ast/src/ast/ts.rs +++ b/crates/oxc_ast/src/ast/ts.rs @@ -217,7 +217,7 @@ pub struct TSTypeOperator<'a> { pub type_annotation: TSType<'a>, } -#[derive(Debug, Hash)] +#[derive(Debug, Clone, Copy, PartialEq, Eq, Hash)] #[cfg_attr(feature = "serialize", derive(Serialize, Tsify))] #[cfg_attr(feature = "serialize", serde(rename_all = "lowercase"))] pub enum TSTypeOperatorOperator { @@ -520,7 +520,7 @@ pub struct TSTypeAliasDeclaration<'a> { pub modifiers: Modifiers<'a>, } -#[derive(Debug, Hash, Clone, PartialEq, Eq, Copy)] +#[derive(Debug, Clone, Copy, PartialEq, Eq, Hash)] #[cfg_attr(feature = "serialize", derive(Serialize, Tsify))] #[cfg_attr(feature = "serialize", serde(rename_all = "lowercase"))] pub enum TSAccessibility { @@ -612,7 +612,7 @@ pub struct TSCallSignatureDeclaration<'a> { pub type_parameters: Option>>, } -#[derive(Debug, Clone, Copy, Hash)] +#[derive(Debug, Clone, Copy, PartialEq, Eq, Hash)] #[cfg_attr(feature = "serialize", derive(Serialize, Tsify))] #[cfg_attr(feature = "serialize", serde(rename_all = "lowercase"))] pub enum TSMethodSignatureKind { @@ -867,7 +867,7 @@ pub struct TSMappedType<'a> { pub readonly: TSMappedTypeModifierOperator, } -#[derive(Debug, Hash)] +#[derive(Debug, Clone, Copy, PartialEq, Eq, Hash)] #[cfg_attr(feature = "serialize", derive(Serialize, Tsify))] #[cfg_attr(feature = "serialize", serde(rename_all = "camelCase"))] pub enum TSMappedTypeModifierOperator { diff --git a/crates/oxc_syntax/src/lib.rs b/crates/oxc_syntax/src/lib.rs index 7ff536f60c43f..b99c13995be68 100644 --- a/crates/oxc_syntax/src/lib.rs +++ b/crates/oxc_syntax/src/lib.rs @@ -12,7 +12,7 @@ pub mod scope; pub mod symbol; pub mod xml_entities; -#[derive(Debug, Clone, Copy, Eq, PartialEq, Hash)] +#[derive(Debug, Clone, Copy, PartialEq, Eq, Hash)] pub enum NumberBase { Float, Decimal, @@ -27,7 +27,7 @@ impl NumberBase { } } -#[derive(Debug, Clone, Copy, Eq, PartialEq, Hash)] +#[derive(Debug, Clone, Copy, PartialEq, Eq, Hash)] pub enum BigintBase { Decimal, Binary,