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

Add VersionReq::is_exact #205

Merged
merged 1 commit into from
May 24, 2020
Merged

Add VersionReq::is_exact #205

merged 1 commit into from
May 24, 2020

Conversation

illicitonion
Copy link
Contributor

I have some logic where it would be useful to shortcut some behaviour if
a VersionReq could only be matched by exactly one value. This would
help me not end up re-parsing the semver string myself to guess whether
it's a single fully-qualified exact match.

I have some logic where it would be useful to shortcut some behaviour if
a `VersionReq` could only be matched by exactly one value. This would
help me not end up re-parsing the semver string myself to guess whether
it's a single fully-qualified exact match.
Copy link
Contributor

@steveklabnik steveklabnik left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hi there! So sorry that I blocked your Cargo contribution here, I didn't realize!

I am happy to merge this, but getting it into a release may take some work. I am not sure if master is in a releasable state or not. I will try to figure that out ASAP!

@steveklabnik steveklabnik merged commit 681ed12 into dtolnay:master May 24, 2020
@illicitonion
Copy link
Contributor Author

Thanks for the merge! No rush with the releasing - we're using a workaround in Cargo for now (inferring this property from the string representation of a VersionReq), but it would be nice to clean that up to use the more precise check whenever it's convenient :)

Thanks again!

@illicitonion illicitonion deleted the is_exact branch May 25, 2020 00:03
@steveklabnik
Copy link
Contributor

Great!

I've published as 0.10.0; the breaking change wasn't actually merged yet, so this should be fine! This is the only new API in the new release.

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

Successfully merging this pull request may close these issues.

2 participants