diff --git a/.github/workflows/ci.yaml b/.github/workflows/ci.yaml index 14a154a..d2469e1 100644 --- a/.github/workflows/ci.yaml +++ b/.github/workflows/ci.yaml @@ -8,14 +8,9 @@ jobs: runs-on: ubuntu-latest strategy: matrix: - rust: [1.56.0, stable, beta, nightly] + rust: [1.71.0, stable, beta, nightly] steps: - uses: actions/checkout@v4 - - uses: actions/cache@v4 - if: startsWith(matrix.rust, '1') - with: - path: ~/.cargo/registry/index - key: cargo-${{ matrix.rust }}-git-index - uses: dtolnay/rust-toolchain@master with: toolchain: ${{ matrix.rust }} @@ -39,7 +34,7 @@ jobs: runs-on: ubuntu-latest steps: - uses: actions/checkout@v4 - - uses: dtolnay/rust-toolchain@1.70.0 + - uses: dtolnay/rust-toolchain@1.71.0 with: components: rustfmt - run: cargo fmt --all --check diff --git a/.github/workflows/main.yaml b/.github/workflows/main.yaml index e181a3d..ac37353 100644 --- a/.github/workflows/main.yaml +++ b/.github/workflows/main.yaml @@ -13,14 +13,9 @@ jobs: runs-on: ubuntu-latest strategy: matrix: - rust: [1.56.0, stable] + rust: [1.71.0, stable] steps: - uses: actions/checkout@v4 - - uses: actions/cache@v4 - if: startsWith(matrix.rust, '1') - with: - path: ~/.cargo/registry/index - key: cargo-${{ matrix.rust }}-git-index - uses: dtolnay/rust-toolchain@master with: toolchain: ${{ matrix.rust }} diff --git a/.github/workflows/pr.yaml b/.github/workflows/pr.yaml index 1cadac0..a7af211 100644 --- a/.github/workflows/pr.yaml +++ b/.github/workflows/pr.yaml @@ -9,14 +9,9 @@ jobs: runs-on: ubuntu-latest strategy: matrix: - rust: [1.56.0, stable] + rust: [1.71.0, stable] steps: - uses: actions/checkout@v4 - - uses: actions/cache@v4 - if: startsWith(matrix.rust, '1') - with: - path: ~/.cargo/registry/index - key: cargo-${{ matrix.rust }}-git-index - uses: dtolnay/rust-toolchain@master with: toolchain: ${{ matrix.rust }} diff --git a/Cargo.toml b/Cargo.toml index 4a13a07..532017f 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -8,16 +8,16 @@ categories = [ "science" ] license = "MIT OR Apache-2.0" name = "num-derive" repository = "https://github.com/rust-num/num-derive" -version = "0.4.2" +version = "0.5.0" readme = "README.md" exclude = ["/ci/*", "/.github/*"] edition = "2021" -rust-version = "1.56.0" +rust-version = "1.71.0" [dependencies] proc-macro2 = "1" quote = "1" -syn = "2.0.5" +syn = "3" [dev-dependencies] num = "0.4" diff --git a/README.md b/README.md index 302b0d0..b36c8ce 100644 --- a/README.md +++ b/README.md @@ -2,7 +2,7 @@ [![crate](https://img.shields.io/crates/v/num-derive.svg)](https://crates.io/crates/num-derive) [![documentation](https://docs.rs/num-derive/badge.svg)](https://docs.rs/num-derive) -[![minimum rustc 1.56](https://img.shields.io/badge/rustc-1.56+-red.svg)](https://rust-lang.github.io/rfcs/2495-min-rust-version.html) +[![minimum rustc 1.71](https://img.shields.io/badge/rustc-1.71+-red.svg)](https://rust-lang.github.io/rfcs/2495-min-rust-version.html) [![build status](https://github.com/rust-num/num-derive/actions/workflows/main.yaml/badge.svg)](https://github.com/rust-num/num-derive/actions/workflows/main.yaml) Procedural macros to derive numeric traits in Rust. @@ -14,7 +14,7 @@ Add this to your `Cargo.toml`: ```toml [dependencies] num-traits = "0.2" -num-derive = "0.4" +num-derive = "0.5" ``` and this to your crate root: @@ -51,7 +51,7 @@ Release notes are available in [RELEASES.md](RELEASES.md). ## Compatibility -The `num-derive` crate is tested for rustc 1.56 and greater. +The `num-derive` crate is tested for rustc 1.71 and greater. ## License diff --git a/RELEASES.md b/RELEASES.md index bbf6d53..dead040 100644 --- a/RELEASES.md +++ b/RELEASES.md @@ -1,3 +1,10 @@ +# Release 0.5.0 (2026-07-20) + +- [Upgrade to `syn v3`.][71] + - This raises the minimum supported rustc to 1.71. + +[71]: https://github.com/rust-num/num-derive/pull/71 + # Release 0.4.2 (2024-02-06) - [Use anon-const to avoid RFC 3373 warnings.][62] diff --git a/ci/check/Cargo.toml b/ci/check/Cargo.toml index 573bbc9..3404b22 100644 --- a/ci/check/Cargo.toml +++ b/ci/check/Cargo.toml @@ -1,9 +1,9 @@ [package] name = "check" version = "0.1.0" -authors = ["Josh Stone "] edition = "2018" -rust-version = "1.56.0" +rust-version = "1.71.0" +publish = false [dependencies.num-derive] path = "../.." diff --git a/ci/import/Cargo.toml b/ci/import/Cargo.toml index 303d1d0..3aebf5c 100644 --- a/ci/import/Cargo.toml +++ b/ci/import/Cargo.toml @@ -1,10 +1,9 @@ [package] name = "import" version = "0.0.1" -authors = ["jean-airoldie <25088801+jean-airoldie@users.noreply.github.com>"] edition = "2018" +rust-version = "1.71.0" publish = false -rust-version = "1.56.0" [dependencies] num-derive = { path = "../.." } diff --git a/ci/rustup.sh b/ci/rustup.sh index 5289138..461e552 100755 --- a/ci/rustup.sh +++ b/ci/rustup.sh @@ -5,6 +5,6 @@ set -ex ci=$(dirname $0) -for version in 1.56.0 stable beta nightly; do +for version in 1.71.0 stable beta nightly; do rustup run "$version" "$ci/test_full.sh" done diff --git a/ci/test_full.sh b/ci/test_full.sh index ddbafcf..903ff80 100755 --- a/ci/test_full.sh +++ b/ci/test_full.sh @@ -3,7 +3,7 @@ set -e CRATE=num-derive -MSRV=1.56 +MSRV=1.71 get_rust_version() { local array=($(rustc --version)); diff --git a/src/lib.rs b/src/lib.rs index 207602b..49750c6 100644 --- a/src/lib.rs +++ b/src/lib.rs @@ -9,7 +9,6 @@ // except according to those terms. #![crate_type = "proc-macro"] -#![doc(html_root_url = "https://docs.rs/num-derive/0.3")] #![recursion_limit = "512"] //! Procedural macros to derive numeric traits in Rust. @@ -21,7 +20,7 @@ //! ```toml //! [dependencies] //! num-traits = "0.2" -//! num-derive = "0.3" +//! num-derive = "0.5" //! ``` //! //! Then you can derive traits on your own types: