Class: Fusion::Interpreter::Func
- Inherits:
-
Object
- Object
- Fusion::Interpreter::Func
- Defined in:
- lib/fusion/interpreter/func.rb
Instance Attribute Summary collapse
-
#clauses ⇒ Object
readonly
Returns the value of attribute clauses.
-
#env ⇒ Object
readonly
Returns the value of attribute env.
Instance Method Summary collapse
-
#initialize(clauses, env) ⇒ Func
constructor
A new instance of Func.
- #inspect ⇒ Object
Constructor Details
#initialize(clauses, env) ⇒ Func
Returns a new instance of Func.
12 13 14 15 |
# File 'lib/fusion/interpreter/func.rb', line 12 def initialize(clauses, env) @clauses = clauses # [AST::Clause, ...] @env = env end |
Instance Attribute Details
#clauses ⇒ Object (readonly)
Returns the value of attribute clauses.
10 11 12 |
# File 'lib/fusion/interpreter/func.rb', line 10 def clauses @clauses end |
#env ⇒ Object (readonly)
Returns the value of attribute env.
10 11 12 |
# File 'lib/fusion/interpreter/func.rb', line 10 def env @env end |
Instance Method Details
#inspect ⇒ Object
17 18 19 |
# File 'lib/fusion/interpreter/func.rb', line 17 def inspect "<func/#{clauses.length}>" end |