Skip to content

Commit c42e7c8

Browse files
committed
Reflect serde_derive required compiler in build script and rust-version metadata
1 parent 5b8e065 commit c42e7c8

File tree

3 files changed

+7
-7
lines changed

3 files changed

+7
-7
lines changed

serde/build.rs

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -78,11 +78,6 @@ fn main() {
7878
println!("cargo:rustc-cfg=no_num_nonzero");
7979
}
8080

81-
// Current minimum supported version of serde_derive crate is Rust 1.31.
82-
if minor < 31 {
83-
println!("cargo:rustc-cfg=no_serde_derive");
84-
}
85-
8681
// TryFrom, Atomic types, non-zero signed integers, and SystemTime::checked_add
8782
// stabilized in Rust 1.34:
8883
// https://blog.rust-lang.org/2019/04/11/Rust-1.34.0.html#tryfrom-and-tryinto
@@ -94,6 +89,11 @@ fn main() {
9489
println!("cargo:rustc-cfg=no_relaxed_trait_bounds");
9590
}
9691

92+
// Current minimum supported version of serde_derive crate is Rust 1.56.
93+
if minor < 56 {
94+
println!("cargo:rustc-cfg=no_serde_derive");
95+
}
96+
9797
// Support for #[cfg(target_has_atomic = "...")] stabilized in Rust 1.60.
9898
if minor < 60 {
9999
println!("cargo:rustc-cfg=no_target_has_atomic");

serde_derive/Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ keywords = ["serde", "serialization", "no_std", "derive"]
1111
license = "MIT OR Apache-2.0"
1212
readme = "crates-io.md"
1313
repository = "https://github.com/serde-rs/serde"
14-
rust-version = "1.31"
14+
rust-version = "1.56"
1515

1616
[features]
1717
default = []

serde_derive_internals/Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ include = ["lib.rs", "src/**/*.rs", "LICENSE-APACHE", "LICENSE-MIT"]
99
keywords = ["serde", "serialization"]
1010
license = "MIT OR Apache-2.0"
1111
repository = "https://github.com/serde-rs/serde"
12-
rust-version = "1.31"
12+
rust-version = "1.56"
1313

1414
[lib]
1515
path = "lib.rs"

0 commit comments

Comments
 (0)