From: Sven Verdoolaege Date: Fri, 6 Apr 2012 09:58:03 +0000 (+0200) Subject: isl_stream_read_map: allow "not" at start of grouped expression X-Git-Tag: isl-0.10~92 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=fa2d3e52a658aaaea849657d289820d37b642af8;p=platform%2Fupstream%2Fisl.git isl_stream_read_map: allow "not" at start of grouped expression Reported-by: Vladimir Klebanov Signed-off-by: Sven Verdoolaege --- diff --git a/isl_input.c b/isl_input.c index c65faac..495366f 100644 --- a/isl_input.c +++ b/isl_input.c @@ -1064,6 +1064,7 @@ static int resolve_paren_expr(struct isl_stream *s, goto error; if (isl_stream_next_token_is(s, ISL_TOKEN_EXISTS) || + isl_stream_next_token_is(s, ISL_TOKEN_NOT) || isl_stream_next_token_is(s, ISL_TOKEN_TRUE) || isl_stream_next_token_is(s, ISL_TOKEN_FALSE) || isl_stream_next_token_is(s, ISL_TOKEN_MAP)) { diff --git a/isl_test.c b/isl_test.c index c6cd583..4fda4d8 100644 --- a/isl_test.c +++ b/isl_test.c @@ -190,6 +190,10 @@ int test_parse(struct isl_ctx *ctx) test_parse_pwaff(ctx, "{ [i] -> [i + 1] : i > 0; [a] -> [a] : a < 0 }"); test_parse_pwqp(ctx, "{ [x] -> ([(x)/2] * [(x)/3]) }"); + if (test_parse_map_equal(ctx, "{ [a] -> [b] : (not false) }", + "{ [a] -> [b] : true }") < 0) + return -1; + return 0; }