]> git.saurik.com Git - cycript.git/commitdiff
Implemented automatic semicolon insertion token restrictions.
authorJay Freeman (saurik) <saurik@saurik.com>
Thu, 1 Oct 2009 00:36:04 +0000 (00:36 +0000)
committerJay Freeman (saurik) <saurik@saurik.com>
Thu, 1 Oct 2009 00:36:04 +0000 (00:36 +0000)
Cycript.y

index 2c9897454e3013feeffa8f49eff9d258b9750992..c4fa44718927123138732df603ed9a2ce556c631 100644 (file)
--- a/Cycript.y
+++ b/Cycript.y
@@ -253,7 +253,7 @@ TerminatorOpt
 Terminator
     : ";"
     | NewLine
-    | error { yyerrok; }
+    | error { if (yychar != 0 && yychar != cy::parser::token::CloseBrace && !yylval.newline_) YYABORT; else yyerrok; }
     ;
 
 NewLineOpt