From: Ilya Zakharevich Date: Wed, 8 Apr 1998 03:21:03 +0000 (-0400) Subject: [PATCH 5.004_64] newSV X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=ff06c60c06e5437e446d6c794b05a29d5e6644fa;p=p5sagit%2Fp5-mst-13.2.git [PATCH 5.004_64] newSV Date: Wed, 8 Apr 1998 03:21:03 -0400 (EDT) Subject: [PATCH 5.004_64] Cryptic error from B::CC Date: Sat, 11 Apr 1998 19:52:25 -0400 (EDT) p4raw-id: //depot/perl@942 --- diff --git a/ext/B/B/CC.pm b/ext/B/B/CC.pm index 0f4cfd2..4c877d9 100644 --- a/ext/B/B/CC.pm +++ b/ext/B/B/CC.pm @@ -1438,7 +1438,7 @@ sub compile { last OPTION; } elsif ($opt eq "o") { $arg ||= shift @options; - open(STDOUT, ">$arg") or return "$arg: $!\n"; + open(STDOUT, ">$arg") or return "open '>$arg': $!\n"; } elsif ($opt eq "n") { $arg ||= shift @options; $module_name = $arg; diff --git a/handy.h b/handy.h index 233304b..443c229 100644 --- a/handy.h +++ b/handy.h @@ -263,6 +263,9 @@ typedef U16 line_t; */ #ifndef lint + +#define NEWSV(x,len) newSV(len) + #ifndef LEAKTEST #define New(x,v,n,t) (v = (t*)safemalloc((MEM_SIZE)((n)*sizeof(t)))) @@ -274,7 +277,6 @@ typedef U16 line_t; #define Renewc(v,n,t,c) \ (v = (c*)saferealloc((Malloc_t)(v),(MEM_SIZE)((n)*sizeof(t)))) #define Safefree(d) safefree((Malloc_t)(d)) -#define NEWSV(x,len) newSV(len) #else /* LEAKTEST */ @@ -287,7 +289,6 @@ typedef U16 line_t; #define Renewc(v,n,t,c) \ (v = (c*)safexrealloc((Malloc_t)(v),(MEM_SIZE)((n)*sizeof(t)))) #define Safefree(d) safexfree((Malloc_t)(d)) -#define NEWSV(x,len) newSV(x,len) #define MAXXCOUNT 1400 #define MAXY_SIZE 80 diff --git a/proto.h b/proto.h index 7641071..3eca378 100644 --- a/proto.h +++ b/proto.h @@ -333,11 +333,7 @@ SV* newRV _((SV* ref)); #if !defined(__GNUC__) && (defined(CRIPPLED_CC) || defined(USE_THREADS)) SV* newRV_noinc _((SV *)); #endif -#ifdef LEAKTEST -SV* newSV _((I32 x, STRLEN len)); -#else SV* newSV _((STRLEN len)); -#endif OP* newSVREF _((OP* o)); OP* newSVOP _((I32 type, I32 flags, SV* sv)); SV* newSViv _((IV i)); diff --git a/sv.c b/sv.c index 1abc3fd..9c6b421 100644 --- a/sv.c +++ b/sv.c @@ -2417,11 +2417,7 @@ sv_catpv_mg(register SV *sv, register char *ptr) } SV * -#ifdef LEAKTEST -newSV(I32 x, STRLEN len) -#else newSV(STRLEN len) -#endif { register SV *sv;