From 711aa1a834a3adfdc07595bcee7d60d54e483047 Mon Sep 17 00:00:00 2001 From: Jim Blandy Date: Sun, 24 Sep 2023 16:34:43 -0700 Subject: [PATCH] snapshots: convert_spv: Don't validate the module twice. Remove the call to `Validator::validate` in `convert_spv`, since it directly follows the call to `check_targets`, which also called `Validator::validate`. The only difference between the two is whether `Parameters::god_mode` is respected, but this difference doesn't seem to have been deliberate: at the time the call to `check_targets` was added to `convert_spv` (5f21cf360, 2021-02-17), the two calls were exactly the same. --- tests/snapshots.rs | 6 ------ 1 file changed, 6 deletions(-) diff --git a/tests/snapshots.rs b/tests/snapshots.rs index 4dcf1dd4d..80b083466 100644 --- a/tests/snapshots.rs +++ b/tests/snapshots.rs @@ -691,12 +691,6 @@ fn convert_spv(name: &str, adjust_coordinate_space: bool, targets: Targets) { ) .unwrap(); check_targets(&mut module, name, targets, None); - naga::valid::Validator::new( - naga::valid::ValidationFlags::all(), - naga::valid::Capabilities::default(), - ) - .validate(&module) - .unwrap(); } #[cfg(feature = "spv-in")]