diff options
author | Stephan Bergmann <sbergman@redhat.com> | 2014-06-17 15:36:26 +0200 |
---|---|---|
committer | Stephan Bergmann <sbergman@redhat.com> | 2014-06-17 15:51:54 +0200 |
commit | a15715c34309416e76ebd2007a51ff6c42f28817 (patch) | |
tree | 8794c25b33abbcd8b050fe71dbd6576949741f0e /rsc | |
parent | 6fcc7efad066d6f3804196f3d3fbddd6a0a485cb (diff) |
-Wstrict-prototypes
...no reason to not have it enabled for URE C include files and what
little real C code is still left. (But note that Clang ignores that
warning.)
Change-Id: Ia6940f9f940a0c226e9b724331d65c9862ce32e6
Diffstat (limited to 'rsc')
-rw-r--r-- | rsc/source/rscpp/cpp.h | 46 | ||||
-rw-r--r-- | rsc/source/rscpp/cpp3.c | 2 | ||||
-rw-r--r-- | rsc/source/rscpp/cpp4.c | 4 | ||||
-rw-r--r-- | rsc/source/rscpp/cpp5.c | 4 | ||||
-rw-r--r-- | rsc/source/rscpp/cpp6.c | 2 |
5 files changed, 29 insertions, 29 deletions
diff --git a/rsc/source/rscpp/cpp.h b/rsc/source/rscpp/cpp.h index 260e5d59a68e..2a42f89ca5c1 100644 --- a/rsc/source/rscpp/cpp.h +++ b/rsc/source/rscpp/cpp.h @@ -295,12 +295,12 @@ int rscpp_main( int argc, char **argv ); #endif -void InitCpp1(); -void InitCpp2(); -void InitCpp3(); -void InitCpp4(); -void InitCpp5(); -void InitCpp6(); +void InitCpp1(void); +void InitCpp2(void); +void InitCpp3(void); +void InitCpp4(void); +void InitCpp5(void); +void InitCpp6(void); #define HELLO() fprintf( stderr, "[Hello at %s, %d] ", __FILE__, __LINE__ ) @@ -310,8 +310,8 @@ void InitCpp6(); /* cpp1.c */ void output( int c ); -void sharp(); -void cppmain(); +void sharp(void); +void cppmain(void); #if OSL_DEBUG_LEVEL > 1 #ifdef EVALDEFS int outputEval( int c ); @@ -321,8 +321,8 @@ int outputEval( int c ); /* cpp2.c */ int control( int counter ); -void doinclude(); -void dodefine(); +void doinclude(void); +void dodefine(void); void doif( int hash ); int openinclude( char *, int ); int hasdirectory(char *, char * ); @@ -331,19 +331,19 @@ int openfile( char * ); /* cpp3.c */ int openfiles( char *filename ); void addfile( FILE *fp, char *filename ); -void setincdirs(); +void setincdirs(void); int AddInclude( char *pIncStr ); int getredirection( int argc, char **argv ); void zap_uc( char *ap ); -void initdefines(); +void initdefines(void); int dooptions( int argc, char *argv[] ); int readoptions(char* filename, char*** pfargv); /* cpp4.c */ -void dodefines(); +void dodefines(void); void checkparm( int c, DEFBUF *dp ); -int expcollect(); +int expcollect(void); void expstuff( DEFBUF *dp ); #if STRING_FORMAL @@ -355,27 +355,27 @@ void stparmscan( int delim); void dumpparm( char *why ); #endif -void doundef(); +void doundef(void); void textput( char *text ); void charput( int c ); void expand( DEFBUF *tokenp ); /* cpp5.c */ -int eval(); +int eval(void); int evallex(int); int *evaleval(int *, int, int ); int evalchar(int); -int dosizeof(); +int dosizeof(void); int evalnum( int c ); int bittest( int ); /* cpp6.c */ -void skipnl(); -int skipws(); +void skipnl(void); +int skipws(void); void scanid( int c ); int macroid( int c ); -int catenate(); +int catenate(void); int scanstring( int c, void (*outfun)( int c ) ); void scannumber( int c, void (*outfun)( int c ) ); void save( int c ); @@ -386,9 +386,9 @@ DEFBUF *lookid( int c ); DEFBUF *defendel( char *name, int delete ); void dunpdef( char *why ); void dumpadef( char *why, DEFBUF *dp); -int get(); -int cget(); -void unget(); +int get(void); +int cget(void); +void unget(void); void ungetstring( char *text ); void cerror( char *format, char *sarg); void cwarn( char *format, char *sarg); diff --git a/rsc/source/rscpp/cpp3.c b/rsc/source/rscpp/cpp3.c index 40635ed9f951..81a5ac898a54 100644 --- a/rsc/source/rscpp/cpp3.c +++ b/rsc/source/rscpp/cpp3.c @@ -441,7 +441,7 @@ void initdefines() time_t tvec; #if !defined( WNT ) && !defined(G3) - extern char *ctime(); + extern char *ctime(time_t const *); #endif /* diff --git a/rsc/source/rscpp/cpp4.c b/rsc/source/rscpp/cpp4.c index f82faacc9b56..d5af024bd717 100644 --- a/rsc/source/rscpp/cpp4.c +++ b/rsc/source/rscpp/cpp4.c @@ -397,7 +397,7 @@ void expand(DEFBUF* tokenp) { register int c; register FILEINFO *file; - extern FILEINFO *getfile(); + extern FILEINFO *getfile(int, char *); #if OSL_DEBUG_LEVEL > 1 if (debug) @@ -553,7 +553,7 @@ void expstuff(DEFBUF* tokenp) char *defend; /* -> output buff end */ int string_magic; /* String formal hack */ FILEINFO *file; /* Funny #include */ - extern FILEINFO *getfile(); + extern FILEINFO *getfile(int, char *); file = getfile(NBUFF, tokenp->name); inp = tokenp->repl; /* -> macro replacement */ diff --git a/rsc/source/rscpp/cpp5.c b/rsc/source/rscpp/cpp5.c index 09a1c5c4119a..14adf4fcec97 100644 --- a/rsc/source/rscpp/cpp5.c +++ b/rsc/source/rscpp/cpp5.c @@ -139,7 +139,7 @@ register int op; #define S_PDOUBLE (sizeof (double *)) #endif #ifndef S_PFPTR -#define S_PFPTR (sizeof (int (*)())) +#define S_PFPTR (sizeof (int (*)(void))) #endif typedef struct types { @@ -218,7 +218,7 @@ eval() int skip; /* For short-circuit testing */ int value[NEXP]; /* Value stack */ OPTAB opstack[NEXP]; /* Operand stack */ - extern int *evaleval(); /* Does actual evaluation */ + extern int *evaleval(int *, int, int); /* Does actual evaluation */ valp = value; opp = opstack; opp->op = OP_END; /* Mark bottom of stack */ diff --git a/rsc/source/rscpp/cpp6.c b/rsc/source/rscpp/cpp6.c index 59708ef87d34..49d12dd7e192 100644 --- a/rsc/source/rscpp/cpp6.c +++ b/rsc/source/rscpp/cpp6.c @@ -1021,7 +1021,7 @@ void ungetstring(char* text) */ { register FILEINFO *file; - extern FILEINFO *getfile(); + extern FILEINFO *getfile(int, char *); file = getfile(strlen(text) + 1, ""); strcpy(file->buffer, text); } |