From 0f1717675f10b7567fdc4782cff47eedb88e19e5 Mon Sep 17 00:00:00 2001 From: Dominic Date: Sat, 6 Jul 2024 22:19:25 +0200 Subject: [PATCH] move the codegen'ed allow somewhere else --- build.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/build.rs b/build.rs index b090f5f..b218bb6 100644 --- a/build.rs +++ b/build.rs @@ -31,7 +31,6 @@ impl AssetsWriter { fn new>(path: P) -> Self { let mut file = File::create(path).expect("Failed to create assets file"); writeln!(file, "// @generated").unwrap(); - writeln!(file, "#![allow(dead_code)]").unwrap(); Self { file, root: Assets::default() @@ -77,6 +76,7 @@ impl AssetsWriter { writeln!(file, "}}")?; } + writeln!(file, "{indent}#[allow(dead_code)]")?; writeln!(file, "{indent}pub struct Assets {{")?; for asset_name in root.assets.keys() { writeln!(