instance method
Set::SubclassCompatible#==
==(other)
lib/set/subclass_compatible.rb
View on GitHub ↗
# File tmp/rubies/ruby-4.0.0/lib/set/subclass_compatible.rb, line 283
def ==(other)
if self.equal?(other)
true
elsif other.instance_of?(self.class)
super
elsif other.is_a?(Set) && self.size == other.size
other.all? { |o| include?(o) }
else
false
end
end
No documentation available