summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGisle Aas <gisle@aas.no>1998-02-24 00:36:09 +0100
committerMalcolm Beattie <mbeattie@sable.ox.ac.uk>1998-02-25 15:27:06 +0000
commit0fa190096f28eaa3c2a08a9aa7c333cd24617fd7 (patch)
tree740bac305fea94d9edfa4b4745e5fbf9c54ad3eb
parent3238f5fe6293a28fd91d4f803f3a2df14d3a9498 (diff)
downloadperl-0fa190096f28eaa3c2a08a9aa7c333cd24617fd7.tar.gz
#ifdef CAN_PROTOTYPE cleanup
p4raw-id: //depot/perl@581
-rw-r--r--doio.c6
-rw-r--r--miniperlmain.c7
-rw-r--r--op.c35
-rw-r--r--perl.c8
-rw-r--r--pp.h4
-rw-r--r--regcomp.c25
-rw-r--r--toke.c10
-rw-r--r--util.c15
8 files changed, 1 insertions, 109 deletions
diff --git a/doio.c b/doio.c
index 3167aea6b7..de0cdee95b 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 190c7fb17b..5b075a52dd 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 d622b0e5cd..39d2a14fcd 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 6b5b2f61b2..9595fd2b2b 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 ab4140c415..2209feeb9a 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 a958971f15..55576d0bf1 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 640ab67c13..e6a740b3e2 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 8d77adefe1..0dd944333f 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;