1 /* Generated By:JavaCC: Do not edit this line. PHPParser.java */
4 import org.eclipse.core.resources.IFile;
5 import org.eclipse.core.resources.IMarker;
6 import org.eclipse.core.runtime.CoreException;
7 import org.eclipse.ui.texteditor.MarkerUtilities;
8 import org.eclipse.jface.preference.IPreferenceStore;
10 import java.util.Hashtable;
11 import java.util.ArrayList;
12 import java.io.StringReader;
14 import java.text.MessageFormat;
16 import net.sourceforge.phpeclipse.actions.PHPStartApacheAction;
17 import net.sourceforge.phpeclipse.PHPeclipsePlugin;
18 import net.sourceforge.phpdt.internal.compiler.ast.*;
19 import net.sourceforge.phpdt.internal.compiler.parser.OutlineableWithChildren;
20 import net.sourceforge.phpdt.internal.compiler.parser.Outlineable;
21 import net.sourceforge.phpdt.internal.compiler.parser.PHPOutlineInfo;
22 import junit.framework.Assert;
26 * This php parser is inspired by the Java 1.2 grammar example
27 * given with JavaCC. You can get JavaCC at http://www.webgain.com
28 * You can test the parser with the PHPParserTestCase2.java
29 * @author Matthieu Casanova
31 public final class PHPParser extends PHPParserSuperclass implements PHPParserConstants {
33 /** The current segment. */
34 private static OutlineableWithChildren currentSegment;
36 private static final String PARSE_ERROR_STRING = "Parse error"; //$NON-NLS-1$
37 private static final String PARSE_WARNING_STRING = "Warning"; //$NON-NLS-1$
38 static PHPOutlineInfo outlineInfo;
40 /** The error level of the current ParseException. */
41 private static int errorLevel = ERROR;
42 /** The message of the current ParseException. If it's null it's because the parse exception wasn't handled */
43 private static String errorMessage;
45 private static int errorStart = -1;
46 private static int errorEnd = -1;
47 private static PHPDocument phpDocument;
49 private static final char[] SYNTAX_ERROR_CHAR = {'s','y','n','t','a','x',' ','e','r','r','o','r'};
51 * The point where html starts.
52 * It will be used by the token manager to create HTMLCode objects
54 public static int htmlStart;
57 private final static int AstStackIncrement = 100;
58 /** The stack of node. */
59 private static AstNode[] nodes;
60 /** The cursor in expression stack. */
61 private static int nodePtr;
63 private static final boolean PARSER_DEBUG = false;
65 public final void setFileToParse(final IFile fileToParse) {
66 PHPParser.fileToParse = fileToParse;
72 public PHPParser(final IFile fileToParse) {
73 this(new StringReader(""));
74 PHPParser.fileToParse = fileToParse;
78 * Reinitialize the parser.
80 private static final void init() {
81 nodes = new AstNode[AstStackIncrement];
87 * Add an php node on the stack.
88 * @param node the node that will be added to the stack
90 private static final void pushOnAstNodes(final AstNode node) {
92 nodes[++nodePtr] = node;
93 } catch (IndexOutOfBoundsException e) {
94 final int oldStackLength = nodes.length;
95 final AstNode[] oldStack = nodes;
96 nodes = new AstNode[oldStackLength + AstStackIncrement];
97 System.arraycopy(oldStack, 0, nodes, 0, oldStackLength);
98 nodePtr = oldStackLength;
99 nodes[nodePtr] = node;
103 public final PHPOutlineInfo parseInfo(final Object parent, final String s) {
104 phpDocument = new PHPDocument(parent,"_root".toCharArray());
105 currentSegment = phpDocument;
106 outlineInfo = new PHPOutlineInfo(parent, currentSegment);
107 final StringReader stream = new StringReader(s);
108 if (jj_input_stream == null) {
109 jj_input_stream = new SimpleCharStream(stream, 1, 1);
115 phpDocument.nodes = new AstNode[nodes.length];
116 System.arraycopy(nodes,0,phpDocument.nodes,0,nodes.length);
117 if (PHPeclipsePlugin.DEBUG) {
118 PHPeclipsePlugin.log(1,phpDocument.toString());
120 } catch (ParseException e) {
121 processParseException(e);
127 * This method will process the parse exception.
128 * If the error message is null, the parse exception wasn't catched and a trace is written in the log
129 * @param e the ParseException
131 private static void processParseException(final ParseException e) {
134 Assert.assertTrue(false);
136 if (errorMessage == null) {
137 PHPeclipsePlugin.log(e);
138 errorMessage = "this exception wasn't handled by the parser please tell us how to reproduce it";
139 errorStart = SimpleCharStream.getPosition();
140 errorEnd = errorStart + 1;
144 // if (PHPeclipsePlugin.DEBUG) PHPeclipsePlugin.log(e);
148 * Create marker for the parse error.
149 * @param e the ParseException
151 private static void setMarker(final ParseException e) {
153 if (errorStart == -1) {
154 setMarker(fileToParse,
156 SimpleCharStream.tokenBegin,
157 SimpleCharStream.tokenBegin + e.currentToken.image.length(),
159 "Line " + e.currentToken.beginLine);
161 setMarker(fileToParse,
166 "Line " + e.currentToken.beginLine);
170 } catch (CoreException e2) {
171 PHPeclipsePlugin.log(e2);
175 private static void scanLine(final String output,
178 final int brIndx) throws CoreException {
180 final StringBuffer lineNumberBuffer = new StringBuffer(10);
182 current = output.substring(indx, brIndx);
184 if (current.indexOf(PARSE_WARNING_STRING) != -1 || current.indexOf(PARSE_ERROR_STRING) != -1) {
185 final int onLine = current.indexOf("on line <b>");
187 lineNumberBuffer.delete(0, lineNumberBuffer.length());
188 for (int i = onLine; i < current.length(); i++) {
189 ch = current.charAt(i);
190 if ('0' <= ch && '9' >= ch) {
191 lineNumberBuffer.append(ch);
195 final int lineNumber = Integer.parseInt(lineNumberBuffer.toString());
197 final Hashtable attributes = new Hashtable();
199 current = current.replaceAll("\n", "");
200 current = current.replaceAll("<b>", "");
201 current = current.replaceAll("</b>", "");
202 MarkerUtilities.setMessage(attributes, current);
204 if (current.indexOf(PARSE_ERROR_STRING) != -1)
205 attributes.put(IMarker.SEVERITY, new Integer(IMarker.SEVERITY_ERROR));
206 else if (current.indexOf(PARSE_WARNING_STRING) != -1)
207 attributes.put(IMarker.SEVERITY, new Integer(IMarker.SEVERITY_WARNING));
209 attributes.put(IMarker.SEVERITY, new Integer(IMarker.SEVERITY_INFO));
210 MarkerUtilities.setLineNumber(attributes, lineNumber);
211 MarkerUtilities.createMarker(file, attributes, IMarker.PROBLEM);
216 public final void parse(final String s) {
217 final StringReader stream = new StringReader(s);
218 if (jj_input_stream == null) {
219 jj_input_stream = new SimpleCharStream(stream, 1, 1);
225 } catch (ParseException e) {
226 processParseException(e);
231 * Call the php parse command ( php -l -f <filename> )
232 * and create markers according to the external parser output
234 public static void phpExternalParse(final IFile file) {
235 final IPreferenceStore store = PHPeclipsePlugin.getDefault().getPreferenceStore();
236 final String filename = file.getLocation().toString();
238 final String[] arguments = { filename };
239 final MessageFormat form = new MessageFormat(store.getString(PHPeclipsePlugin.EXTERNAL_PARSER_PREF));
240 final String command = form.format(arguments);
242 final String parserResult = PHPStartApacheAction.getParserOutput(command, "External parser: ");
245 // parse the buffer to find the errors and warnings
246 createMarkers(parserResult, file);
247 } catch (CoreException e) {
248 PHPeclipsePlugin.log(e);
253 * Put a new html block in the stack.
255 public static final void createNewHTMLCode() {
256 final int currentPosition = SimpleCharStream.getPosition();
257 if (currentPosition == htmlStart || currentPosition > SimpleCharStream.currentBuffer.length()) {
260 final char[] chars = SimpleCharStream.currentBuffer.substring(htmlStart,currentPosition+1).toCharArray();
261 pushOnAstNodes(new HTMLCode(chars, htmlStart,currentPosition));
264 /** Create a new task. */
265 public static final void createNewTask() {
266 final int currentPosition = SimpleCharStream.getPosition();
267 final String todo = SimpleCharStream.currentBuffer.substring(currentPosition-3,
268 SimpleCharStream.currentBuffer.indexOf("\n",
270 PHPeclipsePlugin.log(1,SimpleCharStream.currentBuffer.toString());
272 setMarker(fileToParse,
274 SimpleCharStream.getBeginLine(),
276 "Line "+SimpleCharStream.getBeginLine());
277 } catch (CoreException e) {
278 PHPeclipsePlugin.log(e);
282 private static final void parse() throws ParseException {
286 static final public void phpFile() throws ParseException {
290 switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
329 case INTEGER_LITERAL:
330 case FLOATING_POINT_LITERAL:
345 PHPParser.createNewHTMLCode();
346 } catch (TokenMgrError e) {
347 PHPeclipsePlugin.log(e);
348 errorStart = SimpleCharStream.getPosition();
349 errorEnd = errorStart + 1;
350 errorMessage = e.getMessage();
352 {if (true) throw generateParseException();}
357 * A php block is a <?= expression [;]?>
358 * or <?php somephpcode ?>
359 * or <? somephpcode ?>
361 static final public void PhpBlock() throws ParseException {
362 final int start = SimpleCharStream.getPosition();
363 final PHPEchoBlock phpEchoBlock;
364 switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
366 phpEchoBlock = phpEchoBlock();
367 pushOnAstNodes(phpEchoBlock);
406 case INTEGER_LITERAL:
407 case FLOATING_POINT_LITERAL:
414 switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
417 switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
419 jj_consume_token(PHPSTARTLONG);
422 jj_consume_token(PHPSTARTSHORT);
424 setMarker(fileToParse,
425 "You should use '<?php' instead of '<?' it will avoid some problems with XML",
427 SimpleCharStream.getPosition(),
429 "Line " + token.beginLine);
430 } catch (CoreException e) {
431 PHPeclipsePlugin.log(e);
436 jj_consume_token(-1);
437 throw new ParseException();
446 jj_consume_token(PHPEND);
447 } catch (ParseException e) {
448 errorMessage = "'?>' expected";
450 errorStart = SimpleCharStream.getPosition() - e.currentToken.next.image.length() + 1;
451 errorEnd = SimpleCharStream.getPosition() + 1;
452 processParseException(e);
457 jj_consume_token(-1);
458 throw new ParseException();
462 static final public PHPEchoBlock phpEchoBlock() throws ParseException {
463 final Expression expr;
464 final int pos = SimpleCharStream.getPosition();
465 final PHPEchoBlock echoBlock;
466 jj_consume_token(PHPECHOSTART);
468 switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
470 jj_consume_token(SEMICOLON);
476 jj_consume_token(PHPEND);
477 echoBlock = new PHPEchoBlock(expr,pos,SimpleCharStream.getPosition());
478 pushOnAstNodes(echoBlock);
479 {if (true) return echoBlock;}
480 throw new Error("Missing return statement in function");
483 static final public void Php() throws ParseException {
486 switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
521 case INTEGER_LITERAL:
522 case FLOATING_POINT_LITERAL:
539 static final public ClassDeclaration ClassDeclaration() throws ParseException {
540 final ClassDeclaration classDeclaration;
541 final Token className,superclassName;
543 char[] classNameImage = SYNTAX_ERROR_CHAR;
544 char[] superclassNameImage = null;
545 jj_consume_token(CLASS);
546 pos = SimpleCharStream.getPosition();
548 className = jj_consume_token(IDENTIFIER);
549 classNameImage = className.image.toCharArray();
550 } catch (ParseException e) {
551 errorMessage = "unexpected token : '"+ e.currentToken.next.image +"', identifier expected";
553 errorStart = SimpleCharStream.getPosition() - e.currentToken.next.image.length() + 1;
554 errorEnd = SimpleCharStream.getPosition() + 1;
555 processParseException(e);
557 switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
559 jj_consume_token(EXTENDS);
561 superclassName = jj_consume_token(IDENTIFIER);
562 superclassNameImage = superclassName.image.toCharArray();
563 } catch (ParseException e) {
564 errorMessage = "unexpected token : '"+ e.currentToken.next.image +"', identifier expected";
566 errorStart = SimpleCharStream.getPosition() - e.currentToken.next.image.length() + 1;
567 errorEnd = SimpleCharStream.getPosition() + 1;
568 processParseException(e);
569 superclassNameImage = SYNTAX_ERROR_CHAR;
576 if (superclassNameImage == null) {
577 classDeclaration = new ClassDeclaration(currentSegment,
582 classDeclaration = new ClassDeclaration(currentSegment,
588 currentSegment.add(classDeclaration);
589 currentSegment = classDeclaration;
590 ClassBody(classDeclaration);
591 currentSegment = (OutlineableWithChildren) currentSegment.getParent();
592 classDeclaration.sourceEnd = SimpleCharStream.getPosition();
593 pushOnAstNodes(classDeclaration);
594 {if (true) return classDeclaration;}
595 throw new Error("Missing return statement in function");
598 static final public void ClassBody(final ClassDeclaration classDeclaration) throws ParseException {
600 jj_consume_token(LBRACE);
601 } catch (ParseException e) {
602 errorMessage = "unexpected token : '"+ e.currentToken.next.image + "'. '{' expected";
604 errorStart = SimpleCharStream.getPosition() - e.currentToken.next.image.length() + 1;
605 errorEnd = SimpleCharStream.getPosition() + 1;
606 processParseException(e);
610 switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
619 ClassBodyDeclaration(classDeclaration);
622 jj_consume_token(RBRACE);
623 } catch (ParseException e) {
624 errorMessage = "unexpected token : '"+ e.currentToken.next.image +"'. 'var', 'function' or '}' expected";
626 errorStart = SimpleCharStream.getPosition() - e.currentToken.next.image.length() + 1;
627 errorEnd = SimpleCharStream.getPosition() + 1;
628 processParseException(e);
633 * A class can contain only methods and fields.
635 static final public void ClassBodyDeclaration(final ClassDeclaration classDeclaration) throws ParseException {
636 final MethodDeclaration method;
637 final FieldDeclaration field;
638 switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
640 method = MethodDeclaration();
641 method.analyzeCode();
642 classDeclaration.addMethod(method);
645 field = FieldDeclaration();
646 classDeclaration.addField(field);
650 jj_consume_token(-1);
651 throw new ParseException();
656 * A class field declaration : it's var VariableDeclarator() (, VariableDeclarator())*;.
657 * it is only used by ClassBodyDeclaration()
659 static final public FieldDeclaration FieldDeclaration() throws ParseException {
660 VariableDeclaration variableDeclaration;
661 final VariableDeclaration[] list;
662 final ArrayList arrayList = new ArrayList();
663 final int pos = SimpleCharStream.getPosition();
664 jj_consume_token(VAR);
665 variableDeclaration = VariableDeclaratorNoSuffix();
666 arrayList.add(variableDeclaration);
667 outlineInfo.addVariable(new String(variableDeclaration.name()));
670 switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
678 jj_consume_token(COMMA);
679 variableDeclaration = VariableDeclaratorNoSuffix();
680 arrayList.add(variableDeclaration);
681 outlineInfo.addVariable(new String(variableDeclaration.name()));
684 jj_consume_token(SEMICOLON);
685 } catch (ParseException e) {
686 errorMessage = "unexpected token : '"+ e.currentToken.next.image +"'. A ';' was expected after variable declaration";
688 errorStart = SimpleCharStream.getPosition() - e.currentToken.next.image.length() + 1;
689 errorEnd = SimpleCharStream.getPosition() + 1;
690 processParseException(e);
692 list = new VariableDeclaration[arrayList.size()];
693 arrayList.toArray(list);
694 {if (true) return new FieldDeclaration(list,
696 SimpleCharStream.getPosition(),
698 throw new Error("Missing return statement in function");
702 * a strict variable declarator : there cannot be a suffix here.
703 * It will be used by fields and formal parameters
705 static final public VariableDeclaration VariableDeclaratorNoSuffix() throws ParseException {
707 Expression initializer = null;
708 final int pos = SimpleCharStream.getPosition();
709 varName = jj_consume_token(DOLLAR_ID);
710 switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
712 jj_consume_token(ASSIGN);
714 initializer = VariableInitializer();
715 } catch (ParseException e) {
716 errorMessage = "Literal expression expected in variable initializer";
718 errorStart = SimpleCharStream.getPosition() - e.currentToken.next.image.length() + 1;
719 errorEnd = SimpleCharStream.getPosition() + 1;
720 processParseException(e);
727 if (initializer == null) {
728 {if (true) return new VariableDeclaration(currentSegment,
729 new Variable(varName.image.substring(1).toCharArray(),SimpleCharStream.getPosition()-varName.image.length()-1,SimpleCharStream.getPosition()),
731 SimpleCharStream.getPosition());}
733 {if (true) return new VariableDeclaration(currentSegment,
734 new Variable(varName.image.substring(1).toCharArray(),SimpleCharStream.getPosition()-varName.image.length()-1,SimpleCharStream.getPosition()),
736 VariableDeclaration.EQUAL,
738 throw new Error("Missing return statement in function");
742 * this will be used by static statement
744 static final public VariableDeclaration VariableDeclarator() throws ParseException {
745 final String varName;
746 Expression initializer = null;
747 final int pos = SimpleCharStream.getPosition();
748 varName = VariableDeclaratorId();
749 switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
751 jj_consume_token(ASSIGN);
753 initializer = VariableInitializer();
754 } catch (ParseException e) {
755 errorMessage = "Literal expression expected in variable initializer";
757 errorStart = SimpleCharStream.getPosition() - e.currentToken.next.image.length() + 1;
758 errorEnd = SimpleCharStream.getPosition() + 1;
759 processParseException(e);
766 if (initializer == null) {
767 {if (true) return new VariableDeclaration(currentSegment,
768 new Variable(varName.substring(1).toCharArray(),SimpleCharStream.getPosition()-varName.length()-1,SimpleCharStream.getPosition()),
770 SimpleCharStream.getPosition());}
772 {if (true) return new VariableDeclaration(currentSegment,
773 new Variable(varName.substring(1).toCharArray(),SimpleCharStream.getPosition()-varName.length()-1,SimpleCharStream.getPosition()),
775 VariableDeclaration.EQUAL,
777 throw new Error("Missing return statement in function");
782 * @return the variable name (with suffix)
784 static final public String VariableDeclaratorId() throws ParseException {
786 Expression expression = null;
787 final int pos = SimpleCharStream.getPosition();
788 ConstantIdentifier ex;
798 ex = new ConstantIdentifier(var.toCharArray(),
800 SimpleCharStream.getPosition());
801 expression = VariableSuffix(ex);
803 if (expression == null) {
804 {if (true) return var;}
806 {if (true) return expression.toStringExpression();}
807 } catch (ParseException e) {
808 errorMessage = "'$' expected for variable identifier";
810 errorStart = SimpleCharStream.getPosition() - e.currentToken.next.image.length() + 1;
811 errorEnd = SimpleCharStream.getPosition() + 1;
814 throw new Error("Missing return statement in function");
818 * Return a variablename without the $.
819 * @return a variable name
821 static final public String Variable() throws ParseException {
822 final StringBuffer buff;
823 Expression expression = null;
826 switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
828 token = jj_consume_token(DOLLAR_ID);
829 switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
831 jj_consume_token(LBRACE);
832 expression = Expression();
833 jj_consume_token(RBRACE);
839 if (expression == null) {
840 {if (true) return token.image.substring(1);}
842 buff = new StringBuffer(token.image);
844 buff.append(expression.toStringExpression());
846 {if (true) return buff.toString();}
849 jj_consume_token(DOLLAR);
850 expr = VariableName();
851 {if (true) return expr;}
855 jj_consume_token(-1);
856 throw new ParseException();
858 throw new Error("Missing return statement in function");
862 * A Variable name (without the $)
863 * @return a variable name String
865 static final public String VariableName() throws ParseException {
866 final StringBuffer buff;
868 Expression expression = null;
870 switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
872 jj_consume_token(LBRACE);
873 expression = Expression();
874 jj_consume_token(RBRACE);
875 buff = new StringBuffer("{");
876 buff.append(expression.toStringExpression());
878 {if (true) return buff.toString();}
881 token = jj_consume_token(IDENTIFIER);
882 switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
884 jj_consume_token(LBRACE);
885 expression = Expression();
886 jj_consume_token(RBRACE);
892 if (expression == null) {
893 {if (true) return token.image;}
895 buff = new StringBuffer(token.image);
897 buff.append(expression.toStringExpression());
899 {if (true) return buff.toString();}
902 jj_consume_token(DOLLAR);
903 expr = VariableName();
904 buff = new StringBuffer("$");
906 {if (true) return buff.toString();}
909 token = jj_consume_token(DOLLAR_ID);
910 {if (true) return token.image;}
914 jj_consume_token(-1);
915 throw new ParseException();
917 throw new Error("Missing return statement in function");
920 static final public Expression VariableInitializer() throws ParseException {
921 final Expression expr;
923 final int pos = SimpleCharStream.getPosition();
924 switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
928 case INTEGER_LITERAL:
929 case FLOATING_POINT_LITERAL:
932 {if (true) return expr;}
935 jj_consume_token(MINUS);
936 switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
937 case INTEGER_LITERAL:
938 token = jj_consume_token(INTEGER_LITERAL);
940 case FLOATING_POINT_LITERAL:
941 token = jj_consume_token(FLOATING_POINT_LITERAL);
945 jj_consume_token(-1);
946 throw new ParseException();
948 {if (true) return new PrefixedUnaryExpression(new NumberLiteral(token.image.toCharArray(),
950 SimpleCharStream.getPosition()),
955 jj_consume_token(PLUS);
956 switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
957 case INTEGER_LITERAL:
958 token = jj_consume_token(INTEGER_LITERAL);
960 case FLOATING_POINT_LITERAL:
961 token = jj_consume_token(FLOATING_POINT_LITERAL);
965 jj_consume_token(-1);
966 throw new ParseException();
968 {if (true) return new PrefixedUnaryExpression(new NumberLiteral(token.image.toCharArray(),
970 SimpleCharStream.getPosition()),
975 expr = ArrayDeclarator();
976 {if (true) return expr;}
979 token = jj_consume_token(IDENTIFIER);
980 {if (true) return new ConstantIdentifier(token.image.toCharArray(),pos,SimpleCharStream.getPosition());}
984 jj_consume_token(-1);
985 throw new ParseException();
987 throw new Error("Missing return statement in function");
990 static final public ArrayVariableDeclaration ArrayVariable() throws ParseException {
991 final Expression expr,expr2;
993 switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
995 jj_consume_token(ARRAYASSIGN);
996 expr2 = Expression();
997 {if (true) return new ArrayVariableDeclaration(expr,expr2);}
1000 jj_la1[19] = jj_gen;
1003 {if (true) return new ArrayVariableDeclaration(expr,SimpleCharStream.getPosition());}
1004 throw new Error("Missing return statement in function");
1007 static final public ArrayVariableDeclaration[] ArrayInitializer() throws ParseException {
1008 ArrayVariableDeclaration expr;
1009 final ArrayList list = new ArrayList();
1010 jj_consume_token(LPAREN);
1011 switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
1027 case INTEGER_LITERAL:
1028 case FLOATING_POINT_LITERAL:
1029 case STRING_LITERAL:
1033 expr = ArrayVariable();
1042 jj_consume_token(COMMA);
1043 expr = ArrayVariable();
1048 jj_la1[20] = jj_gen;
1051 switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
1053 jj_consume_token(COMMA);
1057 jj_la1[21] = jj_gen;
1060 jj_consume_token(RPAREN);
1061 final ArrayVariableDeclaration[] vars = new ArrayVariableDeclaration[list.size()];
1063 {if (true) return vars;}
1064 throw new Error("Missing return statement in function");
1068 * A Method Declaration.
1069 * <b>function</b> MetodDeclarator() Block()
1071 static final public MethodDeclaration MethodDeclaration() throws ParseException {
1072 final MethodDeclaration functionDeclaration;
1074 final OutlineableWithChildren seg = currentSegment;
1075 jj_consume_token(FUNCTION);
1077 functionDeclaration = MethodDeclarator();
1078 outlineInfo.addVariable(new String(functionDeclaration.name));
1079 } catch (ParseException e) {
1080 if (errorMessage != null) {if (true) throw e;}
1081 errorMessage = "unexpected token : '"+ e.currentToken.next.image +"', function identifier expected";
1083 errorStart = SimpleCharStream.getPosition() - e.currentToken.next.image.length() + 1;
1084 errorEnd = SimpleCharStream.getPosition() + 1;
1085 {if (true) throw e;}
1087 currentSegment = functionDeclaration;
1089 functionDeclaration.statements = block.statements;
1090 currentSegment = seg;
1091 {if (true) return functionDeclaration;}
1092 throw new Error("Missing return statement in function");
1096 * A MethodDeclarator.
1097 * [&] IDENTIFIER(parameters ...).
1098 * @return a function description for the outline
1100 static final public MethodDeclaration MethodDeclarator() throws ParseException {
1101 final Token identifier;
1102 Token reference = null;
1103 final Hashtable formalParameters;
1104 final int pos = SimpleCharStream.getPosition();
1105 char[] identifierChar = SYNTAX_ERROR_CHAR;
1106 switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
1108 reference = jj_consume_token(BIT_AND);
1111 jj_la1[22] = jj_gen;
1115 identifier = jj_consume_token(IDENTIFIER);
1116 identifierChar = identifier.image.toCharArray();
1117 } catch (ParseException e) {
1118 errorMessage = "unexpected token : '"+ e.currentToken.next.image +"', function identifier expected";
1120 errorStart = SimpleCharStream.getPosition() - e.currentToken.next.image.length() + 1;
1121 errorEnd = SimpleCharStream.getPosition() + 1;
1122 processParseException(e);
1124 formalParameters = FormalParameters();
1125 MethodDeclaration method = new MethodDeclaration(currentSegment,
1130 SimpleCharStream.getPosition());
1131 {if (true) return method;}
1132 throw new Error("Missing return statement in function");
1136 * FormalParameters follows method identifier.
1137 * (FormalParameter())
1139 static final public Hashtable FormalParameters() throws ParseException {
1140 VariableDeclaration var;
1141 final Hashtable parameters = new Hashtable();
1143 jj_consume_token(LPAREN);
1144 } catch (ParseException e) {
1145 errorMessage = "unexpected token : '"+ e.currentToken.next.image +"', '(' expected after function identifier";
1147 errorStart = SimpleCharStream.getPosition() - e.currentToken.next.image.length() + 1;
1148 errorEnd = SimpleCharStream.getPosition() + 1;
1149 processParseException(e);
1151 switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
1154 var = FormalParameter();
1155 parameters.put(new String(var.name()),var);
1158 switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
1163 jj_la1[23] = jj_gen;
1166 jj_consume_token(COMMA);
1167 var = FormalParameter();
1168 parameters.put(new String(var.name()),var);
1172 jj_la1[24] = jj_gen;
1176 jj_consume_token(RPAREN);
1177 } catch (ParseException e) {
1178 errorMessage = "')' expected";
1180 errorStart = SimpleCharStream.getPosition() - e.currentToken.next.image.length() + 1;
1181 errorEnd = SimpleCharStream.getPosition() + 1;
1182 processParseException(e);
1184 {if (true) return parameters;}
1185 throw new Error("Missing return statement in function");
1189 * A formal parameter.
1190 * $varname[=value] (,$varname[=value])
1192 static final public VariableDeclaration FormalParameter() throws ParseException {
1193 final VariableDeclaration variableDeclaration;
1195 switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
1197 token = jj_consume_token(BIT_AND);
1200 jj_la1[25] = jj_gen;
1203 variableDeclaration = VariableDeclaratorNoSuffix();
1204 if (token != null) {
1205 variableDeclaration.setReference(true);
1207 {if (true) return variableDeclaration;}
1208 throw new Error("Missing return statement in function");
1211 static final public ConstantIdentifier Type() throws ParseException {
1213 switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
1215 jj_consume_token(STRING);
1216 pos = SimpleCharStream.getPosition();
1217 {if (true) return new ConstantIdentifier(Types.STRING,pos,pos-6);}
1220 jj_consume_token(BOOL);
1221 pos = SimpleCharStream.getPosition();
1222 {if (true) return new ConstantIdentifier(Types.BOOL,pos,pos-4);}
1225 jj_consume_token(BOOLEAN);
1226 pos = SimpleCharStream.getPosition();
1227 {if (true) return new ConstantIdentifier(Types.BOOLEAN,pos,pos-7);}
1230 jj_consume_token(REAL);
1231 pos = SimpleCharStream.getPosition();
1232 {if (true) return new ConstantIdentifier(Types.REAL,pos,pos-4);}
1235 jj_consume_token(DOUBLE);
1236 pos = SimpleCharStream.getPosition();
1237 {if (true) return new ConstantIdentifier(Types.DOUBLE,pos,pos-5);}
1240 jj_consume_token(FLOAT);
1241 pos = SimpleCharStream.getPosition();
1242 {if (true) return new ConstantIdentifier(Types.FLOAT,pos,pos-5);}
1245 jj_consume_token(INT);
1246 pos = SimpleCharStream.getPosition();
1247 {if (true) return new ConstantIdentifier(Types.INT,pos,pos-3);}
1250 jj_consume_token(INTEGER);
1251 pos = SimpleCharStream.getPosition();
1252 {if (true) return new ConstantIdentifier(Types.INTEGER,pos,pos-7);}
1255 jj_consume_token(OBJECT);
1256 pos = SimpleCharStream.getPosition();
1257 {if (true) return new ConstantIdentifier(Types.OBJECT,pos,pos-6);}
1260 jj_la1[26] = jj_gen;
1261 jj_consume_token(-1);
1262 throw new ParseException();
1264 throw new Error("Missing return statement in function");
1267 static final public Expression Expression() throws ParseException {
1268 final Expression expr;
1269 Expression initializer = null;
1270 final int pos = SimpleCharStream.getPosition();
1271 int assignOperator = -1;
1272 switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
1286 case INTEGER_LITERAL:
1287 case FLOATING_POINT_LITERAL:
1288 case STRING_LITERAL:
1292 expr = ConditionalExpression();
1293 switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
1306 case RSIGNEDSHIFTASSIGN:
1307 assignOperator = AssignmentOperator();
1309 initializer = Expression();
1310 } catch (ParseException e) {
1311 if (errorMessage != null) {
1312 {if (true) throw e;}
1314 errorMessage = "unexpected token : '"+ e.currentToken.next.image +"', expression expected";
1316 errorEnd = SimpleCharStream.getPosition();
1317 {if (true) throw e;}
1321 jj_la1[27] = jj_gen;
1324 char[] varName = expr.toStringExpression().substring(1).toCharArray();
1325 if (assignOperator == -1) {
1326 {if (true) return new VariableDeclaration(currentSegment,
1327 new Variable(varName,SimpleCharStream.getPosition()-varName.length-1,SimpleCharStream.getPosition()),
1329 SimpleCharStream.getPosition());}
1330 {if (true) return expr;}
1332 {if (true) return new VariableDeclaration(currentSegment,
1333 new Variable(varName,SimpleCharStream.getPosition()-varName.length-1,SimpleCharStream.getPosition()),
1337 {if (true) return expr;}
1341 expr = ExpressionWBang();
1342 {if (true) return expr;}
1345 jj_la1[28] = jj_gen;
1346 jj_consume_token(-1);
1347 throw new ParseException();
1349 throw new Error("Missing return statement in function");
1352 static final public Expression ExpressionWBang() throws ParseException {
1353 final Expression expr;
1354 final int pos = SimpleCharStream.getPosition();
1355 switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
1357 jj_consume_token(BANG);
1358 expr = ExpressionWBang();
1359 {if (true) return new PrefixedUnaryExpression(expr,OperatorIds.NOT,pos);}
1363 expr = ExpressionNoBang();
1364 {if (true) return expr;}
1367 jj_la1[29] = jj_gen;
1368 jj_consume_token(-1);
1369 throw new ParseException();
1371 throw new Error("Missing return statement in function");
1374 static final public Expression ExpressionNoBang() throws ParseException {
1376 switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
1378 expr = PrintExpression();
1379 {if (true) return expr;}
1382 expr = ListExpression();
1383 {if (true) return expr;}
1386 jj_la1[30] = jj_gen;
1387 jj_consume_token(-1);
1388 throw new ParseException();
1390 throw new Error("Missing return statement in function");
1394 * Any assignement operator.
1395 * @return the assignement operator id
1397 static final public int AssignmentOperator() throws ParseException {
1398 switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
1400 jj_consume_token(ASSIGN);
1401 {if (true) return VariableDeclaration.EQUAL;}
1404 jj_consume_token(STARASSIGN);
1405 {if (true) return VariableDeclaration.STAR_EQUAL;}
1408 jj_consume_token(SLASHASSIGN);
1409 {if (true) return VariableDeclaration.SLASH_EQUAL;}
1412 jj_consume_token(REMASSIGN);
1413 {if (true) return VariableDeclaration.REM_EQUAL;}
1416 jj_consume_token(PLUSASSIGN);
1417 {if (true) return VariableDeclaration.PLUS_EQUAL;}
1420 jj_consume_token(MINUSASSIGN);
1421 {if (true) return VariableDeclaration.MINUS_EQUAL;}
1424 jj_consume_token(LSHIFTASSIGN);
1425 {if (true) return VariableDeclaration.LSHIFT_EQUAL;}
1427 case RSIGNEDSHIFTASSIGN:
1428 jj_consume_token(RSIGNEDSHIFTASSIGN);
1429 {if (true) return VariableDeclaration.RSIGNEDSHIFT_EQUAL;}
1432 jj_consume_token(ANDASSIGN);
1433 {if (true) return VariableDeclaration.AND_EQUAL;}
1436 jj_consume_token(XORASSIGN);
1437 {if (true) return VariableDeclaration.XOR_EQUAL;}
1440 jj_consume_token(ORASSIGN);
1441 {if (true) return VariableDeclaration.OR_EQUAL;}
1444 jj_consume_token(DOTASSIGN);
1445 {if (true) return VariableDeclaration.DOT_EQUAL;}
1448 jj_consume_token(TILDEEQUAL);
1449 {if (true) return VariableDeclaration.TILDE_EQUAL;}
1452 jj_la1[31] = jj_gen;
1453 jj_consume_token(-1);
1454 throw new ParseException();
1456 throw new Error("Missing return statement in function");
1459 static final public Expression ConditionalExpression() throws ParseException {
1460 final Expression expr;
1461 Expression expr2 = null;
1462 Expression expr3 = null;
1463 expr = ConditionalOrExpression();
1464 switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
1466 jj_consume_token(HOOK);
1467 expr2 = Expression();
1468 jj_consume_token(COLON);
1469 expr3 = ConditionalExpression();
1472 jj_la1[32] = jj_gen;
1475 if (expr3 == null) {
1476 {if (true) return expr;}
1478 {if (true) return new ConditionalExpression(expr,expr2,expr3);}
1479 throw new Error("Missing return statement in function");
1482 static final public Expression ConditionalOrExpression() throws ParseException {
1483 Expression expr,expr2;
1485 expr = ConditionalAndExpression();
1488 switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
1494 jj_la1[33] = jj_gen;
1497 switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
1499 jj_consume_token(OR_OR);
1500 operator = OperatorIds.OR_OR;
1503 jj_consume_token(_ORL);
1504 operator = OperatorIds.ORL;
1507 jj_la1[34] = jj_gen;
1508 jj_consume_token(-1);
1509 throw new ParseException();
1511 expr2 = ConditionalAndExpression();
1512 expr = new BinaryExpression(expr,expr2,operator);
1514 {if (true) return expr;}
1515 throw new Error("Missing return statement in function");
1518 static final public Expression ConditionalAndExpression() throws ParseException {
1519 Expression expr,expr2;
1521 expr = ConcatExpression();
1524 switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
1530 jj_la1[35] = jj_gen;
1533 switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
1535 jj_consume_token(AND_AND);
1536 operator = OperatorIds.AND_AND;
1539 jj_consume_token(_ANDL);
1540 operator = OperatorIds.ANDL;
1543 jj_la1[36] = jj_gen;
1544 jj_consume_token(-1);
1545 throw new ParseException();
1547 expr2 = ConcatExpression();
1548 expr = new BinaryExpression(expr,expr2,operator);
1550 {if (true) return expr;}
1551 throw new Error("Missing return statement in function");
1554 static final public Expression ConcatExpression() throws ParseException {
1555 Expression expr,expr2;
1556 expr = InclusiveOrExpression();
1559 switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
1564 jj_la1[37] = jj_gen;
1567 jj_consume_token(DOT);
1568 expr2 = InclusiveOrExpression();
1569 expr = new BinaryExpression(expr,expr2,OperatorIds.DOT);
1571 {if (true) return expr;}
1572 throw new Error("Missing return statement in function");
1575 static final public Expression InclusiveOrExpression() throws ParseException {
1576 Expression expr,expr2;
1577 expr = ExclusiveOrExpression();
1580 switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
1585 jj_la1[38] = jj_gen;
1588 jj_consume_token(BIT_OR);
1589 expr2 = ExclusiveOrExpression();
1590 expr = new BinaryExpression(expr,expr2,OperatorIds.OR);
1592 {if (true) return expr;}
1593 throw new Error("Missing return statement in function");
1596 static final public Expression ExclusiveOrExpression() throws ParseException {
1597 Expression expr,expr2;
1598 expr = AndExpression();
1601 switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
1606 jj_la1[39] = jj_gen;
1609 jj_consume_token(XOR);
1610 expr2 = AndExpression();
1611 expr = new BinaryExpression(expr,expr2,OperatorIds.XOR);
1613 {if (true) return expr;}
1614 throw new Error("Missing return statement in function");
1617 static final public Expression AndExpression() throws ParseException {
1618 Expression expr,expr2;
1619 expr = EqualityExpression();
1622 switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
1627 jj_la1[40] = jj_gen;
1630 jj_consume_token(BIT_AND);
1631 expr2 = EqualityExpression();
1632 expr = new BinaryExpression(expr,expr2,OperatorIds.AND);
1634 {if (true) return expr;}
1635 throw new Error("Missing return statement in function");
1638 static final public Expression EqualityExpression() throws ParseException {
1639 Expression expr,expr2;
1641 expr = RelationalExpression();
1644 switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
1648 case BANGDOUBLEEQUAL:
1653 jj_la1[41] = jj_gen;
1656 switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
1658 jj_consume_token(EQUAL_EQUAL);
1659 operator = OperatorIds.EQUAL_EQUAL;
1662 jj_consume_token(DIF);
1663 operator = OperatorIds.DIF;
1666 jj_consume_token(NOT_EQUAL);
1667 operator = OperatorIds.DIF;
1669 case BANGDOUBLEEQUAL:
1670 jj_consume_token(BANGDOUBLEEQUAL);
1671 operator = OperatorIds.BANG_EQUAL_EQUAL;
1674 jj_consume_token(TRIPLEEQUAL);
1675 operator = OperatorIds.EQUAL_EQUAL_EQUAL;
1678 jj_la1[42] = jj_gen;
1679 jj_consume_token(-1);
1680 throw new ParseException();
1683 expr2 = RelationalExpression();
1684 } catch (ParseException e) {
1685 if (errorMessage != null) {
1686 {if (true) throw e;}
1688 errorMessage = "unexpected token : '"+ e.currentToken.next.image +"', expression expected";
1690 errorStart = SimpleCharStream.getPosition() - e.currentToken.next.image.length() + 1;
1691 errorEnd = SimpleCharStream.getPosition() + 1;
1692 {if (true) throw e;}
1694 expr = new BinaryExpression(expr,expr2,operator);
1696 {if (true) return expr;}
1697 throw new Error("Missing return statement in function");
1700 static final public Expression RelationalExpression() throws ParseException {
1701 Expression expr,expr2;
1703 expr = ShiftExpression();
1706 switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
1714 jj_la1[43] = jj_gen;
1717 switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
1719 jj_consume_token(LT);
1720 operator = OperatorIds.LESS;
1723 jj_consume_token(GT);
1724 operator = OperatorIds.GREATER;
1727 jj_consume_token(LE);
1728 operator = OperatorIds.LESS_EQUAL;
1731 jj_consume_token(GE);
1732 operator = OperatorIds.GREATER_EQUAL;
1735 jj_la1[44] = jj_gen;
1736 jj_consume_token(-1);
1737 throw new ParseException();
1739 expr2 = ShiftExpression();
1740 expr = new BinaryExpression(expr,expr2,operator);
1742 {if (true) return expr;}
1743 throw new Error("Missing return statement in function");
1746 static final public Expression ShiftExpression() throws ParseException {
1747 Expression expr,expr2;
1749 expr = AdditiveExpression();
1752 switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
1755 case RUNSIGNEDSHIFT:
1759 jj_la1[45] = jj_gen;
1762 switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
1764 jj_consume_token(LSHIFT);
1765 operator = OperatorIds.LEFT_SHIFT;
1768 jj_consume_token(RSIGNEDSHIFT);
1769 operator = OperatorIds.RIGHT_SHIFT;
1771 case RUNSIGNEDSHIFT:
1772 jj_consume_token(RUNSIGNEDSHIFT);
1773 operator = OperatorIds.UNSIGNED_RIGHT_SHIFT;
1776 jj_la1[46] = jj_gen;
1777 jj_consume_token(-1);
1778 throw new ParseException();
1780 expr2 = AdditiveExpression();
1781 expr = new BinaryExpression(expr,expr2,operator);
1783 {if (true) return expr;}
1784 throw new Error("Missing return statement in function");
1787 static final public Expression AdditiveExpression() throws ParseException {
1788 Expression expr,expr2;
1790 expr = MultiplicativeExpression();
1793 switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
1799 jj_la1[47] = jj_gen;
1802 switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
1804 jj_consume_token(PLUS);
1805 operator = OperatorIds.PLUS;
1808 jj_consume_token(MINUS);
1809 operator = OperatorIds.MINUS;
1812 jj_la1[48] = jj_gen;
1813 jj_consume_token(-1);
1814 throw new ParseException();
1816 expr2 = MultiplicativeExpression();
1817 expr = new BinaryExpression(expr,expr2,operator);
1819 {if (true) return expr;}
1820 throw new Error("Missing return statement in function");
1823 static final public Expression MultiplicativeExpression() throws ParseException {
1824 Expression expr,expr2;
1827 expr = UnaryExpression();
1828 } catch (ParseException e) {
1829 if (errorMessage != null) {if (true) throw e;}
1830 errorMessage = "unexpected token '"+e.currentToken.next.image+"'";
1832 errorStart = SimpleCharStream.getPosition() - e.currentToken.next.image.length() + 1;
1833 errorEnd = SimpleCharStream.getPosition() + 1;
1834 {if (true) throw e;}
1838 switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
1845 jj_la1[49] = jj_gen;
1848 switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
1850 jj_consume_token(STAR);
1851 operator = OperatorIds.MULTIPLY;
1854 jj_consume_token(SLASH);
1855 operator = OperatorIds.DIVIDE;
1858 jj_consume_token(REMAINDER);
1859 operator = OperatorIds.REMAINDER;
1862 jj_la1[50] = jj_gen;
1863 jj_consume_token(-1);
1864 throw new ParseException();
1866 expr2 = UnaryExpression();
1867 expr = new BinaryExpression(expr,expr2,operator);
1869 {if (true) return expr;}
1870 throw new Error("Missing return statement in function");
1874 * An unary expression starting with @, & or nothing
1876 static final public Expression UnaryExpression() throws ParseException {
1877 final Expression expr;
1878 final int pos = SimpleCharStream.getPosition();
1879 switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
1881 jj_consume_token(BIT_AND);
1882 expr = UnaryExpressionNoPrefix();
1883 {if (true) return new PrefixedUnaryExpression(expr,OperatorIds.AND,pos);}
1897 case INTEGER_LITERAL:
1898 case FLOATING_POINT_LITERAL:
1899 case STRING_LITERAL:
1903 expr = AtNotUnaryExpression();
1904 {if (true) return expr;}
1907 jj_la1[51] = jj_gen;
1908 jj_consume_token(-1);
1909 throw new ParseException();
1911 throw new Error("Missing return statement in function");
1915 * An expression prefixed (or not) by one or more @ and !.
1916 * @return the expression
1918 static final public Expression AtNotUnaryExpression() throws ParseException {
1919 final Expression expr;
1920 final int pos = SimpleCharStream.getPosition();
1921 switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
1923 jj_consume_token(AT);
1924 expr = AtNotUnaryExpression();
1925 {if (true) return new PrefixedUnaryExpression(expr,OperatorIds.AT,pos);}
1928 jj_consume_token(BANG);
1929 expr = AtNotUnaryExpression();
1930 {if (true) return new PrefixedUnaryExpression(expr,OperatorIds.NOT,pos);}
1942 case INTEGER_LITERAL:
1943 case FLOATING_POINT_LITERAL:
1944 case STRING_LITERAL:
1948 expr = UnaryExpressionNoPrefix();
1949 {if (true) return expr;}
1952 jj_la1[52] = jj_gen;
1953 jj_consume_token(-1);
1954 throw new ParseException();
1956 throw new Error("Missing return statement in function");
1959 static final public Expression UnaryExpressionNoPrefix() throws ParseException {
1960 final Expression expr;
1962 final int pos = SimpleCharStream.getPosition();
1963 switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
1966 switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
1968 jj_consume_token(PLUS);
1969 operator = OperatorIds.PLUS;
1972 jj_consume_token(MINUS);
1973 operator = OperatorIds.MINUS;
1976 jj_la1[53] = jj_gen;
1977 jj_consume_token(-1);
1978 throw new ParseException();
1980 expr = UnaryExpression();
1981 {if (true) return new PrefixedUnaryExpression(expr,operator,pos);}
1985 expr = PreIncDecExpression();
1986 {if (true) return expr;}
1994 case INTEGER_LITERAL:
1995 case FLOATING_POINT_LITERAL:
1996 case STRING_LITERAL:
2000 expr = UnaryExpressionNotPlusMinus();
2001 {if (true) return expr;}
2004 jj_la1[54] = jj_gen;
2005 jj_consume_token(-1);
2006 throw new ParseException();
2008 throw new Error("Missing return statement in function");
2011 static final public Expression PreIncDecExpression() throws ParseException {
2012 final Expression expr;
2014 final int pos = SimpleCharStream.getPosition();
2015 switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
2017 jj_consume_token(PLUS_PLUS);
2018 operator = OperatorIds.PLUS_PLUS;
2021 jj_consume_token(MINUS_MINUS);
2022 operator = OperatorIds.MINUS_MINUS;
2025 jj_la1[55] = jj_gen;
2026 jj_consume_token(-1);
2027 throw new ParseException();
2029 expr = PrimaryExpression();
2030 {if (true) return new PrefixedUnaryExpression(expr,operator,pos);}
2031 throw new Error("Missing return statement in function");
2034 static final public Expression UnaryExpressionNotPlusMinus() throws ParseException {
2035 final Expression expr;
2036 final int pos = SimpleCharStream.getPosition();
2037 if (jj_2_3(2147483647)) {
2038 expr = CastExpression();
2039 {if (true) return expr;}
2041 switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
2047 expr = PostfixExpression();
2048 {if (true) return expr;}
2053 case INTEGER_LITERAL:
2054 case FLOATING_POINT_LITERAL:
2055 case STRING_LITERAL:
2057 {if (true) return expr;}
2060 jj_consume_token(LPAREN);
2061 expr = Expression();
2063 jj_consume_token(RPAREN);
2064 } catch (ParseException e) {
2065 errorMessage = "')' expected";
2067 errorStart = SimpleCharStream.getPosition() - e.currentToken.next.image.length() + 1;
2068 errorEnd = SimpleCharStream.getPosition() + 1;
2069 {if (true) throw e;}
2071 {if (true) return expr;}
2074 jj_la1[56] = jj_gen;
2075 jj_consume_token(-1);
2076 throw new ParseException();
2079 throw new Error("Missing return statement in function");
2082 static final public CastExpression CastExpression() throws ParseException {
2083 final ConstantIdentifier type;
2084 final Expression expr;
2085 final int pos = SimpleCharStream.getPosition();
2086 jj_consume_token(LPAREN);
2087 switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
2100 jj_consume_token(ARRAY);
2101 type = new ConstantIdentifier(Types.ARRAY,pos,SimpleCharStream.getPosition());
2104 jj_la1[57] = jj_gen;
2105 jj_consume_token(-1);
2106 throw new ParseException();
2108 jj_consume_token(RPAREN);
2109 expr = UnaryExpression();
2110 {if (true) return new CastExpression(type,expr,pos,SimpleCharStream.getPosition());}
2111 throw new Error("Missing return statement in function");
2114 static final public Expression PostfixExpression() throws ParseException {
2115 final Expression expr;
2117 final int pos = SimpleCharStream.getPosition();
2118 expr = PrimaryExpression();
2119 switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
2122 switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
2124 jj_consume_token(PLUS_PLUS);
2125 operator = OperatorIds.PLUS_PLUS;
2128 jj_consume_token(MINUS_MINUS);
2129 operator = OperatorIds.MINUS_MINUS;
2132 jj_la1[58] = jj_gen;
2133 jj_consume_token(-1);
2134 throw new ParseException();
2138 jj_la1[59] = jj_gen;
2141 if (operator == -1) {
2142 {if (true) return expr;}
2144 {if (true) return new PostfixedUnaryExpression(expr,operator,pos);}
2145 throw new Error("Missing return statement in function");
2148 static final public Expression PrimaryExpression() throws ParseException {
2150 int assignOperator = -1;
2151 final Token identifier;
2153 final int pos = SimpleCharStream.getPosition();
2154 switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
2158 expr = PrimaryPrefix();
2161 switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
2163 case STATICCLASSACCESS:
2168 jj_la1[60] = jj_gen;
2171 expr = PrimarySuffix(expr);
2173 switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
2175 expr = Arguments(expr);
2178 jj_la1[61] = jj_gen;
2181 {if (true) return expr;}
2184 jj_consume_token(NEW);
2185 expr = ClassIdentifier();
2186 expr = new PrefixedUnaryExpression(expr,
2189 switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
2191 expr = Arguments(expr);
2194 jj_la1[62] = jj_gen;
2197 {if (true) return expr;}
2200 expr = ArrayDeclarator();
2201 {if (true) return expr;}
2204 jj_la1[63] = jj_gen;
2205 jj_consume_token(-1);
2206 throw new ParseException();
2208 throw new Error("Missing return statement in function");
2211 static final public Expression PrimaryPrefix() throws ParseException {
2212 final Expression expr;
2215 final int pos = SimpleCharStream.getPosition();
2216 switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
2218 token = jj_consume_token(IDENTIFIER);
2219 {if (true) return new ConstantIdentifier(token.image.toCharArray(),
2221 SimpleCharStream.getPosition());}
2225 var = VariableDeclaratorId();
2226 {if (true) return new Variable(var.toCharArray(),
2228 SimpleCharStream.getPosition());}
2231 jj_la1[64] = jj_gen;
2232 jj_consume_token(-1);
2233 throw new ParseException();
2235 throw new Error("Missing return statement in function");
2238 static final public AbstractSuffixExpression PrimarySuffix(final Expression prefix) throws ParseException {
2239 final AbstractSuffixExpression suffix;
2240 final Expression expr;
2241 switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
2244 suffix = VariableSuffix(prefix);
2245 {if (true) return suffix;}
2247 case STATICCLASSACCESS:
2248 jj_consume_token(STATICCLASSACCESS);
2249 expr = ClassIdentifier();
2250 suffix = new ClassAccess(prefix,
2252 ClassAccess.STATIC);
2253 {if (true) return suffix;}
2256 jj_la1[65] = jj_gen;
2257 jj_consume_token(-1);
2258 throw new ParseException();
2260 throw new Error("Missing return statement in function");
2264 * An array declarator.
2268 static final public ArrayInitializer ArrayDeclarator() throws ParseException {
2269 final ArrayVariableDeclaration[] vars;
2270 final int pos = SimpleCharStream.getPosition();
2271 jj_consume_token(ARRAY);
2272 vars = ArrayInitializer();
2273 {if (true) return new ArrayInitializer(vars,pos,SimpleCharStream.getPosition());}
2274 throw new Error("Missing return statement in function");
2277 static final public PrefixedUnaryExpression classInstantiation() throws ParseException {
2279 final StringBuffer buff;
2280 final int pos = SimpleCharStream.getPosition();
2281 jj_consume_token(NEW);
2282 expr = ClassIdentifier();
2283 switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
2289 buff = new StringBuffer(expr.toStringExpression());
2290 expr = PrimaryExpression();
2291 buff.append(expr.toStringExpression());
2292 expr = new ConstantIdentifier(buff.toString().toCharArray(),
2294 SimpleCharStream.getPosition());
2297 jj_la1[66] = jj_gen;
2300 {if (true) return new PrefixedUnaryExpression(expr,
2303 throw new Error("Missing return statement in function");
2306 static final public ConstantIdentifier ClassIdentifier() throws ParseException {
2309 final int pos = SimpleCharStream.getPosition();
2310 final ConstantIdentifier type;
2311 switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
2313 token = jj_consume_token(IDENTIFIER);
2314 {if (true) return new ConstantIdentifier(token.image.toCharArray(),
2316 SimpleCharStream.getPosition());}
2328 {if (true) return type;}
2332 expr = VariableDeclaratorId();
2333 {if (true) return new ConstantIdentifier(expr.toCharArray(),
2335 SimpleCharStream.getPosition());}
2338 jj_la1[67] = jj_gen;
2339 jj_consume_token(-1);
2340 throw new ParseException();
2342 throw new Error("Missing return statement in function");
2345 static final public AbstractSuffixExpression VariableSuffix(final Expression prefix) throws ParseException {
2347 final int pos = SimpleCharStream.getPosition();
2348 Expression expression = null;
2349 switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
2351 jj_consume_token(CLASSACCESS);
2353 expr = VariableName();
2354 } catch (ParseException e) {
2355 errorMessage = "unexpected token : '"+ e.currentToken.next.image +"', function call or field access expected";
2357 errorStart = SimpleCharStream.getPosition() - e.currentToken.next.image.length() + 1;
2358 errorEnd = SimpleCharStream.getPosition() + 1;
2359 {if (true) throw e;}
2361 {if (true) return new ClassAccess(prefix,
2362 new ConstantIdentifier(expr.toCharArray(),pos,SimpleCharStream.getPosition()),
2363 ClassAccess.NORMAL);}
2366 jj_consume_token(LBRACKET);
2367 switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
2392 case INTEGER_LITERAL:
2393 case FLOATING_POINT_LITERAL:
2394 case STRING_LITERAL:
2398 switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
2414 case INTEGER_LITERAL:
2415 case FLOATING_POINT_LITERAL:
2416 case STRING_LITERAL:
2420 expression = Expression();
2431 expression = Type();
2434 jj_la1[68] = jj_gen;
2435 jj_consume_token(-1);
2436 throw new ParseException();
2440 jj_la1[69] = jj_gen;
2444 jj_consume_token(RBRACKET);
2445 } catch (ParseException e) {
2446 errorMessage = "']' expected";
2448 errorStart = SimpleCharStream.getPosition() - e.currentToken.next.image.length() + 1;
2449 errorEnd = SimpleCharStream.getPosition() + 1;
2450 {if (true) throw e;}
2452 {if (true) return new ArrayDeclarator(prefix,expression,SimpleCharStream.getPosition());}
2455 jj_la1[70] = jj_gen;
2456 jj_consume_token(-1);
2457 throw new ParseException();
2459 throw new Error("Missing return statement in function");
2462 static final public Literal Literal() throws ParseException {
2465 switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
2466 case INTEGER_LITERAL:
2467 token = jj_consume_token(INTEGER_LITERAL);
2468 pos = SimpleCharStream.getPosition();
2469 {if (true) return new NumberLiteral(token.image.toCharArray(),pos-token.image.length(),pos);}
2471 case FLOATING_POINT_LITERAL:
2472 token = jj_consume_token(FLOATING_POINT_LITERAL);
2473 pos = SimpleCharStream.getPosition();
2474 {if (true) return new NumberLiteral(token.image.toCharArray(),pos-token.image.length(),pos);}
2476 case STRING_LITERAL:
2477 token = jj_consume_token(STRING_LITERAL);
2478 pos = SimpleCharStream.getPosition();
2479 {if (true) return new StringLiteral(token.image.toCharArray(),pos-token.image.length());}
2482 jj_consume_token(TRUE);
2483 pos = SimpleCharStream.getPosition();
2484 {if (true) return new TrueLiteral(pos-4,pos);}
2487 jj_consume_token(FALSE);
2488 pos = SimpleCharStream.getPosition();
2489 {if (true) return new FalseLiteral(pos-4,pos);}
2492 jj_consume_token(NULL);
2493 pos = SimpleCharStream.getPosition();
2494 {if (true) return new NullLiteral(pos-4,pos);}
2497 jj_la1[71] = jj_gen;
2498 jj_consume_token(-1);
2499 throw new ParseException();
2501 throw new Error("Missing return statement in function");
2504 static final public FunctionCall Arguments(final Expression func) throws ParseException {
2505 Expression[] args = null;
2506 jj_consume_token(LPAREN);
2507 switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
2523 case INTEGER_LITERAL:
2524 case FLOATING_POINT_LITERAL:
2525 case STRING_LITERAL:
2529 args = ArgumentList();
2532 jj_la1[72] = jj_gen;
2536 jj_consume_token(RPAREN);
2537 } catch (ParseException e) {
2538 errorMessage = "unexpected token : '"+ e.currentToken.next.image +"', ')' expected to close the argument list";
2540 errorStart = SimpleCharStream.getPosition() - e.currentToken.next.image.length() + 1;
2541 errorEnd = SimpleCharStream.getPosition() + 1;
2542 {if (true) throw e;}
2544 {if (true) return new FunctionCall(func,args,SimpleCharStream.getPosition());}
2545 throw new Error("Missing return statement in function");
2549 * An argument list is a list of arguments separated by comma :
2550 * argumentDeclaration() (, argumentDeclaration)*
2551 * @return an array of arguments
2553 static final public Expression[] ArgumentList() throws ParseException {
2555 final ArrayList list = new ArrayList();
2560 switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
2565 jj_la1[73] = jj_gen;
2568 jj_consume_token(COMMA);
2572 } catch (ParseException e) {
2573 errorMessage = "unexpected token : '"+ e.currentToken.next.image +"'. An expression expected after a comma in argument list";
2575 errorStart = SimpleCharStream.getPosition() - e.currentToken.next.image.length() + 1;
2576 errorEnd = SimpleCharStream.getPosition() + 1;
2577 {if (true) throw e;}
2580 final Expression[] arguments = new Expression[list.size()];
2581 list.toArray(arguments);
2582 {if (true) return arguments;}
2583 throw new Error("Missing return statement in function");
2587 * A Statement without break.
2588 * @return a statement
2590 static final public Statement StatementNoBreak() throws ParseException {
2591 final Statement statement;
2594 statement = expressionStatement();
2595 {if (true) return statement;}
2597 switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
2599 statement = LabeledStatement();
2600 {if (true) return statement;}
2603 statement = Block();
2604 {if (true) return statement;}
2607 statement = EmptyStatement();
2608 {if (true) return statement;}
2611 statement = SwitchStatement();
2612 {if (true) return statement;}
2615 statement = IfStatement();
2616 {if (true) return statement;}
2619 statement = WhileStatement();
2620 {if (true) return statement;}
2623 statement = DoStatement();
2624 {if (true) return statement;}
2627 statement = ForStatement();
2628 {if (true) return statement;}
2631 statement = ForeachStatement();
2632 {if (true) return statement;}
2635 statement = ContinueStatement();
2636 {if (true) return statement;}
2639 statement = ReturnStatement();
2640 {if (true) return statement;}
2643 statement = EchoStatement();
2644 {if (true) return statement;}
2651 switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
2653 token = jj_consume_token(AT);
2656 jj_la1[74] = jj_gen;
2659 statement = IncludeStatement();
2660 if (token != null) {
2661 ((InclusionStatement)statement).silent = true;
2663 {if (true) return statement;}
2666 statement = StaticStatement();
2667 {if (true) return statement;}
2670 statement = GlobalStatement();
2671 {if (true) return statement;}
2674 statement = defineStatement();
2675 currentSegment.add((Outlineable)statement);{if (true) return statement;}
2678 jj_la1[75] = jj_gen;
2679 jj_consume_token(-1);
2680 throw new ParseException();
2683 throw new Error("Missing return statement in function");
2687 * A statement expression.
2689 * @return an expression
2691 static final public Statement expressionStatement() throws ParseException {
2692 final Statement statement;
2693 statement = Expression();
2695 jj_consume_token(SEMICOLON);
2696 } catch (ParseException e) {
2697 if (e.currentToken.next.kind != PHPParserConstants.PHPEND) {
2698 errorMessage = "unexpected token : '"+ e.currentToken.next.image +"'. A ';' was expected";
2700 errorStart = SimpleCharStream.getPosition() - e.currentToken.next.image.length() + 1;
2701 errorEnd = SimpleCharStream.getPosition() + 1;
2702 {if (true) throw e;}
2705 {if (true) return statement;}
2706 throw new Error("Missing return statement in function");
2709 static final public Define defineStatement() throws ParseException {
2710 final int start = SimpleCharStream.getPosition();
2711 Expression defineName,defineValue;
2712 jj_consume_token(DEFINE);
2714 jj_consume_token(LPAREN);
2715 } catch (ParseException e) {
2716 errorMessage = "unexpected token : '"+ e.currentToken.next.image +"', '(' expected";
2718 errorStart = SimpleCharStream.getPosition() - e.currentToken.next.image.length() + 1;
2719 errorEnd = SimpleCharStream.getPosition() + 1;
2720 processParseException(e);
2723 defineName = Expression();
2724 } catch (ParseException e) {
2725 errorMessage = "unexpected token : '"+ e.currentToken.next.image +"', expression expected";
2727 errorStart = SimpleCharStream.getPosition() - e.currentToken.next.image.length() + 1;
2728 errorEnd = SimpleCharStream.getPosition() + 1;
2729 {if (true) throw e;}
2732 jj_consume_token(COMMA);
2733 } catch (ParseException e) {
2734 errorMessage = "unexpected token : '"+ e.currentToken.next.image +"', ',' expected";
2736 errorStart = SimpleCharStream.getPosition() - e.currentToken.next.image.length() + 1;
2737 errorEnd = SimpleCharStream.getPosition() + 1;
2738 processParseException(e);
2741 defineValue = Expression();
2742 } catch (ParseException e) {
2743 errorMessage = "unexpected token : '"+ e.currentToken.next.image +"', expression expected";
2745 errorStart = SimpleCharStream.getPosition() - e.currentToken.next.image.length() + 1;
2746 errorEnd = SimpleCharStream.getPosition() + 1;
2747 {if (true) throw e;}
2750 jj_consume_token(RPAREN);
2751 } catch (ParseException e) {
2752 errorMessage = "unexpected token : '"+ e.currentToken.next.image +"', ')' expected";
2754 errorStart = SimpleCharStream.getPosition() - e.currentToken.next.image.length() + 1;
2755 errorEnd = SimpleCharStream.getPosition() + 1;
2756 processParseException(e);
2758 {if (true) return new Define(currentSegment,
2762 SimpleCharStream.getPosition());}
2763 throw new Error("Missing return statement in function");
2767 * A Normal statement.
2769 static final public Statement Statement() throws ParseException {
2770 final Statement statement;
2771 switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
2803 case INTEGER_LITERAL:
2804 case FLOATING_POINT_LITERAL:
2805 case STRING_LITERAL:
2811 statement = StatementNoBreak();
2812 {if (true) return statement;}
2815 statement = BreakStatement();
2816 {if (true) return statement;}
2819 jj_la1[76] = jj_gen;
2820 jj_consume_token(-1);
2821 throw new ParseException();
2823 throw new Error("Missing return statement in function");
2827 * An html block inside a php syntax.
2829 static final public HTMLBlock htmlBlock() throws ParseException {
2830 final int startIndex = nodePtr;
2831 final AstNode[] blockNodes;
2833 jj_consume_token(PHPEND);
2836 switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
2841 jj_la1[77] = jj_gen;
2847 switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
2849 jj_consume_token(PHPSTARTLONG);
2852 jj_consume_token(PHPSTARTSHORT);
2855 jj_la1[78] = jj_gen;
2856 jj_consume_token(-1);
2857 throw new ParseException();
2859 } catch (ParseException e) {
2860 errorMessage = "unexpected end of file , '<?php' expected";
2862 errorStart = SimpleCharStream.getPosition();
2863 errorEnd = SimpleCharStream.getPosition();
2864 {if (true) throw e;}
2866 nbNodes = nodePtr - startIndex;
2867 blockNodes = new AstNode[nbNodes];
2868 System.arraycopy(nodes,startIndex,blockNodes,0,nbNodes);
2869 nodePtr = startIndex;
2870 {if (true) return new HTMLBlock(blockNodes);}
2871 throw new Error("Missing return statement in function");
2875 * An include statement. It's "include" an expression;
2877 static final public InclusionStatement IncludeStatement() throws ParseException {
2878 final Expression expr;
2880 final int pos = SimpleCharStream.getPosition();
2881 final InclusionStatement inclusionStatement;
2882 switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
2884 jj_consume_token(REQUIRE);
2885 keyword = InclusionStatement.REQUIRE;
2888 jj_consume_token(REQUIRE_ONCE);
2889 keyword = InclusionStatement.REQUIRE_ONCE;
2892 jj_consume_token(INCLUDE);
2893 keyword = InclusionStatement.INCLUDE;
2896 jj_consume_token(INCLUDE_ONCE);
2897 keyword = InclusionStatement.INCLUDE_ONCE;
2900 jj_la1[79] = jj_gen;
2901 jj_consume_token(-1);
2902 throw new ParseException();
2905 expr = Expression();
2906 } catch (ParseException e) {
2907 if (errorMessage != null) {
2908 {if (true) throw e;}
2910 errorMessage = "unexpected token '"+ e.currentToken.next.image+"', expression expected";
2912 errorStart = SimpleCharStream.getPosition() - e.currentToken.next.image.length() + 1;
2913 errorEnd = SimpleCharStream.getPosition() + 1;
2914 {if (true) throw e;}
2916 inclusionStatement = new InclusionStatement(currentSegment,
2920 currentSegment.add(inclusionStatement);
2922 jj_consume_token(SEMICOLON);
2923 } catch (ParseException e) {
2924 errorMessage = "unexpected token : '"+ e.currentToken.next.image +"'. A ';' was expected";
2926 errorStart = SimpleCharStream.getPosition() - e.currentToken.next.image.length() + 1;
2927 errorEnd = SimpleCharStream.getPosition() + 1;
2928 {if (true) throw e;}
2930 {if (true) return inclusionStatement;}
2931 throw new Error("Missing return statement in function");
2934 static final public PrintExpression PrintExpression() throws ParseException {
2935 final Expression expr;
2936 final int pos = SimpleCharStream.getPosition();
2937 jj_consume_token(PRINT);
2938 expr = Expression();
2939 {if (true) return new PrintExpression(expr,pos,SimpleCharStream.getPosition());}
2940 throw new Error("Missing return statement in function");
2943 static final public ListExpression ListExpression() throws ParseException {
2945 final Expression expression;
2946 final ArrayList list = new ArrayList();
2947 final int pos = SimpleCharStream.getPosition();
2948 jj_consume_token(LIST);
2950 jj_consume_token(LPAREN);
2951 } catch (ParseException e) {
2952 errorMessage = "unexpected token : '"+ e.currentToken.next.image +"', '(' expected";
2954 errorStart = SimpleCharStream.getPosition() - e.currentToken.next.image.length() + 1;
2955 errorEnd = SimpleCharStream.getPosition() + 1;
2956 {if (true) throw e;}
2958 switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
2961 expr = VariableDeclaratorId();
2965 jj_la1[80] = jj_gen;
2968 if (expr == null) list.add(null);
2971 switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
2976 jj_la1[81] = jj_gen;
2980 jj_consume_token(COMMA);
2981 } catch (ParseException e) {
2982 errorMessage = "unexpected token : '"+ e.currentToken.next.image +"', ',' expected";
2984 errorStart = SimpleCharStream.getPosition() - e.currentToken.next.image.length() + 1;
2985 errorEnd = SimpleCharStream.getPosition() + 1;
2986 {if (true) throw e;}
2988 switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
2991 expr = VariableDeclaratorId();
2995 jj_la1[82] = jj_gen;
3000 jj_consume_token(RPAREN);
3001 } catch (ParseException e) {
3002 errorMessage = "unexpected token : '"+ e.currentToken.next.image +"', ')' expected";
3004 errorStart = SimpleCharStream.getPosition() - e.currentToken.next.image.length() + 1;
3005 errorEnd = SimpleCharStream.getPosition() + 1;
3006 {if (true) throw e;}
3008 switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
3010 jj_consume_token(ASSIGN);
3011 expression = Expression();
3012 final String[] strings = new String[list.size()];
3013 list.toArray(strings);
3014 {if (true) return new ListExpression(strings,
3017 SimpleCharStream.getPosition());}
3020 jj_la1[83] = jj_gen;
3023 final String[] strings = new String[list.size()];
3024 list.toArray(strings);
3025 {if (true) return new ListExpression(strings,pos,SimpleCharStream.getPosition());}
3026 throw new Error("Missing return statement in function");
3030 * An echo statement.
3031 * echo anyexpression (, otherexpression)*
3033 static final public EchoStatement EchoStatement() throws ParseException {
3034 final ArrayList expressions = new ArrayList();
3036 final int pos = SimpleCharStream.getPosition();
3037 jj_consume_token(ECHO);
3038 expr = Expression();
3039 expressions.add(expr);
3042 switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
3047 jj_la1[84] = jj_gen;
3050 jj_consume_token(COMMA);
3051 expr = Expression();
3052 expressions.add(expr);
3055 jj_consume_token(SEMICOLON);
3056 } catch (ParseException e) {
3057 if (e.currentToken.next.kind != 4) {
3058 errorMessage = "';' expected after 'echo' statement";
3060 errorStart = SimpleCharStream.getPosition() - e.currentToken.next.image.length() + 1;
3061 errorEnd = SimpleCharStream.getPosition() + 1;
3062 {if (true) throw e;}
3065 final Expression[] exprs = new Expression[expressions.size()];
3066 expressions.toArray(exprs);
3067 {if (true) return new EchoStatement(exprs,pos);}
3068 throw new Error("Missing return statement in function");
3071 static final public GlobalStatement GlobalStatement() throws ParseException {
3072 final int pos = SimpleCharStream.getPosition();
3074 final ArrayList vars = new ArrayList();
3075 final GlobalStatement global;
3076 jj_consume_token(GLOBAL);
3077 expr = VariableDeclaratorId();
3081 switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
3086 jj_la1[85] = jj_gen;
3089 jj_consume_token(COMMA);
3090 expr = VariableDeclaratorId();
3094 jj_consume_token(SEMICOLON);
3095 final String[] strings = new String[vars.size()];
3096 vars.toArray(strings);
3097 global = new GlobalStatement(currentSegment,
3100 SimpleCharStream.getPosition());
3101 currentSegment.add(global);
3102 {if (true) return global;}
3103 } catch (ParseException e) {
3104 errorMessage = "unexpected token : '"+ e.currentToken.next.image +"'. a ';' was expected";
3106 errorStart = SimpleCharStream.getPosition() - e.currentToken.next.image.length() + 1;
3107 errorEnd = SimpleCharStream.getPosition() + 1;
3108 {if (true) throw e;}
3110 throw new Error("Missing return statement in function");
3113 static final public StaticStatement StaticStatement() throws ParseException {
3114 final int pos = SimpleCharStream.getPosition();
3115 final ArrayList vars = new ArrayList();
3116 VariableDeclaration expr;
3117 jj_consume_token(STATIC);
3118 expr = VariableDeclarator();
3119 vars.add(new String(expr.name()));
3122 switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
3127 jj_la1[86] = jj_gen;
3130 jj_consume_token(COMMA);
3131 expr = VariableDeclarator();
3132 vars.add(new String(expr.name()));
3135 jj_consume_token(SEMICOLON);
3136 final String[] strings = new String[vars.size()];
3137 vars.toArray(strings);
3138 {if (true) return new StaticStatement(strings,
3140 SimpleCharStream.getPosition());}
3141 } catch (ParseException e) {
3142 errorMessage = "unexpected token : '"+ e.currentToken.next.image +"'. a ';' was expected";
3144 errorStart = SimpleCharStream.getPosition() - e.currentToken.next.image.length() + 1;
3145 errorEnd = SimpleCharStream.getPosition() + 1;
3146 {if (true) throw e;}
3148 throw new Error("Missing return statement in function");
3151 static final public LabeledStatement LabeledStatement() throws ParseException {
3152 final int pos = SimpleCharStream.getPosition();
3154 final Statement statement;
3155 label = jj_consume_token(IDENTIFIER);
3156 jj_consume_token(COLON);
3157 statement = Statement();
3158 {if (true) return new LabeledStatement(label.image.toCharArray(),statement,pos,SimpleCharStream.getPosition());}
3159 throw new Error("Missing return statement in function");
3169 static final public Block Block() throws ParseException {
3170 final int pos = SimpleCharStream.getPosition();
3171 final ArrayList list = new ArrayList();
3172 Statement statement;
3174 jj_consume_token(LBRACE);
3175 } catch (ParseException e) {
3176 errorMessage = "'{' expected";
3178 errorStart = SimpleCharStream.getPosition() - e.currentToken.next.image.length() + 1;
3179 errorEnd = SimpleCharStream.getPosition() + 1;
3180 {if (true) throw e;}
3184 switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
3220 case INTEGER_LITERAL:
3221 case FLOATING_POINT_LITERAL:
3222 case STRING_LITERAL:
3231 jj_la1[87] = jj_gen;
3234 switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
3269 case INTEGER_LITERAL:
3270 case FLOATING_POINT_LITERAL:
3271 case STRING_LITERAL:
3277 statement = BlockStatement();
3278 list.add(statement);
3281 statement = htmlBlock();
3282 list.add(statement);
3285 jj_la1[88] = jj_gen;
3286 jj_consume_token(-1);
3287 throw new ParseException();
3291 jj_consume_token(RBRACE);
3292 } catch (ParseException e) {
3293 errorMessage = "unexpected token : '"+ e.currentToken.image +"', '}' expected";
3295 errorStart = SimpleCharStream.getPosition() - e.currentToken.next.image.length() + 1;
3296 errorEnd = SimpleCharStream.getPosition() + 1;
3297 {if (true) throw e;}
3299 final Statement[] statements = new Statement[list.size()];
3300 list.toArray(statements);
3301 {if (true) return new Block(statements,pos,SimpleCharStream.getPosition());}
3302 throw new Error("Missing return statement in function");
3305 static final public Statement BlockStatement() throws ParseException {
3306 final Statement statement;
3307 switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
3340 case INTEGER_LITERAL:
3341 case FLOATING_POINT_LITERAL:
3342 case STRING_LITERAL:
3348 statement = Statement();
3349 if (phpDocument == currentSegment) pushOnAstNodes(statement);
3350 {if (true) return statement;}
3353 statement = ClassDeclaration();
3354 {if (true) return statement;}
3357 statement = MethodDeclaration();
3358 if (phpDocument == currentSegment) pushOnAstNodes(statement);
3359 currentSegment.add((MethodDeclaration) statement);
3360 ((MethodDeclaration) statement).analyzeCode();
3361 {if (true) return statement;}
3364 jj_la1[89] = jj_gen;
3365 jj_consume_token(-1);
3366 throw new ParseException();
3368 throw new Error("Missing return statement in function");
3372 * A Block statement that will not contain any 'break'
3374 static final public Statement BlockStatementNoBreak() throws ParseException {
3375 final Statement statement;
3376 switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
3408 case INTEGER_LITERAL:
3409 case FLOATING_POINT_LITERAL:
3410 case STRING_LITERAL:
3416 statement = StatementNoBreak();
3417 {if (true) return statement;}
3420 statement = ClassDeclaration();
3421 {if (true) return statement;}
3424 statement = MethodDeclaration();
3425 currentSegment.add((MethodDeclaration) statement);
3426 ((MethodDeclaration) statement).analyzeCode();
3427 {if (true) return statement;}
3430 jj_la1[90] = jj_gen;
3431 jj_consume_token(-1);
3432 throw new ParseException();
3434 throw new Error("Missing return statement in function");
3438 * used only by ForInit()
3440 static final public VariableDeclaration[] LocalVariableDeclaration() throws ParseException {
3441 final ArrayList list = new ArrayList();
3442 VariableDeclaration var;
3443 var = LocalVariableDeclarator();
3447 switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
3452 jj_la1[91] = jj_gen;
3455 jj_consume_token(COMMA);
3456 var = LocalVariableDeclarator();
3459 final VariableDeclaration[] vars = new VariableDeclaration[list.size()];
3461 {if (true) return vars;}
3462 throw new Error("Missing return statement in function");
3466 * used only by LocalVariableDeclaration().
3468 static final public VariableDeclaration LocalVariableDeclarator() throws ParseException {
3469 final String varName;
3470 Expression initializer = null;
3471 final int pos = SimpleCharStream.getPosition();
3472 varName = VariableDeclaratorId();
3473 switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
3475 jj_consume_token(ASSIGN);
3476 initializer = Expression();
3479 jj_la1[92] = jj_gen;
3482 if (initializer == null) {
3483 {if (true) return new VariableDeclaration(currentSegment,
3484 new Variable(varName.toCharArray(),SimpleCharStream.getPosition()-varName.length(),SimpleCharStream.getPosition()),
3486 SimpleCharStream.getPosition());}
3488 {if (true) return new VariableDeclaration(currentSegment,
3489 new Variable(varName.toCharArray(),SimpleCharStream.getPosition()-varName.length(),SimpleCharStream.getPosition()),
3491 VariableDeclaration.EQUAL,
3493 throw new Error("Missing return statement in function");
3496 static final public EmptyStatement EmptyStatement() throws ParseException {
3498 jj_consume_token(SEMICOLON);
3499 pos = SimpleCharStream.getPosition();
3500 {if (true) return new EmptyStatement(pos-1,pos);}
3501 throw new Error("Missing return statement in function");
3505 * used only by StatementExpressionList() which is used only by ForInit() and ForStatement()
3507 static final public Expression StatementExpression() throws ParseException {
3508 final Expression expr,expr2;
3510 switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
3513 expr = PreIncDecExpression();
3514 {if (true) return expr;}
3521 expr = PrimaryExpression();
3522 switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
3525 switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
3527 jj_consume_token(PLUS_PLUS);
3528 {if (true) return new PostfixedUnaryExpression(expr,
3529 OperatorIds.PLUS_PLUS,
3530 SimpleCharStream.getPosition());}
3533 jj_consume_token(MINUS_MINUS);
3534 {if (true) return new PostfixedUnaryExpression(expr,
3535 OperatorIds.MINUS_MINUS,
3536 SimpleCharStream.getPosition());}
3539 jj_la1[93] = jj_gen;
3540 jj_consume_token(-1);
3541 throw new ParseException();
3545 jj_la1[94] = jj_gen;
3548 {if (true) return expr;}
3551 jj_la1[95] = jj_gen;
3552 jj_consume_token(-1);
3553 throw new ParseException();
3555 throw new Error("Missing return statement in function");
3558 static final public SwitchStatement SwitchStatement() throws ParseException {
3559 final Expression variable;
3560 final AbstractCase[] cases;
3561 final int pos = SimpleCharStream.getPosition();
3562 jj_consume_token(SWITCH);
3564 jj_consume_token(LPAREN);
3565 } catch (ParseException e) {
3566 errorMessage = "'(' expected after 'switch'";
3568 errorStart = SimpleCharStream.getPosition() - e.currentToken.next.image.length() + 1;
3569 errorEnd = SimpleCharStream.getPosition() + 1;
3570 {if (true) throw e;}
3573 variable = Expression();
3574 } catch (ParseException e) {
3575 if (errorMessage != null) {
3576 {if (true) throw e;}
3578 errorMessage = "expression expected";
3580 errorStart = SimpleCharStream.getPosition() - e.currentToken.next.image.length() + 1;
3581 errorEnd = SimpleCharStream.getPosition() + 1;
3582 {if (true) throw e;}
3585 jj_consume_token(RPAREN);
3586 } catch (ParseException e) {
3587 errorMessage = "')' expected";
3589 errorStart = SimpleCharStream.getPosition() - e.currentToken.next.image.length() + 1;
3590 errorEnd = SimpleCharStream.getPosition() + 1;
3591 {if (true) throw e;}
3593 switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
3595 cases = switchStatementBrace();
3598 cases = switchStatementColon(pos, pos + 6);
3601 jj_la1[96] = jj_gen;
3602 jj_consume_token(-1);
3603 throw new ParseException();
3605 {if (true) return new SwitchStatement(variable,cases,pos,SimpleCharStream.getPosition());}
3606 throw new Error("Missing return statement in function");
3609 static final public AbstractCase[] switchStatementBrace() throws ParseException {
3611 final ArrayList cases = new ArrayList();
3612 jj_consume_token(LBRACE);
3615 switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
3621 jj_la1[97] = jj_gen;
3624 cas = switchLabel0();
3628 jj_consume_token(RBRACE);
3629 final AbstractCase[] abcase = new AbstractCase[cases.size()];
3630 cases.toArray(abcase);
3631 {if (true) return abcase;}
3632 } catch (ParseException e) {
3633 errorMessage = "'}' expected";
3635 errorStart = SimpleCharStream.getPosition() - e.currentToken.next.image.length() + 1;
3636 errorEnd = SimpleCharStream.getPosition() + 1;
3637 {if (true) throw e;}
3639 throw new Error("Missing return statement in function");
3643 * A Switch statement with : ... endswitch;
3644 * @param start the begin offset of the switch
3645 * @param end the end offset of the switch
3647 static final public AbstractCase[] switchStatementColon(final int start, final int end) throws ParseException {
3649 final ArrayList cases = new ArrayList();
3650 jj_consume_token(COLON);
3652 setMarker(fileToParse,
3653 "Ugly syntax detected, you should switch () {...} instead of switch (): ... enswitch;",
3657 "Line " + token.beginLine);
3658 } catch (CoreException e) {
3659 PHPeclipsePlugin.log(e);
3663 switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
3669 jj_la1[98] = jj_gen;
3672 cas = switchLabel0();
3676 jj_consume_token(ENDSWITCH);
3677 } catch (ParseException e) {
3678 errorMessage = "'endswitch' expected";
3680 errorStart = SimpleCharStream.getPosition() - e.currentToken.next.image.length() + 1;
3681 errorEnd = SimpleCharStream.getPosition() + 1;
3682 {if (true) throw e;}
3685 jj_consume_token(SEMICOLON);
3686 final AbstractCase[] abcase = new AbstractCase[cases.size()];
3687 cases.toArray(abcase);
3688 {if (true) return abcase;}
3689 } catch (ParseException e) {
3690 errorMessage = "';' expected after 'endswitch' keyword";
3692 errorStart = SimpleCharStream.getPosition() - e.currentToken.next.image.length() + 1;
3693 errorEnd = SimpleCharStream.getPosition() + 1;
3694 {if (true) throw e;}
3696 throw new Error("Missing return statement in function");
3699 static final public AbstractCase switchLabel0() throws ParseException {
3700 final Expression expr;
3701 Statement statement;
3702 final ArrayList stmts = new ArrayList();
3703 final int pos = SimpleCharStream.getPosition();
3704 expr = SwitchLabel();
3707 switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
3742 case INTEGER_LITERAL:
3743 case FLOATING_POINT_LITERAL:
3744 case STRING_LITERAL:
3753 jj_la1[99] = jj_gen;
3756 switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
3790 case INTEGER_LITERAL:
3791 case FLOATING_POINT_LITERAL:
3792 case STRING_LITERAL:
3798 statement = BlockStatementNoBreak();
3799 stmts.add(statement);
3802 statement = htmlBlock();
3803 stmts.add(statement);
3806 jj_la1[100] = jj_gen;
3807 jj_consume_token(-1);
3808 throw new ParseException();
3811 switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
3813 statement = BreakStatement();
3814 stmts.add(statement);
3817 jj_la1[101] = jj_gen;
3820 final Statement[] stmtsArray = new Statement[stmts.size()];
3821 stmts.toArray(stmtsArray);
3822 if (expr == null) {//it's a default
3823 {if (true) return new DefaultCase(stmtsArray,pos,SimpleCharStream.getPosition());}
3825 {if (true) return new Case(expr,stmtsArray,pos,SimpleCharStream.getPosition());}
3826 throw new Error("Missing return statement in function");
3831 * case Expression() :
3833 * @return the if it was a case and null if not
3835 static final public Expression SwitchLabel() throws ParseException {
3836 final Expression expr;
3837 switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
3839 token = jj_consume_token(CASE);
3841 expr = Expression();
3842 } catch (ParseException e) {
3843 if (errorMessage != null) {if (true) throw e;}
3844 errorMessage = "expression expected after 'case' keyword";
3846 errorStart = SimpleCharStream.getPosition() - e.currentToken.next.image.length() + 1;
3847 errorEnd = SimpleCharStream.getPosition() + 1;
3848 {if (true) throw e;}
3851 jj_consume_token(COLON);
3852 {if (true) return expr;}
3853 } catch (ParseException e) {
3854 errorMessage = "':' expected after case expression";
3856 errorStart = SimpleCharStream.getPosition() - e.currentToken.next.image.length() + 1;
3857 errorEnd = SimpleCharStream.getPosition() + 1;
3858 {if (true) throw e;}
3862 token = jj_consume_token(_DEFAULT);
3864 jj_consume_token(COLON);
3865 {if (true) return null;}
3866 } catch (ParseException e) {
3867 errorMessage = "':' expected after 'default' keyword";
3869 errorStart = SimpleCharStream.getPosition() - e.currentToken.next.image.length() + 1;
3870 errorEnd = SimpleCharStream.getPosition() + 1;
3871 {if (true) throw e;}
3875 jj_la1[102] = jj_gen;
3876 jj_consume_token(-1);
3877 throw new ParseException();
3879 throw new Error("Missing return statement in function");
3882 static final public Break BreakStatement() throws ParseException {
3883 Expression expression = null;
3884 final int start = SimpleCharStream.getPosition();
3885 jj_consume_token(BREAK);
3886 switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
3902 case INTEGER_LITERAL:
3903 case FLOATING_POINT_LITERAL:
3904 case STRING_LITERAL:
3908 expression = Expression();
3911 jj_la1[103] = jj_gen;
3915 jj_consume_token(SEMICOLON);
3916 } catch (ParseException e) {
3917 errorMessage = "';' expected after 'break' keyword";
3919 errorStart = SimpleCharStream.getPosition() - e.currentToken.next.image.length() + 1;
3920 errorEnd = SimpleCharStream.getPosition() + 1;
3921 {if (true) throw e;}
3923 {if (true) return new Break(expression, start, SimpleCharStream.getPosition());}
3924 throw new Error("Missing return statement in function");
3927 static final public IfStatement IfStatement() throws ParseException {
3928 final int pos = SimpleCharStream.getPosition();
3929 final Expression condition;
3930 final IfStatement ifStatement;
3931 jj_consume_token(IF);
3932 condition = Condition("if");
3933 ifStatement = IfStatement0(condition, pos,pos+2);
3934 {if (true) return ifStatement;}
3935 throw new Error("Missing return statement in function");
3938 static final public Expression Condition(final String keyword) throws ParseException {
3939 final Expression condition;
3941 jj_consume_token(LPAREN);
3942 } catch (ParseException e) {
3943 errorMessage = "'(' expected after " + keyword + " keyword";
3945 errorStart = SimpleCharStream.getPosition() - e.currentToken.next.image.length();
3946 errorEnd = errorStart +1;
3947 processParseException(e);
3949 condition = Expression();
3951 jj_consume_token(RPAREN);
3952 } catch (ParseException e) {
3953 errorMessage = "')' expected after " + keyword + " keyword";
3955 errorStart = SimpleCharStream.getPosition() - e.currentToken.next.image.length() + 1;
3956 errorEnd = SimpleCharStream.getPosition() + 1;
3957 processParseException(e);
3959 {if (true) return condition;}
3960 throw new Error("Missing return statement in function");
3963 static final public IfStatement IfStatement0(final Expression condition, final int start,final int end) throws ParseException {
3964 Statement statement;
3965 final Statement stmt;
3966 final Statement[] statementsArray;
3967 ElseIf elseifStatement;
3968 Else elseStatement = null;
3969 final ArrayList stmts;
3970 final ArrayList elseIfList = new ArrayList();
3971 final ElseIf[] elseIfs;
3972 int pos = SimpleCharStream.getPosition();
3973 final int endStatements;
3974 switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
3976 jj_consume_token(COLON);
3977 stmts = new ArrayList();
3980 switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
4014 case INTEGER_LITERAL:
4015 case FLOATING_POINT_LITERAL:
4016 case STRING_LITERAL:
4025 jj_la1[104] = jj_gen;
4028 switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
4061 case INTEGER_LITERAL:
4062 case FLOATING_POINT_LITERAL:
4063 case STRING_LITERAL:
4069 statement = Statement();
4070 stmts.add(statement);
4073 statement = htmlBlock();
4074 stmts.add(statement);
4077 jj_la1[105] = jj_gen;
4078 jj_consume_token(-1);
4079 throw new ParseException();
4082 endStatements = SimpleCharStream.getPosition();
4085 switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
4090 jj_la1[106] = jj_gen;
4093 elseifStatement = ElseIfStatementColon();
4094 elseIfList.add(elseifStatement);
4096 switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
4098 elseStatement = ElseStatementColon();
4101 jj_la1[107] = jj_gen;
4105 setMarker(fileToParse,
4106 "Ugly syntax detected, you should if () {...} instead of if (): ... endif;",
4110 "Line " + token.beginLine);
4111 } catch (CoreException e) {
4112 PHPeclipsePlugin.log(e);
4115 jj_consume_token(ENDIF);
4116 } catch (ParseException e) {
4117 errorMessage = "'endif' expected";
4119 errorStart = SimpleCharStream.getPosition() - e.currentToken.next.image.length() + 1;
4120 errorEnd = SimpleCharStream.getPosition() + 1;
4121 {if (true) throw e;}
4124 jj_consume_token(SEMICOLON);
4125 } catch (ParseException e) {
4126 errorMessage = "';' expected after 'endif' keyword";
4128 errorStart = SimpleCharStream.getPosition() - e.currentToken.next.image.length() + 1;
4129 errorEnd = SimpleCharStream.getPosition() + 1;
4130 {if (true) throw e;}
4132 elseIfs = new ElseIf[elseIfList.size()];
4133 elseIfList.toArray(elseIfs);
4134 if (stmts.size() == 1) {
4135 {if (true) return new IfStatement(condition,
4136 (Statement) stmts.get(0),
4140 SimpleCharStream.getPosition());}
4142 statementsArray = new Statement[stmts.size()];
4143 stmts.toArray(statementsArray);
4144 {if (true) return new IfStatement(condition,
4145 new Block(statementsArray,pos,endStatements),
4149 SimpleCharStream.getPosition());}
4185 case INTEGER_LITERAL:
4186 case FLOATING_POINT_LITERAL:
4187 case STRING_LITERAL:
4193 switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
4226 case INTEGER_LITERAL:
4227 case FLOATING_POINT_LITERAL:
4228 case STRING_LITERAL:
4240 jj_la1[108] = jj_gen;
4241 jj_consume_token(-1);
4242 throw new ParseException();
4246 switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
4251 jj_la1[109] = jj_gen;
4254 elseifStatement = ElseIfStatement();
4255 elseIfList.add(elseifStatement);
4257 switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
4259 jj_consume_token(ELSE);
4261 pos = SimpleCharStream.getPosition();
4262 statement = Statement();
4263 elseStatement = new Else(statement,pos,SimpleCharStream.getPosition());
4264 } catch (ParseException e) {
4265 if (errorMessage != null) {
4266 {if (true) throw e;}
4268 errorMessage = "unexpected token '"+e.currentToken.next.image+"', a statement was expected";
4270 errorStart = SimpleCharStream.getPosition() - e.currentToken.next.image.length() + 1;
4271 errorEnd = SimpleCharStream.getPosition() + 1;
4272 {if (true) throw e;}
4276 jj_la1[110] = jj_gen;
4279 elseIfs = new ElseIf[elseIfList.size()];
4280 elseIfList.toArray(elseIfs);
4281 {if (true) return new IfStatement(condition,
4286 SimpleCharStream.getPosition());}
4289 jj_la1[111] = jj_gen;
4290 jj_consume_token(-1);
4291 throw new ParseException();
4293 throw new Error("Missing return statement in function");
4296 static final public ElseIf ElseIfStatementColon() throws ParseException {
4297 final Expression condition;
4298 Statement statement;
4299 final ArrayList list = new ArrayList();
4300 final int pos = SimpleCharStream.getPosition();
4301 jj_consume_token(ELSEIF);
4302 condition = Condition("elseif");
4303 jj_consume_token(COLON);
4306 switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
4340 case INTEGER_LITERAL:
4341 case FLOATING_POINT_LITERAL:
4342 case STRING_LITERAL:
4351 jj_la1[112] = jj_gen;
4354 switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
4387 case INTEGER_LITERAL:
4388 case FLOATING_POINT_LITERAL:
4389 case STRING_LITERAL:
4395 statement = Statement();
4396 list.add(statement);
4399 statement = htmlBlock();
4400 list.add(statement);
4403 jj_la1[113] = jj_gen;
4404 jj_consume_token(-1);
4405 throw new ParseException();
4408 final Statement[] stmtsArray = new Statement[list.size()];
4409 list.toArray(stmtsArray);
4410 {if (true) return new ElseIf(condition,stmtsArray ,pos,SimpleCharStream.getPosition());}
4411 throw new Error("Missing return statement in function");
4414 static final public Else ElseStatementColon() throws ParseException {
4415 Statement statement;
4416 final ArrayList list = new ArrayList();
4417 final int pos = SimpleCharStream.getPosition();
4418 jj_consume_token(ELSE);
4419 jj_consume_token(COLON);
4422 switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
4456 case INTEGER_LITERAL:
4457 case FLOATING_POINT_LITERAL:
4458 case STRING_LITERAL:
4467 jj_la1[114] = jj_gen;
4470 switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
4503 case INTEGER_LITERAL:
4504 case FLOATING_POINT_LITERAL:
4505 case STRING_LITERAL:
4511 statement = Statement();
4512 list.add(statement);
4515 statement = htmlBlock();
4516 list.add(statement);
4519 jj_la1[115] = jj_gen;
4520 jj_consume_token(-1);
4521 throw new ParseException();
4524 final Statement[] stmtsArray = new Statement[list.size()];
4525 list.toArray(stmtsArray);
4526 {if (true) return new Else(stmtsArray,pos,SimpleCharStream.getPosition());}
4527 throw new Error("Missing return statement in function");
4530 static final public ElseIf ElseIfStatement() throws ParseException {
4531 final Expression condition;
4532 final Statement statement;
4533 final ArrayList list = new ArrayList();
4534 final int pos = SimpleCharStream.getPosition();
4535 jj_consume_token(ELSEIF);
4536 condition = Condition("elseif");
4537 statement = Statement();
4538 list.add(statement);/*todo:do better*/
4539 final Statement[] stmtsArray = new Statement[list.size()];
4540 list.toArray(stmtsArray);
4541 {if (true) return new ElseIf(condition,stmtsArray,pos,SimpleCharStream.getPosition());}
4542 throw new Error("Missing return statement in function");
4545 static final public WhileStatement WhileStatement() throws ParseException {
4546 final Expression condition;
4547 final Statement action;
4548 final int pos = SimpleCharStream.getPosition();
4549 jj_consume_token(WHILE);
4550 condition = Condition("while");
4551 action = WhileStatement0(pos,pos + 5);
4552 {if (true) return new WhileStatement(condition,action,pos,SimpleCharStream.getPosition());}
4553 throw new Error("Missing return statement in function");
4556 static final public Statement WhileStatement0(final int start, final int end) throws ParseException {
4557 Statement statement;
4558 final ArrayList stmts = new ArrayList();
4559 final int pos = SimpleCharStream.getPosition();
4560 switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
4562 jj_consume_token(COLON);
4565 switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
4598 case INTEGER_LITERAL:
4599 case FLOATING_POINT_LITERAL:
4600 case STRING_LITERAL:
4609 jj_la1[116] = jj_gen;
4612 statement = Statement();
4613 stmts.add(statement);
4616 setMarker(fileToParse,
4617 "Ugly syntax detected, you should while () {...} instead of while (): ... endwhile;",
4621 "Line " + token.beginLine);
4622 } catch (CoreException e) {
4623 PHPeclipsePlugin.log(e);
4626 jj_consume_token(ENDWHILE);
4627 } catch (ParseException e) {
4628 errorMessage = "'endwhile' expected";
4630 errorStart = SimpleCharStream.getPosition() - e.currentToken.next.image.length() + 1;
4631 errorEnd = SimpleCharStream.getPosition() + 1;
4632 {if (true) throw e;}
4635 jj_consume_token(SEMICOLON);
4636 final Statement[] stmtsArray = new Statement[stmts.size()];
4637 stmts.toArray(stmtsArray);
4638 {if (true) return new Block(stmtsArray,pos,SimpleCharStream.getPosition());}
4639 } catch (ParseException e) {
4640 errorMessage = "';' expected after 'endwhile' keyword";
4642 errorStart = SimpleCharStream.getPosition() - e.currentToken.next.image.length() + 1;
4643 errorEnd = SimpleCharStream.getPosition() + 1;
4644 {if (true) throw e;}
4679 case INTEGER_LITERAL:
4680 case FLOATING_POINT_LITERAL:
4681 case STRING_LITERAL:
4687 statement = Statement();
4688 {if (true) return statement;}
4691 jj_la1[117] = jj_gen;
4692 jj_consume_token(-1);
4693 throw new ParseException();
4695 throw new Error("Missing return statement in function");
4698 static final public DoStatement DoStatement() throws ParseException {
4699 final Statement action;
4700 final Expression condition;
4701 final int pos = SimpleCharStream.getPosition();
4702 jj_consume_token(DO);
4703 action = Statement();
4704 jj_consume_token(WHILE);
4705 condition = Condition("while");
4707 jj_consume_token(SEMICOLON);
4708 {if (true) return new DoStatement(condition,action,pos,SimpleCharStream.getPosition());}
4709 } catch (ParseException e) {
4710 errorMessage = "unexpected token : '"+ e.currentToken.next.image +"'. A ';' was expected";
4712 errorStart = SimpleCharStream.getPosition() - e.currentToken.next.image.length() + 1;
4713 errorEnd = SimpleCharStream.getPosition() + 1;
4714 {if (true) throw e;}
4716 throw new Error("Missing return statement in function");
4719 static final public ForeachStatement ForeachStatement() throws ParseException {
4720 Statement statement;
4721 Expression expression;
4722 final int pos = SimpleCharStream.getPosition();
4723 ArrayVariableDeclaration variable;
4724 jj_consume_token(FOREACH);
4726 jj_consume_token(LPAREN);
4727 } catch (ParseException e) {
4728 errorMessage = "'(' expected after 'foreach' keyword";
4730 errorStart = SimpleCharStream.getPosition() - e.currentToken.next.image.length() + 1;
4731 errorEnd = SimpleCharStream.getPosition() + 1;
4732 {if (true) throw e;}
4735 expression = Expression();
4736 } catch (ParseException e) {
4737 errorMessage = "variable expected";
4739 errorStart = SimpleCharStream.getPosition() - e.currentToken.next.image.length() + 1;
4740 errorEnd = SimpleCharStream.getPosition() + 1;
4741 {if (true) throw e;}
4744 jj_consume_token(AS);
4745 } catch (ParseException e) {
4746 errorMessage = "'as' expected";
4748 errorStart = SimpleCharStream.getPosition() - e.currentToken.next.image.length() + 1;
4749 errorEnd = SimpleCharStream.getPosition() + 1;
4750 {if (true) throw e;}
4753 variable = ArrayVariable();
4754 } catch (ParseException e) {
4755 errorMessage = "variable expected";
4757 errorStart = SimpleCharStream.getPosition() - e.currentToken.next.image.length() + 1;
4758 errorEnd = SimpleCharStream.getPosition() + 1;
4759 {if (true) throw e;}
4762 jj_consume_token(RPAREN);
4763 } catch (ParseException e) {
4764 errorMessage = "')' expected after 'foreach' keyword";
4766 errorStart = SimpleCharStream.getPosition() - e.currentToken.next.image.length() + 1;
4767 errorEnd = SimpleCharStream.getPosition() + 1;
4768 {if (true) throw e;}
4771 statement = Statement();
4772 } catch (ParseException e) {
4773 if (errorMessage != null) {if (true) throw e;}
4774 errorMessage = "statement expected";
4776 errorStart = SimpleCharStream.getPosition() - e.currentToken.next.image.length() + 1;
4777 errorEnd = SimpleCharStream.getPosition() + 1;
4778 {if (true) throw e;}
4780 {if (true) return new ForeachStatement(expression,
4784 SimpleCharStream.getPosition());}
4785 throw new Error("Missing return statement in function");
4788 static final public ForStatement ForStatement() throws ParseException {
4790 final int pos = SimpleCharStream.getPosition();
4791 Expression[] initializations = null;
4792 Expression condition = null;
4793 Expression[] increments = null;
4795 final ArrayList list = new ArrayList();
4796 final int startBlock, endBlock;
4797 token = jj_consume_token(FOR);
4799 jj_consume_token(LPAREN);
4800 } catch (ParseException e) {
4801 errorMessage = "'(' expected after 'for' keyword";
4803 errorStart = SimpleCharStream.getPosition() - e.currentToken.next.image.length() + 1;
4804 errorEnd = SimpleCharStream.getPosition() + 1;
4805 {if (true) throw e;}
4807 switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
4815 initializations = ForInit();
4818 jj_la1[118] = jj_gen;
4821 jj_consume_token(SEMICOLON);
4822 switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
4838 case INTEGER_LITERAL:
4839 case FLOATING_POINT_LITERAL:
4840 case STRING_LITERAL:
4844 condition = Expression();
4847 jj_la1[119] = jj_gen;
4850 jj_consume_token(SEMICOLON);
4851 switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
4859 increments = StatementExpressionList();
4862 jj_la1[120] = jj_gen;
4865 jj_consume_token(RPAREN);
4866 switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
4899 case INTEGER_LITERAL:
4900 case FLOATING_POINT_LITERAL:
4901 case STRING_LITERAL:
4907 action = Statement();
4908 {if (true) return new ForStatement(initializations,condition,increments,action,pos,SimpleCharStream.getPosition());}
4911 jj_consume_token(COLON);
4912 startBlock = SimpleCharStream.getPosition();
4915 switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
4948 case INTEGER_LITERAL:
4949 case FLOATING_POINT_LITERAL:
4950 case STRING_LITERAL:
4959 jj_la1[121] = jj_gen;
4962 action = Statement();
4966 setMarker(fileToParse,
4967 "Ugly syntax detected, you should for () {...} instead of for (): ... endfor;",
4969 pos+token.image.length(),
4971 "Line " + token.beginLine);
4972 } catch (CoreException e) {
4973 PHPeclipsePlugin.log(e);
4975 endBlock = SimpleCharStream.getPosition();
4977 jj_consume_token(ENDFOR);
4978 } catch (ParseException e) {
4979 errorMessage = "'endfor' expected";
4981 errorStart = SimpleCharStream.getPosition() - e.currentToken.next.image.length() + 1;
4982 errorEnd = SimpleCharStream.getPosition() + 1;
4983 {if (true) throw e;}
4986 jj_consume_token(SEMICOLON);
4987 final Statement[] stmtsArray = new Statement[list.size()];
4988 list.toArray(stmtsArray);
4989 {if (true) return new ForStatement(initializations,condition,increments,new Block(stmtsArray,startBlock,endBlock),pos,SimpleCharStream.getPosition());}
4990 } catch (ParseException e) {
4991 errorMessage = "';' expected after 'endfor' keyword";
4993 errorStart = SimpleCharStream.getPosition() - e.currentToken.next.image.length() + 1;
4994 errorEnd = SimpleCharStream.getPosition() + 1;
4995 {if (true) throw e;}
4999 jj_la1[122] = jj_gen;
5000 jj_consume_token(-1);
5001 throw new ParseException();
5003 throw new Error("Missing return statement in function");
5006 static final public Expression[] ForInit() throws ParseException {
5007 final Expression[] exprs;
5008 if (jj_2_5(2147483647)) {
5009 exprs = LocalVariableDeclaration();
5010 {if (true) return exprs;}
5012 switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
5020 exprs = StatementExpressionList();
5021 {if (true) return exprs;}
5024 jj_la1[123] = jj_gen;
5025 jj_consume_token(-1);
5026 throw new ParseException();
5029 throw new Error("Missing return statement in function");
5032 static final public Expression[] StatementExpressionList() throws ParseException {
5033 final ArrayList list = new ArrayList();
5034 final Expression expr;
5035 expr = StatementExpression();
5039 switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
5044 jj_la1[124] = jj_gen;
5047 jj_consume_token(COMMA);
5048 StatementExpression();
5051 final Expression[] exprsArray = new Expression[list.size()];
5052 list.toArray(exprsArray);
5053 {if (true) return exprsArray;}
5054 throw new Error("Missing return statement in function");
5057 static final public Continue ContinueStatement() throws ParseException {
5058 Expression expr = null;
5059 final int pos = SimpleCharStream.getPosition();
5060 jj_consume_token(CONTINUE);
5061 switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
5077 case INTEGER_LITERAL:
5078 case FLOATING_POINT_LITERAL:
5079 case STRING_LITERAL:
5083 expr = Expression();
5086 jj_la1[125] = jj_gen;
5090 jj_consume_token(SEMICOLON);
5091 {if (true) return new Continue(expr,pos,SimpleCharStream.getPosition());}
5092 } catch (ParseException e) {
5093 errorMessage = "';' expected after 'continue' statement";
5095 errorStart = SimpleCharStream.getPosition() - e.currentToken.next.image.length() + 1;
5096 errorEnd = SimpleCharStream.getPosition() + 1;
5097 {if (true) throw e;}
5099 throw new Error("Missing return statement in function");
5102 static final public ReturnStatement ReturnStatement() throws ParseException {
5103 Expression expr = null;
5104 final int pos = SimpleCharStream.getPosition();
5105 jj_consume_token(RETURN);
5106 switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
5122 case INTEGER_LITERAL:
5123 case FLOATING_POINT_LITERAL:
5124 case STRING_LITERAL:
5128 expr = Expression();
5131 jj_la1[126] = jj_gen;
5135 jj_consume_token(SEMICOLON);
5136 {if (true) return new ReturnStatement(expr,pos,SimpleCharStream.getPosition());}
5137 } catch (ParseException e) {
5138 errorMessage = "';' expected after 'return' statement";
5140 errorStart = SimpleCharStream.getPosition() - e.currentToken.next.image.length() + 1;
5141 errorEnd = SimpleCharStream.getPosition() + 1;
5142 {if (true) throw e;}
5144 throw new Error("Missing return statement in function");
5147 static final private boolean jj_2_1(int xla) {
5148 jj_la = xla; jj_lastpos = jj_scanpos = token;
5149 boolean retval = !jj_3_1();
5154 static final private boolean jj_2_2(int xla) {
5155 jj_la = xla; jj_lastpos = jj_scanpos = token;
5156 boolean retval = !jj_3_2();
5161 static final private boolean jj_2_3(int xla) {
5162 jj_la = xla; jj_lastpos = jj_scanpos = token;
5163 boolean retval = !jj_3_3();
5168 static final private boolean jj_2_4(int xla) {
5169 jj_la = xla; jj_lastpos = jj_scanpos = token;
5170 boolean retval = !jj_3_4();
5175 static final private boolean jj_2_5(int xla) {
5176 jj_la = xla; jj_lastpos = jj_scanpos = token;
5177 boolean retval = !jj_3_5();
5182 static final private boolean jj_3R_44() {
5183 if (jj_3R_49()) return true;
5184 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5188 if (jj_3R_50()) { jj_scanpos = xsp; break; }
5189 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5194 static final private boolean jj_3R_156() {
5195 if (jj_3R_153()) return true;
5196 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5200 static final private boolean jj_3R_155() {
5201 if (jj_scan_token(BANG)) return true;
5202 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5203 if (jj_3R_152()) return true;
5204 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5208 static final private boolean jj_3R_152() {
5215 if (jj_3R_156()) return true;
5216 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5217 } else if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5218 } else if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5222 static final private boolean jj_3R_154() {
5223 if (jj_scan_token(AT)) return true;
5224 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5225 if (jj_3R_152()) return true;
5226 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5230 static final private boolean jj_3R_43() {
5231 if (jj_3R_47()) return true;
5232 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5233 if (jj_scan_token(SEMICOLON)) return true;
5234 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5238 static final private boolean jj_3R_148() {
5239 if (jj_3R_152()) return true;
5240 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5244 static final private boolean jj_3R_143() {
5249 if (jj_3R_148()) return true;
5250 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5251 } else if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5255 static final private boolean jj_3R_147() {
5256 if (jj_scan_token(BIT_AND)) return true;
5257 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5258 if (jj_3R_153()) return true;
5259 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5263 static final private boolean jj_3R_151() {
5264 if (jj_scan_token(REMAINDER)) return true;
5265 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5269 static final private boolean jj_3R_150() {
5270 if (jj_scan_token(SLASH)) return true;
5271 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5275 static final private boolean jj_3R_149() {
5276 if (jj_scan_token(STAR)) return true;
5277 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5281 static final private boolean jj_3R_144() {
5288 if (jj_3R_151()) return true;
5289 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5290 } else if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5291 } else if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5292 if (jj_3R_143()) return true;
5293 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5297 static final private boolean jj_3_4() {
5298 if (jj_3R_43()) return true;
5299 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5303 static final private boolean jj_3R_138() {
5304 if (jj_3R_143()) return true;
5305 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5309 if (jj_3R_144()) { jj_scanpos = xsp; break; }
5310 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5315 static final private boolean jj_3R_146() {
5316 if (jj_scan_token(MINUS)) return true;
5317 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5321 static final private boolean jj_3R_145() {
5322 if (jj_scan_token(PLUS)) return true;
5323 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5327 static final private boolean jj_3R_139() {
5332 if (jj_3R_146()) return true;
5333 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5334 } else if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5335 if (jj_3R_138()) return true;
5336 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5340 static final private boolean jj_3_5() {
5341 if (jj_3R_44()) return true;
5342 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5346 static final private boolean jj_3R_132() {
5347 if (jj_3R_138()) return true;
5348 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5352 if (jj_3R_139()) { jj_scanpos = xsp; break; }
5353 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5358 static final private boolean jj_3R_208() {
5359 if (jj_scan_token(COMMA)) return true;
5360 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5361 if (jj_3R_47()) return true;
5362 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5366 static final private boolean jj_3R_142() {
5367 if (jj_scan_token(RUNSIGNEDSHIFT)) return true;
5368 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5372 static final private boolean jj_3R_207() {
5373 if (jj_3R_47()) return true;
5374 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5378 if (jj_3R_208()) { jj_scanpos = xsp; break; }
5379 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5384 static final private boolean jj_3R_141() {
5385 if (jj_scan_token(RSIGNEDSHIFT)) return true;
5386 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5390 static final private boolean jj_3R_140() {
5391 if (jj_scan_token(LSHIFT)) return true;
5392 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5396 static final private boolean jj_3R_133() {
5403 if (jj_3R_142()) return true;
5404 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5405 } else if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5406 } else if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5407 if (jj_3R_132()) return true;
5408 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5412 static final private boolean jj_3R_125() {
5413 if (jj_3R_132()) return true;
5414 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5418 if (jj_3R_133()) { jj_scanpos = xsp; break; }
5419 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5424 static final private boolean jj_3R_204() {
5425 if (jj_3R_207()) return true;
5426 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5430 static final private boolean jj_3R_206() {
5431 if (jj_scan_token(COMMA)) return true;
5432 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5436 static final private boolean jj_3R_137() {
5437 if (jj_scan_token(GE)) return true;
5438 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5442 static final private boolean jj_3R_136() {
5443 if (jj_scan_token(LE)) return true;
5444 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5448 static final private boolean jj_3R_135() {
5449 if (jj_scan_token(GT)) return true;
5450 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5454 static final private boolean jj_3_2() {
5455 if (jj_scan_token(COMMA)) return true;
5456 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5457 if (jj_3R_40()) return true;
5458 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5462 static final private boolean jj_3R_134() {
5463 if (jj_scan_token(LT)) return true;
5464 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5468 static final private boolean jj_3R_126() {
5477 if (jj_3R_137()) return true;
5478 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5479 } else if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5480 } else if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5481 } else if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5482 if (jj_3R_125()) return true;
5483 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5487 static final private boolean jj_3R_71() {
5488 if (jj_3R_48()) return true;
5489 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5493 static final private boolean jj_3R_205() {
5494 if (jj_3R_40()) return true;
5495 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5499 if (jj_3_2()) { jj_scanpos = xsp; break; }
5500 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5505 static final private boolean jj_3R_122() {
5506 if (jj_3R_125()) return true;
5507 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5511 if (jj_3R_126()) { jj_scanpos = xsp; break; }
5512 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5517 static final private boolean jj_3R_197() {
5518 if (jj_scan_token(LPAREN)) return true;
5519 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5522 if (jj_3R_204()) jj_scanpos = xsp;
5523 else if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5524 if (jj_scan_token(RPAREN)) return true;
5525 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5529 static final private boolean jj_3R_201() {
5530 if (jj_scan_token(LPAREN)) return true;
5531 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5534 if (jj_3R_205()) jj_scanpos = xsp;
5535 else if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5537 if (jj_3R_206()) jj_scanpos = xsp;
5538 else if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5539 if (jj_scan_token(RPAREN)) return true;
5540 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5544 static final private boolean jj_3R_179() {
5545 if (jj_scan_token(NULL)) return true;
5546 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5550 static final private boolean jj_3R_178() {
5551 if (jj_scan_token(FALSE)) return true;
5552 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5556 static final private boolean jj_3R_177() {
5557 if (jj_scan_token(TRUE)) return true;
5558 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5562 static final private boolean jj_3R_209() {
5563 if (jj_scan_token(ARRAYASSIGN)) return true;
5564 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5565 if (jj_3R_47()) return true;
5566 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5570 static final private boolean jj_3R_176() {
5571 if (jj_scan_token(STRING_LITERAL)) return true;
5572 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5576 static final private boolean jj_3R_175() {
5577 if (jj_scan_token(FLOATING_POINT_LITERAL)) return true;
5578 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5582 static final private boolean jj_3R_40() {
5583 if (jj_3R_47()) return true;
5584 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5587 if (jj_3R_209()) jj_scanpos = xsp;
5588 else if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5592 static final private boolean jj_3R_172() {
5605 if (jj_3R_179()) return true;
5606 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5607 } else if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5608 } else if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5609 } else if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5610 } else if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5611 } else if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5615 static final private boolean jj_3R_174() {
5616 if (jj_scan_token(INTEGER_LITERAL)) return true;
5617 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5621 static final private boolean jj_3R_131() {
5622 if (jj_scan_token(TRIPLEEQUAL)) return true;
5623 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5627 static final private boolean jj_3R_130() {
5628 if (jj_scan_token(BANGDOUBLEEQUAL)) return true;
5629 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5633 static final private boolean jj_3R_129() {
5634 if (jj_scan_token(NOT_EQUAL)) return true;
5635 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5639 static final private boolean jj_3R_128() {
5640 if (jj_scan_token(DIF)) return true;
5641 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5645 static final private boolean jj_3R_70() {
5646 if (jj_3R_47()) return true;
5647 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5651 static final private boolean jj_3R_52() {
5656 if (jj_3R_71()) return true;
5657 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5658 } else if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5662 static final private boolean jj_3R_127() {
5663 if (jj_scan_token(EQUAL_EQUAL)) return true;
5664 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5668 static final private boolean jj_3R_123() {
5679 if (jj_3R_131()) return true;
5680 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5681 } else if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5682 } else if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5683 } else if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5684 } else if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5685 if (jj_3R_122()) return true;
5686 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5690 static final private boolean jj_3R_117() {
5691 if (jj_3R_122()) return true;
5692 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5696 if (jj_3R_123()) { jj_scanpos = xsp; break; }
5697 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5702 static final private boolean jj_3R_46() {
5703 if (jj_scan_token(LBRACKET)) return true;
5704 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5707 if (jj_3R_52()) jj_scanpos = xsp;
5708 else if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5709 if (jj_scan_token(RBRACKET)) return true;
5710 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5714 static final private boolean jj_3R_118() {
5715 if (jj_scan_token(BIT_AND)) return true;
5716 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5717 if (jj_3R_117()) return true;
5718 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5722 static final private boolean jj_3R_115() {
5723 if (jj_3R_117()) return true;
5724 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5728 if (jj_3R_118()) { jj_scanpos = xsp; break; }
5729 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5734 static final private boolean jj_3R_45() {
5735 if (jj_scan_token(CLASSACCESS)) return true;
5736 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5737 if (jj_3R_51()) return true;
5738 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5742 static final private boolean jj_3R_39() {
5747 if (jj_3R_46()) return true;
5748 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5749 } else if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5753 static final private boolean jj_3R_112() {
5754 if (jj_scan_token(LBRACE)) return true;
5755 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5756 if (jj_3R_47()) return true;
5757 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5758 if (jj_scan_token(RBRACE)) return true;
5759 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5763 static final private boolean jj_3R_116() {
5764 if (jj_scan_token(XOR)) return true;
5765 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5766 if (jj_3R_115()) return true;
5767 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5771 static final private boolean jj_3R_69() {
5772 if (jj_scan_token(DOLLAR_ID)) return true;
5773 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5777 static final private boolean jj_3R_113() {
5778 if (jj_3R_115()) return true;
5779 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5783 if (jj_3R_116()) { jj_scanpos = xsp; break; }
5784 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5789 static final private boolean jj_3R_200() {
5790 if (jj_3R_64()) return true;
5791 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5795 static final private boolean jj_3R_199() {
5796 if (jj_3R_48()) return true;
5797 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5801 static final private boolean jj_3R_68() {
5802 if (jj_scan_token(DOLLAR)) return true;
5803 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5804 if (jj_3R_51()) return true;
5805 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5809 static final private boolean jj_3R_198() {
5810 if (jj_scan_token(IDENTIFIER)) return true;
5811 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5815 static final private boolean jj_3R_190() {
5822 if (jj_3R_200()) return true;
5823 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5824 } else if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5825 } else if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5829 static final private boolean jj_3R_114() {
5830 if (jj_scan_token(BIT_OR)) return true;
5831 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5832 if (jj_3R_113()) return true;
5833 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5837 static final private boolean jj_3R_106() {
5838 if (jj_3R_113()) return true;
5839 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5843 if (jj_3R_114()) { jj_scanpos = xsp; break; }
5844 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5849 static final private boolean jj_3R_67() {
5850 if (jj_scan_token(IDENTIFIER)) return true;
5851 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5854 if (jj_3R_112()) jj_scanpos = xsp;
5855 else if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5859 static final private boolean jj_3R_121() {
5860 if (jj_scan_token(ASSIGN)) return true;
5861 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5862 if (jj_3R_47()) return true;
5863 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5867 static final private boolean jj_3R_109() {
5868 if (jj_scan_token(DOT)) return true;
5869 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5870 if (jj_3R_106()) return true;
5871 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5875 static final private boolean jj_3R_51() {
5884 if (jj_3R_69()) return true;
5885 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5886 } else if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5887 } else if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5888 } else if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5892 static final private boolean jj_3R_66() {
5893 if (jj_scan_token(LBRACE)) return true;
5894 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5895 if (jj_3R_47()) return true;
5896 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5897 if (jj_scan_token(RBRACE)) return true;
5898 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5902 static final private boolean jj_3R_100() {
5903 if (jj_3R_106()) return true;
5904 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5908 if (jj_3R_109()) { jj_scanpos = xsp; break; }
5909 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5914 static final private boolean jj_3R_99() {
5915 if (jj_scan_token(LBRACE)) return true;
5916 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5917 if (jj_3R_47()) return true;
5918 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5919 if (jj_scan_token(RBRACE)) return true;
5920 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5924 static final private boolean jj_3R_124() {
5925 if (jj_3R_64()) return true;
5926 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5930 static final private boolean jj_3R_111() {
5931 if (jj_scan_token(_ANDL)) return true;
5932 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5936 static final private boolean jj_3R_110() {
5937 if (jj_scan_token(AND_AND)) return true;
5938 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5942 static final private boolean jj_3R_103() {
5947 if (jj_3R_111()) return true;
5948 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5949 } else if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5950 if (jj_3R_100()) return true;
5951 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5955 static final private boolean jj_3R_82() {
5956 if (jj_scan_token(DOLLAR)) return true;
5957 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5958 if (jj_3R_51()) return true;
5959 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5963 static final private boolean jj_3R_83() {
5964 if (jj_3R_100()) return true;
5965 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5969 if (jj_3R_103()) { jj_scanpos = xsp; break; }
5970 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5975 static final private boolean jj_3R_79() {
5976 if (jj_scan_token(HOOK)) return true;
5977 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5978 if (jj_3R_47()) return true;
5979 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5980 if (jj_scan_token(COLON)) return true;
5981 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5982 if (jj_3R_72()) return true;
5983 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5987 static final private boolean jj_3R_120() {
5988 if (jj_scan_token(COMMA)) return true;
5989 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5992 if (jj_3R_124()) jj_scanpos = xsp;
5993 else if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
5997 static final private boolean jj_3R_184() {
5998 if (jj_scan_token(ARRAY)) return true;
5999 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6000 if (jj_3R_201()) return true;
6001 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6005 static final private boolean jj_3R_119() {
6006 if (jj_3R_64()) return true;
6007 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6011 static final private boolean jj_3R_105() {
6012 if (jj_scan_token(_ORL)) return true;
6013 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6017 static final private boolean jj_3R_104() {
6018 if (jj_scan_token(OR_OR)) return true;
6019 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6023 static final private boolean jj_3R_81() {
6024 if (jj_scan_token(DOLLAR_ID)) return true;
6025 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6028 if (jj_3R_99()) jj_scanpos = xsp;
6029 else if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6033 static final private boolean jj_3R_75() {
6038 if (jj_3R_82()) return true;
6039 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6040 } else if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6044 static final private boolean jj_3R_85() {
6049 if (jj_3R_105()) return true;
6050 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6051 } else if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6052 if (jj_3R_83()) return true;
6053 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6057 static final private boolean jj_3R_108() {
6058 if (jj_scan_token(LIST)) return true;
6059 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6060 if (jj_scan_token(LPAREN)) return true;
6061 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6064 if (jj_3R_119()) jj_scanpos = xsp;
6065 else if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6068 if (jj_3R_120()) { jj_scanpos = xsp; break; }
6069 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6071 if (jj_scan_token(RPAREN)) return true;
6072 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6074 if (jj_3R_121()) jj_scanpos = xsp;
6075 else if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6079 static final private boolean jj_3R_203() {
6080 if (jj_scan_token(STATICCLASSACCESS)) return true;
6081 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6082 if (jj_3R_190()) return true;
6083 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6087 static final private boolean jj_3R_76() {
6088 if (jj_3R_83()) return true;
6089 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6093 if (jj_3R_85()) { jj_scanpos = xsp; break; }
6094 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6099 static final private boolean jj_3R_202() {
6100 if (jj_3R_39()) return true;
6101 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6105 static final private boolean jj_3R_196() {
6110 if (jj_3R_203()) return true;
6111 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6112 } else if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6116 static final private boolean jj_3R_107() {
6117 if (jj_scan_token(PRINT)) return true;
6118 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6119 if (jj_3R_47()) return true;
6120 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6124 static final private boolean jj_3R_193() {
6125 if (jj_3R_64()) return true;
6126 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6130 static final private boolean jj_3R_72() {
6131 if (jj_3R_76()) return true;
6132 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6135 if (jj_3R_79()) jj_scanpos = xsp;
6136 else if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6140 static final private boolean jj_3R_192() {
6141 if (jj_scan_token(IDENTIFIER)) return true;
6142 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6146 static final private boolean jj_3R_183() {
6151 if (jj_3R_193()) return true;
6152 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6153 } else if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6157 static final private boolean jj_3_1() {
6158 if (jj_3R_39()) return true;
6159 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6163 static final private boolean jj_3R_98() {
6164 if (jj_scan_token(TILDEEQUAL)) return true;
6165 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6169 static final private boolean jj_3R_97() {
6170 if (jj_scan_token(DOTASSIGN)) return true;
6171 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6175 static final private boolean jj_3R_96() {
6176 if (jj_scan_token(ORASSIGN)) return true;
6177 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6181 static final private boolean jj_3R_182() {
6182 if (jj_3R_184()) return true;
6183 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6187 static final private boolean jj_3R_64() {
6188 if (jj_3R_75()) return true;
6189 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6193 if (jj_3_1()) { jj_scanpos = xsp; break; }
6194 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6199 static final private boolean jj_3R_95() {
6200 if (jj_scan_token(XORASSIGN)) return true;
6201 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6205 static final private boolean jj_3R_191() {
6206 if (jj_3R_197()) return true;
6207 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6211 static final private boolean jj_3R_94() {
6212 if (jj_scan_token(ANDASSIGN)) return true;
6213 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6217 static final private boolean jj_3R_93() {
6218 if (jj_scan_token(RSIGNEDSHIFTASSIGN)) return true;
6219 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6223 static final private boolean jj_3R_92() {
6224 if (jj_scan_token(LSHIFTASSIGN)) return true;
6225 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6229 static final private boolean jj_3R_91() {
6230 if (jj_scan_token(MINUSASSIGN)) return true;
6231 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6235 static final private boolean jj_3R_90() {
6236 if (jj_scan_token(PLUSASSIGN)) return true;
6237 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6241 static final private boolean jj_3R_89() {
6242 if (jj_scan_token(REMASSIGN)) return true;
6243 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6247 static final private boolean jj_3R_88() {
6248 if (jj_scan_token(SLASHASSIGN)) return true;
6249 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6253 static final private boolean jj_3R_181() {
6254 if (jj_scan_token(NEW)) return true;
6255 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6256 if (jj_3R_190()) return true;
6257 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6260 if (jj_3R_191()) jj_scanpos = xsp;
6261 else if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6265 static final private boolean jj_3R_87() {
6266 if (jj_scan_token(STARASSIGN)) return true;
6267 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6271 static final private boolean jj_3R_189() {
6272 if (jj_3R_197()) return true;
6273 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6277 static final private boolean jj_3R_86() {
6278 if (jj_scan_token(ASSIGN)) return true;
6279 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6283 static final private boolean jj_3R_80() {
6310 if (jj_3R_98()) return true;
6311 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6312 } else if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6313 } else if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6314 } else if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6315 } else if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6316 } else if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6317 } else if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6318 } else if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6319 } else if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6320 } else if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6321 } else if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6322 } else if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6323 } else if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6327 static final private boolean jj_3R_188() {
6328 if (jj_3R_196()) return true;
6329 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6333 static final private boolean jj_3R_180() {
6334 if (jj_3R_183()) return true;
6335 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6339 if (jj_3R_188()) { jj_scanpos = xsp; break; }
6340 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6343 if (jj_3R_189()) jj_scanpos = xsp;
6344 else if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6348 static final private boolean jj_3R_173() {
6355 if (jj_3R_182()) return true;
6356 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6357 } else if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6358 } else if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6362 static final private boolean jj_3R_102() {
6363 if (jj_3R_108()) return true;
6364 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6368 static final private boolean jj_3R_101() {
6369 if (jj_3R_107()) return true;
6370 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6374 static final private boolean jj_3R_84() {
6379 if (jj_3R_102()) return true;
6380 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6381 } else if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6385 static final private boolean jj_3R_195() {
6386 if (jj_scan_token(MINUS_MINUS)) return true;
6387 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6391 static final private boolean jj_3R_78() {
6392 if (jj_3R_84()) return true;
6393 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6397 static final private boolean jj_3R_77() {
6398 if (jj_scan_token(BANG)) return true;
6399 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6400 if (jj_3R_73()) return true;
6401 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6405 static final private boolean jj_3R_73() {
6410 if (jj_3R_78()) return true;
6411 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6412 } else if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6416 static final private boolean jj_3R_194() {
6417 if (jj_scan_token(PLUS_PLUS)) return true;
6418 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6422 static final private boolean jj_3R_187() {
6427 if (jj_3R_195()) return true;
6428 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6429 } else if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6433 static final private boolean jj_3R_171() {
6434 if (jj_3R_173()) return true;
6435 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6438 if (jj_3R_187()) jj_scanpos = xsp;
6439 else if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6443 static final private boolean jj_3R_54() {
6444 if (jj_3R_73()) return true;
6445 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6449 static final private boolean jj_3R_186() {
6450 if (jj_scan_token(ARRAY)) return true;
6451 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6455 static final private boolean jj_3R_185() {
6456 if (jj_3R_48()) return true;
6457 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6461 static final private boolean jj_3R_42() {
6462 if (jj_scan_token(ARRAY)) return true;
6463 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6467 static final private boolean jj_3R_170() {
6468 if (jj_scan_token(LPAREN)) return true;
6469 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6474 if (jj_3R_186()) return true;
6475 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6476 } else if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6477 if (jj_scan_token(RPAREN)) return true;
6478 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6479 if (jj_3R_143()) return true;
6480 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6484 static final private boolean jj_3R_41() {
6485 if (jj_3R_48()) return true;
6486 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6490 static final private boolean jj_3R_74() {
6491 if (jj_3R_80()) return true;
6492 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6493 if (jj_3R_47()) return true;
6494 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6498 static final private boolean jj_3_3() {
6499 if (jj_scan_token(LPAREN)) return true;
6500 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6505 if (jj_3R_42()) return true;
6506 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6507 } else if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6508 if (jj_scan_token(RPAREN)) return true;
6509 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6513 static final private boolean jj_3R_65() {
6514 if (jj_scan_token(ASSIGN)) return true;
6515 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6516 if (jj_3R_47()) return true;
6517 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6521 static final private boolean jj_3R_47() {
6526 if (jj_3R_54()) return true;
6527 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6528 } else if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6532 static final private boolean jj_3R_53() {
6533 if (jj_3R_72()) return true;
6534 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6537 if (jj_3R_74()) jj_scanpos = xsp;
6538 else if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6542 static final private boolean jj_3R_169() {
6543 if (jj_scan_token(LPAREN)) return true;
6544 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6545 if (jj_3R_47()) return true;
6546 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6547 if (jj_scan_token(RPAREN)) return true;
6548 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6552 static final private boolean jj_3R_168() {
6553 if (jj_3R_172()) return true;
6554 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6558 static final private boolean jj_3R_167() {
6559 if (jj_3R_171()) return true;
6560 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6564 static final private boolean jj_3R_163() {
6573 if (jj_3R_169()) return true;
6574 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6575 } else if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6576 } else if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6577 } else if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6581 static final private boolean jj_3R_166() {
6582 if (jj_3R_170()) return true;
6583 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6587 static final private boolean jj_3R_63() {
6588 if (jj_scan_token(OBJECT)) return true;
6589 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6593 static final private boolean jj_3R_62() {
6594 if (jj_scan_token(INTEGER)) return true;
6595 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6599 static final private boolean jj_3R_165() {
6600 if (jj_scan_token(MINUS_MINUS)) return true;
6601 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6605 static final private boolean jj_3R_61() {
6606 if (jj_scan_token(INT)) return true;
6607 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6611 static final private boolean jj_3R_164() {
6612 if (jj_scan_token(PLUS_PLUS)) return true;
6613 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6617 static final private boolean jj_3R_60() {
6618 if (jj_scan_token(FLOAT)) return true;
6619 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6623 static final private boolean jj_3R_59() {
6624 if (jj_scan_token(DOUBLE)) return true;
6625 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6629 static final private boolean jj_3R_58() {
6630 if (jj_scan_token(REAL)) return true;
6631 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6635 static final private boolean jj_3R_162() {
6640 if (jj_3R_165()) return true;
6641 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6642 } else if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6643 if (jj_3R_173()) return true;
6644 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6648 static final private boolean jj_3R_57() {
6649 if (jj_scan_token(BOOLEAN)) return true;
6650 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6654 static final private boolean jj_3R_56() {
6655 if (jj_scan_token(BOOL)) return true;
6656 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6660 static final private boolean jj_3R_48() {
6679 if (jj_3R_63()) return true;
6680 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6681 } else if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6682 } else if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6683 } else if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6684 } else if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6685 } else if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6686 } else if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6687 } else if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6688 } else if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6692 static final private boolean jj_3R_55() {
6693 if (jj_scan_token(STRING)) return true;
6694 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6698 static final private boolean jj_3R_49() {
6699 if (jj_3R_64()) return true;
6700 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6703 if (jj_3R_65()) jj_scanpos = xsp;
6704 else if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6708 static final private boolean jj_3R_159() {
6709 if (jj_3R_163()) return true;
6710 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6714 static final private boolean jj_3R_158() {
6715 if (jj_3R_162()) return true;
6716 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6720 static final private boolean jj_3R_161() {
6721 if (jj_scan_token(MINUS)) return true;
6722 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6726 static final private boolean jj_3R_160() {
6727 if (jj_scan_token(PLUS)) return true;
6728 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6732 static final private boolean jj_3R_50() {
6733 if (jj_scan_token(COMMA)) return true;
6734 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6735 if (jj_3R_49()) return true;
6736 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6740 static final private boolean jj_3R_153() {
6747 if (jj_3R_159()) return true;
6748 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6749 } else if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6750 } else if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6754 static final private boolean jj_3R_157() {
6759 if (jj_3R_161()) return true;
6760 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6761 } else if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6762 if (jj_3R_143()) return true;
6763 if (jj_la == 0 && jj_scanpos == jj_lastpos) return false;
6767 static private boolean jj_initialized_once = false;
6768 static public PHPParserTokenManager token_source;
6769 static SimpleCharStream jj_input_stream;
6770 static public Token token, jj_nt;
6771 static private int jj_ntk;
6772 static private Token jj_scanpos, jj_lastpos;
6773 static private int jj_la;
6774 static public boolean lookingAhead = false;
6775 static private boolean jj_semLA;
6776 static private int jj_gen;
6777 static final private int[] jj_la1 = new int[127];
6778 static private int[] jj_la1_0;
6779 static private int[] jj_la1_1;
6780 static private int[] jj_la1_2;
6781 static private int[] jj_la1_3;
6782 static private int[] jj_la1_4;
6790 private static void jj_la1_0() {
6791 jj_la1_0 = new int[] {0xf960001e,0x6,0x6,0xf960001e,0x0,0xf9600000,0x0,0xc00000,0xc00000,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x8000000,0x0,0x68000000,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x68000000,0x60000000,0x60000000,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x8000000,0x8000000,0x0,0x8000000,0x0,0x8000000,0x8000000,0x0,0x0,0x0,0x0,0x0,0x8000000,0x0,0x0,0x8000000,0x0,0x68000000,0x68000000,0x0,0x0,0x68000000,0x0,0x0,0x81000000,0xf9000000,0x8,0x6,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0xf9600010,0xf9600010,0xf9600000,0xe9600000,0x0,0x0,0x0,0x0,0x8000000,0x0,0x0,0x0,0xe9600010,0xe9600010,0x10000000,0x0,0x68000000,0xf9000010,0xf9000010,0x2000000,0x4000000,0xf9000010,0x2000000,0x4000000,0xf9000010,0xf9000010,0xf9000010,0xf9000010,0xf9000010,0xf9000000,0xf9000000,0x8000000,0x68000000,0x8000000,0xf9000000,0xf9000000,0x8000000,0x0,0x68000000,0x68000000,};
6793 private static void jj_la1_1() {
6794 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,};
6796 private static void jj_la1_2() {
6797 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,};
6799 private static void jj_la1_3() {
6800 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,};
6802 private static void jj_la1_4() {
6803 jj_la1_4 = new int[] {0x4000,0x0,0x0,0x4000,0x0,0x4000,0x0,0x0,0x0,0x0,0x2,0x2,0x0,0x4000,0x0,0x4000,0x0,0x0,0x0,0x0,0x4000,0x0,0x0,0x0,0x4000,0x0,0x0,0x3ffe,0x4000,0x0,0x0,0x3ffe,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x1,0x1,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x4000,0x4000,0x0,0x4000,0x0,0x4000,0x0,0x0,0x0,0x0,0x0,0x0,0x4000,0x4000,0x0,0x4000,0x4000,0x4000,0x4000,0x0,0x0,0x4000,0x0,0x0,0x0,0x4000,0x0,0x0,0x0,0x4000,0x0,0x4000,0x2,0x0,0x0,0x0,0x4000,0x4000,0x4000,0x4000,0x0,0x2,0x0,0x0,0x4000,0x0,0x0,0x0,0x4000,0x4000,0x0,0x0,0x4000,0x4000,0x4000,0x0,0x0,0x4000,0x0,0x0,0x4000,0x4000,0x4000,0x4000,0x4000,0x4000,0x4000,0x4000,0x4000,0x4000,0x4000,0x4000,0x4000,0x0,0x4000,0x4000,};
6805 static final private JJCalls[] jj_2_rtns = new JJCalls[5];
6806 static private boolean jj_rescan = false;
6807 static private int jj_gc = 0;
6809 public PHPParser(java.io.InputStream stream) {
6810 if (jj_initialized_once) {
6811 System.out.println("ERROR: Second call to constructor of static parser. You must");
6812 System.out.println(" either use ReInit() or set the JavaCC option STATIC to false");
6813 System.out.println(" during parser generation.");
6816 jj_initialized_once = true;
6817 jj_input_stream = new SimpleCharStream(stream, 1, 1);
6818 token_source = new PHPParserTokenManager(jj_input_stream);
6819 token = new Token();
6822 for (int i = 0; i < 127; i++) jj_la1[i] = -1;
6823 for (int i = 0; i < jj_2_rtns.length; i++) jj_2_rtns[i] = new JJCalls();
6826 static public void ReInit(java.io.InputStream stream) {
6827 jj_input_stream.ReInit(stream, 1, 1);
6828 token_source.ReInit(jj_input_stream);
6829 token = new Token();
6832 for (int i = 0; i < 127; i++) jj_la1[i] = -1;
6833 for (int i = 0; i < jj_2_rtns.length; i++) jj_2_rtns[i] = new JJCalls();
6836 public PHPParser(java.io.Reader stream) {
6837 if (jj_initialized_once) {
6838 System.out.println("ERROR: Second call to constructor of static parser. You must");
6839 System.out.println(" either use ReInit() or set the JavaCC option STATIC to false");
6840 System.out.println(" during parser generation.");
6843 jj_initialized_once = true;
6844 jj_input_stream = new SimpleCharStream(stream, 1, 1);
6845 token_source = new PHPParserTokenManager(jj_input_stream);
6846 token = new Token();
6849 for (int i = 0; i < 127; i++) jj_la1[i] = -1;
6850 for (int i = 0; i < jj_2_rtns.length; i++) jj_2_rtns[i] = new JJCalls();
6853 static public void ReInit(java.io.Reader stream) {
6854 jj_input_stream.ReInit(stream, 1, 1);
6855 token_source.ReInit(jj_input_stream);
6856 token = new Token();
6859 for (int i = 0; i < 127; i++) jj_la1[i] = -1;
6860 for (int i = 0; i < jj_2_rtns.length; i++) jj_2_rtns[i] = new JJCalls();
6863 public PHPParser(PHPParserTokenManager tm) {
6864 if (jj_initialized_once) {
6865 System.out.println("ERROR: Second call to constructor of static parser. You must");
6866 System.out.println(" either use ReInit() or set the JavaCC option STATIC to false");
6867 System.out.println(" during parser generation.");
6870 jj_initialized_once = true;
6872 token = new Token();
6875 for (int i = 0; i < 127; i++) jj_la1[i] = -1;
6876 for (int i = 0; i < jj_2_rtns.length; i++) jj_2_rtns[i] = new JJCalls();
6879 public void ReInit(PHPParserTokenManager tm) {
6881 token = new Token();
6884 for (int i = 0; i < 127; i++) jj_la1[i] = -1;
6885 for (int i = 0; i < jj_2_rtns.length; i++) jj_2_rtns[i] = new JJCalls();
6888 static final private Token jj_consume_token(int kind) throws ParseException {
6890 if ((oldToken = token).next != null) token = token.next;
6891 else token = token.next = token_source.getNextToken();
6893 if (token.kind == kind) {
6895 if (++jj_gc > 100) {
6897 for (int i = 0; i < jj_2_rtns.length; i++) {
6898 JJCalls c = jj_2_rtns[i];
6900 if (c.gen < jj_gen) c.first = null;
6909 throw generateParseException();
6912 static final private boolean jj_scan_token(int kind) {
6913 if (jj_scanpos == jj_lastpos) {
6915 if (jj_scanpos.next == null) {
6916 jj_lastpos = jj_scanpos = jj_scanpos.next = token_source.getNextToken();
6918 jj_lastpos = jj_scanpos = jj_scanpos.next;
6921 jj_scanpos = jj_scanpos.next;
6924 int i = 0; Token tok = token;
6925 while (tok != null && tok != jj_scanpos) { i++; tok = tok.next; }
6926 if (tok != null) jj_add_error_token(kind, i);
6928 return (jj_scanpos.kind != kind);
6931 static final public Token getNextToken() {
6932 if (token.next != null) token = token.next;
6933 else token = token.next = token_source.getNextToken();
6939 static final public Token getToken(int index) {
6940 Token t = lookingAhead ? jj_scanpos : token;
6941 for (int i = 0; i < index; i++) {
6942 if (t.next != null) t = t.next;
6943 else t = t.next = token_source.getNextToken();
6948 static final private int jj_ntk() {
6949 if ((jj_nt=token.next) == null)
6950 return (jj_ntk = (token.next=token_source.getNextToken()).kind);
6952 return (jj_ntk = jj_nt.kind);
6955 static private java.util.Vector jj_expentries = new java.util.Vector();
6956 static private int[] jj_expentry;
6957 static private int jj_kind = -1;
6958 static private int[] jj_lasttokens = new int[100];
6959 static private int jj_endpos;
6961 static private void jj_add_error_token(int kind, int pos) {
6962 if (pos >= 100) return;
6963 if (pos == jj_endpos + 1) {
6964 jj_lasttokens[jj_endpos++] = kind;
6965 } else if (jj_endpos != 0) {
6966 jj_expentry = new int[jj_endpos];
6967 for (int i = 0; i < jj_endpos; i++) {
6968 jj_expentry[i] = jj_lasttokens[i];
6970 boolean exists = false;
6971 for (java.util.Enumeration enum = jj_expentries.elements(); enum.hasMoreElements();) {
6972 int[] oldentry = (int[])(enum.nextElement());
6973 if (oldentry.length == jj_expentry.length) {
6975 for (int i = 0; i < jj_expentry.length; i++) {
6976 if (oldentry[i] != jj_expentry[i]) {
6984 if (!exists) jj_expentries.addElement(jj_expentry);
6985 if (pos != 0) jj_lasttokens[(jj_endpos = pos) - 1] = kind;
6989 static public ParseException generateParseException() {
6990 jj_expentries.removeAllElements();
6991 boolean[] la1tokens = new boolean[143];
6992 for (int i = 0; i < 143; i++) {
6993 la1tokens[i] = false;
6996 la1tokens[jj_kind] = true;
6999 for (int i = 0; i < 127; i++) {
7000 if (jj_la1[i] == jj_gen) {
7001 for (int j = 0; j < 32; j++) {
7002 if ((jj_la1_0[i] & (1<<j)) != 0) {
7003 la1tokens[j] = true;
7005 if ((jj_la1_1[i] & (1<<j)) != 0) {
7006 la1tokens[32+j] = true;
7008 if ((jj_la1_2[i] & (1<<j)) != 0) {
7009 la1tokens[64+j] = true;
7011 if ((jj_la1_3[i] & (1<<j)) != 0) {
7012 la1tokens[96+j] = true;
7014 if ((jj_la1_4[i] & (1<<j)) != 0) {
7015 la1tokens[128+j] = true;
7020 for (int i = 0; i < 143; i++) {
7022 jj_expentry = new int[1];
7024 jj_expentries.addElement(jj_expentry);
7029 jj_add_error_token(0, 0);
7030 int[][] exptokseq = new int[jj_expentries.size()][];
7031 for (int i = 0; i < jj_expentries.size(); i++) {
7032 exptokseq[i] = (int[])jj_expentries.elementAt(i);
7034 return new ParseException(token, exptokseq, tokenImage);
7037 static final public void enable_tracing() {
7040 static final public void disable_tracing() {
7043 static final private void jj_rescan_token() {
7045 for (int i = 0; i < 5; i++) {
7046 JJCalls p = jj_2_rtns[i];
7048 if (p.gen > jj_gen) {
7049 jj_la = p.arg; jj_lastpos = jj_scanpos = p.first;
7051 case 0: jj_3_1(); break;
7052 case 1: jj_3_2(); break;
7053 case 2: jj_3_3(); break;
7054 case 3: jj_3_4(); break;
7055 case 4: jj_3_5(); break;
7059 } while (p != null);
7064 static final private void jj_save(int index, int xla) {
7065 JJCalls p = jj_2_rtns[index];
7066 while (p.gen > jj_gen) {
7067 if (p.next == null) { p = p.next = new JJCalls(); break; }
7070 p.gen = jj_gen + xla - jj_la; p.first = token; p.arg = xla;
7073 static final class JJCalls {