Class: RLSL::Prism::IR::BinaryOp

Inherits:
Node
  • Object
show all
Defined in:
lib/rlsl/prism/ir/expressions.rb

Instance Attribute Summary collapse

Attributes inherited from Node

#type

Instance Method Summary collapse

Methods inherited from Node

#accept, visits

Constructor Details

#initialize(operator, left, right, type = nil) ⇒ BinaryOp

Returns a new instance of BinaryOp.



71
72
73
74
75
76
77
# File 'lib/rlsl/prism/ir/expressions.rb', line 71

def initialize(operator, left, right, type = nil)
  super()
  @operator = operator
  @left = left
  @right = right
  @type = type
end

Instance Attribute Details

#leftObject (readonly)

Returns the value of attribute left.



67
68
69
# File 'lib/rlsl/prism/ir/expressions.rb', line 67

def left
  @left
end

#operatorObject (readonly)

Returns the value of attribute operator.



67
68
69
# File 'lib/rlsl/prism/ir/expressions.rb', line 67

def operator
  @operator
end

#rightObject (readonly)

Returns the value of attribute right.



67
68
69
# File 'lib/rlsl/prism/ir/expressions.rb', line 67

def right
  @right
end