code: func SameNet(bits uint, ip, other net.IP) bool {
  	ip4, other4 := ip.To4(), other.To4()
  	switch {
  	case (ip4 == nil) != (other4 == nil):
  		return false
  	case ip4 != nil:
  		return sameNet(bits, ip4, other4)
  	default:
  		return sameNet(bits, ip.To16(), other.To16())
  	}
  }
docs: // SameNet reports whether two IP addresses have an equal prefix of the given bit length.