From 76fe48543cfbbed38567135093159f17b442dc0c Mon Sep 17 00:00:00 2001 From: hyd-dev Date: Fri, 2 Jul 2021 16:08:27 +0800 Subject: [PATCH] Update for `TyCtxt::crates()` change --- rust-version | 2 +- src/helpers.rs | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/rust-version b/rust-version index a8a75e9f046..9890818ee95 100644 --- a/rust-version +++ b/rust-version @@ -1 +1 @@ -e98897e5dc9898707bf4331c43b2e76ab7e282fe +46ae6ee65df19c6a3fb683499c1203e749975e60 diff --git a/src/helpers.rs b/src/helpers.rs index b99a446577a..d53b2969fb5 100644 --- a/src/helpers.rs +++ b/src/helpers.rs @@ -20,7 +20,7 @@ impl<'mir, 'tcx: 'mir> EvalContextExt<'mir, 'tcx> for crate::MiriEvalContext<'mi /// Gets an instance for a path. fn try_resolve_did<'mir, 'tcx>(tcx: TyCtxt<'tcx>, path: &[&str]) -> Option { - tcx.crates().iter().find(|&&krate| tcx.crate_name(krate).as_str() == path[0]).and_then( + tcx.crates(()).iter().find(|&&krate| tcx.crate_name(krate).as_str() == path[0]).and_then( |krate| { let krate = DefId { krate: *krate, index: CRATE_DEF_INDEX }; let mut items = tcx.item_children(krate);