#define RETURN(t) do { \
P->num = t; \
+ if (P->flags & PSI_PARSER_DEBUG) { \
+ fprintf(stderr, "PSI> TOKEN: %d %.*s (EOF=%d)\n", P->num, (int) (P->cur-P->tok), P->tok, P->num == PSI_T_EOF); \
+ } \
return t; \
} while(1)
re2c:define:YYCURSOR = P->cur;
re2c:define:YYLIMIT = P->lim;
re2c:define:YYMARKER = P->mrk;
- re2c:define:YYFILL = "{ if (!PSI_ParserFill(P,@@)) RETURN(-1); }";
+ re2c:define:YYFILL = "{ if (!PSI_ParserFill(P,@@)) RETURN(PSI_T_EOF); }";
re2c:yyfill:parameter = 0;
B = [^a-zA-Z0-9_];
'UINT32_T' {RETURN(PSI_T_UINT32);}
'INT64_T' {RETURN(PSI_T_INT64);}
'UINT64_T' {RETURN(PSI_T_UINT64);}
+ 'UNSIGNED' {RETURN(PSI_T_UNSIGNED);}
'STRING' {RETURN(PSI_T_STRING);}
'ARRAY' {RETURN(PSI_T_ARRAY);}
'FUNCTION' {RETURN(PSI_T_FUNCTION);}