diff options
Diffstat (limited to 'tools/qmlmin/main.cpp')
-rw-r--r-- | tools/qmlmin/main.cpp | 9 |
1 files changed, 2 insertions, 7 deletions
diff --git a/tools/qmlmin/main.cpp b/tools/qmlmin/main.cpp index 61223add2c..7a5b8f9457 100644 --- a/tools/qmlmin/main.cpp +++ b/tools/qmlmin/main.cpp @@ -122,11 +122,6 @@ public: } protected: - bool automatic(int token) const - { - return token == T_RBRACE || token == 0 || prevTerminator(); - } - virtual bool parse(int startToken) = 0; static QString quote(const QString &string) @@ -346,7 +341,7 @@ bool Minify::parse(int startToken) const int yyerrorstate = _stateStack[yytos]; // automatic insertion of `;' - if (yytoken != -1 && t_action(yyerrorstate, T_AUTOMATIC_SEMICOLON) && automatic(yytoken)) { + if (yytoken != -1 && t_action(yyerrorstate, T_AUTOMATIC_SEMICOLON) && canInsertAutomaticSemicolon(yytoken)) { _tokens.prepend(yytoken); _tokenStrings.prepend(yytokentext); yyaction = yyerrorstate; @@ -461,7 +456,7 @@ bool Tokenize::parse(int startToken) const int yyerrorstate = _stateStack[yytos]; // automatic insertion of `;' - if (yytoken != -1 && t_action(yyerrorstate, T_AUTOMATIC_SEMICOLON) && automatic(yytoken)) { + if (yytoken != -1 && t_action(yyerrorstate, T_AUTOMATIC_SEMICOLON) && canInsertAutomaticSemicolon(yytoken)) { _tokens.prepend(yytoken); _tokenStrings.prepend(yytokentext); yyaction = yyerrorstate; |