Skip to content

Commit

Permalink
fix: program node CFG.
Browse files Browse the repository at this point in the history
  • Loading branch information
rzvxa committed Jun 5, 2024
1 parent dee2ff4 commit 86be84b
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion crates/oxc_semantic/src/builder.rs
Original file line number Diff line number Diff line change
Expand Up @@ -444,13 +444,14 @@ impl<'a> Visit<'a> for SemanticBuilder<'a> {
flags
});
program.scope_id.set(Some(self.current_scope_id));
self.enter_node(kind);

/* cfg */
let error_harness = self.cfg.attach_error_harness(ErrorEdgeKind::Implicit);
let _program_basic_block = self.cfg.new_basic_block_normal();
/* cfg - must be above directives as directives are in cfg */

self.enter_node(kind);

for directive in &program.directives {
self.visit_directive(directive);
}
Expand Down

0 comments on commit 86be84b

Please sign in to comment.