Open
Conversation
Author
|
The build is failing I think this is unrelated. |
Author
|
I did some digging and it turns out the issue is quickcheck = "1.0.3" is getting upgraded to quickcheck = "1.1.0" which in turn pulls in rand = "0.10.0". That version of rand is incompatible with Bumpalo's MSRV. Should I pin quickcheck = "=1.0.3" in this PR or raise a separate PR? |
Open
Author
|
I fixed the build issue in #306 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
This CR makes the box covariant in 'a to allow for more use cases. This addresses #170.
Making it covariant should be OK for the same reasons as the standard library box is safe. Quoting the RustNomicon (https://doc.rust-lang.org/nomicon/subtyping.html)
The Bumpalo Vec is already covariant.
I tested this code by running
I checked that all tests passed. I also added a unit test for covariance. I wasn't able to come up with a great test, but I verified that the test fails if I make the lifetime invariant.
I additionally ran
miri passed all tests. It complains about some memory leaks in raw_vec, but that should be unrelated.