Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions crates/oxc_transformer/src/common/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -120,6 +120,8 @@ impl<'a, 'ctx> Traverse<'a> for Common<'a, 'ctx> {
self.arrow_function_converter.exit_expression(expr, ctx);
}

// `#[inline]` because this is a hot path and `arrow_function_converter`'s function is small
#[inline]
fn enter_binding_identifier(
&mut self,
node: &mut BindingIdentifier<'a>,
Expand All @@ -128,6 +130,8 @@ impl<'a, 'ctx> Traverse<'a> for Common<'a, 'ctx> {
self.arrow_function_converter.enter_binding_identifier(node, ctx);
}

// `#[inline]` because this is a hot path and `arrow_function_converter`'s function is small
#[inline]
fn enter_identifier_reference(
&mut self,
node: &mut IdentifierReference<'a>,
Expand Down
4 changes: 4 additions & 0 deletions crates/oxc_transformer/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -191,6 +191,8 @@ impl<'a, 'ctx> Traverse<'a> for TransformerImpl<'a, 'ctx> {
self.x2_es2020.enter_big_int_literal(node, ctx);
}

// `#[inline]` because this is a hot path and function at end of chain in `common` transform is small
#[inline]
fn enter_binding_identifier(
&mut self,
node: &mut BindingIdentifier<'a>,
Expand All @@ -199,6 +201,8 @@ impl<'a, 'ctx> Traverse<'a> for TransformerImpl<'a, 'ctx> {
self.common.enter_binding_identifier(node, ctx);
}

// `#[inline]` because this is a hot path and function at end of chain in `common` transform is small
#[inline]
fn enter_identifier_reference(
&mut self,
node: &mut IdentifierReference<'a>,
Expand Down