diff options
Diffstat (limited to 'src/librustc_trans/callee.rs')
| -rw-r--r-- | src/librustc_trans/callee.rs | 10 |
1 files changed, 7 insertions, 3 deletions
diff --git a/src/librustc_trans/callee.rs b/src/librustc_trans/callee.rs index 52e6dce24ed..5231a516f62 100644 --- a/src/librustc_trans/callee.rs +++ b/src/librustc_trans/callee.rs @@ -19,9 +19,10 @@ use common::{self, CrateContext}; use consts; use declare; use llvm::{self, ValueRef}; -use monomorphize::{self, Instance}; +use monomorphize::Instance; use rustc::hir::def_id::DefId; -use rustc::ty::TypeFoldable; +use rustc::ty::{self, TypeFoldable}; +use rustc::traits; use rustc::ty::subst::Substs; use type_of; @@ -179,5 +180,8 @@ pub fn resolve_and_get_fn<'a, 'tcx>(ccx: &CrateContext<'a, 'tcx>, substs: &'tcx Substs<'tcx>) -> ValueRef { - get_fn(ccx, monomorphize::resolve(ccx.tcx(), def_id, substs)) + get_fn(ccx, ty::Instance::resolve(ccx.tcx(), + ty::ParamEnv::empty(traits::Reveal::All), + def_id, + substs).unwrap()) } |
