Project

General

Profile

Feature #8833 ยป ipaddr_pred.patch

iosctr (Brian Burns), 08/29/2013 08:09 PM

View differences:

lib/ipaddr.rb
return self.clone.set(@addr + 1, @family)
end
# Returns the predecessor to the ipaddr.
def pred
return self.clone.set(@addr - 1, @family)
end
# Compares the ipaddr with another.
def <=>(other)
other = coerce_other(other)
    (1-1/1)