/* A lexical scanner generated by flex */

/* scanner skeleton version:
 * $Header: /home/horse/u0/vern/flex/RCS/flex.skel,v 2.16 90/08/03 14:09:36 vern Exp Locker: vern $
 */

#define FLEX_SCANNER

#include <stdio.h>


/* cfront 1.2 defines "c_plusplus" instead of "__cplusplus" */
#ifdef c_plusplus
#ifndef __cplusplus
#define __cplusplus
#endif
#endif


#ifdef __cplusplus

#include <stdlib.h>
#include <osfcn.h>

/* use prototypes in function declarations */
#define YY_USE_PROTOS

/* the "const" storage-class-modifier is valid */
#define YY_USE_CONST

#else	/* ! __cplusplus */

#ifdef __STDC__

#ifdef __GNUC__
#include <stddef.h>
void *malloc( size_t );
void free( void* );
#else
#include <stdlib.h>
#endif	/* __GNUC__ */

#define YY_USE_PROTOS
#define YY_USE_CONST

#endif	/* __STDC__ */
#endif	/* ! __cplusplus */


#ifdef __TURBOC__
#define YY_USE_CONST
#endif


#ifndef YY_USE_CONST
#define const
#endif


#ifdef YY_USE_PROTOS
#define YY_PROTO(proto) proto
#else
#define YY_PROTO(proto) ()
/* we can't get here if it's an ANSI C compiler, or a C++ compiler,
 * so it's got to be a K&R compiler, and therefore there's no standard
 * place from which to include these definitions
 */
char *malloc();
int free();
int read();
#endif


/* amount of stuff to slurp up with each read */
#ifndef YY_READ_BUF_SIZE
#define YY_READ_BUF_SIZE 8192
#endif

/* returned upon end-of-file */
#define YY_END_TOK 0

/* copy whatever the last rule matched to the standard output */

/* cast to (char *) is because for 8-bit chars, yytext is (unsigned char *) */
/* this used to be an fputs(), but since the string might contain NUL's,
 * we now use fwrite()
 */
#define ECHO (void) fwrite( (char *) yytext, yyleng, 1, yyout )

/* gets input and stuffs it into "buf".  number of characters read, or YY_NULL,
 * is returned in "result".
 */
#define YY_INPUT(buf,result,max_size) \
	if ( (result = read( fileno(yyin), (char *) buf, max_size )) < 0 ) \
	    YY_FATAL_ERROR( "read() in flex scanner failed" );
#define YY_NULL 0

/* no semi-colon after return; correct usage is to write "yyterminate();" -
 * we don't want an extra ';' after the "return" because that will cause
 * some compilers to complain about unreachable statements.
 */
#define yyterminate() return ( YY_NULL )

/* report a fatal error */

/* The funky do-while is used to turn this macro definition into
 * a single C statement (which needs a semi-colon terminator).
 * This avoids problems with code like:
 *
 * 	if ( something_happens )
 *		YY_FATAL_ERROR( "oops, the something happened" );
 *	else
 *		everything_okay();
 *
 * Prior to using the do-while the compiler would get upset at the
 * "else" because it interpreted the "if" statement as being all
 * done when it reached the ';' after the YY_FATAL_ERROR() call.
 */

#define YY_FATAL_ERROR(msg) \
	do \
		{ \
		(void) fputs( msg, stderr ); \
		(void) putc( '\n', stderr ); \
		exit( 1 ); \
		} \
	while ( 0 )

/* default yywrap function - always treat EOF as an EOF */
#define yywrap() 1

/* enter a start condition.  This macro really ought to take a parameter,
 * but we do it the disgusting crufty way forced on us by the ()-less
 * definition of BEGIN
 */
#define BEGIN yy_start = 1 + 2 *

/* action number for EOF rule of a given start state */
#define YY_STATE_EOF(state) (YY_END_OF_BUFFER + state + 1)

/* special action meaning "start processing a new file" */
#define YY_NEW_FILE \
	do \
		{ \
		yy_init_buffer( yy_current_buffer, yyin ); \
		yy_load_buffer_state(); \
		} \
	while ( 0 )

/* default declaration of generated scanner - a define so the user can
 * easily add parameters
 */
#define YY_DECL int yylex YY_PROTO(( void )) 

/* code executed at the end of each rule */
#define YY_BREAK break;

#define YY_END_OF_BUFFER_CHAR 0

#ifndef YY_BUF_SIZE
#define YY_BUF_SIZE (YY_READ_BUF_SIZE * 2) /* size of default input buffer */
#endif

typedef struct yy_buffer_state *YY_BUFFER_STATE;

#define YY_CHAR unsigned char
# line 1 "seshl.l"
#define INITIAL 0
# line 3 "seshl.l"
#define YYSTYPE char *
#include "sesh.h"


#undef YYLMAX
#define YYLMAX 10240
#include <string.h>
#include <strings.h>
#include <stdio.h>

#define G(x) {yylval=g(x); return HIEROGLYPHE;}
#define Commence(x) BEGIN(x); etat=x;

extern char * genere();
extern char * yylval ;

#include "hache.h"
extern TABLE definitions;

void traite();
char *g();
char * nomdefine;

int dieze=0;
int couleur=0;
int etat= INITIAL;
extern int numligne;
#define DEFINE0 1
#define DEFINE1 2
#define HieroText 3
#define TEXTEIMBR 4
# line 41 "seshl.l"

/* done after the current pattern has been matched and before the
 * corresponding action - sets up yytext
 */
#define YY_DO_BEFORE_ACTION \
	yytext = yy_bp; \
	yytext -= yy_more_len; \
	yyleng = yy_cp - yytext; \
	yy_hold_char = *yy_cp; \
	*yy_cp = '\0'; \
	yy_c_buf_p = yy_cp;

#define EOB_ACT_CONTINUE_SCAN 0
#define EOB_ACT_END_OF_FILE 1
#define EOB_ACT_LAST_MATCH 2

/* return all but the first 'n' matched characters back to the input stream */
#define yyless(n) \
	do \
		{ \
		/* undo effects of setting up yytext */ \
		*yy_cp = yy_hold_char; \
		yy_c_buf_p = yy_cp = yy_bp + n; \
		YY_DO_BEFORE_ACTION; /* set up yytext again */ \
		} \
	while ( 0 )

#define unput(c) yyunput( c, yytext )


struct yy_buffer_state
    {
    FILE *yy_input_file;

    YY_CHAR *yy_ch_buf;		/* input buffer */
    YY_CHAR *yy_buf_pos;	/* current position in input buffer */

    /* size of input buffer in bytes, not including room for EOB characters */
    int yy_buf_size;	

    /* number of characters read into yy_ch_buf, not including EOB characters */
    int yy_n_chars;

    int yy_eof_status;		/* whether we've seen an EOF on this buffer */
#define EOF_NOT_SEEN 0
    /* "pending" happens when the EOF has been seen but there's still
     * some text process
     */
#define EOF_PENDING 1
#define EOF_DONE 2
    };

static YY_BUFFER_STATE yy_current_buffer;

/* we provide macros for accessing buffer states in case in the
 * future we want to put the buffer states in a more general
 * "scanner state"
 */
#define YY_CURRENT_BUFFER yy_current_buffer


/* yy_hold_char holds the character lost when yytext is formed */
static YY_CHAR yy_hold_char;

static int yy_n_chars;		/* number of characters read into yy_ch_buf */



#ifndef YY_USER_ACTION
#define YY_USER_ACTION
#endif

#ifndef YY_USER_INIT
#define YY_USER_INIT
#endif

extern YY_CHAR *yytext;
extern int yyleng;
extern FILE *yyin, *yyout;

YY_CHAR *yytext;
int yyleng;

FILE *yyin = (FILE *) 0, *yyout = (FILE *) 0;

#define YY_END_OF_BUFFER 85
typedef int yy_state_type;
static const short int yy_acclist[231] =
    {   0,
       85,    1,   84,    2,   84,    1,   84,   84,    4,   84,
       84,    5,   84,   81,   84,    7,   81,   84,    7,    9,
       84,   41,   81,   84,   81,   84,   78,   81,   84,   79,
       81,   84,   81,   84,   16,   40,   81,   84,   31,   81,
       84,   81,   84,   81,   84,   81,   84,   16,   38,   40,
       81,   84,   46,   81,   84,   16,   40,   81,   84,   16,
       40,   81,   84,   32,   81,   84,   22,   81,   84,   27,
       81,   84,   26,   81,   84,   54,   81,   84,   16,   40,
       81,   84,   16,   40,   81,   84,   11,   16,   40,   81,
       84,   16,   40,   52,   81,   84,   81,   84,   80,   81,

       84,   81,   84,   53,   81,   84,   16,   40,   81,   84,
       16,   40,   51,   81,   84,   16,   40,   81,   84,   81,
       84,   81,   84,   83,   84,   83,   84,    4,    5,    5,
        7,   41,   31,    8,   32,   41,   42,   63,   78,   50,
       79,   57,   16,   40,   65,   31,   30,   33,   20,   41,
       78,   79,   22,   28,   26,   16,   39,   40,   43,   15,
       16,   40,   32,   29,   22,   67,   68,   66,   55,   16,
       17,   40,   16,   40,   62,   56,   64,   60,   58,   37,
       18,   18,   18,   18,   61,   44,   45,   36,   59,   82,
       42,   47,   48,   49,   34,   35,   14,   16,   40,   72,

       74,   73,   75,   77,   76,   69,   71,   70,   23,   25,
       24,   16,   17,   40,   10,   12,   18,   19,   18,   23,
       25,   24,   13,   18,   19,   18,   21,    6,    3,    3
    } ;

static const short int yy_accept[192] =
    {   0,
        1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
        1,    2,    4,    6,    8,    9,   11,   12,   14,   16,
       19,   22,   25,   27,   30,   33,   35,   39,   42,   44,
       46,   48,   53,   56,   60,   64,   67,   70,   73,   76,
       79,   83,   87,   92,   97,   99,  102,  104,  107,  111,
      116,  120,  122,  124,  126,  128,  128,  129,  129,  130,
      131,  132,  133,  134,  135,  136,  136,  137,  138,  139,
      140,  141,  141,  141,  141,  142,  143,  145,  146,  147,
      148,  148,  148,  149,  150,  151,  152,  153,  154,  155,
      156,  159,  160,  163,  164,  165,  166,  167,  168,  169,

      169,  169,  169,  170,  173,  175,  175,  176,  177,  178,
      179,  180,  181,  182,  183,  184,  185,  186,  187,  188,
      189,  190,  191,  191,  191,  192,  193,  193,  194,  195,
      196,  197,  200,  201,  202,  203,  204,  205,  206,  207,
      208,  209,  210,  211,  212,  215,  216,  216,  217,  219,
      220,  220,  220,  220,  221,  222,  223,  224,  226,  227,
      227,  227,  227,  227,  227,  228,  228,  228,  228,  228,
      228,  228,  228,  228,  228,  228,  228,  228,  228,  228,
      228,  228,  228,  228,  228,  228,  229,  229,  230,  231,
      231

    } ;

static const YY_CHAR yy_ec[256] =
    {   0,
        1,    1,    1,    1,    1,    1,    1,    1,    2,    3,
        1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
        1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
        1,    2,    4,    5,    6,    7,    1,    8,    9,    1,
        1,   10,   11,   12,   13,   14,   15,   16,   17,   18,
       17,   17,   17,   17,   17,   17,   17,   19,    1,   20,
       21,   22,   23,    1,   24,   25,   25,   26,   25,   27,
       25,   28,   25,   25,   25,   25,   25,   25,   29,   25,
       25,   25,   30,   25,   25,   25,   25,   25,   25,   25,
       31,   32,   33,   34,    1,    1,   35,   36,   37,   38,

       39,   40,   41,   42,   43,   37,   37,   44,   45,   46,
       47,   48,   37,   49,   50,   51,   37,   52,   37,   37,
       53,   37,   54,   55,   56,    1,    1,    1,    1,    1,
        1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
        1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
        1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
        1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
        1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
        1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
        1,    1,    1,    1,    1,    1,    1,    1,    1,    1,

        1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
        1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
        1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
        1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
        1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
        1,    1,    1,    1,    1
    } ;

static const YY_CHAR yy_meta[57] =
    {   0,
        1,    2,    2,    3,    1,    1,    1,    1,    4,    1,
        1,    1,    5,    4,    1,    4,    4,    4,    1,    1,
        1,    1,    1,    4,    4,    4,    4,    4,    4,    4,
        1,    1,    6,    1,    4,    4,    4,    4,    4,    4,
        4,    4,    4,    4,    4,    4,    4,    4,    4,    4,
        4,    4,    4,    1,    1,    1
    } ;

static const short int yy_base[201] =
    {   0,
        0,    1,    3,    5,  361,  360,   33,    0,  354,  353,
      363,  368,  368,  326,  368,    7,  355,    9,  368,   88,
       92,   11,  327,   84,  346,  325,  324,  106,   62,    0,
      108,   90,  341,  322,   77,  114,  112,  368,  368,  331,
      127,  116,  136,  147,  162,  213,  320,  368,   98,  319,
      104,    0,  318,  368,  300,  310,   14,  342,   16,   18,
      171,   20,   22,  368,   24,  308,   26,   28,  368,  368,
      331,  306,  329,  328,  368,  368,  309,  368,  144,  368,
      300,  302,  368,    0,  173,  326,  325,  143,  368,  368,
      304,  368,  105,  156,  368,  368,  147,  155,  159,  194,

      199,  203,  368,  191,  194,  180,  368,  368,  368,  368,
      368,  368,  332,  216,  231,  168,  368,  368,  368,    0,
      368,  368,  294,  288,  219,  368,  293,  368,  368,  368,
      368,  299,  368,  368,  368,  368,  368,  368,  368,  368,
      368,  223,  242,  251,  117,  368,  296,  368,  242,  181,
      287,  291,  254,  368,  368,  368,  368,  226,  114,  282,
      273,  259,  284,  271,  265,  281,  281,  283,  278,  271,
      280,  271,  268,  274,  265,  260,  224,  210,  184,  175,
      160,  157,  141,  131,  136,  368,  110,  267,  269,  368,
      272,  278,  284,  290,  296,  299,  157,  303,  307,  312

    } ;

static const short int yy_def[201] =
    {   0,
      191,  191,  192,  192,  193,  193,  190,    7,  194,  194,
      190,  190,  190,  190,  190,  190,  195,  190,  190,  190,
      190,  190,  190,  190,  190,  190,  196,  190,  190,  197,
      190,  196,  190,  196,  196,  190,  190,  190,  190,  190,
      196,  196,  196,  196,  190,  198,  190,  190,  196,  196,
      196,  199,  190,  190,  190,  190,  190,  195,  190,  190,
      190,  190,  190,  190,  190,  190,  190,  190,  190,  190,
      190,  190,  190,  190,  190,  190,  196,  190,  190,  190,
      190,  190,  190,  197,  190,  190,  190,  190,  190,  190,
      196,  190,  196,  190,  190,  190,  190,  190,  190,  190,

      190,  190,  190,  196,  196,  190,  190,  190,  190,  190,
      190,  190,  198,  198,  198,  198,  190,  190,  190,  199,
      190,  190,  190,  190,  190,  190,  190,  190,  190,  190,
      190,  196,  190,  190,  190,  190,  190,  190,  190,  190,
      190,  190,  190,  190,  196,  190,  190,  190,  198,  198,
      190,  190,  190,  190,  190,  190,  190,  198,  198,  190,
      190,  200,  190,  190,  200,  190,  190,  190,  190,  190,
      190,  190,  190,  190,  190,  190,  190,  190,  190,  190,
      190,  190,  190,  190,  190,  190,  190,  190,  190,    0,
      190,  190,  190,  190,  190,  190,  190,  190,  190,  190

    } ;

static const short int yy_nxt[425] =
    {   0,
      190,  190,   13,   13,   16,   16,   16,   16,   57,   57,
       60,   60,   67,   67,   68,   57,   57,   60,   60,   60,
       60,   67,   67,   79,   79,   94,   94,   67,   67,  125,
      125,   14,   14,   19,   20,   21,   22,   23,   24,   25,
       26,   27,   28,   29,   30,   31,   32,   33,   34,   34,
       35,   36,   37,   38,   39,   40,   41,   42,   43,   42,
       42,   44,   42,   45,   46,   47,   48,   34,   34,   34,
       34,   34,   34,   34,   49,   34,   34,   34,   34,   50,
       34,   34,   34,   34,   51,   34,   19,   52,   53,   61,
       61,   62,   93,   61,   61,   62,   70,   63,   71,   81,

       64,   63,   82,   91,   64,   83,   65,   79,   79,  190,
       65,   85,  118,   86,   87,   94,   94,  190,  119,   66,
      132,   72,  190,   66,   96,   73,   80,   88,   89,   90,
      190,  104,  104,  104,   95,   74,  190,  190,   97,   98,
      145,   99,  104,  104,  104,   79,   79,  100,  190,  190,
      101,  104,  104,  104,  106,   96,  102,   94,   94,  190,
       84,  105,  104,  104,  104,  188,  107,  163,  190,  108,
      109,  190,   61,   61,   67,   67,   68,  187,  100,  190,
       63,  101,  133,   64,  190,  134,  186,  102,  185,   65,
      136,  135,  110,  137,  139,  142,  142,  140,  184,  138,

      143,  143,   66,  141,  144,  144,  104,  104,  104,  104,
      104,  104,  183,  150,  145,  111,  112,  146,  159,  190,
      125,  125,  182,  190,  142,  142,  190,  181,  147,  190,
      148,  149,  149,  149,  190,  154,  114,  115,  115,  115,
      115,  115,  115,  143,  143,  190,  149,  149,  149,  158,
      115,  116,  144,  144,  155,  162,  162,  149,  149,  149,
      162,  162,  180,  156,  179,  158,  190,  190,  189,  189,
      189,  189,   12,   12,   12,   12,   12,   12,   15,   15,
       15,   15,   15,   15,   17,   17,   17,   17,   17,   17,
       54,   54,   54,   54,   54,   54,   58,   58,   58,   58,

       58,   58,   77,  178,   77,  113,  113,  120,  120,  120,
      120,  177,  120,  165,  176,  165,  175,  174,  173,  172,
      171,  170,  169,  168,  167,  166,  163,  164,  161,  160,
      157,  190,  153,  152,  151,  190,  190,   75,   70,  131,
      130,  190,  129,  128,  127,  126,  124,   59,  123,  122,
      121,  190,  117,  103,  190,   92,   78,   76,   75,   69,
       59,   56,  190,   55,   55,   18,   18,   11,  190,  190,
      190,  190,  190,  190,  190,  190,  190,  190,  190,  190,
      190,  190,  190,  190,  190,  190,  190,  190,  190,  190,
      190,  190,  190,  190,  190,  190,  190,  190,  190,  190,

      190,  190,  190,  190,  190,  190,  190,  190,  190,  190,
      190,  190,  190,  190,  190,  190,  190,  190,  190,  190,
      190,  190,  190,  190
    } ;

static const short int yy_chk[425] =
    {   0,
        0,    0,    1,    2,    3,    3,    4,    4,   16,   16,
       18,   18,   22,   22,   22,   57,   57,   59,   59,   60,
       60,   62,   62,   63,   63,   65,   65,   67,   67,   68,
       68,    1,    2,    7,    7,    7,    7,    7,    7,    7,
        7,    7,    7,    7,    7,    7,    7,    7,    7,    7,
        7,    7,    7,    7,    7,    7,    7,    7,    7,    7,
        7,    7,    7,    7,    7,    7,    7,    7,    7,    7,
        7,    7,    7,    7,    7,    7,    7,    7,    7,    7,
        7,    7,    7,    7,    7,    7,    7,    7,    7,   20,
       20,   20,   35,   21,   21,   21,   24,   20,   24,   29,

       20,   21,   29,   32,   21,   29,   20,   28,   28,   35,
       21,   31,   49,   31,   31,   36,   36,  159,   51,   20,
       93,   24,   32,   21,   37,   24,   28,   31,   31,   31,
       49,   42,   42,   42,   36,   24,   51,   93,   37,   37,
      145,   37,   41,   41,   41,   79,   79,   37,   42,  145,
       37,   43,   43,   43,   43,   88,   37,   94,   94,   41,
      197,   41,   44,   44,   44,  187,   45,  159,   43,   45,
       45,  116,   61,   61,   85,   85,   85,  185,   88,   44,
       61,   88,   97,   61,  150,   97,  184,   88,  183,   61,
       98,   97,   45,   98,   99,  100,  100,   99,  182,   98,

      101,  101,   61,   99,  102,  102,  104,  104,  104,  105,
      105,  105,  181,  116,  104,   45,   46,  106,  150,  114,
      125,  125,  180,  104,  142,  142,  105,  179,  106,  158,
      106,  114,  114,  114,  115,  142,   46,   46,   46,   46,
       46,   46,   46,  143,  143,  149,  115,  115,  115,  158,
      114,   46,  144,  144,  143,  153,  153,  149,  149,  149,
      162,  162,  178,  144,  177,  149,  165,  165,  188,  188,
      189,  189,  191,  191,  191,  191,  191,  191,  192,  192,
      192,  192,  192,  192,  193,  193,  193,  193,  193,  193,
      194,  194,  194,  194,  194,  194,  195,  195,  195,  195,

      195,  195,  196,  176,  196,  198,  198,  199,  199,  199,
      199,  175,  199,  200,  174,  200,  173,  172,  171,  170,
      169,  168,  167,  166,  164,  163,  161,  160,  152,  151,
      147,  132,  127,  124,  123,  113,   91,   87,   86,   82,
       81,   77,   74,   73,   72,   71,   66,   58,   56,   55,
       53,   50,   47,   40,   34,   33,   27,   26,   25,   23,
       17,   14,   11,   10,    9,    6,    5,  190,  190,  190,
      190,  190,  190,  190,  190,  190,  190,  190,  190,  190,
      190,  190,  190,  190,  190,  190,  190,  190,  190,  190,
      190,  190,  190,  190,  190,  190,  190,  190,  190,  190,

      190,  190,  190,  190,  190,  190,  190,  190,  190,  190,
      190,  190,  190,  190,  190,  190,  190,  190,  190,  190,
      190,  190,  190,  190
    } ;

static yy_state_type yy_last_accepting_state;
static YY_CHAR *yy_last_accepting_cpos;

static yy_state_type yy_state_buf[YY_BUF_SIZE + 2], *yy_state_ptr;
static YY_CHAR *yy_full_match;
static int yy_lp;
#define REJECT \
{ \
*yy_cp = yy_hold_char; /* undo effects of setting up yytext */ \
yy_cp = yy_full_match; /* restore poss. backed-over text */ \
++yy_lp; \
goto find_rule; \
}
static int yy_more_flag = 0;
static int yy_doing_yy_more = 0;
static int yy_more_len = 0;
#define yymore() { yy_more_flag = 1; }
#define YY_MORE_ADJ (yy_doing_yy_more ? yy_more_len : 0)

/* these variables are all declared out here so that section 3 code can
 * manipulate them
 */
/* points to current character in buffer */
static YY_CHAR *yy_c_buf_p = (YY_CHAR *) 0;
static int yy_init = 1;		/* whether we need to initialize */
static int yy_start = 0;	/* start state number */

/* flag which is used to allow yywrap()'s to do buffer switches
 * instead of setting up a fresh yyin.  A bit of a hack ...
 */
static int yy_did_buffer_switch_on_eof;

static yy_state_type yy_get_previous_state YY_PROTO(( void ));
static yy_state_type yy_try_NUL_trans YY_PROTO(( yy_state_type current_state ));
static int yy_get_next_buffer YY_PROTO(( void ));
static void yyunput YY_PROTO(( YY_CHAR c, YY_CHAR *buf_ptr ));
void yyrestart YY_PROTO(( FILE *input_file ));
void yy_switch_to_buffer YY_PROTO(( YY_BUFFER_STATE new_buffer ));
void yy_load_buffer_state YY_PROTO(( void ));
YY_BUFFER_STATE yy_create_buffer YY_PROTO(( FILE *file, int size ));
void yy_delete_buffer YY_PROTO(( YY_BUFFER_STATE b ));
void yy_init_buffer YY_PROTO(( YY_BUFFER_STATE b, FILE *file ));

#define yy_new_buffer yy_create_buffer

#ifdef __cplusplus
static int yyinput YY_PROTO(( void ));
#else
static int input YY_PROTO(( void ));
#endif

YY_DECL
    {
    register yy_state_type yy_current_state;
    register YY_CHAR *yy_cp, *yy_bp;
    register int yy_act;


                 switch(etat)
		 	{ case INITIAL: BEGIN(INITIAL);break;
			  case HieroText: BEGIN(HieroText);break;
                        }


    if ( yy_init )
	{
	YY_USER_INIT;

	if ( ! yy_start )
	    yy_start = 1;	/* first start state */

	if ( ! yyin )
	    yyin = stdin;

	if ( ! yyout )
	    yyout = stdout;

	if ( yy_current_buffer )
	    yy_init_buffer( yy_current_buffer, yyin );
	else
	    yy_current_buffer = yy_create_buffer( yyin, YY_BUF_SIZE );

	yy_load_buffer_state();

	yy_init = 0;
	}

    while ( 1 )		/* loops until end-of-file is reached */
	{
	yy_more_len = 0;
	yy_doing_yy_more = yy_more_flag;
	if ( yy_doing_yy_more )
	    {
	    yy_more_len = yyleng;
	    yy_more_flag = 0;
	    }
	yy_cp = yy_c_buf_p;

	/* support of yytext */
	*yy_cp = yy_hold_char;

	/* yy_bp points to the position in yy_ch_buf of the start of the
	 * current run.
	 */
	yy_bp = yy_cp;

	yy_current_state = yy_start;
	yy_state_ptr = yy_state_buf;
	*yy_state_ptr++ = yy_current_state;
yy_match:
	do
	    {
	    register YY_CHAR yy_c = yy_ec[*yy_cp];
	    while ( yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_state )
		{
		yy_current_state = yy_def[yy_current_state];
		if ( yy_current_state >= 191 )
		    yy_c = yy_meta[yy_c];
		}
	    yy_current_state = yy_nxt[yy_base[yy_current_state] + yy_c];
	    *yy_state_ptr++ = yy_current_state;
	    ++yy_cp;
	    }
	while ( yy_current_state != 190 );

yy_find_action:
	yy_current_state = *--yy_state_ptr;
	yy_lp = yy_accept[yy_current_state];
find_rule: /* we branch to this label when backtracking */
	for ( ; ; ) /* until we find what rule we matched */
	    {
	    if ( yy_lp && yy_lp < yy_accept[yy_current_state + 1] )
		{
		yy_act = yy_acclist[yy_lp];
		    {
		    yy_full_match = yy_cp;
		    break;
		    }
		}
	    --yy_cp;
	    yy_current_state = *--yy_state_ptr;
	    yy_lp = yy_accept[yy_current_state];
	    }

	YY_DO_BEFORE_ACTION;
	YY_USER_ACTION;

do_action:	/* this label is used only to access EOF actions */


	switch ( yy_act )
	    {
case 1:
# line 47 "seshl.l"
{ECHO; return TEXTE;}
	YY_BREAK
case 2:
# line 48 "seshl.l"
{ECHO; numligne++; return TEXTE;}
	YY_BREAK
case 3:
# line 49 "seshl.l"
{ printf("\\begin{hieroglyph}%%\n");
                                          TLIGNE();
                              					  Commence(HieroText); 
                                          return DEBUTHIEROGS;}
	YY_BREAK
case 4:
# line 54 "seshl.l"
BEGIN(DEFINE1);
	YY_BREAK
case 5:
# line 55 "seshl.l"
{ char *pt;
						  char *s= strdup(yytext);
						  TLIGNE();
						  pt= s + yyleng;
						  while (*(--pt) != '#');
						  *pt= 0;
						  stocke(nomdefine, s); 
						  Commence(HieroText);}
	YY_BREAK
case 6:
# line 64 "seshl.l"
{ TLIGNE(); Commence(INITIAL); return FINHIEROGS;}
	YY_BREAK
case 7:
# line 67 "seshl.l"
case 8:
# line 67 "seshl.l"
{TLIGNE(); return ESPACE;}
	YY_BREAK
case 9:
# line 68 "seshl.l"
{numligne++; return ESPACE;}
	YY_BREAK
case 10:
# line 70 "seshl.l"
{yylval= genere("\\ligAROBDd%\n", NULL);
					return HIEROGLYPHE;}
	YY_BREAK
case 11:
# line 72 "seshl.l"
{yylval= genere("\\ligAROBD%\n", NULL);
					return HIEROGLYPHE;}
	YY_BREAK
case 12:
# line 74 "seshl.l"
{yylval= genere("\\ligAROBDt%\n", NULL);		
					return HIEROGLYPHE;}
	YY_BREAK
case 13:
# line 76 "seshl.l"
{yylval= genere("\\ligAROBDra%\n", NULL);		
					return HIEROGLYPHE;}
	YY_BREAK
case 14:
# line 78 "seshl.l"
{yylval= genere("\\hierCC%\n", NULL);
					return HIEROGLYPHE;}
	YY_BREAK
case 15:
# line 80 "seshl.l"
{yylval= genere("\\hierXX%\n", NULL);
					return HIEROGLYPHE;}
	YY_BREAK
case 16:
# line 83 "seshl.l"
case 17:
# line 83 "seshl.l"
{if (!(yylval =g(yytext,0))) {REJECT } else return HIEROGLYPHE;}
	YY_BREAK
case 18:
# line 86 "seshl.l"
case 19:
# line 86 "seshl.l"
{if (!(yylval =g(yytext+1,1))) {REJECT } else return HIEROGLYPHE;}
	YY_BREAK
case 20:
# line 88 "seshl.l"
{traite(yytext+1);}
	YY_BREAK
case 21:
# line 89 "seshl.l"
{ int i;
                                  for (i=4; yytext[i]
				   && (yytext[i] == ' ' || yytext[i]== '\t');
				   i++);
			 	   if  (yytext[i])
			 	     {
			               nomdefine=strdup(yytext+i);
			               BEGIN (DEFINE0);
			             }
				   else
				     yyerror("Mauvaise definition");
		                }
	YY_BREAK
case 22:
# line 101 "seshl.l"
return CARTO;
	YY_BREAK
case 23:
# line 102 "seshl.l"
return DEBCARTO;
	YY_BREAK
case 24:
# line 103 "seshl.l"
return MILCARTO;
	YY_BREAK
case 25:
# line 104 "seshl.l"
return FINCARTO;
	YY_BREAK
case 26:
# line 105 "seshl.l"
return CARTF;
	YY_BREAK
case 27:
# line 106 "seshl.l"
return '-';
	YY_BREAK
case 28:
# line 107 "seshl.l"
return '-';
	YY_BREAK
case 29:
# line 108 "seshl.l"
return ':';
	YY_BREAK
case 30:
# line 109 "seshl.l"
return '*';
	YY_BREAK
case 31:
# line 110 "seshl.l"
return '*';
	YY_BREAK
case 32:
# line 111 "seshl.l"
{return ':'; }
	YY_BREAK
case 33:
# line 112 "seshl.l"
BEGIN(TEXTEIMBR);
	YY_BREAK
case 34:
# line 113 "seshl.l"
return DROITEGAUCHE;
	YY_BREAK
case 35:
# line 114 "seshl.l"
return GAUCHEDROITE;
	YY_BREAK
case 36:
# line 115 "seshl.l"
{ yylval= strdup(yytext+1);
                                  return TEXTESUPER;
                                }
	YY_BREAK
case 37:
# line 118 "seshl.l"
return KERNING;
	YY_BREAK
case 38:
# line 119 "seshl.l"
return POINT;
	YY_BREAK
case 39:
# line 120 "seshl.l"
return POINTPOINT;
	YY_BREAK
case 40:
# line 121 "seshl.l"
{traite(yytext);}
	YY_BREAK
case 41:
# line 122 "seshl.l"
{TLIGNE(); return FINLIGNE;}
	YY_BREAK
case 42:
# line 123 "seshl.l"
{ TLIGNE(); return FINPAGE;}
	YY_BREAK
case 43:
# line 124 "seshl.l"
return HACHUREG;
	YY_BREAK
case 44:
# line 125 "seshl.l"
return HACHUREH;
	YY_BREAK
case 45:
# line 126 "seshl.l"
return HACHUREV;
	YY_BREAK
case 46:
# line 127 "seshl.l"
return HACHURET;
	YY_BREAK
case 47:
# line 128 "seshl.l"
return HACHUREGA ;
	YY_BREAK
case 48:
# line 129 "seshl.l"
return HACHUREHA ;
	YY_BREAK
case 49:
# line 130 "seshl.l"
return HACHUREVA;
	YY_BREAK
case 50:
# line 131 "seshl.l"
return HACHURETA;
	YY_BREAK
case 51:
# line 132 "seshl.l"
return POINTROUGE;
	YY_BREAK
case 52:
# line 133 "seshl.l"
return POINTNOIR;
	YY_BREAK
case 53:
# line 134 "seshl.l"
return HAPLOGRAPHIE;
	YY_BREAK
case 54:
# line 135 "seshl.l"
return LACUNE;
	YY_BREAK
case 55:
# line 136 "seshl.l"
return  LIGNELACUNE;
	YY_BREAK
case 56:
# line 137 "seshl.l"
return DSTSUPERFETATOIRE;
	YY_BREAK
case 57:
# line 138 "seshl.l"
return FSTSUPERFETATOIRE;
	YY_BREAK
case 58:
# line 139 "seshl.l"
return DSTEFFACE;
	YY_BREAK
case 59:
# line 140 "seshl.l"
return FSTEFFACE;
	YY_BREAK
case 60:
# line 141 "seshl.l"
return  DSTDISPARU ;
	YY_BREAK
case 61:
# line 142 "seshl.l"
return  FSTDISPARU ;
	YY_BREAK
case 62:
# line 143 "seshl.l"
return  DSTRAJOUTSCRIBE;
	YY_BREAK
case 63:
# line 144 "seshl.l"
return  FSTRAJOUTSCRIBE;
	YY_BREAK
case 64:
# line 145 "seshl.l"
return  DSTRAJOUTAUTEUR;
	YY_BREAK
case 65:
# line 146 "seshl.l"
return  FSTRAJOUTAUTEUR;
	YY_BREAK
case 66:
# line 147 "seshl.l"
return SEREKH;
	YY_BREAK
case 67:
# line 148 "seshl.l"
return ENCEINTE;
	YY_BREAK
case 68:
# line 149 "seshl.l"
return CHATEAU;
	YY_BREAK
case 69:
# line 150 "seshl.l"
return DEBSEREKH;
	YY_BREAK
case 70:
# line 151 "seshl.l"
return MILSEREKH;
	YY_BREAK
case 71:
# line 152 "seshl.l"
return FINSEREKH;
	YY_BREAK
case 72:
# line 153 "seshl.l"
return DEBENCEINTE;
	YY_BREAK
case 73:
# line 154 "seshl.l"
return MILENCEINTE;
	YY_BREAK
case 74:
# line 155 "seshl.l"
return FINENCEINTE;
	YY_BREAK
case 75:
# line 156 "seshl.l"
return DEBCHATEAU;
	YY_BREAK
case 76:
# line 157 "seshl.l"
return MILCHATEAU;
	YY_BREAK
case 77:
# line 158 "seshl.l"
return FINCHATEAU;
	YY_BREAK
case 78:
# line 159 "seshl.l"
{ dieze=1-dieze; /* ne compliquons pas la grammaire */
				  if (dieze==1) return DIEZE0;
				     else return DIEZE1;}
	YY_BREAK
case 79:
# line 162 "seshl.l"
{ couleur=1-couleur; /* ne compliquons pas la grammaire */
				  if (couleur==1) return COULEUR0;
				     else return COULEUR1;}
	YY_BREAK
case 80:
# line 165 "seshl.l"
yymore();
	YY_BREAK
case 81:
# line 166 "seshl.l"
return yytext[0];
	YY_BREAK
case 82:
# line 168 "seshl.l"
{yylval= strdup(yytext); 
				 yylval[strlen(yylval)-2]=0;
				 return ROMAIN;
                                }
	YY_BREAK
case 83:
# line 172 "seshl.l"
{TLIGNE(); yymore(); }
	YY_BREAK
case 84:
# line 173 "seshl.l"
ECHO;
	YY_BREAK
	    case YY_STATE_EOF(INITIAL):
	    case YY_STATE_EOF(DEFINE0):
	    case YY_STATE_EOF(DEFINE1):
	    case YY_STATE_EOF(HieroText):
	    case YY_STATE_EOF(TEXTEIMBR):
		yyterminate();

	    case YY_END_OF_BUFFER:
		{
		/* amount of text matched not including the EOB char */
		int yy_amount_of_matched_text = yy_cp - yytext - 1;

		/* undo the effects of YY_DO_BEFORE_ACTION */
		*yy_cp = yy_hold_char;

		/* note that here we test for yy_c_buf_p "<=" to the position
		 * of the first EOB in the buffer, since yy_c_buf_p will
		 * already have been incremented past the NUL character
		 * (since all states make transitions on EOB to the end-
		 * of-buffer state).  Contrast this with the test in yyinput().
		 */
		if ( yy_c_buf_p <= &yy_current_buffer->yy_ch_buf[yy_n_chars] )
		    /* this was really a NUL */
		    {
		    yy_state_type yy_next_state;

		    yy_c_buf_p = yytext + yy_amount_of_matched_text;

		    yy_current_state = yy_get_previous_state();

		    /* okay, we're now positioned to make the
		     * NUL transition.  We couldn't have
		     * yy_get_previous_state() go ahead and do it
		     * for us because it doesn't know how to deal
		     * with the possibility of jamming (and we
		     * don't want to build jamming into it because
		     * then it will run more slowly)
		     */

		    yy_next_state = yy_try_NUL_trans( yy_current_state );

		    yy_bp = yytext + YY_MORE_ADJ;

		    if ( yy_next_state )
			{
			/* consume the NUL */
			yy_cp = ++yy_c_buf_p;
			yy_current_state = yy_next_state;
			goto yy_match;
			}

		    else
			{
			goto yy_find_action;
			}
		    }

		else switch ( yy_get_next_buffer() )
		    {
		    case EOB_ACT_END_OF_FILE:
			{
			yy_did_buffer_switch_on_eof = 0;

			if ( yywrap() )
			    {
			    /* note: because we've taken care in
			     * yy_get_next_buffer() to have set up yytext,
			     * we can now set up yy_c_buf_p so that if some
			     * total hoser (like flex itself) wants
			     * to call the scanner after we return the
			     * YY_NULL, it'll still work - another YY_NULL
			     * will get returned.
			     */
			    yy_c_buf_p = yytext + YY_MORE_ADJ;

			    yy_act = YY_STATE_EOF((yy_start - 1) / 2);
			    goto do_action;
			    }

			else
			    {
			    if ( ! yy_did_buffer_switch_on_eof )
				YY_NEW_FILE;
			    }
			}
			break;

		    case EOB_ACT_CONTINUE_SCAN:
			yy_c_buf_p = yytext + yy_amount_of_matched_text;

			yy_current_state = yy_get_previous_state();

			yy_cp = yy_c_buf_p;
			yy_bp = yytext + YY_MORE_ADJ;
			goto yy_match;

		    case EOB_ACT_LAST_MATCH:
			yy_c_buf_p =
			    &yy_current_buffer->yy_ch_buf[yy_n_chars];

			yy_current_state = yy_get_previous_state();

			yy_cp = yy_c_buf_p;
			yy_bp = yytext + YY_MORE_ADJ;
			goto yy_find_action;
		    }
		break;
		}

	    default:
#ifdef FLEX_DEBUG
		printf( "action # %d\n", yy_act );
#endif
		YY_FATAL_ERROR(
			"fatal flex scanner internal error--no action found" );
	    }
	}
    }


/* yy_get_next_buffer - try to read in a new buffer
 *
 * synopsis
 *     int yy_get_next_buffer();
 *     
 * returns a code representing an action
 *     EOB_ACT_LAST_MATCH - 
 *     EOB_ACT_CONTINUE_SCAN - continue scanning from current position
 *     EOB_ACT_END_OF_FILE - end of file
 */

static int yy_get_next_buffer()

    {
    register YY_CHAR *dest = yy_current_buffer->yy_ch_buf;
    register YY_CHAR *source = yytext - 1; /* copy prev. char, too */
    register int number_to_move, i;
    int ret_val;

    if ( yy_c_buf_p > &yy_current_buffer->yy_ch_buf[yy_n_chars + 1] )
	YY_FATAL_ERROR(
		"fatal flex scanner internal error--end of buffer missed" );

    /* try to read more data */

    /* first move last chars to start of buffer */
    number_to_move = yy_c_buf_p - yytext;

    for ( i = 0; i < number_to_move; ++i )
	*(dest++) = *(source++);

    if ( yy_current_buffer->yy_eof_status != EOF_NOT_SEEN )
	/* don't do the read, it's not guaranteed to return an EOF,
	 * just force an EOF
	 */
	yy_n_chars = 0;

    else
	{
	int num_to_read = yy_current_buffer->yy_buf_size - number_to_move - 1;

	if ( num_to_read > YY_READ_BUF_SIZE )
	    num_to_read = YY_READ_BUF_SIZE;

	else if ( num_to_read <= 0 )
	    YY_FATAL_ERROR( "fatal error - scanner input buffer overflow" );

	/* read in more data */
	YY_INPUT( (&yy_current_buffer->yy_ch_buf[number_to_move]),
		  yy_n_chars, num_to_read );
	}

    if ( yy_n_chars == 0 )
	{
	if ( number_to_move - YY_MORE_ADJ == 1 )
	    {
	    ret_val = EOB_ACT_END_OF_FILE;
	    yy_current_buffer->yy_eof_status = EOF_DONE;
	    }

	else
	    {
	    ret_val = EOB_ACT_LAST_MATCH;
	    yy_current_buffer->yy_eof_status = EOF_PENDING;
	    }
	}

    else
	ret_val = EOB_ACT_CONTINUE_SCAN;

    yy_n_chars += number_to_move;
    yy_current_buffer->yy_ch_buf[yy_n_chars] = YY_END_OF_BUFFER_CHAR;
    yy_current_buffer->yy_ch_buf[yy_n_chars + 1] = YY_END_OF_BUFFER_CHAR;

    /* yytext begins at the second character in yy_ch_buf; the first
     * character is the one which preceded it before reading in the latest
     * buffer; it needs to be kept around in case it's a newline, so
     * yy_get_previous_state() will have with '^' rules active
     */

    yytext = &yy_current_buffer->yy_ch_buf[1];

    return ( ret_val );
    }


/* yy_get_previous_state - get the state just before the EOB char was reached
 *
 * synopsis
 *     yy_state_type yy_get_previous_state();
 */

static yy_state_type yy_get_previous_state()

    {
    register yy_state_type yy_current_state;
    register YY_CHAR *yy_cp;

    yy_current_state = yy_start;
    yy_state_ptr = yy_state_buf;
    *yy_state_ptr++ = yy_current_state;

    for ( yy_cp = yytext + YY_MORE_ADJ; yy_cp < yy_c_buf_p; ++yy_cp )
	{
	register YY_CHAR yy_c = (*yy_cp ? yy_ec[*yy_cp] : 1);
	while ( yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_state )
	    {
	    yy_current_state = yy_def[yy_current_state];
	    if ( yy_current_state >= 191 )
		yy_c = yy_meta[yy_c];
	    }
	yy_current_state = yy_nxt[yy_base[yy_current_state] + yy_c];
	*yy_state_ptr++ = yy_current_state;
	}

    return ( yy_current_state );
    }


/* yy_try_NUL_trans - try to make a transition on the NUL character
 *
 * synopsis
 *     next_state = yy_try_NUL_trans( current_state );
 */

#ifdef YY_USE_PROTOS
static yy_state_type yy_try_NUL_trans( register yy_state_type yy_current_state )
#else
static yy_state_type yy_try_NUL_trans( yy_current_state )
register yy_state_type yy_current_state;
#endif

    {
    register int yy_is_jam;

    register YY_CHAR yy_c = 1;
    while ( yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_state )
	{
	yy_current_state = yy_def[yy_current_state];
	if ( yy_current_state >= 191 )
	    yy_c = yy_meta[yy_c];
	}
    yy_current_state = yy_nxt[yy_base[yy_current_state] + yy_c];
    *yy_state_ptr++ = yy_current_state;
    yy_is_jam = (yy_current_state == 190);

    return ( yy_is_jam ? 0 : yy_current_state );
    }


#ifdef YY_USE_PROTOS
static void yyunput( YY_CHAR c, register YY_CHAR *yy_bp )
#else
static void yyunput( c, yy_bp )
YY_CHAR c;
register YY_CHAR *yy_bp;
#endif

    {
    register YY_CHAR *yy_cp = yy_c_buf_p;

    /* undo effects of setting up yytext */
    *yy_cp = yy_hold_char;

    if ( yy_cp < yy_current_buffer->yy_ch_buf + 2 )
	{ /* need to shift things up to make room */
	register int number_to_move = yy_n_chars + 2; /* +2 for EOB chars */
	register YY_CHAR *dest =
	    &yy_current_buffer->yy_ch_buf[yy_current_buffer->yy_buf_size + 2];
	register YY_CHAR *source =
	    &yy_current_buffer->yy_ch_buf[number_to_move];

	while ( source > yy_current_buffer->yy_ch_buf )
	    *--dest = *--source;

	yy_cp += dest - source;
	yy_bp += dest - source;
	yy_n_chars = yy_current_buffer->yy_buf_size;

	if ( yy_cp < yy_current_buffer->yy_ch_buf + 2 )
	    YY_FATAL_ERROR( "flex scanner push-back overflow" );
	}

    if ( yy_cp > yy_bp && yy_cp[-1] == '\n' )
	yy_cp[-2] = '\n';

    *--yy_cp = c;

    /* note: the formal parameter *must* be called "yy_bp" for this
     *       macro to now work correctly
     */
    YY_DO_BEFORE_ACTION; /* set up yytext again */
    }


#ifdef __cplusplus
static int yyinput()
#else
static int input()
#endif

    {
    int c;
    YY_CHAR *yy_cp = yy_c_buf_p;

    *yy_cp = yy_hold_char;

    if ( *yy_c_buf_p == YY_END_OF_BUFFER_CHAR )
	{
	/* yy_c_buf_p now points to the character we want to return.
	 * If this occurs *before* the EOB characters, then it's a
	 * valid NUL; if not, then we've hit the end of the buffer.
	 */
	if ( yy_c_buf_p < &yy_current_buffer->yy_ch_buf[yy_n_chars] )
	    /* this was really a NUL */
	    *yy_c_buf_p = '\0';

	else
	    { /* need more input */
	    yytext = yy_c_buf_p;
	    ++yy_c_buf_p;

	    switch ( yy_get_next_buffer() )
		{
		case EOB_ACT_END_OF_FILE:
		    {
		    if ( yywrap() )
			{
			yy_c_buf_p = yytext + YY_MORE_ADJ;
			return ( EOF );
			}

		    YY_NEW_FILE;

#ifdef __cplusplus
		    return ( yyinput() );
#else
		    return ( input() );
#endif
		    }
		    break;

		case EOB_ACT_CONTINUE_SCAN:
		    yy_c_buf_p = yytext + YY_MORE_ADJ;
		    break;

		case EOB_ACT_LAST_MATCH:
#ifdef __cplusplus
		    YY_FATAL_ERROR( "unexpected last match in yyinput()" );
#else
		    YY_FATAL_ERROR( "unexpected last match in input()" );
#endif
		}
	    }
	}

    c = *yy_c_buf_p;
    yy_hold_char = *++yy_c_buf_p;

    return ( c );
    }


#ifdef YY_USE_PROTOS
void yyrestart( FILE *input_file )
#else
void yyrestart( input_file )
FILE *input_file;
#endif

    {
    yy_init_buffer( yy_current_buffer, input_file );
    yy_load_buffer_state();
    }


#ifdef YY_USE_PROTOS
void yy_switch_to_buffer( YY_BUFFER_STATE new_buffer )
#else
void yy_switch_to_buffer( new_buffer )
YY_BUFFER_STATE new_buffer;
#endif

    {
    if ( yy_current_buffer == new_buffer )
	return;

    if ( yy_current_buffer )
	{
	/* flush out information for old buffer */
	*yy_c_buf_p = yy_hold_char;
	yy_current_buffer->yy_buf_pos = yy_c_buf_p;
	yy_current_buffer->yy_n_chars = yy_n_chars;
	}

    yy_current_buffer = new_buffer;
    yy_load_buffer_state();

    /* we don't actually know whether we did this switch during
     * EOF (yywrap()) processing, but the only time this flag
     * is looked at is after yywrap() is called, so it's safe
     * to go ahead and always set it.
     */
    yy_did_buffer_switch_on_eof = 1;
    }


#ifdef YY_USE_PROTOS
void yy_load_buffer_state( void )
#else
void yy_load_buffer_state()
#endif

    {
    yy_n_chars = yy_current_buffer->yy_n_chars;
    yytext = yy_c_buf_p = yy_current_buffer->yy_buf_pos;
    yyin = yy_current_buffer->yy_input_file;
    yy_hold_char = *yy_c_buf_p;
    }


#ifdef YY_USE_PROTOS
YY_BUFFER_STATE yy_create_buffer( FILE *file, int size )
#else
YY_BUFFER_STATE yy_create_buffer( file, size )
FILE *file;
int size;
#endif

    {
    YY_BUFFER_STATE b;

    b = (YY_BUFFER_STATE) malloc( sizeof( struct yy_buffer_state ) );

    if ( ! b )
	YY_FATAL_ERROR( "out of dynamic memory in yy_create_buffer()" );

    b->yy_buf_size = size;

    /* yy_ch_buf has to be 2 characters longer than the size given because
     * we need to put in 2 end-of-buffer characters.
     */
    b->yy_ch_buf = (YY_CHAR *) malloc( (unsigned) (b->yy_buf_size + 2) );

    if ( ! b->yy_ch_buf )
	YY_FATAL_ERROR( "out of dynamic memory in yy_create_buffer()" );

    yy_init_buffer( b, file );

    return ( b );
    }


#ifdef YY_USE_PROTOS
void yy_delete_buffer( YY_BUFFER_STATE b )
#else
void yy_delete_buffer( b )
YY_BUFFER_STATE b;
#endif

    {
    if ( b == yy_current_buffer )
	yy_current_buffer = (YY_BUFFER_STATE) 0;

    free( (char *) b->yy_ch_buf );
    free( (char *) b );
    }


#ifdef YY_USE_PROTOS
void yy_init_buffer( YY_BUFFER_STATE b, FILE *file )
#else
void yy_init_buffer( b, file )
YY_BUFFER_STATE b;
FILE *file;
#endif

    {
    b->yy_input_file = file;

    /* we put in the '\n' and start reading from [1] so that an
     * initial match-at-newline will be true.
     */

    b->yy_ch_buf[0] = '\n';
    b->yy_n_chars = 1;

    /* we always need two end-of-buffer characters.  The first causes
     * a transition to the end-of-buffer state.  The second causes
     * a jam in that state.
     */
    b->yy_ch_buf[1] = YY_END_OF_BUFFER_CHAR;
    b->yy_ch_buf[2] = YY_END_OF_BUFFER_CHAR;

    b->yy_buf_pos = &b->yy_ch_buf[1];

    b->yy_eof_status = EOF_NOT_SEEN;
    }
# line 173 "seshl.l"


void traite(texte)
     char * texte;
{
  int i;
  char *result;
  if ((result= trouve(texte, definitions)))
    {
      for (i=strlen(result) -1; i> -1; i--)
	unput(result[i]);		
    }
  else
    {
			char toto[300];
			sprintf(toto, "texte non reconnu: %s", texte);
     	yyerror(toto);
    }
}

TLIGNE()
{
	char *s;
	int i=0;
	s= yytext;
	while (s= strchr(s, '\n'))
	{
		numligne++;
		s++;
	}
	return i;
}
