Method: CTypes::Union.==

Defined in:
lib/ctypes/union.rb

.==(other) ⇒ Object

check if another Union subclass has the same members as this Union



373
374
375
376
377
378
379
# File 'lib/ctypes/union.rb', line 373

def self.==(other)
  return true if super
  return false unless other.is_a?(Class) && other < Union
  other.field_layout == @fields &&
    other.default_endian == default_endian &&
    other.size == size
end