We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 5dd1877 commit 24932d6Copy full SHA for 24932d6
compiler/rustc_codegen_ssa/src/back/symbol_export.rs
@@ -376,14 +376,16 @@ fn exported_symbols_provider_local(
376
let should_export = has_generics
377
&& (def.as_local().is_some_and(|local_did| {
378
visibilities.public_at_level(local_did).is_some()
379
- }) || types.all(|arg| {
380
- arg.walk().all(|ty| {
381
- let Some(ty) = ty.as_type() else {
382
- return true;
383
- };
384
- !is_local_to_current_crate(ty)
385
- })
386
- }));
+ }) || (tcx.codegen_fn_attrs(mono_item.def_id()).inline
+ != rustc_attr_parsing::InlineAttr::None)
+ || types.all(|arg| {
+ arg.walk().all(|ty| {
+ let Some(ty) = ty.as_type() else {
+ return true;
+ };
+ !is_local_to_current_crate(ty)
387
+ })
388
+ }));
389
390
if should_export {
391
let symbol = ExportedSymbol::Generic(def, args);
0 commit comments