scanner.l

Fri, 28 Dec 2001 16:04:15 +0000

author
eric
date
Fri, 28 Dec 2001 16:04:15 +0000
changeset 8
7288d2753c18
parent 7
e1f52aa9f252
child 9
de78038d990f
permissions
-rw-r--r--

*** empty log message ***

eric@5 1 %option case-insensitive
eric@5 2
eric@5 3 /*
eric@5 4 %{
eric@5 5 #include "parser.tab.h"
eric@5 6 }%
eric@5 7 */
eric@5 8
eric@5 9 digit [0-9]
eric@5 10 alpha [a-zA-Z]
eric@5 11
eric@5 12 %%
eric@5 13
eric@7 14 \.\. { return (ELIPSIS); }
eric@7 15
eric@5 16 {digit}+ { yylval.integer = atoi (yytext); return (INTEGER); }
eric@5 17
eric@5 18 all { return (ALL); }
eric@5 19 bookmark { return (BOOKMARK); }
eric@5 20 crop { return (CROP); }
eric@5 21 even { return (EVEN); }
eric@5 22 file { return (FILE); }
eric@5 23 image { return (IMAGE); }
eric@5 24 input { return (INPUT); }
eric@5 25 odd { return (ODD); }
eric@5 26 output { return (OUTPUT); }
eric@5 27 page { return (PAGE); }
eric@8 28 pages { return (PAGES); }
eric@5 29 rotate { return (ROTATE); }
eric@5 30 size { return (SIZE); }
eric@5 31
eric@5 32 \".*\" { yylval.string = newstr (yytext); return (STRING); }