Skip to content

Commit

Permalink
Add support for processing lex source files with flex v 2.6.3
Browse files Browse the repository at this point in the history
	PR 21059
binutils* arlex.l: Support processing with flex 2.6.3.
	* deflex.l: Likewise.

gas	* config/bfin-lex.l: Support processing with flex 2.6.3.
	* itbl-lex.l: Likewise.
  • Loading branch information
berolinux authored and nickclifton committed Jan 18, 2017
1 parent 1ec4b9f commit 2cedb9e
Show file tree
Hide file tree
Showing 6 changed files with 18 additions and 27 deletions.
6 changes: 6 additions & 0 deletions binutils/ChangeLog
Original file line number Diff line number Diff line change
@@ -1,3 +1,9 @@
2017-01-18 Bernhard Rosenkranzer <bero@lindev.ch>

PR 21059
* arlex.l: Support processing with flex 2.6.3.
* deflex.l: Likewise.

2017-01-17 Dmitry Timoshkov <dmitry@baikal.ru>

* resbin.c: Optional dialog control data immediately follows
Expand Down
6 changes: 1 addition & 5 deletions binutils/arlex.l
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
%option noinput nounput
%option noinput nounput noyywrap

%{
/* arlex.l - Strange script language lexer */
Expand Down Expand Up @@ -88,7 +88,3 @@ int linenumber;
"\n" { linenumber ++; return NEWLINE; }

%%
#ifndef yywrap
/* Needed for lex, though not flex. */
int yywrap(void) { return 1; }
#endif
6 changes: 1 addition & 5 deletions binutils/deflex.l
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
%option noinput nounput
%option noinput nounput noyywrap

%{/* deflex.l - Lexer for .def files */

Expand Down Expand Up @@ -91,7 +91,3 @@ int linenumber;
"@" { return '@';}
"," { return ',';}
%%
#ifndef yywrap
/* Needed for lex, though not flex. */
int yywrap(void) { return 1; }
#endif
6 changes: 6 additions & 0 deletions gas/ChangeLog
Original file line number Diff line number Diff line change
@@ -1,3 +1,9 @@
2017-01-18 Bernhard Rosenkranzer <bero@lindev.ch>

PR 21059
* config/bfin-lex.l: Support processing with flex 2.6.3.
* itbl-lex.l: Likewise.

2017-01-18 Nathan Sidwell <nathan@acm.org>

* as.h (gas_assert): Use abort.
Expand Down
11 changes: 2 additions & 9 deletions gas/config/bfin-lex.l
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
%option noyywrap

/* bfin-lex.l ADI Blackfin lexer
Copyright (C) 2005-2017 Free Software Foundation, Inc.
Expand Down Expand Up @@ -545,12 +547,3 @@ set_start_state (void)
{
BEGIN KEYWORD;
}


#ifndef yywrap
int
yywrap ()
{
return 1;
}
#endif
10 changes: 2 additions & 8 deletions gas/itbl-lex.l
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
%option noyywrap

/* itbl-lex.l
Copyright (C) 1997-2017 Free Software Foundation, Inc.
Expand Down Expand Up @@ -102,11 +104,3 @@ HEX [0-9A-Fa-f]
return yytext[0];
}
%%

#ifndef yywrap
int
yywrap ()
{
return 1;
}
#endif

0 comments on commit 2cedb9e

Please sign in to comment.