Class: LLVM::Instruction
Direct Known Subclasses
Instance Method Summary collapse
-
#next ⇒ Object
Returns the next instruction after this one.
-
#parent ⇒ Object
Returns the parent of the instruction (a BasicBlock).
-
#previous ⇒ Object
Returns the previous instruction before this one.
Methods inherited from User
Methods inherited from Value
#==, #add_attribute, #constant?, #dump, #eql?, from_ptr, #hash, #name, #name=, #null?, to_ptr, #to_ptr, type, #type, #undefined?
Instance Method Details
#next ⇒ Object
Returns the next instruction after this one.
727 728 729 730 |
# File 'lib/llvm/core/value.rb', line 727 def next ptr = C.LLVMGetNextInstruction(self) LLVM::Instruction.from_ptr(ptr) unless ptr.null? end |
#parent ⇒ Object
Returns the parent of the instruction (a BasicBlock).
721 722 723 724 |
# File 'lib/llvm/core/value.rb', line 721 def parent ptr = C.LLVMGetInstructionParent(self) LLVM::BasicBlock.from_ptr(ptr) unless ptr.null? end |
#previous ⇒ Object
Returns the previous instruction before this one.
733 734 735 736 |
# File 'lib/llvm/core/value.rb', line 733 def previous ptr = C.LLVMGetPreviousInstruction(self) LLVM::Instruction.from_ptr(ptr) unless ptr.null? end |