summaryrefslogtreecommitdiff
path: root/scope.c
diff options
context:
space:
mode:
authorAndy Dougherty <doughera@lafcol.lafayette.edu>1995-06-06 01:41:07 +0000
committerAndy Dougherty <doughera@lafcol.lafayette.edu>1995-06-06 01:41:07 +0000
commit4aa0a1f7324b8447469670a1b2427c3ac2428bae (patch)
treef47ecacdb42503ee8ea8e4984302ab1aaad85431 /scope.c
parent005c1a0e007f6f2f3efe461d6a5930a88ccb88fb (diff)
downloadperl-4aa0a1f7324b8447469670a1b2427c3ac2428bae.tar.gz
This is my patch patch.1l for perl5.001.
To apply, change to your perl directory, run the command above, then apply with patch -p1 -N < thispatch. This patch fixes all the Configure & build problems for which I have a solution. After you apply this patch, I would recommend: make distclean # or at the very least rm config.sh sh Configure [whatever options you use] make depend make make test Patch and enjoy, Andy Dougherty doughera@lafcol.lafayette.edu Dept. of Physics Lafayette College, Easton PA 18042 Here are the file-by-file contents: Changes.Conf Updated a bit. Configure Now honors hints on <pwd.h>-related things (for CX/UX, in particular). Now honors previous values of d_stdio_ptr_lval and d_stdio_cnt_lval. DB test programs now conditionally include 'const'. MANIFEST Updated. config_H Updated. config_h.SH Include trailing /**/ on STDIO_..._LVALUE defines. hints/cxux.sh Simplified. Include info about failing test. hints/epix.sh A guess at a dynamic loading fix. hints/next_3.sh Add a few comments. lib/Benchmark.pm Ensure numeric context on number of loop iterations. op.c Spider's padlex and goto &$nonesuch patches. perl.c fputs("\tUnofficial patchlevel 1l.\n",stdout); pp_ctl.c pp_hot.c scope.c Spider's padlex and goto &$nonesuch patches.
Diffstat (limited to 'scope.c')
-rw-r--r--scope.c8
1 files changed, 5 insertions, 3 deletions
diff --git a/scope.c b/scope.c
index 44713e1953..12f3595b54 100644
--- a/scope.c
+++ b/scope.c
@@ -276,7 +276,7 @@ save_iv(ivp)
IV *ivp;
{
SSCHECK(3);
- SSPUSHINT(*ivp);
+ SSPUSHIV(*ivp);
SSPUSHPTR(ivp);
SSPUSHINT(SAVEt_IV);
}
@@ -365,7 +365,7 @@ save_clearsv(svp)
SV** svp;
{
SSCHECK(2);
- SSPUSHPTR(svp);
+ SSPUSHLONG((long)(svp-curpad));
SSPUSHINT(SAVEt_CLEARSV);
}
@@ -540,7 +540,7 @@ I32 base;
Safefree((char*)ptr);
break;
case SAVEt_CLEARSV:
- ptr = SSPOPPTR;
+ ptr = (void*)&curpad[SSPOPLONG];
sv = *(SV**)ptr;
if (SvREFCNT(sv) <= 1) { /* Can clear pad variable in place. */
if (SvTHINKFIRST(sv)) {
@@ -573,12 +573,14 @@ I32 base;
}
}
else { /* Someone has a claim on this, so abandon it. */
+ U32 padflags = SvFLAGS(sv) & (SVs_PADBUSY|SVs_PADMY|SVs_PADTMP);
SvREFCNT_dec(sv); /* Cast current value to the winds. */
switch (SvTYPE(sv)) { /* Console ourselves with a new value */
case SVt_PVAV: *(SV**)ptr = (SV*)newAV(); break;
case SVt_PVHV: *(SV**)ptr = (SV*)newHV(); break;
default: *(SV**)ptr = NEWSV(0,0); break;
}
+ SvFLAGS(*(SV**)ptr) |= padflags; /* preserve pad nature */
}
break;
case SAVEt_DELETE: