Skip to content

Commit 4761e27

Browse files
[naga] Fix improper feature gates (#7484)
1 parent be16f8c commit 4761e27

File tree

3 files changed

+11
-5
lines changed

3 files changed

+11
-5
lines changed

Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -106,7 +106,7 @@ fern = "0.7"
106106
flume = "0.11"
107107
futures-lite = "2"
108108
glam = "0.29"
109-
half = "2.5" # We require 2.5 to have `Arbitrary` support.
109+
half = { version = "2.5", default-features = false } # We require 2.5 to have `Arbitrary` support.
110110
hashbrown = { version = "0.15.2", default-features = false, features = [
111111
"default-hasher",
112112
"inline-more",

naga/Cargo.toml

Lines changed: 9 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,13 @@ deserialize = [
5050
"hashbrown/serde",
5151
"indexmap/serde",
5252
]
53-
arbitrary = ["dep:arbitrary", "bitflags/arbitrary", "indexmap/arbitrary"]
53+
arbitrary = [
54+
"dep:arbitrary",
55+
"bitflags/arbitrary",
56+
"indexmap/arbitrary",
57+
"half/arbitrary",
58+
"half/std",
59+
]
5460
spv-in = ["dep:petgraph", "dep:spirv"]
5561
spv-out = ["dep:spirv"]
5662
wgsl-in = [
@@ -85,12 +91,12 @@ codespan-reporting = { workspace = true, default-features = false, features = [
8591
"termcolor",
8692
] }
8793
hashbrown.workspace = true
88-
half = { workspace = true, features = ["arbitrary", "num-traits"] }
94+
half = { workspace = true, default-features = false, features = ["num-traits"] }
8995
rustc-hash.workspace = true
9096
indexmap.workspace = true
9197
log = "0.4"
9298
# `half` requires 0.2.16 for `FromBytes` and `ToBytes`.
93-
num-traits = "0.2.16"
99+
num-traits = { version = "0.2.16", default-features = false }
94100
strum = { workspace = true, optional = true }
95101
spirv = { version = "0.3", optional = true }
96102
thiserror.workspace = true

tests/Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,7 @@ cfg-if.workspace = true
4444
ctor.workspace = true
4545
futures-lite.workspace = true
4646
glam.workspace = true
47-
half = { workspace = true, features = ["bytemuck"] }
47+
half = { workspace = true, features = ["bytemuck", "std"] }
4848
itertools.workspace = true
4949
image.workspace = true
5050
libtest-mimic.workspace = true

0 commit comments

Comments
 (0)