]> git.saurik.com Git - cycript.git/blobdiff - Cycript.y
Implemented automatic semicolon insertion token restrictions.
[cycript.git] / 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