diff options
| author | Oli Scherer <github333195615777966@oli-obk.de> | 2025-04-22 09:50:49 +0000 |
|---|---|---|
| committer | Oli Scherer <github333195615777966@oli-obk.de> | 2025-04-22 11:02:37 +0000 |
| commit | 5d2952100f587ee1badfd39280e6c90a28e35c3a (patch) | |
| tree | 78346d72f5c35cc937f8d08b49cb3a3306363820 /compiler/rustc_monomorphize/src | |
| parent | 9bfa31f632912180dc742809bcc51a97f2d7079d (diff) | |
| download | rust-5d2952100f587ee1badfd39280e6c90a28e35c3a.tar.gz rust-5d2952100f587ee1badfd39280e6c90a28e35c3a.zip | |
Use `is_lang_item` and `as_lang_item` instead of handrolling their logic
Diffstat (limited to 'compiler/rustc_monomorphize/src')
| -rw-r--r-- | compiler/rustc_monomorphize/src/partitioning.rs | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/compiler/rustc_monomorphize/src/partitioning.rs b/compiler/rustc_monomorphize/src/partitioning.rs index d7690a96e10..6bc8a0fc88c 100644 --- a/compiler/rustc_monomorphize/src/partitioning.rs +++ b/compiler/rustc_monomorphize/src/partitioning.rs @@ -223,7 +223,7 @@ where match mono_item.instantiation_mode(cx.tcx) { InstantiationMode::GloballyShared { .. } => {} InstantiationMode::LocalCopy => { - if Some(mono_item.def_id()) != cx.tcx.lang_items().start_fn() { + if !cx.tcx.is_lang_item(mono_item.def_id(), LangItem::Start) { continue; } } |
