Skip to content

Commit c988b9a

Browse files
committed
Increase the MSRV from 1.63 to 1.65
1 parent c4caf5c commit c988b9a

6 files changed

Lines changed: 51 additions & 107 deletions

File tree

.github/workflows/main.yml

Lines changed: 42 additions & 48 deletions
Original file line numberDiff line numberDiff line change
@@ -25,17 +25,17 @@ jobs:
2525
runs-on: ${{ matrix.os }}
2626
strategy:
2727
matrix:
28-
build: [stable, nightly, 1.63]
28+
build: [stable, nightly, 1.65]
2929
include:
3030
- build: stable
3131
os: ubuntu-latest
3232
rust: stable
3333
- build: nightly
3434
os: ubuntu-latest
3535
rust: nightly
36-
- build: 1.63
36+
- build: 1.65
3737
os: ubuntu-latest
38-
rust: 1.63
38+
rust: 1.65
3939

4040
env:
4141
# -D warnings is commented out in our install-rust action; re-add it here.
@@ -48,19 +48,16 @@ jobs:
4848
with:
4949
toolchain: ${{ matrix.rust }}
5050

51-
- name: Use specific dependency versions for Rust 1.63 compatibility.
52-
if: matrix.rust == '1.63'
51+
- name: Use specific dependency versions for Rust 1.65 compatibility.
52+
if: matrix.rust == '1.65'
5353
run: |
54-
cargo update --package=dashmap --precise 5.4.0
55-
cargo update --package=regex --precise=1.9.0
5654
cargo update --package=half --precise=2.2.1
5755
cargo update --package=flate2 --precise=1.0.35
5856
cargo update --package=syn --precise=2.0.106
5957
cargo update --package=textwrap --precise=0.16.1
60-
cargo update --package=once_cell --precise=1.20.3
61-
cargo update --package=parking_lot --precise=0.12.3
62-
cargo update --package=parking_lot_core --precise=0.9.10
63-
cargo update --package=lock_api --precise=0.4.12
58+
cargo update --package=parking_lot --precise=0.12.4
59+
cargo update --package=parking_lot_core --precise=0.9.11
60+
cargo update --package=lock_api --precise=0.4.13
6461
cargo update --package=rayon --precise=1.10.0
6562
cargo update --package=rayon-core --precise=1.12.1
6663
cargo update --package=windows-sys --precise=0.60.2
@@ -107,13 +104,13 @@ jobs:
107104
aarch64-linux-android
108105
aarch64-apple-ios
109106
i686-pc-windows-msvc
110-
- if: matrix.rust != '1.63'
107+
- if: matrix.rust != '1.65'
111108
run: >
112109
rustup target add
113110
wasm32-wasip1
114111
wasm32-wasip2
115112
x86_64-unknown-fuchsia
116-
- if: matrix.rust == '1.63'
113+
- if: matrix.rust == '1.65'
117114
run: rustup target add x86_64-fuchsia
118115

119116
- run: cargo check --workspace --release -vv --all-targets
@@ -129,13 +126,13 @@ jobs:
129126
- run: cargo check --workspace --release -vv --target=x86_64-apple-darwin --features=all-apis --all-targets
130127
- run: cargo check --workspace --release -vv --target=x86_64-unknown-freebsd --features=all-apis --all-targets
131128
- run: cargo check --workspace --release -vv --target=x86_64-unknown-netbsd --features=all-apis --all-targets
132-
- if: matrix.rust != '1.63'
129+
- if: matrix.rust != '1.65'
133130
run: cargo check --workspace --release -vv --target=wasm32-wasip1 --features=all-apis
134-
- if: matrix.rust != '1.63'
131+
- if: matrix.rust != '1.65'
135132
run: cargo check --workspace --release -vv --target=wasm32-wasip2 --features=all-apis
136-
- if: matrix.rust != '1.63'
133+
- if: matrix.rust != '1.65'
137134
run: cargo check --workspace --release -vv --target=x86_64-unknown-fuchsia --features=all-apis --all-targets
138-
- if: matrix.rust == '1.63'
135+
- if: matrix.rust == '1.65'
139136
run: cargo check --workspace --release -vv --target=x86_64-fuchsia --features=all-apis --all-targets
140137
- run: cargo check --workspace --release -vv --target=x86_64-unknown-illumos --features=all-apis --all-targets
141138
- run: cargo check --workspace --release -vv --target=i686-unknown-linux-gnu --features=all-apis --all-targets
@@ -291,14 +288,14 @@ jobs:
291288
powerpc-linux-stable,
292289
powerpc64le-linux-stable,
293290
arm-linux-stable,
294-
ubuntu-1.63,
295-
i686-linux-1.63,
296-
aarch64-linux-1.63,
297-
riscv64-linux-1.63,
298-
s390x-linux-1.63,
291+
ubuntu-1.65,
292+
i686-linux-1.65,
293+
aarch64-linux-1.65,
294+
riscv64-linux-1.65,
295+
s390x-linux-1.65,
299296
powerpc64le-linux,
300-
powerpc64le-linux-1.63,
301-
arm-linux-1.63,
297+
powerpc64le-linux-1.65,
298+
arm-linux-1.65,
302299
macos-latest,
303300
macos-15-intel,
304301
macos-14,
@@ -437,64 +434,64 @@ jobs:
437434
qemu: qemu-arm
438435
qemu_args: -L /usr/arm-linux-gnueabi
439436
qemu_target: arm-linux-user
440-
- build: ubuntu-1.63
437+
- build: ubuntu-1.65
441438
os: ubuntu-latest
442-
rust: 1.63
443-
- build: i686-linux-1.63
439+
rust: 1.65
440+
- build: i686-linux-1.65
444441
os: ubuntu-latest
445-
rust: 1.63
442+
rust: 1.65
446443
target: i686-unknown-linux-gnu
447444
gcc_package: gcc-i686-linux-gnu
448445
gcc: i686-linux-gnu-gcc
449446
libc_package: libc-dev-i386-cross
450-
- build: aarch64-linux-1.63
447+
- build: aarch64-linux-1.65
451448
os: ubuntu-latest
452-
rust: 1.63
449+
rust: 1.65
453450
target: aarch64-unknown-linux-gnu
454451
gcc_package: gcc-aarch64-linux-gnu
455452
gcc: aarch64-linux-gnu-gcc
456453
qemu: qemu-aarch64
457454
qemu_args: -L /usr/aarch64-linux-gnu
458455
qemu_target: aarch64-linux-user
459-
- build: riscv64-linux-1.63
456+
- build: riscv64-linux-1.65
460457
os: ubuntu-latest
461-
rust: 1.63
458+
rust: 1.65
462459
target: riscv64gc-unknown-linux-gnu
463460
gcc_package: gcc-riscv64-linux-gnu
464461
gcc: riscv64-linux-gnu-gcc
465462
qemu: qemu-riscv64
466463
qemu_args: -L /usr/riscv64-linux-gnu
467464
qemu_target: riscv64-linux-user
468-
- build: s390x-linux-1.63
465+
- build: s390x-linux-1.65
469466
os: ubuntu-latest
470-
rust: 1.63
467+
rust: 1.65
471468
target: s390x-unknown-linux-gnu
472469
gcc_package: gcc-s390x-linux-gnu
473470
gcc: s390x-linux-gnu-gcc
474471
qemu: qemu-s390x
475472
qemu_args: -L /usr/s390x-linux-gnu
476473
qemu_target: s390x-linux-user
477-
- build: powerpc-linux-1.63
474+
- build: powerpc-linux-1.65
478475
os: ubuntu-latest
479-
rust: 1.63
476+
rust: 1.65
480477
target: powerpc-unknown-linux-gnu
481478
gcc_package: gcc-powerpc-linux-gnu
482479
gcc: powerpc-linux-gnu-gcc
483480
qemu: qemu-ppc
484481
qemu_args: -L /usr/powerpc-linux-gnu
485482
qemu_target: ppc-linux-user
486-
- build: powerpc64le-linux-1.63
483+
- build: powerpc64le-linux-1.65
487484
os: ubuntu-latest
488-
rust: 1.63
485+
rust: 1.65
489486
target: powerpc64le-unknown-linux-gnu
490487
gcc_package: gcc-powerpc64le-linux-gnu
491488
gcc: powerpc64le-linux-gnu-gcc
492489
qemu: qemu-ppc64le
493490
qemu_args: -L /usr/powerpc64le-linux-gnu
494491
qemu_target: ppc64le-linux-user
495-
- build: arm-linux-1.63
492+
- build: arm-linux-1.65
496493
os: ubuntu-latest
497-
rust: 1.63
494+
rust: 1.65
498495
target: armv5te-unknown-linux-gnueabi
499496
gcc_package: gcc-arm-linux-gnueabi
500497
gcc: arm-linux-gnueabi-gcc
@@ -585,19 +582,16 @@ jobs:
585582
ninja -C build install
586583
if: matrix.qemu != '' && matrix.os == 'ubuntu-latest'
587584

588-
- name: Use specific dependency versions for Rust 1.63 compatibility.
589-
if: matrix.rust == '1.63'
585+
- name: Use specific dependency versions for Rust 1.65 compatibility.
586+
if: matrix.rust == '1.65'
590587
run: |
591-
cargo update --package=dashmap --precise 5.4.0
592-
cargo update --package=regex --precise=1.9.0
593588
cargo update --package=half --precise=2.2.1
594589
cargo update --package=flate2 --precise=1.0.35
595590
cargo update --package=syn --precise=2.0.106
596591
cargo update --package=textwrap --precise=0.16.1
597-
cargo update --package=once_cell --precise=1.20.3
598-
cargo update --package=parking_lot --precise=0.12.3
599-
cargo update --package=parking_lot_core --precise=0.9.10
600-
cargo update --package=lock_api --precise=0.4.12
592+
cargo update --package=parking_lot --precise=0.12.4
593+
cargo update --package=parking_lot_core --precise=0.9.11
594+
cargo update --package=lock_api --precise=0.4.13
601595
cargo update --package=rayon --precise=1.10.0
602596
cargo update --package=rayon-core --precise=1.12.1
603597
cargo update --package=windows-sys --precise=0.60.2

Cargo.toml

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ edition = "2021"
1313
keywords = ["api", "file", "network", "safe", "syscall"]
1414
categories = ["os::unix-apis", "date-and-time", "filesystem", "network-programming"]
1515
include = ["src", "build.rs", "Cargo.toml", "COPYRIGHT", "LICENSE*", "/*.md", "benches"]
16-
rust-version = "1.63"
16+
rust-version = "1.65"
1717

1818
[hints]
1919
# Most users use a fraction of the rustix API surface area, so this reduces compilation times
@@ -268,7 +268,6 @@ check-cfg = [
268268
'cfg(rustc_diagnostics)',
269269
'cfg(solarish)',
270270
'cfg(staged_api)',
271-
'cfg(static_assertions)',
272271
'cfg(thumb_mode)',
273272
'cfg(wasi)',
274273
'cfg(wasi_ext)',

README.md

Lines changed: 7 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@ more portable APIs built on this functionality, see the [`cap-std`], [`memfd`],
3333

3434
* linux_raw, which uses raw Linux system calls and vDSO calls, and is
3535
supported on Linux on x86-64, x86, aarch64, riscv64gc, powerpc64le,
36-
arm (v5 onwards), mipsel, and mips64el, with stable, nightly, and 1.63 Rust.
36+
arm (v5 onwards), mipsel, and mips64el, with stable, nightly, and 1.65 Rust.
3737
- By being implemented entirely in Rust, avoiding `libc`, `errno`, and pthread
3838
cancellation, and employing some specialized optimizations, most functions
3939
compile down to very efficient code, which can often be fully inlined into
@@ -157,9 +157,11 @@ safety types rather than `RawFd`, and the flags parameters to functions such as
157157

158158
## Minimum Supported Rust Version (MSRV)
159159

160-
This crate currently works on the version of [Rust on Debian stable], which is
161-
currently [Rust 1.63]. This policy may change in the future, in minor version
162-
releases, so users using a fixed version of Rust should pin to a specific
160+
This crate has a Minimum Supported Rust Version (MSRV) of [Rust 1.65].
161+
162+
The MSRV may change in future minor versions; however, the current policy is
163+
that it will not be increased beyond the version of [Rust on Debian stable].
164+
Users who rely on a fixed version of Rust should pin to a specific
163165
version of this crate.
164166

165167
## Minimum Linux Version
@@ -172,7 +174,7 @@ The specifics of this policy may change in the future, but we intend it to
172174
always reflect “very old” Linux versions.
173175

174176
[MSRV]: #minimum-supported-rust-version-msrv
175-
[Rust 1.63]: https://blog.rust-lang.org/2022/08/11/Rust-1.63.0.html
177+
[Rust 1.65]: https://blog.rust-lang.org/2022/11/03/Rust-1.65.0/
176178
[any current Rust target]: https://doc.rust-lang.org/nightly/rustc/platform-support.html
177179
[kernel.org]: https://www.kernel.org/releases.html
178180
[Rust on Debian stable]: https://packages.debian.org/stable/rust/rustc

build.rs

Lines changed: 0 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -79,11 +79,6 @@ fn main() {
7979
use_feature_or_nothing("error_in_core");
8080
}
8181

82-
// Feature needed for testing.
83-
if use_static_assertions() {
84-
use_feature("static_assertions");
85-
}
86-
8782
// `LowerExp`/`UpperExp` for `NonZeroI32` etc.
8883
if has_lower_upper_exp_for_non_zero() {
8984
use_feature("lower_upper_exp_for_non_zero");
@@ -197,11 +192,6 @@ fn main() {
197192
println!("cargo:rerun-if-env-changed=CARGO_CFG_MIRI");
198193
}
199194

200-
fn use_static_assertions() -> bool {
201-
// `offset_from` was made const in Rust 1.65.
202-
can_compile("const unsafe fn foo(p: *const u8) -> isize { p.offset_from(p) }")
203-
}
204-
205195
fn use_thumb_mode() -> bool {
206196
// In thumb mode, r7 is reserved.
207197
!can_compile("pub unsafe fn f() { core::arch::asm!(\"udf #16\", in(\"r7\") 0); }")

src/lib.rs

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -153,15 +153,10 @@ extern crate rustc_std_workspace_alloc as alloc;
153153
#[cfg(all(feature = "alloc", not(feature = "rustc-dep-of-std")))]
154154
extern crate alloc;
155155

156-
// Use `static_assertions` macros if we have them, or a polyfill otherwise.
157-
#[cfg(all(test, static_assertions))]
156+
#[cfg(test)]
158157
#[macro_use]
159158
#[allow(unused_imports)]
160159
extern crate static_assertions;
161-
#[cfg(all(test, not(static_assertions)))]
162-
#[macro_use]
163-
#[allow(unused_imports)]
164-
mod static_assertions;
165160

166161
pub mod buffer;
167162
#[cfg(not(windows))]

src/static_assertions.rs

Lines changed: 0 additions & 36 deletions
This file was deleted.

0 commit comments

Comments
 (0)