class Riml::UnaryOperatorNode

Public Class Methods

new(operator, operands) click to toggle source
Calls superclass method
# File lib/riml/nodes.rb, line 457
def initialize(operator, operands)
  len = operands.length
  unless len == 1
    raise ArgumentError, "unary operator must have 1 operand, has #{len}"
  end
  super
end

Public Instance Methods

operand() click to toggle source
# File lib/riml/nodes.rb, line 464
def operand
  operands.first
end