Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[naga] Require hashbrown's serde feature as a dev-dependency. #7039

Open
wants to merge 1 commit into
base: trunk
Choose a base branch
from

Conversation

jimblandy
Copy link
Member

@jimblandy jimblandy commented Jan 30, 2025

Add hashbrown with the "serde" feature as a development dependency for Naga. Regardless of whether Naga's deserialize feature is enabled, the snapshot tests need to deserialize parameters saved in files as RON text.

It would also suffice to use std::collections::HashSet in the snapshot tests, although we would need to build a naga::FashHashSet from the std HashSet at one point. Adding the dev-dependency seems slightly simpler.

Fixes #7038.

@jimblandy jimblandy added area: tests Improvements or issues with our test suite naga Shader Translator labels Jan 30, 2025
@jimblandy jimblandy requested a review from a team as a code owner January 30, 2025 20:17
Add `hashbrown` with the `"serde"` feature as a development dependency
for Naga. Regardless of whether Naga's `deserialize` feature is
enabled, the snapshot tests need to deserialize parameters saved in
files as RON text.

It would also suffice to use `std::collections::HashSet` in the
snapshot tests, although we would need to build a `naga::FashHashSet`
from the std `HashSet` at one point. Adding the dev-dependency seems
slightly simpler.

Fixes gfx-rs#7038.
@jimblandy jimblandy force-pushed the naga-snapshot-hashbrown-serde branch from 54781b9 to d04df38 Compare January 30, 2025 20:18
@@ -117,3 +117,4 @@ ron = "0.8.0"
rspirv = { version = "0.11", git = "https://github.com/gfx-rs/rspirv", rev = "b969f175d5663258b4891e44b76c1544da9661ab" }
serde = { workspace = true, features = ["default", "derive"] }
spirv = { version = "0.3", features = ["deserialize"] }
hashbrown = { workspace = true, features = ["serde"] }
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sort pls

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area: tests Improvements or issues with our test suite naga Shader Translator
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Naga tests don't build without features
2 participants