diff options
author | Kaleb Keithley <kaleb@freedesktop.org> | 2003-11-14 16:48:58 +0000 |
---|---|---|
committer | Kaleb Keithley <kaleb@freedesktop.org> | 2003-11-14 16:48:58 +0000 |
commit | 4b339f0a4311b4db171584bc6671292a9052665a (patch) | |
tree | bd48cdf361c0881f45d09ce46c478ad8674e87c1 /src/lex.l | |
parent | cfa9fa24253b5ef8045172852509be413d7b00ca (diff) |
XFree86 4.3.0.1xf86-4_3_0_1PRE_xf86-4_3_0_1
Diffstat (limited to 'src/lex.l')
-rw-r--r-- | src/lex.l | 15 |
1 files changed, 8 insertions, 7 deletions
@@ -59,20 +59,20 @@ in this Software without prior written authorization from The Open Group. * 12-Nov-87 Thomas E. LaStrange File created * ***********************************************************************/ +/* $XFree86: xc/programs/twm/lex.l,v 3.14 2001/12/14 20:01:08 dawes Exp $ */ /* #include <stdio.h> */ /* lex already includes stdio.h */ +#include "twm.h" #include "gram.h" +#include "list.h" #include "parse.h" -extern char *ProgramName; -extern int ParseError; #ifdef FLEX_SCANNER int yylineno; #undef YY_INPUT #define YY_INPUT(buf,result,size) ((result) = doinput((buf),(size))) -doinput (buf, size) -char *buf; +int doinput (char *buf, int size) { int c; @@ -85,6 +85,7 @@ char *buf; buf[0] = c; return (1); } +#define YY_NO_UNPUT #endif %} @@ -102,7 +103,7 @@ number [0-9]+ "-" { return MINUS; } "|" { return OR; } -[a-zA-Z\.]+ { int token = parse_keyword (yytext, +[a-zA-Z\.]+ { int token = parse_keyword ((char *)yytext, &yylval.num); if (token == ERRORTOKEN) { twmrc_error_prefix(); @@ -122,7 +123,7 @@ number [0-9]+ return (NUMBER); } \#[^\n]*\n {;} -[\n\t ] {;} +[\r\n\t ] {;} . { twmrc_error_prefix(); fprintf (stderr, @@ -132,7 +133,7 @@ number [0-9]+ } %% #ifndef yywrap -yywrap() { return(1);} +int yywrap() { return(1);} #endif #undef unput |