Skip to content

Roll back the MSRV to Rust 1.48#246

Merged
marshallpierce merged 1 commit intomarshallpierce:masterfrom
tcharding:08-09-roll-back-msrv
Aug 26, 2023
Merged

Roll back the MSRV to Rust 1.48#246
marshallpierce merged 1 commit intomarshallpierce:masterfrom
tcharding:08-09-roll-back-msrv

Conversation

@tcharding
Copy link
Contributor

The current MSRV (for non-dev builds) is Rust 1.57 however the codebase does not use any features from edition 2021 (landed Rust 1.56) except the TryFrom trait.

If we explicitly import core::convert::tryFrom we can stay on edition 2018.

The rust-version manifest option was added in Rust 1.56 but lets leave it there as added documentation of the MSRV and in preparation for bumping the MSRV when needed.

Rust 1.48 is a suitably old toolchain version, it is the toolchain included in Debian Bullseye.

@tcharding
Copy link
Contributor Author

tcharding commented Aug 10, 2023

I was going to create an issue but I saw the very amusing "How I, the issue filer, am going to help solve it" :)

Awesome library by the way, your code is a pleasure to read.

@tcharding tcharding force-pushed the 08-09-roll-back-msrv branch from 6e0d6f6 to 2a69cc3 Compare August 10, 2023 04:54
The current MSRV (for non-dev builds) is Rust 1.57 however the codebase
does not use any features from edition 2021 (landed Rust 1.56) except
the `TryFrom` trait.

If we explicitly import `core::convert::tryFrom` we can stay on edition
2018.

The `rust-version` manifest option was added in Rust 1.56 but lets leave
it there as added documentation of the MSRV and in preparation for
bumping the MSRV when needed.

Rust 1.48 is a suitably old toolchain version, it is in Debian
oldstable.

Roll back the crate MSRV to Rust 1.48
@tcharding tcharding force-pushed the 08-09-roll-back-msrv branch from 2a69cc3 to a383018 Compare August 10, 2023 04:58
@tcharding
Copy link
Contributor Author

PR currently uses use std::convert::TryFrom;, would you prefer use std::convert::TryFrom as _; as it was in the tests? I don't know the exact benefit, is it to future proof against name clashes?

@marshallpierce
Copy link
Owner

If planned obsolescence was taken as a motivating goal, the result would be Debian...

I'll take care of the trait tweaking. The _ thing is to avoid being able to accidentally refer to things by their "bare" name, in keeping with the habit I picked up from working on ring of leaving a bit of the module path intact when working directly on types from other crates.

@marshallpierce marshallpierce merged commit b001749 into marshallpierce:master Aug 26, 2023
@tcharding tcharding deleted the 08-09-roll-back-msrv branch August 27, 2023 21:46
@tcharding
Copy link
Contributor Author

Thanks man!

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