From 69eeeea138dbe01a59e30e04e39f4d9036e2cf04 Mon Sep 17 00:00:00 2001 From: overlookmotel <557937+overlookmotel@users.noreply.github.com> Date: Tue, 17 Dec 2024 15:59:09 +0000 Subject: [PATCH] refactor(transformer/class-properties): methods take `&self` where possible (#7967) These 2 methods don't need to take `&mut self`. --- .../src/es2022/class_properties/private_field.rs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/crates/oxc_transformer/src/es2022/class_properties/private_field.rs b/crates/oxc_transformer/src/es2022/class_properties/private_field.rs index da4b2e23ebbf0..94be2fd6de0f8 100644 --- a/crates/oxc_transformer/src/es2022/class_properties/private_field.rs +++ b/crates/oxc_transformer/src/es2022/class_properties/private_field.rs @@ -418,7 +418,7 @@ impl<'a, 'ctx> ClassProperties<'a, 'ctx> { #[inline] #[expect(clippy::needless_pass_by_value)] fn transform_static_assignment_expression( - &mut self, + &self, expr: &mut Expression<'a>, prop_binding: BoundIdentifier<'a>, class_binding: BoundIdentifier<'a>, @@ -577,7 +577,7 @@ impl<'a, 'ctx> ClassProperties<'a, 'ctx> { #[inline] #[expect(clippy::needless_pass_by_value)] fn transform_instance_assignment_expression( - &mut self, + &self, expr: &mut Expression<'a>, prop_binding: BoundIdentifier<'a>, ctx: &mut TraverseCtx<'a>,