Skip to content

Commit b054a19

Browse files
author
hyd-dev
committed
We don't need to check SymbolExportLevel
1 parent 382295c commit b054a19

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

src/shims/foreign_items.rs

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -154,8 +154,9 @@ pub trait EvalContextExt<'mir, 'tcx: 'mir>: crate::MiriEvalContextExt<'mir, 'tcx
154154
|(num, &linkage)| (linkage != Linkage::NotLinked).then_some(CrateNum::new(num + 1)),
155155
))
156156
{
157-
// FIXME: Do we need to check `SymbolExportLevel` (the `_` below)?
158-
for &(symbol, _) in tcx.exported_symbols(cnum) {
157+
// We can ignore `_export_level` here: we are a Rust crate, and everything is exported
158+
// from a Rust crate.
159+
for &(symbol, _export_level) in tcx.exported_symbols(cnum) {
159160
if let ExportedSymbol::NonGeneric(def_id) = symbol {
160161
let attrs = tcx.codegen_fn_attrs(def_id);
161162
let symbol_name = if let Some(export_name) = attrs.export_name {

0 commit comments

Comments
 (0)