enforce stricter lints, drop discarded results properly
This commit is contained in:
+3
-3
@@ -39,18 +39,18 @@ fn compile_shaders() {
|
||||
"cargo:warning=fxc failed for {entry}: {}",
|
||||
String::from_utf8_lossy(&o.stderr)
|
||||
);
|
||||
let _ = std::fs::write(&dst, []);
|
||||
drop(std::fs::write(&dst, []));
|
||||
}
|
||||
Err(e) => {
|
||||
println!("cargo:warning=could not run fxc for {entry}: {e}");
|
||||
let _ = std::fs::write(&dst, []);
|
||||
drop(std::fs::write(&dst, []));
|
||||
}
|
||||
}
|
||||
}
|
||||
None => {
|
||||
// No SDK on the build machine - emit an empty .cso; capture.rs
|
||||
// detects the zero size and compiles the HLSL at runtime.
|
||||
let _ = std::fs::write(&dst, []);
|
||||
drop(std::fs::write(&dst, []));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user