class SimpleLogic::Variable
Public Instance Methods
eval(context)
click to toggle source
# File lib/simple_logic/syntax_nodes.rb, line 61 def eval(context) key = text_value.to_sym if context.include?(key) context[key] else raise UndefinedVariableError.new(interval.first, text_value), "Undefined variable: \"#{text_value}\"" end end