diff options
Diffstat (limited to 'mathoms.c')
-rw-r--r-- | mathoms.c | 75 |
1 files changed, 75 insertions, 0 deletions
@@ -1088,6 +1088,81 @@ Perl_sv_nounlocking(pTHX_ SV *sv) PERL_UNUSED_ARG(sv); } +void +Perl_save_long(pTHX_ long int *longp) +{ + dVAR; + SSCHECK(3); + SSPUSHLONG(*longp); + SSPUSHPTR(longp); + SSPUSHINT(SAVEt_LONG); +} + +void +Perl_save_I16(pTHX_ I16 *intp) +{ + dVAR; + SSCHECK(3); + SSPUSHINT(*intp); + SSPUSHPTR(intp); + SSPUSHINT(SAVEt_I16); +} + +void +Perl_save_I8(pTHX_ I8 *bytep) +{ + dVAR; + SSCHECK(3); + SSPUSHINT(*bytep); + SSPUSHPTR(bytep); + SSPUSHINT(SAVEt_I8); +} + +void +Perl_save_iv(pTHX_ IV *ivp) +{ + dVAR; + SSCHECK(3); + SSPUSHIV(*ivp); + SSPUSHPTR(ivp); + SSPUSHINT(SAVEt_IV); +} + +void +Perl_save_nogv(pTHX_ GV *gv) +{ + dVAR; + SSCHECK(2); + SSPUSHPTR(gv); + SSPUSHINT(SAVEt_NSTAB); +} + +void +Perl_save_list(pTHX_ register SV **sarg, I32 maxsarg) +{ + dVAR; + register I32 i; + + for (i = 1; i <= maxsarg; i++) { + register SV * const sv = newSV(0); + sv_setsv(sv,sarg[i]); + SSCHECK(3); + SSPUSHPTR(sarg[i]); /* remember the pointer */ + SSPUSHPTR(sv); /* remember the value */ + SSPUSHINT(SAVEt_ITEM); + } +} + +void +Perl_save_destructor(pTHX_ DESTRUCTORFUNC_NOCONTEXT_t f, void* p) +{ + dVAR; + SSCHECK(3); + SSPUSHDPTR(f); + SSPUSHPTR(p); + SSPUSHINT(SAVEt_DESTRUCTOR); +} + #endif /* NO_MATHOMS */ /* |