Class: Brainfuck::AST::Script

Inherits:
Struct
  • Object
show all
Defined in:
lib/brainfuck/ast.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Instance Attribute Details

#expObject

Returns the value of attribute exp

Returns:

  • (Object)

    the current value of exp



132
133
134
# File 'lib/brainfuck/ast.rb', line 132

def exp
  @exp
end

Instance Method Details

#bytecode(g) ⇒ Object



133
134
135
136
137
# File 'lib/brainfuck/ast.rb', line 133

def bytecode(g)
  exp.each do |e|
    e.bytecode(g)
  end
end