From: Per Bothner Date: Fri, 22 May 1992 20:56:37 +0000 (+0000) Subject: * ldlex.c: Fix some unnecessary flex-specific-isms. X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=91e25b4f8f14ebe408b603c829e2d0f8010ff13d;p=binutils-gdb.git * ldlex.c: Fix some unnecessary flex-specific-isms. --- diff --git a/ld/ChangeLog b/ld/ChangeLog index ba412b8cbe2..c8c81cb0e56 100644 --- a/ld/ChangeLog +++ b/ld/ChangeLog @@ -1,3 +1,13 @@ +Fri May 22 13:47:19 1992 Per Bothner (bothner@cygnus.com) + + * config/sparc.mh: Fix HOSTING_LIBS so it has a chance of working. + * ldlex.c: Fix some unnecessary flex-specific-isms. + +Fri May 8 11:49:43 1992 Steve Chamberlain (sac@thepub.cygnus.com) + + * ldgram.y: move spurious semicolon + * ldexp.h: fix prototype + Thu May 7 17:01:12 1992 Roland H. Pesch (pesch@fowanton.cygnus.com) * ld.texinfo: references to linker now say "ld" not "gld". diff --git a/ld/ldlex.l b/ld/ldlex.l index 31b85a28ef5..2c21a5898f0 100644 --- a/ld/ldlex.l +++ b/ld/ldlex.l @@ -74,15 +74,15 @@ FILENAMECHAR [_a-zA-Z0-9\/\.\-\_\+\=\$\:\[\]\\] FILENAME {FILENAMECHAR}+ WHITE [ \t\n]+ -%x COMMAND -%x SCRIPT -%x EXPRESSION -%x COMMENT -%x BOTH -%x DEFSYMEXP -%x MRI +%s COMMAND +%s SCRIPT +%s EXPRESSION +%s COMMENT +%s BOTH +%s DEFSYMEXP +%s MRI %% - + "-" { RTOKEN('-');} "+" { RTOKEN('+');} {FILENAMECHAR1}{SYMBOLCHARN}* { yylval.name = buystring(yytext); return NAME; } @@ -172,8 +172,7 @@ WHITE [ \t\n]+ return INT; } -([0-9A-Fa-f])+(H|X|B|O|D) - { +([0-9A-Fa-f])+(H|X|B|O|D) { int base ; switch (yytext[yyleng-1]) { case 'X': @@ -289,10 +288,13 @@ WHITE [ \t\n]+ "l" { RTOKEN( LENGTH);} "len" { RTOKEN( LENGTH);} "\n" { ++ lineno; RTOKEN(NEWLINE); } -^"*".* { /* Mri comment line */ } +"*".* { /* Mri comment line */ } "END" { RTOKEN(ENDWORD); } "CHIP" { RTOKEN(CHIP); } +"BASE" { RTOKEN(BASE); } +"ALIAS" { RTOKEN(ALIAS); } "LOAD" { RTOKEN(LOAD); } +"PUBLIC" { RTOKEN(PUBLIC); } "ORDER" { RTOKEN(ORDER); } "NAME" { RTOKEN(NAMEWORD); } "FORMAT" { RTOKEN(FORMAT); } @@ -343,8 +345,6 @@ WHITE [ \t\n]+ "*"+[^*/\\n]* \\n { ++lineno;} "*"+"/" { BEGIN(old); } - - <> { include_stack_ptr--; @@ -360,13 +360,6 @@ WHITE [ \t\n]+ return END; } - - - - - - - %% void @@ -508,4 +501,3 @@ int max_size; YY_FATAL_ERROR( "read() in flex scanner failed" ); } } -