From: kpouer Date: Wed, 6 Aug 2003 06:39:11 +0000 (+0000) Subject: *** empty log message *** X-Git-Url: http://secure.phpeclipse.com *** empty log message *** --- diff --git a/net.sourceforge.phpeclipse/src/test/PHPParser.java b/net.sourceforge.phpeclipse/src/test/PHPParser.java index d85c2b9..f151bde 100644 --- a/net.sourceforge.phpeclipse/src/test/PHPParser.java +++ b/net.sourceforge.phpeclipse/src/test/PHPParser.java @@ -19,6 +19,7 @@ import net.sourceforge.phpdt.internal.compiler.ast.*; import net.sourceforge.phpdt.internal.compiler.parser.OutlineableWithChildren; import net.sourceforge.phpdt.internal.compiler.parser.Outlineable; import net.sourceforge.phpdt.internal.compiler.parser.PHPOutlineInfo; +import junit.framework.Assert; /** * A new php parser. @@ -130,7 +131,7 @@ public final class PHPParser extends PHPParserSuperclass implements PHPParserCon private static void processParseException(final ParseException e) { if (PARSER_DEBUG) { e.printStackTrace(); - return; + Assert.assertTrue(false); } if (errorMessage == null) { PHPeclipsePlugin.log(e); @@ -212,7 +213,7 @@ public final class PHPParser extends PHPParserSuperclass implements PHPParserCon } } - public final void parse(final String s) throws CoreException { + public final void parse(final String s) { final StringReader stream = new StringReader(s); if (jj_input_stream == null) { jj_input_stream = new SimpleCharStream(stream, 1, 1); @@ -699,6 +700,7 @@ public final class PHPParser extends PHPParserSuperclass implements PHPParserCon /** * a strict variable declarator : there cannot be a suffix here. + * It will be used by fields and formal parameters */ static final public VariableDeclaration VariableDeclaratorNoSuffix() throws ParseException { final Token varName; @@ -736,6 +738,9 @@ public final class PHPParser extends PHPParserSuperclass implements PHPParserCon throw new Error("Missing return statement in function"); } +/** + * this will be used by static statement + */ static final public VariableDeclaration VariableDeclarator() throws ParseException { final String varName; Expression initializer = null; @@ -1272,6 +1277,7 @@ final Expression expr,expr2; case FALSE: case AT: case DOLLAR: + case BANG: case PLUS_PLUS: case MINUS_MINUS: case PLUS: @@ -1300,7 +1306,7 @@ final Expression expr,expr2; case RSIGNEDSHIFTASSIGN: assignOperator = AssignmentOperator(); try { - initializer = ConditionalExpression(); + initializer = Expression(); } catch (ParseException e) { if (errorMessage != null) { {if (true) throw e;} @@ -1332,7 +1338,6 @@ final Expression expr,expr2; break; case LIST: case PRINT: - case BANG: expr = ExpressionWBang(); {if (true) return expr;} break; @@ -1367,10 +1372,7 @@ final Expression expr,expr2; } static final public Expression ExpressionNoBang() throws ParseException { - Expression expr = null; - int assignOperator = -1; - String var; - final int pos = SimpleCharStream.getPosition(); + Expression expr; switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case PRINT: expr = PrintExpression(); @@ -1887,6 +1889,7 @@ final Expression expr,expr2; case FALSE: case AT: case DOLLAR: + case BANG: case PLUS_PLUS: case MINUS_MINUS: case PLUS: @@ -1897,8 +1900,8 @@ final Expression expr,expr2; case IDENTIFIER: case LPAREN: case DOLLAR_ID: - expr = AtUnaryExpression(); - {if (true) return expr;} + expr = AtNotUnaryExpression(); + {if (true) return expr;} break; default: jj_la1[51] = jj_gen; @@ -1908,15 +1911,24 @@ final Expression expr,expr2; throw new Error("Missing return statement in function"); } - static final public Expression AtUnaryExpression() throws ParseException { +/** + * An expression prefixed (or not) by one or more @ and !. + * @return the expression + */ + static final public Expression AtNotUnaryExpression() throws ParseException { final Expression expr; final int pos = SimpleCharStream.getPosition(); switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case AT: jj_consume_token(AT); - expr = AtUnaryExpression(); + expr = AtNotUnaryExpression(); {if (true) return new PrefixedUnaryExpression(expr,OperatorIds.AT,pos);} break; + case BANG: + jj_consume_token(BANG); + expr = AtNotUnaryExpression(); + {if (true) return new PrefixedUnaryExpression(expr,OperatorIds.NOT,pos);} + break; case ARRAY: case NEW: case NULL: @@ -3422,6 +3434,9 @@ final ArrayList list = new ArrayList(); throw new Error("Missing return statement in function"); } +/** + * used only by ForInit() + */ static final public VariableDeclaration[] LocalVariableDeclaration() throws ParseException { final ArrayList list = new ArrayList(); VariableDeclaration var; @@ -3447,6 +3462,9 @@ final ArrayList list = new ArrayList(); throw new Error("Missing return statement in function"); } +/** + * used only by LocalVariableDeclaration(). + */ static final public VariableDeclaration LocalVariableDeclarator() throws ParseException { final String varName; Expression initializer = null; @@ -3483,6 +3501,9 @@ final ArrayList list = new ArrayList(); throw new Error("Missing return statement in function"); } +/** + * used only by StatementExpressionList() which is used only by ForInit() and ForStatement() + */ static final public Expression StatementExpression() throws ParseException { final Expression expr,expr2; final int operator; @@ -5158,69 +5179,6 @@ final int startBlock, endBlock; return retval; } - static final private boolean jj_3R_157() { - if (jj_3R_161()) return true; - if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; - return false; - } - - static final private boolean jj_3R_49() { - if (jj_3R_64()) return true; - if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; - Token xsp; - xsp = jj_scanpos; - if (jj_3R_65()) jj_scanpos = xsp; - else if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; - return false; - } - - static final private boolean jj_3R_160() { - if (jj_scan_token(MINUS)) return true; - if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; - return false; - } - - static final private boolean jj_3R_159() { - if (jj_scan_token(PLUS)) return true; - if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; - return false; - } - - static final private boolean jj_3R_153() { - Token xsp; - xsp = jj_scanpos; - if (jj_3R_156()) { - jj_scanpos = xsp; - if (jj_3R_157()) { - jj_scanpos = xsp; - if (jj_3R_158()) return true; - if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; - } else if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; - } else if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; - return false; - } - - static final private boolean jj_3R_156() { - Token xsp; - xsp = jj_scanpos; - if (jj_3R_159()) { - jj_scanpos = xsp; - if (jj_3R_160()) return true; - if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; - } else if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; - if (jj_3R_143()) return true; - if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; - return false; - } - - static final private boolean jj_3R_50() { - if (jj_scan_token(COMMA)) return true; - if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; - if (jj_3R_49()) return true; - if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; - return false; - } - static final private boolean jj_3R_44() { if (jj_3R_49()) return true; if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; @@ -5233,20 +5191,31 @@ final int startBlock, endBlock; return false; } - static final private boolean jj_3R_155() { + static final private boolean jj_3R_156() { if (jj_3R_153()) return true; if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; return false; } + static final private boolean jj_3R_155() { + if (jj_scan_token(BANG)) return true; + if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; + if (jj_3R_152()) return true; + if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; + return false; + } + static final private boolean jj_3R_152() { Token xsp; xsp = jj_scanpos; if (jj_3R_154()) { jj_scanpos = xsp; - if (jj_3R_155()) return true; + if (jj_3R_155()) { + jj_scanpos = xsp; + if (jj_3R_156()) return true; if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; } else if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; + } else if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; return false; } @@ -5258,6 +5227,14 @@ final int startBlock, endBlock; return false; } + static final private boolean jj_3R_43() { + if (jj_3R_47()) return true; + if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; + if (jj_scan_token(SEMICOLON)) return true; + if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; + return false; + } + static final private boolean jj_3R_148() { if (jj_3R_152()) return true; if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; @@ -5283,14 +5260,6 @@ final int startBlock, endBlock; return false; } - static final private boolean jj_3R_43() { - if (jj_3R_47()) return true; - if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; - if (jj_scan_token(SEMICOLON)) return true; - if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; - return false; - } - static final private boolean jj_3R_151() { if (jj_scan_token(REMAINDER)) return true; if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; @@ -5325,6 +5294,12 @@ final int startBlock, endBlock; return false; } + static final private boolean jj_3_4() { + if (jj_3R_43()) return true; + if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; + return false; + } + static final private boolean jj_3R_138() { if (jj_3R_143()) return true; if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; @@ -5343,12 +5318,6 @@ final int startBlock, endBlock; return false; } - static final private boolean jj_3_4() { - if (jj_3R_43()) return true; - if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; - return false; - } - static final private boolean jj_3R_145() { if (jj_scan_token(PLUS)) return true; if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; @@ -5368,6 +5337,12 @@ final int startBlock, endBlock; return false; } + static final private boolean jj_3_5() { + if (jj_3R_44()) return true; + if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; + return false; + } + static final private boolean jj_3R_132() { if (jj_3R_138()) return true; if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; @@ -5380,12 +5355,32 @@ final int startBlock, endBlock; return false; } + static final private boolean jj_3R_208() { + if (jj_scan_token(COMMA)) return true; + if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; + if (jj_3R_47()) return true; + if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; + return false; + } + static final private boolean jj_3R_142() { if (jj_scan_token(RUNSIGNEDSHIFT)) return true; if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; return false; } + static final private boolean jj_3R_207() { + if (jj_3R_47()) return true; + if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; + Token xsp; + while (true) { + xsp = jj_scanpos; + if (jj_3R_208()) { jj_scanpos = xsp; break; } + if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; + } + return false; + } + static final private boolean jj_3R_141() { if (jj_scan_token(RSIGNEDSHIFT)) return true; if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; @@ -5426,29 +5421,15 @@ final int startBlock, endBlock; return false; } - static final private boolean jj_3_5() { - if (jj_3R_44()) return true; - if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; - return false; - } - - static final private boolean jj_3R_207() { - if (jj_scan_token(COMMA)) return true; - if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; - if (jj_3R_47()) return true; + static final private boolean jj_3R_204() { + if (jj_3R_207()) return true; if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; return false; } static final private boolean jj_3R_206() { - if (jj_3R_47()) return true; + if (jj_scan_token(COMMA)) return true; if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; - Token xsp; - while (true) { - xsp = jj_scanpos; - if (jj_3R_207()) { jj_scanpos = xsp; break; } - if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; - } return false; } @@ -5470,9 +5451,11 @@ final int startBlock, endBlock; return false; } - static final private boolean jj_3R_205() { + static final private boolean jj_3_2() { if (jj_scan_token(COMMA)) return true; if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; + if (jj_3R_40()) return true; + if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; return false; } @@ -5501,78 +5484,82 @@ final int startBlock, endBlock; return false; } - static final private boolean jj_3_2() { - if (jj_scan_token(COMMA)) return true; - if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; - if (jj_3R_40()) return true; + static final private boolean jj_3R_71() { + if (jj_3R_48()) return true; if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; return false; } - static final private boolean jj_3R_122() { - if (jj_3R_125()) return true; + static final private boolean jj_3R_205() { + if (jj_3R_40()) return true; if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; Token xsp; while (true) { xsp = jj_scanpos; - if (jj_3R_126()) { jj_scanpos = xsp; break; } + if (jj_3_2()) { jj_scanpos = xsp; break; } if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; } return false; } - static final private boolean jj_3R_203() { - if (jj_3R_206()) return true; - if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; - return false; - } - - static final private boolean jj_3R_204() { - if (jj_3R_40()) return true; + static final private boolean jj_3R_122() { + if (jj_3R_125()) return true; if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; Token xsp; while (true) { xsp = jj_scanpos; - if (jj_3_2()) { jj_scanpos = xsp; break; } + if (jj_3R_126()) { jj_scanpos = xsp; break; } if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; } return false; } - static final private boolean jj_3R_200() { + static final private boolean jj_3R_197() { if (jj_scan_token(LPAREN)) return true; if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; Token xsp; xsp = jj_scanpos; if (jj_3R_204()) jj_scanpos = xsp; else if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; + if (jj_scan_token(RPAREN)) return true; + if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; + return false; + } + + static final private boolean jj_3R_201() { + if (jj_scan_token(LPAREN)) return true; + if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; + Token xsp; xsp = jj_scanpos; if (jj_3R_205()) jj_scanpos = xsp; else if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; + xsp = jj_scanpos; + if (jj_3R_206()) jj_scanpos = xsp; + else if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; if (jj_scan_token(RPAREN)) return true; if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; return false; } - static final private boolean jj_3R_71() { - if (jj_3R_48()) return true; + static final private boolean jj_3R_179() { + if (jj_scan_token(NULL)) return true; if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; return false; } - static final private boolean jj_3R_196() { - if (jj_scan_token(LPAREN)) return true; + static final private boolean jj_3R_178() { + if (jj_scan_token(FALSE)) return true; if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; - Token xsp; - xsp = jj_scanpos; - if (jj_3R_203()) jj_scanpos = xsp; - else if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; - if (jj_scan_token(RPAREN)) return true; + return false; + } + + static final private boolean jj_3R_177() { + if (jj_scan_token(TRUE)) return true; if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; return false; } - static final private boolean jj_3R_208() { + static final private boolean jj_3R_209() { if (jj_scan_token(ARRAYASSIGN)) return true; if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; if (jj_3R_47()) return true; @@ -5580,14 +5567,14 @@ final int startBlock, endBlock; return false; } - static final private boolean jj_3R_178() { - if (jj_scan_token(NULL)) return true; + static final private boolean jj_3R_176() { + if (jj_scan_token(STRING_LITERAL)) return true; if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; return false; } - static final private boolean jj_3R_177() { - if (jj_scan_token(FALSE)) return true; + static final private boolean jj_3R_175() { + if (jj_scan_token(FLOATING_POINT_LITERAL)) return true; if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; return false; } @@ -5597,11 +5584,40 @@ final int startBlock, endBlock; if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; Token xsp; xsp = jj_scanpos; - if (jj_3R_208()) jj_scanpos = xsp; + if (jj_3R_209()) jj_scanpos = xsp; else if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; return false; } + static final private boolean jj_3R_172() { + Token xsp; + xsp = jj_scanpos; + if (jj_3R_174()) { + jj_scanpos = xsp; + if (jj_3R_175()) { + jj_scanpos = xsp; + if (jj_3R_176()) { + jj_scanpos = xsp; + if (jj_3R_177()) { + jj_scanpos = xsp; + if (jj_3R_178()) { + jj_scanpos = xsp; + if (jj_3R_179()) return true; + if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; + } else if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; + } else if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; + } else if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; + } else if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; + } else if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; + return false; + } + + static final private boolean jj_3R_174() { + if (jj_scan_token(INTEGER_LITERAL)) return true; + if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; + return false; + } + static final private boolean jj_3R_131() { if (jj_scan_token(TRIPLEEQUAL)) return true; if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; @@ -5620,32 +5636,31 @@ final int startBlock, endBlock; return false; } - static final private boolean jj_3R_176() { - if (jj_scan_token(TRUE)) return true; - if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; - return false; - } - static final private boolean jj_3R_128() { if (jj_scan_token(DIF)) return true; if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; return false; } - static final private boolean jj_3R_127() { - if (jj_scan_token(EQUAL_EQUAL)) return true; + static final private boolean jj_3R_70() { + if (jj_3R_47()) return true; if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; return false; } - static final private boolean jj_3R_175() { - if (jj_scan_token(STRING_LITERAL)) return true; + static final private boolean jj_3R_52() { + Token xsp; + xsp = jj_scanpos; + if (jj_3R_70()) { + jj_scanpos = xsp; + if (jj_3R_71()) return true; if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; + } else if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; return false; } - static final private boolean jj_3R_174() { - if (jj_scan_token(FLOATING_POINT_LITERAL)) return true; + static final private boolean jj_3R_127() { + if (jj_scan_token(EQUAL_EQUAL)) return true; if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; return false; } @@ -5672,35 +5687,6 @@ final int startBlock, endBlock; return false; } - static final private boolean jj_3R_171() { - Token xsp; - xsp = jj_scanpos; - if (jj_3R_173()) { - jj_scanpos = xsp; - if (jj_3R_174()) { - jj_scanpos = xsp; - if (jj_3R_175()) { - jj_scanpos = xsp; - if (jj_3R_176()) { - jj_scanpos = xsp; - if (jj_3R_177()) { - jj_scanpos = xsp; - if (jj_3R_178()) return true; - if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; - } else if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; - } else if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; - } else if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; - } else if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; - } else if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; - return false; - } - - static final private boolean jj_3R_173() { - if (jj_scan_token(INTEGER_LITERAL)) return true; - if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; - return false; - } - static final private boolean jj_3R_117() { if (jj_3R_122()) return true; if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; @@ -5713,20 +5699,15 @@ final int startBlock, endBlock; return false; } - static final private boolean jj_3R_70() { - if (jj_3R_47()) return true; + static final private boolean jj_3R_46() { + if (jj_scan_token(LBRACKET)) return true; if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; - return false; - } - - static final private boolean jj_3R_52() { Token xsp; xsp = jj_scanpos; - if (jj_3R_70()) { - jj_scanpos = xsp; - if (jj_3R_71()) return true; + if (jj_3R_52()) jj_scanpos = xsp; + else if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; + if (jj_scan_token(RBRACKET)) return true; if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; - } else if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; return false; } @@ -5750,23 +5731,22 @@ final int startBlock, endBlock; return false; } - static final private boolean jj_3R_46() { - if (jj_scan_token(LBRACKET)) return true; + static final private boolean jj_3R_45() { + if (jj_scan_token(CLASSACCESS)) return true; if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; - Token xsp; - xsp = jj_scanpos; - if (jj_3R_52()) jj_scanpos = xsp; - else if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; - if (jj_scan_token(RBRACKET)) return true; + if (jj_3R_51()) return true; if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; return false; } - static final private boolean jj_3R_116() { - if (jj_scan_token(XOR)) return true; - if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; - if (jj_3R_115()) return true; + static final private boolean jj_3R_39() { + Token xsp; + xsp = jj_scanpos; + if (jj_3R_45()) { + jj_scanpos = xsp; + if (jj_3R_46()) return true; if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; + } else if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; return false; } @@ -5780,6 +5760,20 @@ final int startBlock, endBlock; return false; } + static final private boolean jj_3R_116() { + if (jj_scan_token(XOR)) return true; + if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; + if (jj_3R_115()) return true; + if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; + return false; + } + + static final private boolean jj_3R_69() { + if (jj_scan_token(DOLLAR_ID)) return true; + if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; + return false; + } + static final private boolean jj_3R_113() { if (jj_3R_115()) return true; if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; @@ -5792,36 +5786,43 @@ final int startBlock, endBlock; return false; } - static final private boolean jj_3R_69() { - if (jj_scan_token(DOLLAR_ID)) return true; + static final private boolean jj_3R_200() { + if (jj_3R_64()) return true; if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; return false; } - static final private boolean jj_3R_45() { - if (jj_scan_token(CLASSACCESS)) return true; + static final private boolean jj_3R_199() { + if (jj_3R_48()) return true; + if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; + return false; + } + + static final private boolean jj_3R_68() { + if (jj_scan_token(DOLLAR)) return true; if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; if (jj_3R_51()) return true; if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; return false; } - static final private boolean jj_3R_39() { - Token xsp; - xsp = jj_scanpos; - if (jj_3R_45()) { - jj_scanpos = xsp; - if (jj_3R_46()) return true; + static final private boolean jj_3R_198() { + if (jj_scan_token(IDENTIFIER)) return true; if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; - } else if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; return false; } - static final private boolean jj_3R_68() { - if (jj_scan_token(DOLLAR)) return true; - if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; - if (jj_3R_51()) return true; + static final private boolean jj_3R_190() { + Token xsp; + xsp = jj_scanpos; + if (jj_3R_198()) { + jj_scanpos = xsp; + if (jj_3R_199()) { + jj_scanpos = xsp; + if (jj_3R_200()) return true; if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; + } else if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; + } else if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; return false; } @@ -5845,38 +5846,6 @@ final int startBlock, endBlock; return false; } - static final private boolean jj_3R_199() { - if (jj_3R_64()) return true; - if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; - return false; - } - - static final private boolean jj_3R_198() { - if (jj_3R_48()) return true; - if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; - return false; - } - - static final private boolean jj_3R_197() { - if (jj_scan_token(IDENTIFIER)) return true; - if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; - return false; - } - - static final private boolean jj_3R_189() { - Token xsp; - xsp = jj_scanpos; - if (jj_3R_197()) { - jj_scanpos = xsp; - if (jj_3R_198()) { - jj_scanpos = xsp; - if (jj_3R_199()) return true; - if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; - } else if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; - } else if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; - return false; - } - static final private boolean jj_3R_67() { if (jj_scan_token(IDENTIFIER)) return true; if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; @@ -5887,23 +5856,19 @@ final int startBlock, endBlock; return false; } - static final private boolean jj_3R_109() { - if (jj_scan_token(DOT)) return true; + static final private boolean jj_3R_121() { + if (jj_scan_token(ASSIGN)) return true; if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; - if (jj_3R_106()) return true; + if (jj_3R_47()) return true; if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; return false; } - static final private boolean jj_3R_100() { + static final private boolean jj_3R_109() { + if (jj_scan_token(DOT)) return true; + if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; if (jj_3R_106()) return true; if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; - Token xsp; - while (true) { - xsp = jj_scanpos; - if (jj_3R_109()) { jj_scanpos = xsp; break; } - if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; - } return false; } @@ -5934,11 +5899,15 @@ final int startBlock, endBlock; return false; } - static final private boolean jj_3R_121() { - if (jj_scan_token(ASSIGN)) return true; - if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; - if (jj_3R_47()) return true; + static final private boolean jj_3R_100() { + if (jj_3R_106()) return true; if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; + Token xsp; + while (true) { + xsp = jj_scanpos; + if (jj_3R_109()) { jj_scanpos = xsp; break; } + if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; + } return false; } @@ -5952,6 +5921,12 @@ final int startBlock, endBlock; return false; } + static final private boolean jj_3R_124() { + if (jj_3R_64()) return true; + if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; + return false; + } + static final private boolean jj_3R_111() { if (jj_scan_token(_ANDL)) return true; if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; @@ -5977,6 +5952,14 @@ final int startBlock, endBlock; return false; } + static final private boolean jj_3R_82() { + if (jj_scan_token(DOLLAR)) return true; + if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; + if (jj_3R_51()) return true; + if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; + return false; + } + static final private boolean jj_3R_83() { if (jj_3R_100()) return true; if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; @@ -6001,46 +5984,38 @@ final int startBlock, endBlock; return false; } - static final private boolean jj_3R_124() { - if (jj_3R_64()) return true; + static final private boolean jj_3R_120() { + if (jj_scan_token(COMMA)) return true; if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; + Token xsp; + xsp = jj_scanpos; + if (jj_3R_124()) jj_scanpos = xsp; + else if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; return false; } - static final private boolean jj_3R_82() { - if (jj_scan_token(DOLLAR)) return true; + static final private boolean jj_3R_184() { + if (jj_scan_token(ARRAY)) return true; if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; - if (jj_3R_51()) return true; + if (jj_3R_201()) return true; if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; return false; } - static final private boolean jj_3R_105() { - if (jj_scan_token(_ORL)) return true; - if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; - return false; - } - - static final private boolean jj_3R_104() { - if (jj_scan_token(OR_OR)) return true; + static final private boolean jj_3R_119() { + if (jj_3R_64()) return true; if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; return false; } - static final private boolean jj_3R_120() { - if (jj_scan_token(COMMA)) return true; + static final private boolean jj_3R_105() { + if (jj_scan_token(_ORL)) return true; if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; - Token xsp; - xsp = jj_scanpos; - if (jj_3R_124()) jj_scanpos = xsp; - else if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; return false; } - static final private boolean jj_3R_183() { - if (jj_scan_token(ARRAY)) return true; - if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; - if (jj_3R_200()) return true; + static final private boolean jj_3R_104() { + if (jj_scan_token(OR_OR)) return true; if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; return false; } @@ -6079,24 +6054,6 @@ final int startBlock, endBlock; return false; } - static final private boolean jj_3R_119() { - if (jj_3R_64()) return true; - if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; - return false; - } - - static final private boolean jj_3R_76() { - if (jj_3R_83()) return true; - if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; - Token xsp; - while (true) { - xsp = jj_scanpos; - if (jj_3R_85()) { jj_scanpos = xsp; break; } - if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; - } - return false; - } - static final private boolean jj_3R_108() { if (jj_scan_token(LIST)) return true; if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; @@ -6119,31 +6076,57 @@ final int startBlock, endBlock; return false; } - static final private boolean jj_3R_202() { + static final private boolean jj_3R_203() { if (jj_scan_token(STATICCLASSACCESS)) return true; if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; - if (jj_3R_189()) return true; + if (jj_3R_190()) return true; if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; return false; } - static final private boolean jj_3R_201() { + static final private boolean jj_3R_76() { + if (jj_3R_83()) return true; + if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; + Token xsp; + while (true) { + xsp = jj_scanpos; + if (jj_3R_85()) { jj_scanpos = xsp; break; } + if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; + } + return false; + } + + static final private boolean jj_3R_202() { if (jj_3R_39()) return true; if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; return false; } - static final private boolean jj_3R_195() { + static final private boolean jj_3R_196() { Token xsp; xsp = jj_scanpos; - if (jj_3R_201()) { + if (jj_3R_202()) { jj_scanpos = xsp; - if (jj_3R_202()) return true; + if (jj_3R_203()) return true; if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; } else if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; return false; } + static final private boolean jj_3R_107() { + if (jj_scan_token(PRINT)) return true; + if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; + if (jj_3R_47()) return true; + if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; + return false; + } + + static final private boolean jj_3R_193() { + if (jj_3R_64()) return true; + if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; + return false; + } + static final private boolean jj_3R_72() { if (jj_3R_76()) return true; if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; @@ -6154,17 +6137,20 @@ final int startBlock, endBlock; return false; } - static final private boolean jj_3R_107() { - if (jj_scan_token(PRINT)) return true; - if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; - if (jj_3R_47()) return true; + static final private boolean jj_3R_192() { + if (jj_scan_token(IDENTIFIER)) return true; if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; return false; } - static final private boolean jj_3R_192() { - if (jj_3R_64()) return true; + static final private boolean jj_3R_183() { + Token xsp; + xsp = jj_scanpos; + if (jj_3R_192()) { + jj_scanpos = xsp; + if (jj_3R_193()) return true; if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; + } else if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; return false; } @@ -6186,26 +6172,27 @@ final int startBlock, endBlock; return false; } - static final private boolean jj_3R_191() { - if (jj_scan_token(IDENTIFIER)) return true; + static final private boolean jj_3R_96() { + if (jj_scan_token(ORASSIGN)) return true; if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; return false; } static final private boolean jj_3R_182() { - Token xsp; - xsp = jj_scanpos; - if (jj_3R_191()) { - jj_scanpos = xsp; - if (jj_3R_192()) return true; + if (jj_3R_184()) return true; if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; - } else if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; return false; } - static final private boolean jj_3R_96() { - if (jj_scan_token(ORASSIGN)) return true; + static final private boolean jj_3R_64() { + if (jj_3R_75()) return true; if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; + Token xsp; + while (true) { + xsp = jj_scanpos; + if (jj_3_1()) { jj_scanpos = xsp; break; } + if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; + } return false; } @@ -6215,27 +6202,21 @@ final int startBlock, endBlock; return false; } - static final private boolean jj_3R_94() { - if (jj_scan_token(ANDASSIGN)) return true; + static final private boolean jj_3R_191() { + if (jj_3R_197()) return true; if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; return false; } - static final private boolean jj_3R_93() { - if (jj_scan_token(RSIGNEDSHIFTASSIGN)) return true; + static final private boolean jj_3R_94() { + if (jj_scan_token(ANDASSIGN)) return true; if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; return false; } - static final private boolean jj_3R_64() { - if (jj_3R_75()) return true; + static final private boolean jj_3R_93() { + if (jj_scan_token(RSIGNEDSHIFTASSIGN)) return true; if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; - Token xsp; - while (true) { - xsp = jj_scanpos; - if (jj_3_1()) { jj_scanpos = xsp; break; } - if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; - } return false; } @@ -6269,12 +6250,30 @@ final int startBlock, endBlock; return false; } + static final private boolean jj_3R_181() { + if (jj_scan_token(NEW)) return true; + if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; + if (jj_3R_190()) return true; + if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; + Token xsp; + xsp = jj_scanpos; + if (jj_3R_191()) jj_scanpos = xsp; + else if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; + return false; + } + static final private boolean jj_3R_87() { if (jj_scan_token(STARASSIGN)) return true; if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; return false; } + static final private boolean jj_3R_189() { + if (jj_3R_197()) return true; + if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; + return false; + } + static final private boolean jj_3R_86() { if (jj_scan_token(ASSIGN)) return true; if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; @@ -6325,38 +6324,43 @@ final int startBlock, endBlock; return false; } - static final private boolean jj_3R_181() { - if (jj_3R_183()) return true; - if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; - return false; - } - - static final private boolean jj_3R_190() { + static final private boolean jj_3R_188() { if (jj_3R_196()) return true; if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; return false; } static final private boolean jj_3R_180() { - if (jj_scan_token(NEW)) return true; - if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; - if (jj_3R_189()) return true; + if (jj_3R_183()) return true; if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; Token xsp; + while (true) { + xsp = jj_scanpos; + if (jj_3R_188()) { jj_scanpos = xsp; break; } + if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; + } xsp = jj_scanpos; - if (jj_3R_190()) jj_scanpos = xsp; + if (jj_3R_189()) jj_scanpos = xsp; else if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; return false; } - static final private boolean jj_3R_102() { - if (jj_3R_108()) return true; + static final private boolean jj_3R_173() { + Token xsp; + xsp = jj_scanpos; + if (jj_3R_180()) { + jj_scanpos = xsp; + if (jj_3R_181()) { + jj_scanpos = xsp; + if (jj_3R_182()) return true; if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; + } else if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; + } else if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; return false; } - static final private boolean jj_3R_188() { - if (jj_3R_196()) return true; + static final private boolean jj_3R_102() { + if (jj_3R_108()) return true; if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; return false; } @@ -6378,38 +6382,9 @@ final int startBlock, endBlock; return false; } - static final private boolean jj_3R_187() { - if (jj_3R_195()) return true; - if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; - return false; - } - - static final private boolean jj_3R_179() { - if (jj_3R_182()) return true; - if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; - Token xsp; - while (true) { - xsp = jj_scanpos; - if (jj_3R_187()) { jj_scanpos = xsp; break; } - if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; - } - xsp = jj_scanpos; - if (jj_3R_188()) jj_scanpos = xsp; - else if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; - return false; - } - - static final private boolean jj_3R_172() { - Token xsp; - xsp = jj_scanpos; - if (jj_3R_179()) { - jj_scanpos = xsp; - if (jj_3R_180()) { - jj_scanpos = xsp; - if (jj_3R_181()) return true; + static final private boolean jj_3R_195() { + if (jj_scan_token(MINUS_MINUS)) return true; if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; - } else if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; - } else if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; return false; } @@ -6439,51 +6414,45 @@ final int startBlock, endBlock; } static final private boolean jj_3R_194() { - if (jj_scan_token(MINUS_MINUS)) return true; - if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; - return false; - } - - static final private boolean jj_3R_193() { if (jj_scan_token(PLUS_PLUS)) return true; if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; return false; } - static final private boolean jj_3R_186() { + static final private boolean jj_3R_187() { Token xsp; xsp = jj_scanpos; - if (jj_3R_193()) { + if (jj_3R_194()) { jj_scanpos = xsp; - if (jj_3R_194()) return true; + if (jj_3R_195()) return true; if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; } else if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; return false; } - static final private boolean jj_3R_54() { - if (jj_3R_73()) return true; + static final private boolean jj_3R_171() { + if (jj_3R_173()) return true; if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; + Token xsp; + xsp = jj_scanpos; + if (jj_3R_187()) jj_scanpos = xsp; + else if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; return false; } - static final private boolean jj_3R_170() { - if (jj_3R_172()) return true; + static final private boolean jj_3R_54() { + if (jj_3R_73()) return true; if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; - Token xsp; - xsp = jj_scanpos; - if (jj_3R_186()) jj_scanpos = xsp; - else if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; return false; } - static final private boolean jj_3R_185() { + static final private boolean jj_3R_186() { if (jj_scan_token(ARRAY)) return true; if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; return false; } - static final private boolean jj_3R_184() { + static final private boolean jj_3R_185() { if (jj_3R_48()) return true; if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; return false; @@ -6495,14 +6464,14 @@ final int startBlock, endBlock; return false; } - static final private boolean jj_3R_169() { + static final private boolean jj_3R_170() { if (jj_scan_token(LPAREN)) return true; if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; Token xsp; xsp = jj_scanpos; - if (jj_3R_184()) { + if (jj_3R_185()) { jj_scanpos = xsp; - if (jj_3R_185()) return true; + if (jj_3R_186()) return true; if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; } else if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; if (jj_scan_token(RPAREN)) return true; @@ -6521,56 +6490,56 @@ final int startBlock, endBlock; static final private boolean jj_3R_74() { if (jj_3R_80()) return true; if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; - if (jj_3R_72()) return true; + if (jj_3R_47()) return true; if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; return false; } - static final private boolean jj_3R_47() { + static final private boolean jj_3_3() { + if (jj_scan_token(LPAREN)) return true; + if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; Token xsp; xsp = jj_scanpos; - if (jj_3R_53()) { + if (jj_3R_41()) { jj_scanpos = xsp; - if (jj_3R_54()) return true; + if (jj_3R_42()) return true; if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; } else if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; + if (jj_scan_token(RPAREN)) return true; + if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; return false; } - static final private boolean jj_3R_53() { - if (jj_3R_72()) return true; + static final private boolean jj_3R_65() { + if (jj_scan_token(ASSIGN)) return true; + if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; + if (jj_3R_47()) return true; if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; - Token xsp; - xsp = jj_scanpos; - if (jj_3R_74()) jj_scanpos = xsp; - else if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; return false; } - static final private boolean jj_3_3() { - if (jj_scan_token(LPAREN)) return true; - if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; + static final private boolean jj_3R_47() { Token xsp; xsp = jj_scanpos; - if (jj_3R_41()) { + if (jj_3R_53()) { jj_scanpos = xsp; - if (jj_3R_42()) return true; + if (jj_3R_54()) return true; if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; } else if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; - if (jj_scan_token(RPAREN)) return true; - if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; return false; } - static final private boolean jj_3R_65() { - if (jj_scan_token(ASSIGN)) return true; - if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; - if (jj_3R_47()) return true; + static final private boolean jj_3R_53() { + if (jj_3R_72()) return true; if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; + Token xsp; + xsp = jj_scanpos; + if (jj_3R_74()) jj_scanpos = xsp; + else if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; return false; } - static final private boolean jj_3R_168() { + static final private boolean jj_3R_169() { if (jj_scan_token(LPAREN)) return true; if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; if (jj_3R_47()) return true; @@ -6580,8 +6549,8 @@ final int startBlock, endBlock; return false; } - static final private boolean jj_3R_63() { - if (jj_scan_token(OBJECT)) return true; + static final private boolean jj_3R_168() { + if (jj_3R_172()) return true; if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; return false; } @@ -6592,37 +6561,43 @@ final int startBlock, endBlock; return false; } + static final private boolean jj_3R_163() { + Token xsp; + xsp = jj_scanpos; + if (jj_3R_166()) { + jj_scanpos = xsp; + if (jj_3R_167()) { + jj_scanpos = xsp; + if (jj_3R_168()) { + jj_scanpos = xsp; + if (jj_3R_169()) return true; + if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; + } else if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; + } else if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; + } else if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; + return false; + } + static final private boolean jj_3R_166() { if (jj_3R_170()) return true; if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; return false; } - static final private boolean jj_3R_62() { - if (jj_scan_token(INTEGER)) return true; + static final private boolean jj_3R_63() { + if (jj_scan_token(OBJECT)) return true; if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; return false; } - static final private boolean jj_3R_162() { - Token xsp; - xsp = jj_scanpos; - if (jj_3R_165()) { - jj_scanpos = xsp; - if (jj_3R_166()) { - jj_scanpos = xsp; - if (jj_3R_167()) { - jj_scanpos = xsp; - if (jj_3R_168()) return true; + static final private boolean jj_3R_62() { + if (jj_scan_token(INTEGER)) return true; if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; - } else if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; - } else if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; - } else if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; return false; } static final private boolean jj_3R_165() { - if (jj_3R_169()) return true; + if (jj_scan_token(MINUS_MINUS)) return true; if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; return false; } @@ -6633,6 +6608,12 @@ final int startBlock, endBlock; return false; } + static final private boolean jj_3R_164() { + if (jj_scan_token(PLUS_PLUS)) return true; + if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; + return false; + } + static final private boolean jj_3R_60() { if (jj_scan_token(FLOAT)) return true; if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; @@ -6651,8 +6632,15 @@ final int startBlock, endBlock; return false; } - static final private boolean jj_3R_164() { - if (jj_scan_token(MINUS_MINUS)) return true; + static final private boolean jj_3R_162() { + Token xsp; + xsp = jj_scanpos; + if (jj_3R_164()) { + jj_scanpos = xsp; + if (jj_3R_165()) return true; + if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; + } else if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; + if (jj_3R_173()) return true; if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; return false; } @@ -6663,12 +6651,6 @@ final int startBlock, endBlock; return false; } - static final private boolean jj_3R_163() { - if (jj_scan_token(PLUS_PLUS)) return true; - if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; - return false; - } - static final private boolean jj_3R_56() { if (jj_scan_token(BOOL)) return true; if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; @@ -6713,21 +6695,71 @@ final int startBlock, endBlock; return false; } + static final private boolean jj_3R_49() { + if (jj_3R_64()) return true; + if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; + Token xsp; + xsp = jj_scanpos; + if (jj_3R_65()) jj_scanpos = xsp; + else if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; + return false; + } + + static final private boolean jj_3R_159() { + if (jj_3R_163()) return true; + if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; + return false; + } + + static final private boolean jj_3R_158() { + if (jj_3R_162()) return true; + if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; + return false; + } + static final private boolean jj_3R_161() { + if (jj_scan_token(MINUS)) return true; + if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; + return false; + } + + static final private boolean jj_3R_160() { + if (jj_scan_token(PLUS)) return true; + if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; + return false; + } + + static final private boolean jj_3R_50() { + if (jj_scan_token(COMMA)) return true; + if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; + if (jj_3R_49()) return true; + if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; + return false; + } + + static final private boolean jj_3R_153() { Token xsp; xsp = jj_scanpos; - if (jj_3R_163()) { + if (jj_3R_157()) { + jj_scanpos = xsp; + if (jj_3R_158()) { jj_scanpos = xsp; - if (jj_3R_164()) return true; + if (jj_3R_159()) return true; if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; } else if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; - if (jj_3R_172()) return true; - if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; + } else if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; return false; } - static final private boolean jj_3R_158() { - if (jj_3R_162()) return true; + static final private boolean jj_3R_157() { + Token xsp; + xsp = jj_scanpos; + if (jj_3R_160()) { + jj_scanpos = xsp; + if (jj_3R_161()) return true; + if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; + } else if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; + if (jj_3R_143()) return true; if (jj_la == 0 && jj_scanpos == jj_lastpos) return false; return false; } @@ -6762,7 +6794,7 @@ final int startBlock, endBlock; jj_la1_1 = new int[] {0x875d507f,0x0,0x0,0x875d507f,0x0,0x875d507f,0x8000,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x3080000,0x200,0x30c0000,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x30c0000,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x30c0000,0x30c0000,0x0,0x30c0000,0x0,0x30c0000,0x0,0x0,0x0,0x180,0x0,0x0,0x40000,0x0,0x180,0x40000,0x0,0x30c0000,0x30c0000,0x80,0x3080000,0x30c0000,0x0,0x0,0x8451507f,0x875d507f,0x0,0x0,0xf,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x875d507f,0x875d507f,0x875d507f,0x875d507f,0x0,0x0,0x0,0x0,0x40000,0x0,0x2400,0x2400,0x875d507f,0x875d507f,0x0,0x2400,0x30c0000,0x875d507f,0x875d507f,0x0,0x0,0x875d507f,0x0,0x0,0x875d507f,0x875d507f,0x875d507f,0x875d507f,0x875d507f,0x875d507f,0x875d507f,0x40000,0x30c0000,0x40000,0x875d507f,0x875d507f,0x40000,0x0,0x30c0000,0x30c0000,}; } private static void jj_la1_2() { - jj_la1_2 = new int[] {0x13c1c00,0x0,0x0,0x13c1c00,0x0,0x13c1c00,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x800,0x0,0x800,0x0,0x0,0x300000,0x0,0x13c1c00,0x0,0x1000000,0x0,0x1000000,0x1000000,0x3fe,0x0,0x13c1c00,0x1000,0x0,0x0,0x4000,0x80010000,0x80010000,0x20000,0x20000,0x0,0x2000000,0x4000000,0x1000000,0x0,0x0,0x0,0x0,0x70000000,0x70000000,0x300000,0x300000,0x8c00000,0x8c00000,0x13c0c00,0x3c0c00,0x300000,0x3c0800,0xc0000,0x800,0x3fe,0xc0000,0xc0000,0x0,0x0,0x0,0x800,0x800,0x0,0x800,0xbfe,0x13c1ffe,0x13c1ffe,0x0,0x0,0x13c1c00,0x0,0x400,0x400,0x13c1c00,0x0,0x0,0x0,0x800,0x0,0x800,0x0,0x0,0x0,0x0,0x13c1c00,0x13c1c00,0x13c1c00,0x13c1c00,0x0,0x0,0xc0000,0xc0000,0xc0800,0x8000,0x0,0x0,0x13c1c00,0x13c1c00,0x0,0x0,0x13c1c00,0x13c1c00,0x13c1c00,0x0,0x0,0x13c1c00,0x0,0x0,0x13c9c00,0x13c1c00,0x13c1c00,0x13c1c00,0x13c1c00,0x13c1c00,0x13c9c00,0xc0800,0x13c1c00,0xc0800,0x13c1c00,0x13c9c00,0xc0800,0x0,0x13c1c00,0x13c1c00,}; + jj_la1_2 = new int[] {0x13c1c00,0x0,0x0,0x13c1c00,0x0,0x13c1c00,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x800,0x0,0x800,0x0,0x0,0x300000,0x0,0x13c1c00,0x0,0x1000000,0x0,0x1000000,0x1000000,0x3fe,0x0,0x13c1c00,0x1000,0x0,0x0,0x4000,0x80010000,0x80010000,0x20000,0x20000,0x0,0x2000000,0x4000000,0x1000000,0x0,0x0,0x0,0x0,0x70000000,0x70000000,0x300000,0x300000,0x8c00000,0x8c00000,0x13c1c00,0x3c1c00,0x300000,0x3c0800,0xc0000,0x800,0x3fe,0xc0000,0xc0000,0x0,0x0,0x0,0x800,0x800,0x0,0x800,0xbfe,0x13c1ffe,0x13c1ffe,0x0,0x0,0x13c1c00,0x0,0x400,0x400,0x13c1c00,0x0,0x0,0x0,0x800,0x0,0x800,0x0,0x0,0x0,0x0,0x13c1c00,0x13c1c00,0x13c1c00,0x13c1c00,0x0,0x0,0xc0000,0xc0000,0xc0800,0x8000,0x0,0x0,0x13c1c00,0x13c1c00,0x0,0x0,0x13c1c00,0x13c1c00,0x13c1c00,0x0,0x0,0x13c1c00,0x0,0x0,0x13c9c00,0x13c1c00,0x13c1c00,0x13c1c00,0x13c1c00,0x13c1c00,0x13c9c00,0xc0800,0x13c1c00,0xc0800,0x13c1c00,0x13c9c00,0xc0800,0x0,0x13c1c00,0x13c1c00,}; } private static void jj_la1_3() { jj_la1_3 = new int[] {0x2288a2,0x0,0x0,0x2288a2,0x200000,0x2288a2,0x0,0x0,0x0,0x400000,0x0,0x0,0x20000,0x0,0x20000,0x20800,0x22,0x22,0x8a2,0x0,0x88a2,0x400000,0x0,0x400000,0x0,0x0,0x0,0x0,0x88a2,0x0,0x0,0x0,0x0,0x0,0x0,0x1,0x1,0x800000,0x0,0x0,0x0,0xe4000000,0xe4000000,0x1b000000,0x1b000000,0x0,0x0,0x0,0x0,0x0,0x0,0x88a2,0x88a2,0x0,0x88a2,0x0,0x88a2,0x0,0x0,0x0,0x80000,0x8000,0x8000,0x800,0x800,0x80000,0x800,0x800,0x88a2,0x88a2,0x80000,0xa2,0x88a2,0x400000,0x0,0x220800,0x2288a2,0x0,0x0,0x0,0x0,0x400000,0x0,0x0,0x400000,0x400000,0x400000,0x2288a2,0x2288a2,0x2288a2,0x2288a2,0x400000,0x0,0x0,0x0,0x800,0x20000,0x0,0x0,0x2288a2,0x2288a2,0x0,0x0,0x88a2,0x2288a2,0x2288a2,0x0,0x0,0x2288a2,0x0,0x0,0x2288a2,0x2288a2,0x2288a2,0x2288a2,0x2288a2,0x2288a2,0x2288a2,0x800,0x88a2,0x800,0x2288a2,0x2288a2,0x800,0x400000,0x88a2,0x88a2,}; diff --git a/net.sourceforge.phpeclipse/src/test/PHPParser.jj b/net.sourceforge.phpeclipse/src/test/PHPParser.jj index 1e7e5a2..530693d 100644 --- a/net.sourceforge.phpeclipse/src/test/PHPParser.jj +++ b/net.sourceforge.phpeclipse/src/test/PHPParser.jj @@ -40,6 +40,7 @@ import net.sourceforge.phpdt.internal.compiler.ast.*; import net.sourceforge.phpdt.internal.compiler.parser.OutlineableWithChildren; import net.sourceforge.phpdt.internal.compiler.parser.Outlineable; import net.sourceforge.phpdt.internal.compiler.parser.PHPOutlineInfo; +import junit.framework.Assert; /** * A new php parser. @@ -151,7 +152,7 @@ public final class PHPParser extends PHPParserSuperclass { private static void processParseException(final ParseException e) { if (PARSER_DEBUG) { e.printStackTrace(); - return; + Assert.assertTrue(false); } if (errorMessage == null) { PHPeclipsePlugin.log(e); @@ -233,7 +234,7 @@ public final class PHPParser extends PHPParserSuperclass { } } - public final void parse(final String s) throws CoreException { + public final void parse(final String s) { final StringReader stream = new StringReader(s); if (jj_input_stream == null) { jj_input_stream = new SimpleCharStream(stream, 1, 1); @@ -791,6 +792,7 @@ FieldDeclaration FieldDeclaration() : /** * a strict variable declarator : there cannot be a suffix here. + * It will be used by fields and formal parameters */ VariableDeclaration VariableDeclaratorNoSuffix() : { @@ -827,6 +829,9 @@ VariableDeclaration VariableDeclaratorNoSuffix() : } } +/** + * this will be used by static statement + */ VariableDeclaration VariableDeclarator() : { final String varName; @@ -1192,7 +1197,7 @@ Expression Expression() : [ assignOperator = AssignmentOperator() try { - initializer = ConditionalExpression() + initializer = Expression() } catch (ParseException e) { if (errorMessage != null) { throw e; @@ -1234,10 +1239,7 @@ Expression ExpressionWBang() : Expression ExpressionNoBang() : { - Expression expr = null; - int assignOperator = -1; - String var; - final int pos = SimpleCharStream.getPosition(); + Expression expr; } { expr = PrintExpression() {return expr;} @@ -1492,19 +1494,27 @@ Expression UnaryExpression() : expr = UnaryExpressionNoPrefix() {return new PrefixedUnaryExpression(expr,OperatorIds.AND,pos);} | - expr = AtUnaryExpression() {return expr;} + expr = AtNotUnaryExpression() {return expr;} } -Expression AtUnaryExpression() : +/** + * An expression prefixed (or not) by one or more @ and !. + * @return the expression + */ +Expression AtNotUnaryExpression() : { final Expression expr; final int pos = SimpleCharStream.getPosition(); } { - expr = AtUnaryExpression() + expr = AtNotUnaryExpression() {return new PrefixedUnaryExpression(expr,OperatorIds.AT,pos);} | + + expr = AtNotUnaryExpression() + {return new PrefixedUnaryExpression(expr,OperatorIds.NOT,pos);} +| expr = UnaryExpressionNoPrefix() {return expr;} } @@ -1530,6 +1540,9 @@ Expression UnaryExpressionNoPrefix() : | expr = UnaryExpressionNotPlusMinus() {return expr;} +/*| + LOOKAHEAD(2) + expr = PrintExpression() {return expr;}*/ } @@ -2269,6 +2282,9 @@ Statement BlockStatementNoBreak() : return statement;} } +/** + * used only by ForInit() + */ VariableDeclaration[] LocalVariableDeclaration() : { final ArrayList list = new ArrayList(); @@ -2284,6 +2300,9 @@ VariableDeclaration[] LocalVariableDeclaration() : return vars;} } +/** + * used only by LocalVariableDeclaration(). + */ VariableDeclaration LocalVariableDeclarator() : { final String varName; @@ -2317,6 +2336,9 @@ EmptyStatement EmptyStatement() : return new EmptyStatement(pos-1,pos);} } +/** + * used only by StatementExpressionList() which is used only by ForInit() and ForStatement() + */ Expression StatementExpression() : { final Expression expr,expr2; diff --git a/net.sourceforge.phpeclipse/src/test/PHPParserTokenManager.java b/net.sourceforge.phpeclipse/src/test/PHPParserTokenManager.java index 9c3f605..26fc6eb 100644 --- a/net.sourceforge.phpeclipse/src/test/PHPParserTokenManager.java +++ b/net.sourceforge.phpeclipse/src/test/PHPParserTokenManager.java @@ -16,6 +16,7 @@ import net.sourceforge.phpdt.internal.compiler.ast.*; import net.sourceforge.phpdt.internal.compiler.parser.OutlineableWithChildren; import net.sourceforge.phpdt.internal.compiler.parser.Outlineable; import net.sourceforge.phpdt.internal.compiler.parser.PHPOutlineInfo; +import junit.framework.Assert; public class PHPParserTokenManager implements PHPParserConstants {