Skip to content

Commit

Permalink
chore: comment
Browse files Browse the repository at this point in the history
  • Loading branch information
hi-ogawa committed Jun 29, 2024
1 parent 8f22bc7 commit 6a64b2d
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion oxc-rsc/src/hoist.rs
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ fn has_directive(body: &FunctionBody, directive: &str) -> bool {
.any(|e| e.expression.value == directive)
}

// replace function definition with action register/bind
// create action register and bind expression
// $$register($$hoist, "<id>", "$$hoist").bind(null, <args>)
fn ast_register_bind_expression<'a>(
ctx: &mut oxc_traverse::TraverseCtx<'a>,
Expand Down Expand Up @@ -122,6 +122,8 @@ fn ast_register_bind_expression<'a>(
expr
}

// create hoisted function declarations
// export function $$hoist(...) { ... }
fn ast_hoist_declaration<'a>(
ctx: &mut oxc_traverse::TraverseCtx<'a>,
span: Span,
Expand Down

0 comments on commit 6a64b2d

Please sign in to comment.