Class: Mgmg::IR::Const

Inherits:
Object
  • Object
show all
Defined in:
lib/mgmg/ir.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(value) ⇒ Const



6
7
8
# File 'lib/mgmg/ir.rb', line 6

def initialize(value)
	@value = value
end

Instance Attribute Details

#valueObject

Returns the value of attribute value.



9
10
11
# File 'lib/mgmg/ir.rb', line 9

def value
  @value
end

Instance Method Details

#evaluate(s, c) ⇒ Object



13
14
15
# File 'lib/mgmg/ir.rb', line 13

def evaluate(s, c)
	@value
end

#evaluate3(s, a, c) ⇒ Object



16
17
18
# File 'lib/mgmg/ir.rb', line 16

def evaluate3(s, a, c)
	@value
end

#initialize_copy(other) ⇒ Object



10
11
12
# File 'lib/mgmg/ir.rb', line 10

def initialize_copy(other)
	@value = other.value
end

#to_sObject



19
20
21
# File 'lib/mgmg/ir.rb', line 19

def to_s
	@value.to_s
end