Skip to content

Commit a493e27

Browse files
committed
Auto merge of rust-lang#144678 - jdonszelmann:no-mangle-extern, r=bjorn3
Make no_mangle on foreign items explicit instead of implicit for a followup PR I'm working on I need some foreign items to mangle. I could add a new attribute: `no_no_mangle` or something silly like that but by explicitly putting `no_mangle` in the codegen fn attrs of foreign items we can default it to `no_mangle` and then easily remove it when we don't want it. I guess you'd know about this r? `@bjorn3.` Shouldn't be too hard to review :) Builds on rust-lang#144655 which should merge first.
2 parents 12087f1 + 68c1574 commit a493e27

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

clippy_lints/src/missing_inline.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -190,5 +190,5 @@ impl<'tcx> LateLintPass<'tcx> for MissingInline {
190190
/// and a rustc warning would be triggered, see #15301
191191
fn fn_is_externally_exported(cx: &LateContext<'_>, def_id: DefId) -> bool {
192192
let attrs = cx.tcx.codegen_fn_attrs(def_id);
193-
attrs.contains_extern_indicator()
193+
attrs.contains_extern_indicator(cx.tcx, def_id)
194194
}

0 commit comments

Comments
 (0)