Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Replace net.IP with netip.Addr #16

Open
GabyGH opened this issue Apr 5, 2024 · 0 comments
Open

Replace net.IP with netip.Addr #16

GabyGH opened this issue Apr 5, 2024 · 0 comments

Comments

@GabyGH
Copy link
Collaborator

GabyGH commented Apr 5, 2024

As we compare a lot of IP addresses, it would be nice if we could do away with the casting and 'just' natively compare them. net.IP does not allow comparison, it's moral successor, netip.Addr does allow direct comparison. Additionally it should help reduce logic around ipv4 and ipv6. Explanation here: https://djosephsen.github.io//posts/ipnet/

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant