From 9f5373107ae292a0d787fc89ae3c0138a2af15cc Mon Sep 17 00:00:00 2001 From: Weicao-CatilGrass <1992414357@qq.com> Date: Mon, 9 Mar 2026 20:25:12 +0800 Subject: Replace warnings with panics in Windows GUI build script --- build.rs | 13 +++---------- 1 file changed, 3 insertions(+), 10 deletions(-) diff --git a/build.rs b/build.rs index 4c8cec0..0bd7e8d 100644 --- a/build.rs +++ b/build.rs @@ -74,11 +74,7 @@ fn build_win32_gui() { .expect("Failed to execute build script"); if !status.success() { - eprintln!( - "Warning: Build script failed with exit code: {:?}", - status.code() - ); - return; + panic!("Build script failed with exit code: {:?}", status.code()); } let exe_path = Path::new(crate_root) @@ -89,13 +85,10 @@ fn build_win32_gui() { let dest_path = target_dir.join(EXE_NAME); if let Err(e) = fs::copy(&exe_path, &dest_path) { - eprintln!( - "Warning: Failed to copy executable to build directory: {}", - e - ); + panic!("Failed to copy executable to build directory: {}", e); } } else { - eprintln!("Warning: Executable not found at: {:?}", exe_path); + panic!("Executable not found at: {:?}", exe_path); } } -- cgit