Class: SyntaxTree::YARV::Leave
Overview
### Summary
‘leave` exits the current frame.
### Usage
~~~ruby ;; ~~~
Instance Method Summary
collapse
Methods inherited from Instruction
#branch_targets, #canonical, #falls_through?, #length, #side_effects?
Instance Method Details
#==(other) ⇒ Object
2276
2277
2278
|
# File 'lib/syntax_tree/yarv/instructions.rb', line 2276
def ==(other)
other.is_a?(Leave)
end
|
#call(vm) ⇒ Object
2290
2291
2292
|
# File 'lib/syntax_tree/yarv/instructions.rb', line 2290
def call(vm)
vm.leave
end
|
#deconstruct_keys(_keys) ⇒ Object
2272
2273
2274
|
# File 'lib/syntax_tree/yarv/instructions.rb', line 2272
def deconstruct_keys(_keys)
{}
end
|
#disasm(fmt) ⇒ Object
2264
2265
2266
|
# File 'lib/syntax_tree/yarv/instructions.rb', line 2264
def disasm(fmt)
fmt.instruction("leave")
end
|
#leaves? ⇒ Boolean
2294
2295
2296
|
# File 'lib/syntax_tree/yarv/instructions.rb', line 2294
def leaves?
true
end
|
#pops ⇒ Object
2280
2281
2282
|
# File 'lib/syntax_tree/yarv/instructions.rb', line 2280
def pops
1
end
|
#pushes ⇒ Object
2284
2285
2286
2287
2288
|
# File 'lib/syntax_tree/yarv/instructions.rb', line 2284
def pushes
0
end
|
#to_a(_iseq) ⇒ Object
2268
2269
2270
|
# File 'lib/syntax_tree/yarv/instructions.rb', line 2268
def to_a(_iseq)
[:leave]
end
|