Skip to content

Commit

Permalink
refact(api): lower MSRV to 1.65.0
Browse files Browse the repository at this point in the history
  • Loading branch information
pedromfedricci committed Nov 18, 2024
1 parent adb4a28 commit 05491b7
Show file tree
Hide file tree
Showing 4 changed files with 20 additions and 11 deletions.
14 changes: 10 additions & 4 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -26,13 +26,19 @@ jobs:
msrv:
name: MSRV
runs-on: ubuntu-latest
env:
CARGO_UNSTABLE_SPARSE_REGISTRY: true
steps:
- name: Checkout repository
uses: actions/checkout@v3
- name: Install Rust 1.70.0
run: rustup toolchain install 1.70.0
- name: Set Rust 1.70.0 as default
run: rustup default 1.70.0
- name: Install Rust 1.65.0
# NOTE: We are actually installing the first nightly 1.66.0. It should
# be equivalent to stable 1.65.0. We need the nightly version to use the
# sparse registry feature. This massively improves the index download.
# Link: https://blog.rust-lang.org/2022/06/22/sparse-registry-testing.html
run: rustup toolchain install nightly-2022-09-18
- name: Set Rust 1.65.0 as default
run: rustup default nightly-2022-09-18
- name: Check MSRV
run: cargo check --all-features

Expand Down
4 changes: 2 additions & 2 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,8 @@ and eventually fair lock for mutual exclusion, referred to as Malthusian lock.
name = "malthlock"
version = "0.1.0"
edition = "2021"
# NOTE: Rust 1.70 is required for `AtomicPtr::as_ptr`.
rust-version = "1.70.0"
# NOTE: Rust 1.65 is required for GATs and let-else statements.
rust-version = "1.65.0"
license = "MIT OR Apache-2.0"
readme = "README.md"
documentation = "https://docs.rs/malthlock"
Expand Down
7 changes: 6 additions & 1 deletion Makefile.toml
Original file line number Diff line number Diff line change
Expand Up @@ -22,8 +22,13 @@ args = ["rustdoc", "--all-features", "--open", "--", "--default-theme", "ayu"]

# Check MSRV.
[tasks.msrv]
toolchain = "1.70.0"
# NOTE: We are actually installing the first nightly 1.66.0. It should be
# equivalent to stable 1.65.0. We need the nightly version to use the sparse
# registry feature. This massively improves the index download.
# Link: https://blog.rust-lang.org/2022/06/22/sparse-registry-testing.html
toolchain = "nightly-2022-09-18"
command = "cargo"
env = { "CARGO_UNSTABLE_SPARSE_REGISTRY" = "true" }
args = ["check", "--all-features"]

# Check semver viloations.
Expand Down
6 changes: 2 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,10 +3,8 @@
## Minimum Supported Rust Version (MSRV)

This crate is guaranteed to compile on a Minimum Supported Rust Version (MSRV)
of 1.70.0 and above. This version will not be changed without a minor version
bump. If you intend to use this crate but can only target a older Rust version,
feel free to open a issue with your specific target, it is possible to lower
this crate MSRV substantially, it just has not been explored yet.
of 1.65.0 and above. This version will not be changed without a minor version
bump.

## License

Expand Down

0 comments on commit 05491b7

Please sign in to comment.