scanner.l

changeset 5
9eb47d44dab9
child 7
e1f52aa9f252
     1.1 diff -r 86a98659662f -r 9eb47d44dab9 scanner.l
     1.2 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
     1.3 +++ b/scanner.l	Fri Dec 28 04:44:05 2001 +0000
     1.4 @@ -0,0 +1,29 @@
     1.5 +%option case-insensitive
     1.6 +
     1.7 +/*
     1.8 +%{
     1.9 +#include "parser.tab.h"
    1.10 +}%
    1.11 +*/
    1.12 +
    1.13 +digit [0-9]
    1.14 +alpha [a-zA-Z]
    1.15 +
    1.16 +%%
    1.17 +
    1.18 +{digit}+	{ yylval.integer = atoi (yytext); return (INTEGER); }
    1.19 +
    1.20 +all		{ return (ALL); }
    1.21 +bookmark	{ return (BOOKMARK); }
    1.22 +crop		{ return (CROP); }
    1.23 +even		{ return (EVEN); }
    1.24 +file		{ return (FILE); }
    1.25 +image		{ return (IMAGE); }
    1.26 +input		{ return (INPUT); }
    1.27 +odd		{ return (ODD); }
    1.28 +output		{ return (OUTPUT); }
    1.29 +page		{ return (PAGE); }
    1.30 +rotate		{ return (ROTATE); }
    1.31 +size		{ return (SIZE); }
    1.32 +
    1.33 +\".*\"		{ yylval.string = newstr (yytext); return (STRING); }