-
Notifications
You must be signed in to change notification settings - Fork 101
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
v2 #144
Commits on Aug 18, 2024
-
The preformance of this is approximately the same as the net.IP version, except for the methods that return a network. For those, there is a slight improvement.
Configuration menu - View commit details
-
Copy full SHA for 853e75b - Browse repository at this point
Copy the full SHA 853e75bView commit details -
Configuration menu - View commit details
-
Copy full SHA for 4a5a9d6 - Browse repository at this point
Copy the full SHA 4a5a9d6View commit details -
This makes it easier to extend without adding many different lookup methods.
Configuration menu - View commit details
-
Copy full SHA for b46d987 - Browse repository at this point
Copy the full SHA b46d987View commit details -
Add the ability to decode a single path
This is more ergonomic than creating a struct for a single value and the performance is better as well due to less reflection: BenchmarkDecodeCountryCodeWithStruct-8 1347441 882.4 ns/op 1 B/op 0 allocs/op BenchmarkDecodePathCountryCode-8 2708011 445.1 ns/op 1 B/op 0 allocs/op
Configuration menu - View commit details
-
Copy full SHA for 8da779a - Browse repository at this point
Copy the full SHA 8da779aView commit details -
It is somewhat arbitrary, especially when dealing with switch statements and code may be inlined for performance reasons.
Configuration menu - View commit details
-
Copy full SHA for 800e54a - Browse repository at this point
Copy the full SHA 800e54aView commit details -
Configuration menu - View commit details
-
Copy full SHA for 3987a4b - Browse repository at this point
Copy the full SHA 3987a4bView commit details -
Configuration menu - View commit details
-
Copy full SHA for 0a0e493 - Browse repository at this point
Copy the full SHA 0a0e493View commit details -
Configuration menu - View commit details
-
Copy full SHA for 62022ad - Browse repository at this point
Copy the full SHA 62022adView commit details -
In order to make it easier to refactor and optimize.
Configuration menu - View commit details
-
Copy full SHA for 9541b71 - Browse repository at this point
Copy the full SHA 9541b71View commit details -
Configuration menu - View commit details
-
Copy full SHA for 3c14af0 - Browse repository at this point
Copy the full SHA 3c14af0View commit details -
Configuration menu - View commit details
-
Copy full SHA for 21b9508 - Browse repository at this point
Copy the full SHA 21b9508View commit details -
Reduce allocations in Networks
Slice length of 64 is used as most IPv6 trees will have that as their maximum depth.
Configuration menu - View commit details
-
Copy full SHA for 13ed83b - Browse repository at this point
Copy the full SHA 13ed83bView commit details -
Fix lints with new golangci-lint
The comment on "iter" is because the linter was not stable and kept on shifting it every time it ran.
Configuration menu - View commit details
-
Copy full SHA for a584c61 - Browse repository at this point
Copy the full SHA a584c61View commit details -
Configuration menu - View commit details
-
Copy full SHA for c075ec6 - Browse repository at this point
Copy the full SHA c075ec6View commit details -
Configuration menu - View commit details
-
Copy full SHA for 791db99 - Browse repository at this point
Copy the full SHA 791db99View commit details -
To more closely match net/netip. Also, it may reduce confusion with Networks and NetworksWithin, which refer to more than just the network.
Configuration menu - View commit details
-
Copy full SHA for cb27d1e - Browse repository at this point
Copy the full SHA cb27d1eView commit details
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.