diff options
| author | bors <bors@rust-lang.org> | 2021-05-13 13:37:32 +0000 |
|---|---|---|
| committer | bors <bors@rust-lang.org> | 2021-05-13 13:37:32 +0000 |
| commit | d2df620789cd82a6751320223cd3de87256bf15e (patch) | |
| tree | 54b3796748cfb316bc5d1e17dc9e64fbdfc2eda8 /compiler/rustc_codegen_ssa/src | |
| parent | 17b60b8738735d8d64d03601d1dad4001d1e5733 (diff) | |
| parent | c61e8face090e2b8a0a8eca535e8b58feee25625 (diff) | |
| download | rust-d2df620789cd82a6751320223cd3de87256bf15e.tar.gz rust-d2df620789cd82a6751320223cd3de87256bf15e.zip | |
Auto merge of #85110 - RalfJung:no-rustc_args_required_const, r=oli-obk
Remove rustc_args_required_const attribute Now that stdarch no longer needs it (thanks `@Amanieu!),` we can kill the `rustc_args_required_const` attribute. This means that lifetime extension of references to temporaries is the only remaining job that promotion is performing. :-) r? `@oli-obk` Fixes https://github.com/rust-lang/rust/issues/69493
Diffstat (limited to 'compiler/rustc_codegen_ssa/src')
| -rw-r--r-- | compiler/rustc_codegen_ssa/src/mir/rvalue.rs | 4 |
1 files changed, 0 insertions, 4 deletions
diff --git a/compiler/rustc_codegen_ssa/src/mir/rvalue.rs b/compiler/rustc_codegen_ssa/src/mir/rvalue.rs index 9917c23f121..530de3de9e8 100644 --- a/compiler/rustc_codegen_ssa/src/mir/rvalue.rs +++ b/compiler/rustc_codegen_ssa/src/mir/rvalue.rs @@ -14,7 +14,6 @@ use rustc_middle::ty::cast::{CastTy, IntTy}; use rustc_middle::ty::layout::HasTyCtxt; use rustc_middle::ty::{self, adjustment::PointerCast, Instance, Ty, TyCtxt}; use rustc_span::source_map::{Span, DUMMY_SP}; -use rustc_span::symbol::sym; use rustc_target::abi::{Abi, Int, LayoutOf, Variants}; impl<'a, 'tcx, Bx: BuilderMethods<'a, 'tcx>> FunctionCx<'a, 'tcx, Bx> { @@ -187,9 +186,6 @@ impl<'a, 'tcx, Bx: BuilderMethods<'a, 'tcx>> FunctionCx<'a, 'tcx, Bx> { mir::CastKind::Pointer(PointerCast::ReifyFnPointer) => { match *operand.layout.ty.kind() { ty::FnDef(def_id, substs) => { - if bx.cx().tcx().has_attr(def_id, sym::rustc_args_required_const) { - bug!("reifying a fn ptr that requires const arguments"); - } let instance = ty::Instance::resolve_for_fn_ptr( bx.tcx(), ty::ParamEnv::reveal_all(), |
