1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42
|
/* rawl.l - RAW sequence lexer */
%{
#ifdef HAVE_CONFIG_H
# include <config.h>
#endif
#include <stdlib.h>
#include <string.h>
#include "extern/text.h"
#include "sequence.h"
#include "sequence/rawy.h"
%}
%option bison-bridge
%option never-interactive
%option noinput nounput noyywrap
alp [[:alpha:]]
blk [[:blank:]]
eol "\n"
min "-"
spc " "
sta "*"
tab "\t"
gap {min}
bas ({alp}|{gap}|{sta}){1,80}
%%
{eol} ; /* Newlines ignored */
{blk} ; /* Spaces/Tabs ignored */
{bas} { yylval->str = xstrdup(yytext, yyleng); return BAS; }
<<EOF>> { return NUL; }
. { return ERR; }
%%
|