ISL_TOKEN_UNKNOWN = 256, ISL_TOKEN_VALUE,
ISL_TOKEN_IDENT, ISL_TOKEN_GE,
ISL_TOKEN_LE, ISL_TOKEN_GT, ISL_TOKEN_LT,
- ISL_TOKEN_NE,
+ ISL_TOKEN_NE, ISL_TOKEN_EQ_EQ,
ISL_TOKEN_LEX_GE, ISL_TOKEN_LEX_LE,
ISL_TOKEN_LEX_GT, ISL_TOKEN_LEX_LT,
ISL_TOKEN_TO, ISL_TOKEN_AND,
c == '%' ||
c == '?' ||
c == '^' ||
- c == '=' ||
c == '@' ||
c == '$' ||
c == ',' ||
tok->u.s = strdup(s->buffer);
return tok;
}
+ if (c == '=') {
+ int c;
+ tok = isl_token_new(s->ctx, line, col, old_line != line);
+ if (!tok)
+ return NULL;
+ if ((c = isl_stream_getc(s)) == '=') {
+ tok->u.s = strdup("==");
+ tok->type = ISL_TOKEN_EQ_EQ;
+ return tok;
+ }
+ if (c != -1)
+ isl_stream_ungetc(s, c);
+ tok->type = (enum isl_token_type) '=';
+ return tok;
+ }
if (c == ':') {
int c;
tok = isl_token_new(s->ctx, line, col, old_line != line);