Sync from rust ed620cf969
This commit is contained in:
commit
e3d70e266b
1 changed files with 3 additions and 4 deletions
|
|
@ -348,10 +348,9 @@ pub(crate) fn codegen_terminator_call<'tcx>(
|
|||
|
||||
// Handle special calls like intrinsics and empty drop glue.
|
||||
let instance = if let ty::FnDef(def_id, substs) = *func.layout().ty.kind() {
|
||||
let instance = ty::Instance::resolve(fx.tcx, ty::ParamEnv::reveal_all(), def_id, substs)
|
||||
.unwrap()
|
||||
.unwrap()
|
||||
.polymorphize(fx.tcx);
|
||||
let instance =
|
||||
ty::Instance::expect_resolve(fx.tcx, ty::ParamEnv::reveal_all(), def_id, substs)
|
||||
.polymorphize(fx.tcx);
|
||||
|
||||
if fx.tcx.symbol_name(instance).name.starts_with("llvm.") {
|
||||
crate::intrinsics::codegen_llvm_intrinsic_call(
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue