Class: CodeTools::AST::File

Inherits:
Node
  • Object
show all
Defined in:
lib/rubinius/code/ast/file.rb

Instance Attribute Summary

Attributes inherited from Node

#line

Instance Method Summary collapse

Methods inherited from Node

#ascii_graph, #attributes, #children, #initialize, match_arguments?, match_send?, #new_block_generator, #new_generator, #node_name, #or_bytecode, #pos, #set_child, #transform, transform, transform_comment, transform_kind, transform_kind=, transform_name, #value_defined, #visit, #walk

Constructor Details

This class inherits a constructor from CodeTools::AST::Node

Instance Method Details

#bytecode(g) ⇒ Object



6
7
8
9
10
11
# File 'lib/rubinius/code/ast/file.rb', line 6

def bytecode(g)
  pos(g)

  g.push_scope
  g.send :active_path, 0
end

#defined(g) ⇒ Object



13
14
15
# File 'lib/rubinius/code/ast/file.rb', line 13

def defined(g)
  g.push_literal "expression"
end

#to_sexpObject



17
18
19
# File 'lib/rubinius/code/ast/file.rb', line 17

def to_sexp
  [:file]
end