]> git.saurik.com Git - cycript.git/blobdiff - Cycript.l
Added cyrver to make clean, fixed GC protection for CYJS*, implemented array comprehe...
[cycript.git] / Cycript.l
index 66f38cee04f54c703194d62ee62d4c2eb6bf6277..dd6e2042657bc815afaa56c7ac1e2d8b84344ccf 100644 (file)
--- a/Cycript.l
+++ b/Cycript.l
@@ -187,7 +187,9 @@ Escape   \\[\\'"bfnrtv]|\\0|\\x[0-9a-fA-F]{2}|\\u[0-9a-fA-F]{4}|\\\n
 "transient"    L C yylval->word_ = new CYWord("transient"); return tk::Transient;
 "volatile"     L C yylval->word_ = new CYWord("volatile"); return tk::Volatile;
 
 "transient"    L C yylval->word_ = new CYWord("transient"); return tk::Transient;
 "volatile"     L C yylval->word_ = new CYWord("volatile"); return tk::Volatile;
 
-[a-zA-Z$_][a-zA-Z$_0-9]* yylval->identifier_ = new CYIdentifier(apr_pstrmemdup(yyextra->pool_, yytext, yyleng)); L C return tk::Identifier;
+"each"         L C yylval->word_ = new CYIdentifier("each"); return tk::Each;
+
+[a-zA-Z$_][a-zA-Z$_0-9]* yylval->identifier_ = new CYIdentifier(apr_pstrmemdup(yyextra->pool_, yytext, yyleng)); L C return tk::Identifier_;
 
 (\.[0-9]+|(0|[1-9][0-9]*)(\.[0-9]*)?){Exponent}? yylval->number_ = new CYNumber(strtod(yytext, NULL)); L C return tk::NumericLiteral;
 
 
 (\.[0-9]+|(0|[1-9][0-9]*)(\.[0-9]*)?){Exponent}? yylval->number_ = new CYNumber(strtod(yytext, NULL)); L C return tk::NumericLiteral;