Class: Kalc::Ast::ParenExpression
- Inherits:
-
Object
- Object
- Kalc::Ast::ParenExpression
- Defined in:
- lib/kalc/ast.rb
Instance Attribute Summary collapse
-
#value ⇒ Object
readonly
Returns the value of attribute value.
Instance Method Summary collapse
- #eval(context) ⇒ Object
-
#initialize(value) ⇒ ParenExpression
constructor
A new instance of ParenExpression.
Constructor Details
#initialize(value) ⇒ ParenExpression
Returns a new instance of ParenExpression.
95 96 97 |
# File 'lib/kalc/ast.rb', line 95 def initialize(value) @value = value end |
Instance Attribute Details
#value ⇒ Object (readonly)
Returns the value of attribute value.
93 94 95 |
# File 'lib/kalc/ast.rb', line 93 def value @value end |
Instance Method Details
#eval(context) ⇒ Object
99 100 101 |
# File 'lib/kalc/ast.rb', line 99 def eval(context) @value.eval(context) end |