Closed rye closed 2 years ago
Just a minor nit: pls annotate the chanelog entry, mentioning this as a breaking change. Will bump the version appropriately when publishing the next release.
Looks good to me otherwise.
Just a minor nit: pls annotate the chanelog entry, mentioning this as a breaking change.
Historically, there's been a lot of discussion on wether MSRV bump should be considered a breaking change. e.g. https://users.rust-lang.org/t/rust-version-requirement-change-as-semver-breaking-or-not/20980/39
I don't really understand how the rust-version constraint added to Cargo.toml since 1.56 will affect this, but since we're still supporting toolchains older than that, I suspect it's yet irrelevant.
I'm sorry if I wasn't clear. Upgrading heapless is what I considered breaking, not the msrv change.
I see I may be mistaken here. Is the heapless change visible in public API? If not it's not really breaking change, and we don't need to mention in the changelog.
Regarding, msrv, yeah it's debatable whether to call it a breaking change. @rye sorry for the confusion, but could you revert back to your previous changelog message?
@rmanoka no problem, I have reverted back to the original state.
To be clear:
The change to heapless
is not visible in the public API.
The only place the heapless
crate is used is in the algorithm::nearest_neighbor
module, as an inner type in the SmallHeap::Stack
type. This enum (SmallHeap
) is not pub
— it seems to be an internal type only. (You can try and search for BinaryHeap
or SmallHeap
or Stack
on docs.rs to confirm this.)
A separate BinaryHeap
, the one from alloc::collections::binary_heap
is used and visible in the public API in the same module, but that's not the one that's changed here.
I'll give it a day if @michaelkirk or others have any more suggestions, and merge it otherwise. Thanks @rye !
Thanks @rye!
bors r+
may be try more politely? please: bors r+
[x] I added an entry to
rstar/CHANGELOG.md
if knowledge of this change could be valuable to users.Rust 1.51 has been released for nearly 12 months now.
As the community upgrades through and past this Rust version, some required dependencies of
rstar
(namely,heapless
v0.6, which itself required theas-slice
andgeneric-array
dependencies before Rust 1.51) have since released updates to make use of the new Const Generics MVP functionality that was released with Rust 1.51.To remove a few outdated dependencies and upgrade the codebase to the latest version of
heapless
, this PR does the following:Upgrades the
heapless
dependency from 0.6 to 0.7.This broke my local compile, as
heapless
' signature for theheapless::binary_heap::BinaryHeap
type changed, and theheapless::consts::U32
can now be represented with a plain old32_usize
. I made changes tosrc/algorithm/nearest_neighbor.rs
to fix the compile, and this resolved the compile failure. The tests now seem to pass.Updates the CI workflows file to test versions as far back as Rust 1.51 (but not Rust 1.50), as well as two more recent MSRVs.
Updates the
rstar/Cargo.toml
file to specify arust-version
key to indicate that Rust 1.51 is the Minimum Supported Rust Version (MSRV). This will display a warning on versions of cargo older than that which was distributed with Rust 1.56, as therust-version
key was added in that release.