Class: WAG::Instruction::Br

Inherits:
Object
  • Object
show all
Includes:
WAG::Instructable
Defined in:
lib/wag/instructions/br.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods included from WAG::Instructable

#f32, #f64, #i32, #i64, #local, #memory

Constructor Details

#initialize(label) ⇒ Br

Returns a new instance of Br.



9
10
11
12
# File 'lib/wag/instructions/br.rb', line 9

def initialize(label)
  @label = WAG::Label.from(label)
  super()
end

Instance Attribute Details

#labelObject (readonly)

Returns the value of attribute label.



7
8
9
# File 'lib/wag/instructions/br.rb', line 7

def label
  @label
end

Instance Method Details

#to_sexprObject



14
15
16
# File 'lib/wag/instructions/br.rb', line 14

def to_sexpr
  [name, label.to_sexpr]
end