Fix LTO errors by not adding AlwaysInline to __rust_alloc_error_handler_should_panic_v2
This commit is contained in:
@@ -104,7 +104,8 @@ fn create_const_value_function(
|
||||
tcx.sess.default_visibility(),
|
||||
)));
|
||||
|
||||
func.add_attribute(FnAttribute::AlwaysInline);
|
||||
// FIXME(antoyo): cg_llvm sets AlwaysInline, but AlwaysInline is different in GCC and using
|
||||
// it here will causes linking errors when using LTO.
|
||||
func.add_attribute(FnAttribute::Inline);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user