replace(enum)
public
Replaces the contents of the set with the contents of the given enumerable
object and returns self.
Show source
def replace(enum)
if enum.instance_of?(self.class)
@hash.replace(enum.instance_variable_get(:@hash))
else
clear
merge(enum)
end
self
end