From: Joel E. Denny Date: Sat, 1 Aug 2009 21:51:34 +0000 (-0400) Subject: Pacify "gcc -Wunused" for the input function from Flex. X-Git-Tag: v2.5_rc1~205 X-Git-Url: https://git.saurik.com/bison.git/commitdiff_plain/4521fcdf02e081b691c4a4485dd3441f8cda7c6b?ds=sidebyside Pacify "gcc -Wunused" for the input function from Flex. Reported by Alex Rozenman. This warning shows up with gcc-4.3.0 and later. * src/scan-code.l: Add "%option noinput", which I cannot find in the Flex manual, but which Flex has supported since at least as far back as 2.5.4. However, if any of our developers still use Flex 2.5.4, they'll need to stop configuring with --enable-gcc-warnings because "%option noinput" didn't work correctly until Flex 2.5.6. * src/scan-gram.l: Likewise. * src/scan-skel.l: Likewise. (cherry picked from commit 42f8609bbd033edf6cca102ca080eade94ed08ef) --- diff --git a/ChangeLog b/ChangeLog index f9881595..18c58988 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,17 @@ +2009-08-01 Joel E. Denny + + Pacify "gcc -Wunused" for the input function from Flex. + Reported by Alex Rozenman. This warning shows up with gcc-4.3.0 + and later. + * src/scan-code.l: Add "%option noinput", which I cannot find in + the Flex manual, but which Flex has supported since at least as + far back as 2.5.4. However, if any of our developers still use + Flex 2.5.4, they'll need to stop configuring with + --enable-gcc-warnings because "%option noinput" didn't work + correctly until Flex 2.5.6. + * src/scan-gram.l: Likewise. + * src/scan-skel.l: Likewise. + 2009-07-31 Alex Rozenman Fix --enable-gcc-warnings problems. diff --git a/src/scan-code.l b/src/scan-code.l index d976517d..235800f8 100644 --- a/src/scan-code.l +++ b/src/scan-code.l @@ -17,7 +17,7 @@ You should have received a copy of the GNU General Public License along with this program. If not, see . */ -%option debug nodefault nounput noyywrap never-interactive +%option debug nodefault noinput nounput noyywrap never-interactive %option prefix="code_" outfile="lex.yy.c" %{ diff --git a/src/scan-gram.l b/src/scan-gram.l index 422eae64..55ca3ac6 100644 --- a/src/scan-gram.l +++ b/src/scan-gram.l @@ -18,7 +18,7 @@ You should have received a copy of the GNU General Public License along with this program. If not, see . */ -%option debug nodefault nounput noyywrap never-interactive +%option debug nodefault noinput nounput noyywrap never-interactive %option prefix="gram_" outfile="lex.yy.c" %{ diff --git a/src/scan-skel.l b/src/scan-skel.l index 6ef53511..6841b4a4 100644 --- a/src/scan-skel.l +++ b/src/scan-skel.l @@ -18,7 +18,7 @@ You should have received a copy of the GNU General Public License along with this program. If not, see . */ -%option nodefault noyywrap nounput never-interactive debug +%option nodefault noyywrap noinput nounput never-interactive debug %option prefix="skel_" outfile="lex.yy.c" %{