#define INSTR_BITAND 59
#define INSTR_BITOR 60
-#define mem_a(x) malloc(x)
-#define mem_d(x) free (x)
-
/*
* This is the smallest lexer I've ever wrote: and I must say, it's quite
* more nicer than those large bulky complex parsers that most people write
/*
* It's important that this table never exceed 32 keywords, the ascii
- * table starts at 33 (which we need)
+ * table starts at 33 (and we don't want conflicts)
*/
#define TOKEN_DO 0
#define TOKEN_ELSE 1
#define TOKEN_GOTO 7
#define TOKEN_FOR 8 // extension
#define TOKEN_TYPEDEF 9 // extension
-#define TOKEN_INT 10 // extension
-#define TOKEN_VOID 11
-#define TOKEN_STRING 12
-#define TOKEN_FLOAT 13
-#define TOKEN_VECTOR 14
-#define TOKEN_ENTITY 15
+#define TOKEN_VOID 10
+#define TOKEN_STRING 11
+#define TOKEN_FLOAT 12
+#define TOKEN_VECTOR 13
+#define TOKEN_ENTITY 14
/*
* Lexer state constants, these are numbers for where exactly in
int lex_token(struct lex_file *);
void lex_reset(struct lex_file *);
-int lex_debug(struct lex_file *);
int lex_close(struct lex_file *);
struct lex_file *lex_open (FILE *);
typedef_node *typedef_find(const char *);
int typedef_add (const char *, const char *);
+/* alloc.c */
+void *memory_a(unsigned int, unsigned int, const char *);
+void memory_d(void *, unsigned int, const char *);
+#ifdef NOTRACK
+# define mem_a(x) malloc(x)
+# define mem_d(x) free (x)
+#else
+# define mem_a(x) memory_a((x), __LINE__, __FILE__)
+# define mem_d(x) memory_d((x), __LINE__, __FILE__)
+#endif
#endif