From: Peter Avalos Date: Sat, 19 Jan 2013 13:59:58 +0000 (-0800) Subject: Fix warnings from byacc import. X-Git-Url: https://gitweb.dragonflybsd.org/~polachok/dragonfly.git/commitdiff_plain/52e9aa73cf3364e912d7cc4bd5c662f17d48674c Fix warnings from byacc import. --- diff --git a/bin/expr/expr.y b/bin/expr/expr.y index 99b1851424..fb581909e6 100644 --- a/bin/expr/expr.y +++ b/bin/expr/expr.y @@ -61,7 +61,6 @@ quad_t to_integer (struct val *); void to_string (struct val *); int yyerror (const char *); int yylex (void); -int yyparse (void); char **av; %} diff --git a/games/atc/extern.h b/games/atc/extern.h index ce8d0dc4d6..6305c93e1c 100644 --- a/games/atc/extern.h +++ b/games/atc/extern.h @@ -57,8 +57,6 @@ extern struct termios tty_start, tty_new; extern DISPLACEMENT displacement[MAXDIR]; -extern int yyparse(void); - /* graphics.c */ extern void done_screen(void); extern void draw_all(void); diff --git a/games/atc/main.c b/games/atc/main.c index dc867e6190..73f0590160 100644 --- a/games/atc/main.c +++ b/games/atc/main.c @@ -49,6 +49,7 @@ #include "pathnames.h" extern FILE *yyin; +extern int yyparse(void); static int read_file(const char *); static const char *default_game(void); static const char *okay_game(const char *); diff --git a/libexec/dma/dma.c b/libexec/dma/dma.c index 48c429c443..b6040ec223 100644 --- a/libexec/dma/dma.c +++ b/libexec/dma/dma.c @@ -58,7 +58,7 @@ #include "dma.h" - +extern int yyparse(void); static void deliver(struct qitem *); struct aliases aliases = LIST_HEAD_INITIALIZER(aliases); diff --git a/libexec/dma/dma.h b/libexec/dma/dma.h index 44ba84b9bd..d413ca5172 100644 --- a/libexec/dma/dma.h +++ b/libexec/dma/dma.h @@ -164,7 +164,6 @@ extern char neterr[ERRMSG_SIZE]; extern char errmsg[ERRMSG_SIZE]; /* aliases_parse.y */ -int yyparse(void); extern FILE *yyin; /* conf.c */ diff --git a/sbin/devd/parse.y b/sbin/devd/parse.y index 2b32c9dd4b..68bf221ffb 100644 --- a/sbin/devd/parse.y +++ b/sbin/devd/parse.y @@ -30,9 +30,9 @@ * $DragonFly: src/sbin/devd/parse.y,v 1.1 2008/10/03 00:26:21 hasso Exp $ */ -#include "devd.h" #include #include +#include "devd.h" %} diff --git a/usr.bin/bc/bc.y b/usr.bin/bc/bc.y index 1816138c98..57b771afa0 100644 --- a/usr.bin/bc/bc.y +++ b/usr.bin/bc/bc.y @@ -44,6 +44,7 @@ #include #include #include +#include #include #include diff --git a/usr.bin/colldef/parse.y b/usr.bin/colldef/parse.y index 4a2ddcce30..04244a1c27 100644 --- a/usr.bin/colldef/parse.y +++ b/usr.bin/colldef/parse.y @@ -43,7 +43,6 @@ extern FILE *yyin; void yyerror(const char *fmt, ...) __printflike(1, 2); -int yyparse(void); int yylex(void); static void usage(void); static void collate_print_tables(void); diff --git a/usr.bin/find/getdate.y b/usr.bin/find/getdate.y index debf796314..ac0f954618 100644 --- a/usr.bin/find/getdate.y +++ b/usr.bin/find/getdate.y @@ -63,7 +63,6 @@ #define yylex getdate_yylex #define yyerror getdate_yyerror -static int yyparse(void); static int yylex(void); static int yyerror(const char *); diff --git a/usr.bin/m4/parser.y b/usr.bin/m4/parser.y index a72269fa61..bbb2195fa8 100644 --- a/usr.bin/m4/parser.y +++ b/usr.bin/m4/parser.y @@ -30,7 +30,6 @@ extern int yylex(void); extern int yyerror(const char *); -extern int yyparse(void); %} %token NUMBER %token ERROR diff --git a/usr.bin/mkcsmapper/ldef.h b/usr.bin/mkcsmapper/ldef.h index efe1ad154c..9bd505823d 100644 --- a/usr.bin/mkcsmapper/ldef.h +++ b/usr.bin/mkcsmapper/ldef.h @@ -35,5 +35,4 @@ typedef struct { extern int aline_number; extern int debug; -int yyparse(void); int yyerror(const char *); diff --git a/usr.bin/mkesdb/ldef.h b/usr.bin/mkesdb/ldef.h index fa53277f81..218b01b962 100644 --- a/usr.bin/mkesdb/ldef.h +++ b/usr.bin/mkesdb/ldef.h @@ -28,7 +28,6 @@ extern int aline_number; -int yyparse(void); int yyerror(const char *); struct named_csid { diff --git a/usr.bin/mklocale/yacc.y b/usr.bin/mklocale/yacc.y index f5e6fd5681..1ca37bbb93 100644 --- a/usr.bin/mklocale/yacc.y +++ b/usr.bin/mklocale/yacc.y @@ -73,7 +73,6 @@ void *xmalloc(unsigned int sz); uint32_t *xlalloc(unsigned int sz); uint32_t *xrelalloc(uint32_t *old, unsigned int sz); void dump_tables(void); -int yyparse(void); extern int yylex(void); %} diff --git a/usr.sbin/bthcid/parser.y b/usr.sbin/bthcid/parser.y index e919e207d8..da0aacb3da 100644 --- a/usr.sbin/bthcid/parser.y +++ b/usr.sbin/bthcid/parser.y @@ -38,12 +38,12 @@ #include #include #include +#include #include #include #include #include "bthcid.h" - int yyparse (void); int yylex (void); static void free_key (link_key_p key); diff --git a/usr.sbin/config/config.h b/usr.sbin/config/config.h index aaab9ea32f..b6b0ba88e3 100644 --- a/usr.sbin/config/config.h +++ b/usr.sbin/config/config.h @@ -150,7 +150,6 @@ char *raisestr(char *); void moveifchanged(const char *, const char *); void init_dev(struct device *); void newbus_ioconf(void); -int yyparse(void); void options(void); void makefile(void); void headers(void); diff --git a/usr.sbin/config/main.c b/usr.sbin/config/main.c index fd786a0172..faa59ce796 100644 --- a/usr.sbin/config/main.c +++ b/usr.sbin/config/main.c @@ -67,6 +67,7 @@ static int no_config_clobber = TRUE; int debugging; int profiling; +extern int yyparse(void); static void configfile(void); static void get_srcdir(void); static void usage(void); diff --git a/usr.sbin/mrouted/cfparse.y b/usr.sbin/mrouted/cfparse.y index c790e0d1a6..2ca30d27f6 100644 --- a/usr.sbin/mrouted/cfparse.y +++ b/usr.sbin/mrouted/cfparse.y @@ -23,7 +23,6 @@ static char * next_word(void); static int yylex(void); static u_int32 valid_if(char *s); static struct ifreq * ifconfaddr(struct ifconf *ifcp, u_int32 a); -int yyparse(void); static FILE *f; diff --git a/usr.sbin/ndiscvt/inf-parse.y b/usr.sbin/ndiscvt/inf-parse.y index a6d47799b0..2507990215 100644 --- a/usr.sbin/ndiscvt/inf-parse.y +++ b/usr.sbin/ndiscvt/inf-parse.y @@ -39,7 +39,6 @@ #include "inf.h" -extern int yyparse (void); extern int yylex (void); extern void yyerror(const char *); %} diff --git a/usr.sbin/pfctl/parse.y b/usr.sbin/pfctl/parse.y index bda6eca956..5e107e78d2 100644 --- a/usr.sbin/pfctl/parse.y +++ b/usr.sbin/pfctl/parse.y @@ -87,7 +87,6 @@ static struct file { struct file *pushfile(const char *, int); int popfile(void); int check_file_secrecy(int, const char *); -int yyparse(void); int yylex(void); int yyerror(const char *, ...) __printflike(1, 2); int kw_cmp(const void *, const void *); diff --git a/usr.sbin/setkey/parse.y b/usr.sbin/setkey/parse.y index 5609f3737d..67b7e6e0cd 100644 --- a/usr.sbin/setkey/parse.y +++ b/usr.sbin/setkey/parse.y @@ -46,6 +46,7 @@ #include #include #include +#include #include #include #include