From: kramm Date: Fri, 2 Jan 2009 19:52:23 +0000 (+0000) Subject: implemented in X-Git-Tag: release-0-9-0~452 X-Git-Url: http://git.asbjorn.biz/?p=swftools.git;a=commitdiff_plain;h=1476da7c7f16895f76a6b9ab44c2414b6b8f1943 implemented in --- diff --git a/lib/as3/parser.y b/lib/as3/parser.y index 093b1eb..959f76d 100644 --- a/lib/as3/parser.y +++ b/lib/as3/parser.y @@ -211,7 +211,7 @@ %nonassoc '^' %nonassoc '&' %nonassoc "==" "!=" "===" "!==" -%nonassoc "is" "as" +%nonassoc "is" "as" "in" %nonassoc "<=" '<' ">=" '>' "instanceof" // TODO: support "a < b < c" syntax? %left "<<" ">>" ">>>" %left below_minus @@ -222,6 +222,7 @@ %nonassoc below_curly %left '[' ']' '{' "new" '.' ".." "::" %nonassoc T_IDENTIFIER +%left above_identifier %left below_else %nonassoc "else" %left '(' @@ -2103,6 +2104,11 @@ E : E '*' E {$$.c = code_append($1.c,$3.c); } } +E : E "in" E {$$.c = code_append($1.c,$3.c); + $$.c = abc_in($$.c); + $$.t = TYPE_BOOLEAN; + } + E : E "as" E {char use_astype=0; // flash player's astype works differently than astypelate if(use_astype && TYPE_IS_CLASS($3.t)) { MULTINAME(m,$3.t->cls);