// Returns a Value of the "eh_unwind_resume" lang item if one is defined,
// otherwise declares it as an external function.
Returns a Value of the "eh_unwind_resume" lang item if one is defined,
otherwise declares it as an external function.
Returns a Value of the " eh_unwind_resume " lang item if one is defined otherwise declares it as an external function .
pub fn eh_unwind_resume(&self) -> &'b Value {
        use attributes;
        let unwresume = &self.eh_unwind_resume;
        if let Some(llfn) = unwresume.get() {
            return llfn;
        }
        let tcx = self.tcx;
        assert!(self.sess().target.target.options.custom_unwind_resume);
        if let Some(def_id) = tcx.lang_items().eh_unwind_resume() {
            let llfn = callee::resolve_and_get_fn(self, def_id, tcx.intern_substs(&[]));
            unwresume.set(Some(llfn));
            return llfn;
        }
        let ty = tcx.mk_fn_ptr(ty::Binder::bind(tcx.mk_fn_sig(
            iter::once(tcx.mk_mut_ptr(tcx.types.u8)),
            tcx.types.never,
            false,
            hir::Unsafety::Unsafe,
            Abi::C
        )));
        let llfn = declare::declare_fn(self, "rust_eh_unwind_resume", ty);
        attributes::unwind(llfn, true);
        attributes::apply_target_cpu_attr(self, llfn);
        unwresume.set(Some(llfn));
        llfn
    }
pub fn eh_unwind_resume ( & self ) -> & ' b Value { use attributes ; let unwresume = & self . eh_unwind_resume ; if let Some ( llfn ) = unwresume . get ( ) { return llfn ; } let tcx = self . tcx ; assert ! ( self sess ( ) target target options custom_unwind_resume ) ; if let Some ( def_id ) = tcx . lang_items ( ) . eh_unwind_resume ( ) { let llfn = callee :: resolve_and_get_fn ( self , def_id , tcx . intern_substs ( & [ ] ) ) ; unwresume . set ( Some ( llfn ) ) ; return llfn ; } let ty = tcx . mk_fn_ptr ( ty :: Binder :: bind ( tcx . mk_fn_sig ( iter :: once ( tcx . mk_mut_ptr ( tcx . types . u8 ) ) , tcx . types . never , false , hir :: Unsafety :: Unsafe , Abi :: C ) ) ) ; let llfn = declare :: declare_fn ( self , " " , ty ) ; attributes :: unwind ( llfn , true ) ; attributes :: apply_target_cpu_attr ( self , llfn ) ; unwresume . set ( Some ( llfn ) ) ; llfn }
Returns a Value of the "eh_unwind_resume" lang item if one is defined,
otherwise declares it as an external function.
Returns a Value of the " eh_unwind_resume " lang item if one is defined otherwise declares it as an external function .
&self