Class: Dentaku::AST::And

Inherits:
Combinator show all
Defined in:
lib/dentaku/ast/combinators.rb

Instance Attribute Summary

Attributes inherited from Operation

#left, #right

Instance Method Summary collapse

Methods inherited from Combinator

#initialize, #type

Methods inherited from Operation

#dependencies, #initialize, max_param_count, min_param_count, right_associative?

Methods inherited from Node

arity, #dependencies, peek, precedence, #type

Constructor Details

This class inherits a constructor from Dentaku::AST::Combinator

Instance Method Details

#operatorObject



31
32
33
# File 'lib/dentaku/ast/combinators.rb', line 31

def operator
  :and
end

#value(context = {}) ⇒ Object



35
36
37
# File 'lib/dentaku/ast/combinators.rb', line 35

def value(context = {})
  left.value(context) && right.value(context)
end