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

VersionRange additions #99

Merged
merged 2 commits into from
Dec 2, 2024
Merged

Conversation

rukai
Copy link
Collaborator

@rukai rukai commented Nov 21, 2024

This PR introduces 2 new pieces of functionality around VersionRange.
These were required to implement a unit test in my project that compares the currently supported versions of the project against the supported versions of the kafka-protocol crate.

The additions are:

  • Add PartialEq impl for VersionRange
    • allows for direct comparison between ranges which seems like a reasonable operation.
  • Add Display impl for VersionRange
    • It takes the format 0..10 where min is 0 and max is 10
    • This compact format will be nice for logs and error messages.
    • Possibly we should do 0 to 10 or 0-10 or 0..=10 instead, since in regular rust 0..10 would mean an exclusive 10.

@tychedelia tychedelia added the enhancement New feature or request label Dec 2, 2024
@tychedelia tychedelia added this to the 0.14.0 milestone Dec 2, 2024
@tychedelia tychedelia merged commit 1bbdeed into tychedelia:main Dec 2, 2024
3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants