Module: LLVM::PointerIdentity

Included in:
Module, PassManagerBuilder, Target, TargetMachine, Type, Value
Defined in:
lib/llvm.rb

Instance Method Summary collapse

Instance Method Details

#==(other) ⇒ Object

Checks if the value is equal to other.



20
21
22
23
# File 'lib/llvm.rb', line 20

def ==(other)
  other.respond_to?(:to_ptr) &&
      @ptr == other.to_ptr
end

#eql?(other) ⇒ Boolean

Checks if the value is equivalent to other.

Returns:

  • (Boolean)


31
32
33
# File 'lib/llvm.rb', line 31

def eql?(other)
  self == other
end

#hashObject

Computes hash.



26
27
28
# File 'lib/llvm.rb', line 26

def hash
  @ptr.address.hash
end

#to_ptrObject



15
16
17
# File 'lib/llvm.rb', line 15

def to_ptr
  @ptr
end