svn commit: r254626 - stable/9/usr.bin/yacc

Glen Barber gjb at FreeBSD.org
Thu Aug 22 05:25:27 UTC 2013


On Wed, Aug 21, 2013 at 10:57:30PM +0000, David E. O'Brien wrote:
> Author: obrien
> Date: Wed Aug 21 22:57:29 2013
> New Revision: 254626
> URL: http://svnweb.freebsd.org/changeset/base/254626
> 
> Log:
>   Provide a prototype for yyparse() so that "-Werror" along with stringent
>   -W* warnings can be used on byacc's output.
> 
> Modified:
>   stable/9/usr.bin/yacc/skeleton.c
> 
> Modified: stable/9/usr.bin/yacc/skeleton.c
> ==============================================================================
> --- stable/9/usr.bin/yacc/skeleton.c	Wed Aug 21 22:55:10 2013	(r254625)
> +++ stable/9/usr.bin/yacc/skeleton.c	Wed Aug 21 22:57:29 2013	(r254626)
> @@ -196,6 +196,10 @@ const char *body[] =
>      "#endif	/* ANSI-C/C++ */",
>      "#endif	/* ! YYPARSE_PARAM */",
>      "",
> +    "#if defined(__cplusplus) || __STDC__",
> +    "extern int yyparse (YYPARSE_PARAM_ARG);",
> +    "#endif	/* ANSI-C/C++ */",
> +    "",
>      "int",
>      "yyparse (YYPARSE_PARAM_ARG)",
>      "    YYPARSE_PARAM_DECL",

===> bin/expr (all)
cc -O -pipe  -std=gnu99 -Wsystem-headers -Werror -Wall -Wno-format-y2k
-W -Wno-unused-parameter -Wstrict-prototypes
-Wmissing-prototypes -Wpointer-arith -Wreturn-type -Wcast-qual
-Wwrite-strings -Wswitch -Wshadow -Wunused-parameter -Wcast-align
-Wchar-subscripts -Winline -Wnested-externs -Wredundant-decls
-Wold-style-definition -Wno-pointer-sign -c expr.c
cc1: warnings being treated as errors
expr.c:812: warning: redundant redeclaration of 'yyparse'
/src/bin/expr/expr.y:77: warning: previous declaration of 'yyparse' was
here
*** Error code 1

Stop in /src/bin/expr.
*** Error code 1

Stop in /src/bin.
*** Error code 1

Stop in /src.
*** Error code 1

Stop in /src.
*** Error code 1

Stop in /src.
TB --- 2013-08-22 05:18:18 - WARNING: /usr/bin/make returned exit code
1
TB --- 2013-08-22 05:18:18 - ERROR: failed to build world
TB --- 2013-08-22 05:18:18 - 1691.60 user 375.84 system 2575.39 real


http://tinderbox.freebsd.org/tinderbox-freebsd9-build-RELENG_9-arm-arm.full

Glen

-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 488 bytes
Desc: not available
URL: <http://lists.freebsd.org/pipermail/svn-src-all/attachments/20130822/076732da/attachment.sig>


More information about the svn-src-all mailing list