Skip to content

Commit

Permalink
Fix ast tool to prepare scopes properly.
Browse files Browse the repository at this point in the history
  • Loading branch information
headius committed Apr 3, 2015
1 parent 539b3da commit e3d8944
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions bin/ast
Expand Up @@ -169,6 +169,7 @@ def print_passes_on(scope, passes)
end

scope.lexical_scopes.each do |child_scope|
child_scope.prepare_for_initial_compilation
print_passes_on(child_scope, passes)
end
end
Expand All @@ -194,6 +195,7 @@ def ir_setup(root)
builder = org.jruby.ir.IRBuilder

scope = builder.build_root(manager, root).scope
scope.prepare_for_initial_compilation
passes = manager.get_compiler_passes(scope)
[scope, passes]
end
Expand Down

0 comments on commit e3d8944

Please sign in to comment.