From: Gisle Aas Date: Mon, 23 Feb 1998 23:36:09 +0000 (+0100) Subject: #ifdef CAN_PROTOTYPE cleanup X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=0fa190096f28eaa3c2a08a9aa7c333cd24617fd7;p=p5sagit%2Fp5-mst-13.2.git #ifdef CAN_PROTOTYPE cleanup p4raw-id: //depot/perl@581 --- diff --git a/doio.c b/doio.c index 3167aea..de0cdee 100644 --- a/doio.c +++ b/doio.c @@ -564,13 +564,7 @@ badexit: /* explicit renamed to avoid C++ conflict -- kja */ bool -#ifndef CAN_PROTOTYPE -do_close(gv,not_implicit) -GV *gv; -bool not_implicit; -#else do_close(GV *gv, bool not_implicit) -#endif /* CAN_PROTOTYPE */ { bool retval; IO *io; diff --git a/miniperlmain.c b/miniperlmain.c index 190c7fb..5b075a5 100644 --- a/miniperlmain.c +++ b/miniperlmain.c @@ -14,14 +14,7 @@ static void xs_init _((void)); static PerlInterpreter *my_perl; int -#ifdef CAN_PROTOTYPE main(int argc, char **argv, char **env) -#else -main(argc, argv, env) -int argc; -char **argv; -char **env; -#endif { int exitstatus; diff --git a/op.c b/op.c index d622b0e..39d2a14 100644 --- a/op.c +++ b/op.c @@ -148,16 +148,7 @@ pad_allocmy(char *name) } static PADOFFSET -#ifndef CAN_PROTOTYPE -pad_findlex(name, newoff, seq, startcv, cx_ix) -char *name; -PADOFFSET newoff; -U32 seq; -CV* startcv; -I32 cx_ix; -#else pad_findlex(char *name, PADOFFSET newoff, U32 seq, CV* startcv, I32 cx_ix) -#endif { dTHR; CV *cv; @@ -401,12 +392,7 @@ pad_alloc(I32 optype, U32 tmptype) } SV * -#ifndef CAN_PROTOTYPE -pad_sv(po) -PADOFFSET po; -#else pad_sv(PADOFFSET po) -#endif /* CAN_PROTOTYPE */ { dTHR; #ifdef USE_THREADS @@ -422,12 +408,7 @@ pad_sv(PADOFFSET po) } void -#ifndef CAN_PROTOTYPE -pad_free(po) -PADOFFSET po; -#else pad_free(PADOFFSET po) -#endif /* CAN_PROTOTYPE */ { dTHR; if (!curpad) @@ -450,12 +431,7 @@ pad_free(PADOFFSET po) } void -#ifndef CAN_PROTOTYPE -pad_swipe(po) -PADOFFSET po; -#else pad_swipe(PADOFFSET po) -#endif /* CAN_PROTOTYPE */ { dTHR; if (AvARRAY(comppad) != curpad) @@ -2926,18 +2902,7 @@ newWHILEOP(I32 flags, I32 debuggable, LOOP *loop, I32 whileline, OP *expr, OP *b } OP * -#ifndef CAN_PROTOTYPE -newFOROP(flags,label,forline,sv,expr,block,cont) -I32 flags; -char *label; -line_t forline; -OP* sv; -OP* expr; -OP*block; -OP*cont; -#else newFOROP(I32 flags,char *label,line_t forline,OP *sv,OP *expr,OP *block,OP *cont) -#endif /* CAN_PROTOTYPE */ { LOOP *loop; OP *wop; diff --git a/perl.c b/perl.c index 6b5b2f6..9595fd2 100644 --- a/perl.c +++ b/perl.c @@ -1755,16 +1755,8 @@ init_main_stash(void) sv_setpvn(GvSV(gv_fetchpv("/", TRUE, SVt_PV)), "\n", 1); } -#ifdef CAN_PROTOTYPE static void open_script(char *scriptname, bool dosearch, SV *sv) -#else -static void -open_script(scriptname,dosearch,sv) -char *scriptname; -bool dosearch; -SV *sv; -#endif { dTHR; char *xfound = Nullch; diff --git a/pp.h b/pp.h index ab4140c..2209fee 100644 --- a/pp.h +++ b/pp.h @@ -14,11 +14,7 @@ #define ARGS #define dARGS #endif /* USE_THREADS */ -#ifdef CAN_PROTOTYPE #define PP(s) OP * s(ARGSproto) -#else /* CAN_PROTOTYPE */ -#define PP(s) OP* s(ARGS) dARGS -#endif /* CAN_PROTOTYPE */ #define SP sp #define MARK mark diff --git a/regcomp.c b/regcomp.c index a958971..55576d0 100644 --- a/regcomp.c +++ b/regcomp.c @@ -2045,12 +2045,7 @@ nextchar(void) - reg_node - emit a node */ static regnode * /* Location. */ -#ifdef CAN_PROTOTYPE reg_node(U8 op) -#else -reg_node(op) -U8 op; -#endif { register regnode *ret; register regnode *ptr; @@ -2078,13 +2073,7 @@ U8 op; - reganode - emit a node with an argument */ static regnode * /* Location. */ -#ifdef CAN_PROTOTYPE reganode(U8 op, U32 arg) -#else -reganode(op, arg) -U8 op; -U32 arg; -#endif { register regnode *ret; register regnode *ptr; @@ -2111,15 +2100,8 @@ U32 arg; /* - regc - emit (if appropriate) a byte of code */ -#ifdef CAN_PROTOTYPE static void regc(U8 b, char* s) -#else -static void -regc(b, s) -U8 b; -char *s; -#endif { if (!SIZE_ONLY) *s = b; @@ -2130,15 +2112,8 @@ char *s; * * Means relocating the operand. */ -#ifdef CAN_PROTOTYPE static void reginsert(U8 op, regnode *opnd) -#else -static void -reginsert(op, opnd) -U8 op; -regnode *opnd; -#endif { register regnode *src; register regnode *dst; diff --git a/toke.c b/toke.c index 640ab67..e6a740b 100644 --- a/toke.c +++ b/toke.c @@ -478,15 +478,7 @@ uni(I32 f, char *s) #define LOP(f,x) return lop(f,x,s) static I32 -lop -#ifdef CAN_PROTOTYPE - (I32 f, expectation x, char *s) -#else - (f,x,s) -I32 f; -expectation x; -char *s; -#endif /* CAN_PROTOTYPE */ +lop(I32 f, expectation x, char *s) { dTHR; yylval.ival = f; diff --git a/util.c b/util.c index 8d77ade..0dd9443 100644 --- a/util.c +++ b/util.c @@ -1707,12 +1707,7 @@ char *args; #ifdef MYSWAP #if BYTEORDER != 0x4321 short -#ifndef CAN_PROTOTYPE -my_swap(s) -short s; -#else my_swap(short s) -#endif { #if (BYTEORDER & 1) == 0 short result; @@ -1725,12 +1720,7 @@ my_swap(short s) } long -#ifndef CAN_PROTOTYPE -my_htonl(l) -register long l; -#else my_htonl(long l) -#endif { union { long result; @@ -1759,12 +1749,7 @@ my_htonl(long l) } long -#ifndef CAN_PROTOTYPE -my_ntohl(l) -register long l; -#else my_ntohl(long l) -#endif { union { long l;