// lex.h: lexer defines & declarations

#ifndef _LEX_H_
#define _LEX_H_

#include <stdio.h>

#ifdef _LEX_CPP_
   int lineno = 1; // line number count; this will be used for error messages later
#else
   // Import some variables
   extern int lineno;
   extern FILE *yyin;  // the input stream

   // Function prototype
   int yylex ();
#endif

int yyparse ();


#ifndef YYLTYPE
typedef
  struct yyltype
    {
      int timestamp;
      int first_line;
      int first_column;
      int last_line;
      int last_column;
      char *text;
   }
  yyltype;

#define YYLTYPE yyltype
#endif

extern YYLTYPE yylloc;

/*
enum {
	TOKEN_BEGIN = 258,	

	TOKEN_INCLUDE,
	TOKEN_DEFINE,

	TOKEN_INTEGERVALUE,
	TOKEN_FLOATVALUE,
	TOKEN_BOOLVALUE,
	TOKEN_STRINGVALUE,
	
	TOKEN_VOID,
	TOKEN_INT,	
	TOKEN_FLOAT,
	TOKEN_BOOL,
	TOKEN_STRING,

	TOKEN_FOR,
	TOKEN_WHILE,
	TOKEN_IF,
	TOKEN_ELSE,
	TOKEN_SWITCH,
	TOKEN_CASE,
	TOKEN_DEFAULT,
	TOKEN_CONTINUE,
	TOKEN_BREAK,
	TOKEN_RETURN,

	TOKEN_ID,

	TOKEN_ADDITION,
	TOKEN_SUBTRACTION,
	TOKEN_MULTIPLICATION,
	TOKEN_DIVISION,
	TOKEN_REMINDER,
	TOKEN_ASSIGNMENT,	
	TOKEN_COMPOUNDADDITION,
	TOKEN_COMPOUNDSUBTRACTION,
	TOKEN_COMPOUNDMULTIPLICATION,
	TOKEN_COMPOUNDDIVISION,
	TOKEN_COMPOUNDREMINDER,
	TOKEN_INCREMENT,
	TOKEN_DECREMENT,

	TOKEN_NOT,
	TOKEN_LESSTHAN,
	TOKEN_LESSTHANOREQUAL,
	TOKEN_MORETHAN,
	TOKEN_MORETHANOREQUAL,
	TOKEN_EQUALITY,
	TOKEN_NOTEQUAL,
	TOKEN_AND,
	TOKEN_OR,

	TOKEN_ENDSTATEMENT,
	TOKEN_LEFTPARENTHESIS,
	TOKEN_RIGHTPARENTHESIS,
	TOKEN_LEFTBRACE,
	TOKEN_RIGHTBRACE,
	TOKEN_LEFTBRACKET,
	TOKEN_RIGHTBRACKET,
	TOKEN_COMMA,
	TOKEN_COLON,

	TOKEN_ERROR,

	TOKEN_END
};
*/
#define	TOKEN_ID	258
#define	TOKEN_INTEGERVALUE	259
#define	TOKEN_FLOATVALUE	260
#define	TOKEN_BOOLVALUE	261
#define	TOKEN_STRINGVALUE	262
#define	TOKEN_INT	263
#define	TOKEN_FLOAT	264
#define	TOKEN_BOOL	265
#define	TOKEN_STRING	266
#define	TOKEN_VOID	267
#define	TOKEN_FOR	268
#define	TOKEN_WHILE	269
#define	TOKEN_IF	270
#define	TOKEN_ELSE	271
#define	TOKEN_SWITCH	272
#define	TOKEN_CASE	273
#define	TOKEN_DEFAULT	274
#define	TOKEN_CONTINUE	275
#define	TOKEN_BREAK	276
#define	TOKEN_RETURN	277
#define	TOKEN_ENDSTATEMENT	278
#define	TOKEN_LEFTPARENTHESIS	279
#define	TOKEN_RIGHTPARENTHESIS	280
#define	TOKEN_LEFTBRACE	281
#define	TOKEN_RIGHTBRACE	282
#define	TOKEN_LEFTBRACKET	283
#define	TOKEN_RIGHTBRACKET	284
#define	TOKEN_ERROR	285
#define	TOKEN_COMMA	286
#define	TOKEN_COLON	287
#define	TOKEN_ASSIGNMENT	288
#define	TOKEN_COMPOUNDADDITION	289
#define	TOKEN_COMPOUNDSUBTRACTION	290
#define	TOKEN_COMPOUNDMULTIPLICATION	291
#define	TOKEN_COMPOUNDDIVISION	292
#define	TOKEN_COMPOUNDREMINDER	293
#define	TOKEN_AND	294
#define	TOKEN_OR	295
#define	TOKEN_LESSTHAN	296
#define	TOKEN_LESSTHANOREQUAL	297
#define	TOKEN_MORETHAN	298
#define	TOKEN_MORETHANOREQUAL	299
#define	TOKEN_EQUALITY	300
#define	TOKEN_NOTEQUAL	301
#define	TOKEN_ADDITION	302
#define	TOKEN_SUBTRACTION	303
#define	TOKEN_MULTIPLICATION	304
#define	TOKEN_DIVISION	305
#define	TOKEN_REMINDER	306
#define	TOKEN_NOT	307
#define	PREFIXINCREMENT	308
#define	PREFIXDECREMENT	309
#define	TOKEN_INCREMENT	310
#define	TOKEN_DECREMENT	311
#define TOKEN_INCLUDE 312
#define TOKEN_DEFINE 313

#endif