give a bit more debug info when a function fails to codegen

This commit is contained in:
Folkert 2020-12-14 01:59:07 +01:00
parent 99a95b7200
commit 5e29ee1576

View file

@ -149,7 +149,8 @@ pub fn gen_from_mono_module(
// env.module.print_to_stderr(); // env.module.print_to_stderr();
// NOTE: If this fails, uncomment the above println to debug. // NOTE: If this fails, uncomment the above println to debug.
panic!( panic!(
"Non-main function failed LLVM verification. Uncomment the above println to debug!" r"Non-main function {:?} failed LLVM verification. Uncomment the above println to debug!",
fn_val.get_name(),
); );
} }
} }