X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=blobdiff_plain;f=scope.h;h=6cfe1247e01c5a2aeca6eeef730333682a0d9c1a;hb=5cb3728cfe288ad05e8d10c8176f72378da2238f;hp=edf7ffef48b03848a3e163669a8f3567f8c91e18;hpb=26d9b02fa65570745e70dcbd0d92c1354fc4ecff;p=p5sagit%2Fp5-mst-13.2.git diff --git a/scope.h b/scope.h index edf7ffe..6cfe124 100644 --- a/scope.h +++ b/scope.h @@ -1,3 +1,12 @@ +/* scope.h + * + * Copyright (c) 1997-2002, Larry Wall + * + * You may distribute under the terms of either the GNU General Public + * License or the Artistic License, as specified in the README file. + * + */ + #define SAVEt_ITEM 0 #define SAVEt_SV 1 #define SAVEt_AV 2 @@ -35,6 +44,7 @@ #define SAVEt_GENERIC_PVREF 34 #define SAVEt_PADSV 35 #define SAVEt_MORTALIZESV 36 +#define SAVEt_SHARED_PVREF 37 #ifndef SCOPE_SAVES_SIGNAL_MASK #define SCOPE_SAVES_SIGNAL_MASK 0 @@ -55,6 +65,8 @@ #define SSPOPDXPTR (PL_savestack[--PL_savestack_ix].any_dxptr) /* +=head1 Callback Functions + =for apidoc Ams||SAVETMPS Opening bracket for temporaries on a callback. See C and L. @@ -115,6 +127,7 @@ Closing bracket on a callback. See C and L. #define SAVECLEARSV(sv) save_clearsv(SOFT_CAST(SV**)&(sv)) #define SAVEGENERICSV(s) save_generic_svref((SV**)&(s)) #define SAVEGENERICPV(s) save_generic_pvref((char**)&(s)) +#define SAVESHAREDPV(s) save_shared_pvref((char**)&(s)) #define SAVEDELETE(h,k,l) \ save_delete(SOFT_CAST(HV*)(h), SOFT_CAST(char*)(k), (I32)(l)) #define SAVEDESTRUCTOR(f,p) \ @@ -158,9 +171,9 @@ Closing bracket on a callback. See C and L. #ifdef USE_ITHREADS # define SAVECOPSTASH(c) SAVEPPTR(CopSTASHPV(c)) -# define SAVECOPSTASH_FREE(c) SAVEGENERICPV(CopSTASHPV(c)) +# define SAVECOPSTASH_FREE(c) SAVESHAREDPV(CopSTASHPV(c)) # define SAVECOPFILE(c) SAVEPPTR(CopFILE(c)) -# define SAVECOPFILE_FREE(c) SAVEGENERICPV(CopFILE(c)) +# define SAVECOPFILE_FREE(c) SAVESHAREDPV(CopFILE(c)) #else # define SAVECOPSTASH(c) SAVESPTR(CopSTASH(c)) # define SAVECOPSTASH_FREE(c) SAVECOPSTASH(c) /* XXX not refcounted */