From cd9d5edd5cdbb65269d3c0fc84358d0aed8088ad Mon Sep 17 00:00:00 2001 From: Connor Fitzgerald Date: Wed, 25 Oct 2023 15:48:17 -0400 Subject: [PATCH] Further iteration --- .github/workflows/ci.yml | 2 +- .github/workflows/lazy.yml | 6 +++--- naga/src/span.rs | 3 ++- naga/xtask/src/main.rs | 2 +- 4 files changed, 7 insertions(+), 6 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 21e8164a8a..077d75feff 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -376,7 +376,7 @@ jobs: run: | set -e - cargo xtask test --llvm-cov --all-features + cargo xtask test --llvm-cov - uses: actions/upload-artifact@v3 if: always() # We want artifacts even if the tests fail. diff --git a/.github/workflows/lazy.yml b/.github/workflows/lazy.yml index 665c21871c..385ca2032e 100644 --- a/.github/workflows/lazy.yml +++ b/.github/workflows/lazy.yml @@ -37,7 +37,7 @@ jobs: - name: Convert shaders run: | cd naga - for file in data/*.spv do echo "Translating" ${file} && ../target/release/naga --validate 27 ${file} ${file}.metal; done + for file in data/*.spv ; do echo "Translating" ${file} && target/release/naga --validate 27 ${file} ${file}.metal; done parse-vulkan-tutorial-shaders: name: Parse Sascha Willems Vulkan tutorial shaders @@ -168,12 +168,12 @@ jobs: - name: Test minimal (without span) run: | cd naga - cargo nextest run --features validate -p naga + cargo nextest run -p naga --features validate - name: Test all (without validation) run: | cd naga - cargo nextest run --features wgsl-in,wgsl-out,glsl-in,glsl-out,spv-in,spv-out,msl-out,hlsl-out,dot-out --workspace + cargo nextest run -p naga --features wgsl-in,wgsl-out,glsl-in,glsl-out,spv-in,spv-out,msl-out,hlsl-out,dot-out - name: Check snapshots (without validation) run: | diff --git a/naga/src/span.rs b/naga/src/span.rs index 0bc97ff460..4dee0f0db3 100644 --- a/naga/src/span.rs +++ b/naga/src/span.rs @@ -189,7 +189,7 @@ impl WithSpan { } /// Add a new span with description. - #[cfg_attr(not(feature = "span"), allow(unused_variables, unused_mut))] + #[cfg_attr(not(feature = "span"), allow(unused_variables, unused_mut, clippy::missing_const_for_fn))] pub fn with_span(mut self, span: Span, description: S) -> Self where S: ToString, @@ -249,6 +249,7 @@ impl WithSpan { } #[cfg(not(feature = "span"))] + #[allow(clippy::missing_const_for_fn)] /// Return a [`SourceLocation`] for our first span, if we have one. pub fn location(&self, _source: &str) -> Option { None diff --git a/naga/xtask/src/main.rs b/naga/xtask/src/main.rs index 48e3f52764..8325c1961d 100644 --- a/naga/xtask/src/main.rs +++ b/naga/xtask/src/main.rs @@ -190,7 +190,7 @@ fn run(args: Args) -> anyhow::Result<()> { ValidateSubcommand::Wgsl => { visit_files(snapshots_base_out, "wgsl/*.wgsl", |path| { ack_visiting(path); - EasyCommand::new("cargo", |cmd| cmd.args(["run", "--"]).arg(path)).success() + EasyCommand::new("cargo", |cmd| cmd.args(["run", "-p", "naga-cli", "--"]).arg(path)).success() }) } ValidateSubcommand::Hlsl(cmd) => {