ipv4_compat()
public
Returns a new ipaddr built by
converting the native IPv4 address into
an IPv4-compatible IPv6 address.
Show source
def ipv4_compat
warn "IPAddr\##{__callee__} is obsolete", uplevel: 1 if $VERBOSE
if !ipv4?
raise InvalidAddressError, "not an IPv4 address"
end
return self.clone.set(@addr, Socket::AF_INET6)
end