File: lex_input_example.tex

package info (click to toggle)
kimwitu-doc 10a-3
  • links: PTS
  • area: main
  • in suites: etch, etch-m68k, sarge
  • size: 1,192 kB
  • ctags: 341
  • sloc: makefile: 166; yacc: 125; ansic: 40; lex: 18; sh: 2
file content (12 lines) | stat: -rw-r--r-- 520 bytes parent folder | download | duplicates (3)
1
2
3
4
5
6
7
8
9
10
11
12
% Remember to use the lgrind style

\File{lex\_input\_example.l},{15:00},{Sep 28 1992}
\L{\LB{\C{}\1\* Lexemes \*\1\CE{}}}
\L{\LB{\%\{}}
\L{\LB{\K{\#include}_\S{}\"k.h\"\SE{}_}}
\L{\LB{\K{\#include}_\S{}\"y.tab.h\"\SE{}_}}
\L{\LB{\%\}}}
\L{\LB{\%\%}}
\L{\LB{[\V{a}\-\V{zA}\-\V{Z0}\-9]+}\Tab{16}{\{_\V{yylval}.\V{yt\_casestring}_=_\V{mkcasestring}(\V{yytext});_\K{return}_\V{ID};\}}}
\L{\LB{[\2\V{t}\2\V{n}_]}\Tab{16}{\{_;_\}__\C{}\1\* skip the white space \*\1\CE{}}}
\L{\LB{.}\Tab{16}{\{_\K{return}_\V{yytext}[0];_\}}}