Class: Array

Inherits:
Object
  • Object
show all
Defined in:
lib/bud/monkeypatch.rb

Overview

XXX: TEMPORARY/UGLY hack to ensure that arrays and structs compare. This can be removed once tests are rewritten.

Instance Method Summary collapse

Instance Method Details

#==(o) ⇒ Object



87
88
89
90
# File 'lib/bud/monkeypatch.rb', line 87

def ==(o)
  o = o.to_a if o.kind_of? Bud::TupleStruct
  self.old_eq(o)
end

#eql?(o) ⇒ Boolean

Returns:

  • (Boolean)


92
93
94
95
# File 'lib/bud/monkeypatch.rb', line 92

def eql?(o)
  o = o.to_a if o.kind_of? Bud::TupleStruct
  self.old_eql?(o)
end

#old_eqObject



84
# File 'lib/bud/monkeypatch.rb', line 84

alias :old_eq :==

#old_eql?Object



85
# File 'lib/bud/monkeypatch.rb', line 85

alias :old_eql? :eql?