Skip to content

Commit 3f906c3

Browse files
committed
Add missing #[inline] to TargetOptions::link_args
1 parent a49592e commit 3f906c3

File tree

2 files changed

+4
-0
lines changed

2 files changed

+4
-0
lines changed

compiler/rustc_target/src/spec/link_args.rs

+2
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,8 @@ pub enum LazyLinkArgsState {
1919

2020
impl FnOnce<()> for LazyLinkArgsState {
2121
type Output = LinkArgs;
22+
23+
#[inline]
2224
extern "rust-call" fn call_once(self, _args: ()) -> Self::Output {
2325
match self {
2426
LazyLinkArgsState::Simple(flavor, args) => {

compiler/rustc_target/src/spec/mod.rs

+2
Original file line numberDiff line numberDiff line change
@@ -2390,10 +2390,12 @@ fn add_link_args(link_args: &mut LinkArgs, flavor: LinkerFlavor, args: &[&'stati
23902390
}
23912391

23922392
impl TargetOptions {
2393+
#[inline]
23932394
fn link_args(flavor: LinkerFlavor, args: &'static [&'static str]) -> LazyLinkArgs {
23942395
MaybeLazy::lazied(link_args::LazyLinkArgsState::Simple(flavor, args))
23952396
}
23962397

2398+
#[inline]
23972399
fn link_args_list(list: &'static [(LinkerFlavor, &'static [&'static str])]) -> LazyLinkArgs {
23982400
MaybeLazy::lazied(link_args::LazyLinkArgsState::List(list))
23992401
}

0 commit comments

Comments
 (0)