Skip to content

Commit 719ca30

Browse files
committed
fix clippy beta
1 parent 7bd8df8 commit 719ca30

File tree

9 files changed

+10
-7
lines changed

9 files changed

+10
-7
lines changed

.github/workflows/ci.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,7 @@ jobs:
4444
python-version: "3.12"
4545
- name: resolve MSRV
4646
id: resolve-msrv
47-
run: echo MSRV=`python -c 'import tomllib; print(tomllib.load(open("Cargo.toml", "rb"))["package"]["rust-version"])'` >> $GITHUB_OUTPUT
47+
run: echo MSRV=`python -c 'import tomllib; print(tomllib.load(open("Cargo.toml", "rb"))["workspace"]["package"]["rust-version"])'` >> $GITHUB_OUTPUT
4848

4949
semver-checks:
5050
if: github.ref != 'refs/heads/main'

Cargo.toml

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ categories = ["api-bindings", "development-tools::ffi"]
1212
license = "MIT OR Apache-2.0"
1313
exclude = ["/.gitignore", ".cargo/config", "/codecov.yml", "/Makefile", "/pyproject.toml", "/noxfile.py", "/.github", "/tests/test_compile_error.rs", "/tests/ui"]
1414
edition = "2021"
15-
rust-version = "1.63"
15+
rust-version.workspace = true
1616

1717
[dependencies]
1818
cfg-if = "1.0"
@@ -144,6 +144,7 @@ members = [
144144
"pytests",
145145
"examples",
146146
]
147+
package.rust-version = "1.63"
147148

148149
[package.metadata.docs.rs]
149150
no-default-features = true

examples/Cargo.toml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@ name = "pyo3-examples"
33
version = "0.0.0"
44
publish = false
55
edition = "2021"
6+
rust-version.workspace = true
67

78
[dev-dependencies]
89
pyo3 = { path = "..", features = ["auto-initialize", "extension-module"] }

pyo3-build-config/Cargo.toml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@ repository = "https://github.com/pyo3/pyo3"
99
categories = ["api-bindings", "development-tools::ffi"]
1010
license = "MIT OR Apache-2.0"
1111
edition = "2021"
12+
rust-version.workspace = true
1213

1314
[dependencies]
1415
once_cell = "1"

pyo3-build-config/src/impl_.rs

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1122,11 +1122,7 @@ impl BuildFlags {
11221122
Self(
11231123
BuildFlags::ALL
11241124
.iter()
1125-
.filter(|flag| {
1126-
config_map
1127-
.get_value(flag.to_string())
1128-
.map_or(false, |value| value == "1")
1129-
})
1125+
.filter(|flag| config_map.get_value(flag.to_string()) == Some("1"))
11301126
.cloned()
11311127
.collect(),
11321128
)

pyo3-ffi/Cargo.toml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,7 @@ categories = ["api-bindings", "development-tools::ffi"]
1010
license = "MIT OR Apache-2.0"
1111
edition = "2021"
1212
links = "python"
13+
rust-version.workspace = true
1314

1415
[dependencies]
1516
libc = "0.2.62"

pyo3-macros-backend/Cargo.toml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@ repository = "https://github.com/pyo3/pyo3"
99
categories = ["api-bindings", "development-tools::ffi"]
1010
license = "MIT OR Apache-2.0"
1111
edition = "2021"
12+
rust-version.workspace = true
1213

1314
# Note: we use default-features = false for proc-macro related crates
1415
# not to depend on proc-macro itself.

pyo3-macros/Cargo.toml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@ repository = "https://github.com/pyo3/pyo3"
99
categories = ["api-bindings", "development-tools::ffi"]
1010
license = "MIT OR Apache-2.0"
1111
edition = "2021"
12+
rust-version.workspace = true
1213

1314
[lib]
1415
proc-macro = true

pytests/Cargo.toml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@ version = "0.1.0"
55
description = "Python-based tests for PyO3"
66
edition = "2021"
77
publish = false
8+
rust-version.workspace = true
89

910
[dependencies]
1011
pyo3 = { path = "../", features = ["extension-module"] }

0 commit comments

Comments
 (0)