1 /* Generated By:JavaCC: Do not edit this line. PHPParserTokenManager.java */
3 import org.eclipse.core.resources.IFile;
4 import org.eclipse.core.resources.IMarker;
5 import org.eclipse.core.runtime.CoreException;
6 import org.eclipse.ui.texteditor.MarkerUtilities;
7 import org.eclipse.jface.preference.IPreferenceStore;
8 import java.util.Hashtable;
9 import java.io.StringReader;
10 import java.text.MessageFormat;
11 import net.sourceforge.phpeclipse.actions.PHPStartApacheAction;
12 import net.sourceforge.phpeclipse.PHPeclipsePlugin;
13 import net.sourceforge.phpdt.internal.compiler.parser.PHPOutlineInfo;
15 public class PHPParserTokenManager implements PHPParserConstants
17 public static java.io.PrintStream debugStream = System.out;
18 public static void setDebugStream(java.io.PrintStream ds) { debugStream = ds; }
19 private static final int jjStopStringLiteralDfa_0(int pos, long active0, long active1, long active2)
27 private static final int jjStartNfa_0(int pos, long active0, long active1, long active2)
29 return jjMoveNfa_0(jjStopStringLiteralDfa_0(pos, active0, active1, active2), pos + 1);
31 static private final int jjStopAtPos(int pos, int kind)
37 static private final int jjStartNfaWithStates_0(int pos, int kind, int state)
41 try { curChar = input_stream.readChar(); }
42 catch(java.io.IOException e) { return pos + 1; }
43 return jjMoveNfa_0(state, pos + 1);
45 static private final int jjMoveStringLiteralDfa0_0()
50 return jjMoveStringLiteralDfa1_0(0x8000000000000000L);
52 return jjMoveNfa_0(0, 0);
55 static private final int jjMoveStringLiteralDfa1_0(long active1)
57 try { curChar = input_stream.readChar(); }
58 catch(java.io.IOException e) {
59 jjStopStringLiteralDfa_0(0, 0L, active1, 0L);
65 if ((active1 & 0x8000000000000000L) != 0L)
66 return jjStopAtPos(1, 127);
71 return jjStartNfa_0(0, 0L, active1, 0L);
73 static private final void jjCheckNAdd(int state)
75 if (jjrounds[state] != jjround)
77 jjstateSet[jjnewStateCnt++] = state;
78 jjrounds[state] = jjround;
81 static private final void jjAddStates(int start, int end)
84 jjstateSet[jjnewStateCnt++] = jjnextStates[start];
85 } while (start++ != end);
87 static private final void jjCheckNAddTwoStates(int state1, int state2)
92 static private final void jjCheckNAddStates(int start, int end)
95 jjCheckNAdd(jjnextStates[start]);
96 } while (start++ != end);
98 static private final void jjCheckNAddStates(int start)
100 jjCheckNAdd(jjnextStates[start]);
101 jjCheckNAdd(jjnextStates[start + 1]);
103 static private final int jjMoveNfa_0(int startState, int curPos)
109 jjstateSet[0] = startState;
110 int j, kind = 0x7fffffff;
113 if (++jjround == 0x7fffffff)
117 long l = 1L << curChar;
120 switch(jjstateSet[--i])
128 jjstateSet[jjnewStateCnt++] = 3;
131 if (curChar == 63 && kind > 1)
136 } while(i != startsAt);
138 else if (curChar < 128)
140 long l = 1L << (curChar & 077);
143 switch(jjstateSet[--i])
146 if ((0x1000000010000L & l) != 0L && kind > 1)
150 if ((0x10000000100L & l) != 0L)
151 jjstateSet[jjnewStateCnt++] = 1;
154 if ((0x1000000010000L & l) != 0L)
155 jjstateSet[jjnewStateCnt++] = 2;
159 } while(i != startsAt);
163 int i2 = (curChar & 0xff) >> 6;
164 long l2 = 1L << (curChar & 077);
167 switch(jjstateSet[--i])
171 } while(i != startsAt);
173 if (kind != 0x7fffffff)
175 jjmatchedKind = kind;
176 jjmatchedPos = curPos;
180 if ((i = jjnewStateCnt) == (startsAt = 6 - (jjnewStateCnt = startsAt)))
182 try { curChar = input_stream.readChar(); }
183 catch(java.io.IOException e) { return curPos; }
186 static private final int jjMoveStringLiteralDfa0_4()
191 return jjMoveStringLiteralDfa1_4(0x4000L);
196 static private final int jjMoveStringLiteralDfa1_4(long active0)
198 try { curChar = input_stream.readChar(); }
199 catch(java.io.IOException e) {
205 if ((active0 & 0x4000L) != 0L)
206 return jjStopAtPos(1, 14);
213 static private final int jjMoveStringLiteralDfa0_2()
215 return jjMoveNfa_2(0, 0);
217 static private final int jjMoveNfa_2(int startState, int curPos)
223 jjstateSet[0] = startState;
224 int j, kind = 0x7fffffff;
227 if (++jjround == 0x7fffffff)
231 long l = 1L << curChar;
234 switch(jjstateSet[--i])
237 if ((0x2400L & l) != 0L)
242 else if (curChar == 63)
243 jjstateSet[jjnewStateCnt++] = 3;
245 jjstateSet[jjnewStateCnt++] = 1;
248 if (curChar == 10 && kind > 12)
253 jjstateSet[jjnewStateCnt++] = 1;
261 jjstateSet[jjnewStateCnt++] = 3;
265 } while(i != startsAt);
267 else if (curChar < 128)
269 long l = 1L << (curChar & 077);
272 switch(jjstateSet[--i])
276 } while(i != startsAt);
280 int i2 = (curChar & 0xff) >> 6;
281 long l2 = 1L << (curChar & 077);
284 switch(jjstateSet[--i])
288 } while(i != startsAt);
290 if (kind != 0x7fffffff)
292 jjmatchedKind = kind;
293 jjmatchedPos = curPos;
297 if ((i = jjnewStateCnt) == (startsAt = 5 - (jjnewStateCnt = startsAt)))
299 try { curChar = input_stream.readChar(); }
300 catch(java.io.IOException e) { return curPos; }
303 private static final int jjStopStringLiteralDfa_1(int pos, long active0, long active1)
308 if ((active0 & 0xfffffffc7fff0000L) != 0L)
313 if ((active0 & 0xa00L) != 0L || (active1 & 0x20040000000000L) != 0L)
315 if ((active1 & 0x1000000L) != 0L)
317 if ((active1 & 0x200000000400000L) != 0L)
321 if ((active0 & 0x800L) != 0L)
323 if ((active0 & 0x4400008000080000L) != 0L)
325 if ((active0 & 0xbbffff7c7ff70000L) != 0L)
327 if (jjmatchedPos != 1)
336 if ((active0 & 0xb000140000040000L) != 0L)
338 if ((active0 & 0xfffeb7c7ff30000L) != 0L)
340 if (jjmatchedPos != 2)
349 if ((active0 & 0x2c79c3747ec30000L) != 0L)
351 if (jjmatchedPos != 3)
358 if ((active0 & 0x386280801300000L) != 0L)
362 if ((active0 & 0x808821400c10000L) != 0L)
364 if ((active0 & 0x257141607e120000L) != 0L)
372 if ((active0 & 0x461400060100000L) != 0L)
374 if ((active0 & 0x211001601e020000L) != 0L)
382 if ((active0 & 0x210001401e000000L) != 0L)
384 if ((active0 & 0x10002000020000L) != 0L)
386 if (jjmatchedPos != 6)
395 if ((active0 & 0x10002000020000L) != 0L)
397 if ((active0 & 0x18000000L) != 0L)
405 if ((active0 & 0x18000000L) != 0L)
413 if ((active0 & 0x18000000L) != 0L)
421 if ((active0 & 0x18000000L) != 0L)
432 private static final int jjStartNfa_1(int pos, long active0, long active1)
434 return jjMoveNfa_1(jjStopStringLiteralDfa_1(pos, active0, active1), pos + 1);
436 static private final int jjStartNfaWithStates_1(int pos, int kind, int state)
438 jjmatchedKind = kind;
440 try { curChar = input_stream.readChar(); }
441 catch(java.io.IOException e) { return pos + 1; }
442 return jjMoveNfa_1(state, pos + 1);
444 static private final int jjMoveStringLiteralDfa0_1()
450 return jjMoveStringLiteralDfa1_1(0x0L, 0x400000000L);
452 return jjStartNfaWithStates_1(0, 88, 16);
455 return jjMoveStringLiteralDfa1_1(0x0L, 0x400000000000000L);
458 return jjMoveStringLiteralDfa1_1(0x0L, 0x40001000000000L);
460 return jjStopAtPos(0, 78);
462 return jjStopAtPos(0, 79);
465 return jjMoveStringLiteralDfa1_1(0x0L, 0x10000000000000L);
468 return jjMoveStringLiteralDfa1_1(0x0L, 0x4002000000000L);
470 return jjStopAtPos(0, 85);
473 return jjMoveStringLiteralDfa1_1(0x80000000L, 0x8004000000000L);
476 return jjMoveStringLiteralDfa1_1(0x0L, 0x200000000000000L);
479 return jjMoveStringLiteralDfa1_1(0xa00L, 0x20000000000000L);
482 return jjMoveStringLiteralDfa1_1(0x100000000L, 0x0L);
484 return jjStopAtPos(0, 84);
487 return jjMoveStringLiteralDfa1_1(0x0L, 0x800800100000000L);
490 return jjMoveStringLiteralDfa1_1(0x200000000L, 0x80000000L);
493 return jjMoveStringLiteralDfa1_1(0x0L, 0x3003000200000000L);
496 return jjMoveStringLiteralDfa1_1(0x4L, 0x0L);
498 return jjStopAtPos(0, 87);
500 return jjStopAtPos(0, 82);
502 return jjStopAtPos(0, 83);
505 return jjMoveStringLiteralDfa1_1(0x0L, 0x100000000000000L);
508 return jjMoveStringLiteralDfa1_1(0x8000000000400000L, 0x0L);
511 return jjMoveStringLiteralDfa1_1(0x180000400000000L, 0x0L);
514 return jjMoveStringLiteralDfa1_1(0x3800010000L, 0x0L);
517 return jjMoveStringLiteralDfa1_1(0x40000c000000000L, 0x0L);
520 return jjMoveStringLiteralDfa1_1(0x10010001300000L, 0x0L);
523 return jjMoveStringLiteralDfa1_1(0x800060000020000L, 0x0L);
526 return jjMoveStringLiteralDfa1_1(0x80020000000L, 0x0L);
529 return jjMoveStringLiteralDfa1_1(0x300000000a080000L, 0x0L);
532 return jjMoveStringLiteralDfa1_1(0x300000000000L, 0x0L);
535 return jjMoveStringLiteralDfa1_1(0x4040000000000000L, 0x0L);
538 return jjMoveStringLiteralDfa1_1(0x800000L, 0x0L);
541 return jjMoveStringLiteralDfa1_1(0x200400014000000L, 0x0L);
544 return jjMoveStringLiteralDfa1_1(0x21800040000000L, 0x0L);
547 return jjMoveStringLiteralDfa1_1(0x6000000000000L, 0x0L);
550 return jjMoveStringLiteralDfa1_1(0x40000L, 0x0L);
553 return jjMoveStringLiteralDfa1_1(0x8000000000000L, 0x0L);
555 return jjStopAtPos(0, 80);
558 return jjMoveStringLiteralDfa1_1(0x0L, 0x80000800000000L);
560 return jjStopAtPos(0, 81);
562 return jjMoveNfa_1(3, 0);
565 static private final int jjMoveStringLiteralDfa1_1(long active0, long active1)
567 try { curChar = input_stream.readChar(); }
568 catch(java.io.IOException e) {
569 jjStopStringLiteralDfa_1(0, active0, active1);
575 if ((active1 & 0x1000000000L) != 0L)
576 return jjStopAtPos(1, 100);
579 if ((active0 & 0x800L) != 0L)
580 return jjStartNfaWithStates_1(1, 11, 0);
583 if ((active1 & 0x2000000000L) != 0L)
584 return jjStopAtPos(1, 101);
587 if ((active1 & 0x4000000000L) != 0L)
588 return jjStopAtPos(1, 102);
591 if ((active0 & 0x200L) != 0L)
592 return jjStopAtPos(1, 9);
595 if ((active0 & 0x100000000L) != 0L)
596 return jjStopAtPos(1, 32);
599 if ((active1 & 0x800000000000L) != 0L)
604 return jjMoveStringLiteralDfa2_1(active0, 0L, active1, 0x800000000000000L);
606 if ((active1 & 0x80000000L) != 0L)
607 return jjStopAtPos(1, 95);
608 else if ((active1 & 0x100000000L) != 0L)
609 return jjStopAtPos(1, 96);
610 else if ((active1 & 0x200000000L) != 0L)
611 return jjStopAtPos(1, 97);
612 else if ((active1 & 0x400000000L) != 0L)
613 return jjStopAtPos(1, 98);
614 else if ((active1 & 0x4000000000000L) != 0L)
615 return jjStopAtPos(1, 114);
616 else if ((active1 & 0x8000000000000L) != 0L)
617 return jjStopAtPos(1, 115);
618 else if ((active1 & 0x10000000000000L) != 0L)
619 return jjStopAtPos(1, 116);
620 else if ((active1 & 0x20000000000000L) != 0L)
621 return jjStopAtPos(1, 117);
622 else if ((active1 & 0x40000000000000L) != 0L)
623 return jjStopAtPos(1, 118);
624 else if ((active1 & 0x80000000000000L) != 0L)
625 return jjStopAtPos(1, 119);
626 else if ((active1 & 0x100000000000000L) != 0L)
627 return jjStopAtPos(1, 120);
628 else if ((active1 & 0x200000000000000L) != 0L)
629 return jjStopAtPos(1, 121);
630 else if ((active1 & 0x400000000000000L) != 0L)
631 return jjStopAtPos(1, 122);
634 if ((active0 & 0x4L) != 0L)
635 return jjStopAtPos(1, 2);
636 else if ((active0 & 0x80000000L) != 0L)
637 return jjStopAtPos(1, 31);
638 else if ((active0 & 0x200000000L) != 0L)
639 return jjStopAtPos(1, 33);
640 else if ((active1 & 0x1000000000000L) != 0L)
645 return jjMoveStringLiteralDfa2_1(active0, 0L, active1, 0x3002000000000000L);
648 return jjMoveStringLiteralDfa2_1(active0, 0x20800040000L, active1, 0L);
651 return jjMoveStringLiteralDfa2_1(active0, 0x40000000000000L, active1, 0L);
654 return jjMoveStringLiteralDfa2_1(active0, 0x1000000L, active1, 0L);
657 return jjMoveStringLiteralDfa2_1(active0, 0x200504014000000L, active1, 0L);
660 if ((active0 & 0x80000L) != 0L)
661 return jjStartNfaWithStates_1(1, 19, 14);
665 return jjMoveStringLiteralDfa2_1(active0, 0xa000000000000L, active1, 0L);
668 return jjMoveStringLiteralDfa2_1(active0, 0x800000020310000L, active1, 0L);
671 return jjMoveStringLiteralDfa2_1(active0, 0xb01000000a000000L, active1, 0L);
674 if ((active0 & 0x8000000000L) != 0L)
679 return jjMoveStringLiteralDfa2_1(active0, 0x5800c3000000000L, active1, 0L);
682 if ((active0 & 0x4000000000000000L) != 0L)
683 return jjStartNfaWithStates_1(1, 62, 14);
684 return jjMoveStringLiteralDfa2_1(active0, 0x4000400c00000L, active1, 0L);
687 return jjMoveStringLiteralDfa2_1(active0, 0x20000040000000L, active1, 0L);
690 return jjMoveStringLiteralDfa2_1(active0, 0xa00000020000L, active1, 0L);
693 return jjMoveStringLiteralDfa2_1(active0, 0x1000000000000L, active1, 0L);
696 return jjMoveStringLiteralDfa2_1(active0, 0x10000000000L, active1, 0L);
698 if ((active1 & 0x800000000L) != 0L)
699 return jjStopAtPos(1, 99);
704 return jjStartNfa_1(0, active0, active1);
706 static private final int jjMoveStringLiteralDfa2_1(long old0, long active0, long old1, long active1)
708 if (((active0 &= old0) | (active1 &= old1)) == 0L)
709 return jjStartNfa_1(0, old0, old1);
710 try { curChar = input_stream.readChar(); }
711 catch(java.io.IOException e) {
712 jjStopStringLiteralDfa_1(1, active0, active1);
718 if ((active1 & 0x800000000000000L) != 0L)
719 return jjStopAtPos(2, 123);
720 else if ((active1 & 0x1000000000000000L) != 0L)
721 return jjStopAtPos(2, 124);
724 if ((active1 & 0x2000000000000L) != 0L)
729 return jjMoveStringLiteralDfa3_1(active0, 0L, active1, 0x2000000000000000L);
732 return jjMoveStringLiteralDfa3_1(active0, 0x200000040010000L, active1, 0L);
735 return jjMoveStringLiteralDfa3_1(active0, 0xa000000L, active1, 0L);
738 if ((active0 & 0x8000000000000000L) != 0L)
739 return jjStartNfaWithStates_1(2, 63, 14);
740 return jjMoveStringLiteralDfa3_1(active0, 0x10000000000000L, active1, 0L);
743 return jjMoveStringLiteralDfa3_1(active0, 0x400000000L, active1, 0L);
746 return jjMoveStringLiteralDfa3_1(active0, 0x4000000000L, active1, 0L);
749 return jjMoveStringLiteralDfa3_1(active0, 0x1000000L, active1, 0L);
752 return jjMoveStringLiteralDfa3_1(active0, 0xb000000800000L, active1, 0L);
755 return jjMoveStringLiteralDfa3_1(active0, 0x40000000000000L, active1, 0L);
758 return jjMoveStringLiteralDfa3_1(active0, 0x220000000000L, active1, 0L);
761 return jjMoveStringLiteralDfa3_1(active0, 0x3000020000L, active1, 0L);
764 return jjMoveStringLiteralDfa3_1(active0, 0x980000020000000L, active1, 0L);
767 return jjMoveStringLiteralDfa3_1(active0, 0x800000000000L, active1, 0L);
770 return jjMoveStringLiteralDfa3_1(active0, 0x14000000L, active1, 0L);
773 if ((active0 & 0x40000L) != 0L)
774 return jjStartNfaWithStates_1(2, 18, 14);
775 else if ((active0 & 0x40000000000L) != 0L)
776 return jjStartNfaWithStates_1(2, 42, 14);
777 return jjMoveStringLiteralDfa3_1(active0, 0x20000000400000L, active1, 0L);
780 return jjMoveStringLiteralDfa3_1(active0, 0x800300000L, active1, 0L);
783 if ((active0 & 0x1000000000000000L) != 0L)
788 return jjMoveStringLiteralDfa3_1(active0, 0x2000490000000000L, active1, 0L);
791 return jjMoveStringLiteralDfa3_1(active0, 0x404000000000000L, active1, 0L);
794 if ((active0 & 0x100000000000L) != 0L)
795 return jjStartNfaWithStates_1(2, 44, 14);
800 return jjStartNfa_1(1, active0, active1);
802 static private final int jjMoveStringLiteralDfa3_1(long old0, long active0, long old1, long active1)
804 if (((active0 &= old0) | (active1 &= old1)) == 0L)
805 return jjStartNfa_1(1, old0, old1);
806 try { curChar = input_stream.readChar(); }
807 catch(java.io.IOException e) {
808 jjStopStringLiteralDfa_1(2, active0, active1);
814 if ((active1 & 0x2000000000000000L) != 0L)
815 return jjStopAtPos(3, 125);
819 return jjMoveStringLiteralDfa4_1(active0, 0x800004400400000L, active1, 0L);
822 return jjMoveStringLiteralDfa4_1(active0, 0x400000020000000L, active1, 0L);
825 return jjMoveStringLiteralDfa4_1(active0, 0x20000L, active1, 0L);
828 if ((active0 & 0x200000L) != 0L)
833 else if ((active0 & 0x800000000L) != 0L)
834 return jjStartNfaWithStates_1(3, 35, 14);
835 else if ((active0 & 0x4000000000000L) != 0L)
836 return jjStartNfaWithStates_1(3, 50, 14);
837 return jjMoveStringLiteralDfa4_1(active0, 0x2040810000100000L, active1, 0L);
840 return jjMoveStringLiteralDfa4_1(active0, 0x20000000000000L, active1, 0L);
843 if ((active0 & 0x200000000000L) != 0L)
844 return jjStartNfaWithStates_1(3, 45, 14);
845 else if ((active0 & 0x80000000000000L) != 0L)
850 else if ((active0 & 0x200000000000000L) != 0L)
851 return jjStartNfaWithStates_1(3, 57, 14);
852 return jjMoveStringLiteralDfa4_1(active0, 0x10800000a000000L, active1, 0L);
855 return jjMoveStringLiteralDfa4_1(active0, 0x800000L, active1, 0L);
858 if ((active0 & 0x1000000L) != 0L)
859 return jjStartNfaWithStates_1(3, 24, 14);
860 else if ((active0 & 0x80000000000L) != 0L)
861 return jjStartNfaWithStates_1(3, 43, 14);
865 if ((active0 & 0x2000000000000L) != 0L)
866 return jjStartNfaWithStates_1(3, 49, 14);
867 return jjMoveStringLiteralDfa4_1(active0, 0x21000010000L, active1, 0L);
870 return jjMoveStringLiteralDfa4_1(active0, 0x1002040000000L, active1, 0L);
873 return jjMoveStringLiteralDfa4_1(active0, 0x400014000000L, active1, 0L);
876 return jjMoveStringLiteralDfa4_1(active0, 0x10000000000000L, active1, 0L);
880 return jjStartNfa_1(2, active0, active1);
882 static private final int jjMoveStringLiteralDfa4_1(long old0, long active0, long old1, long active1)
884 if (((active0 &= old0) | (active1 &= old1)) == 0L)
885 return jjStartNfa_1(2, old0, old1);
886 try { curChar = input_stream.readChar(); }
887 catch(java.io.IOException e) {
888 jjStopStringLiteralDfa_1(3, active0, 0L);
895 return jjMoveStringLiteralDfa5_1(active0, 0x20000000L);
898 return jjMoveStringLiteralDfa5_1(active0, 0x41000000000000L);
901 if ((active0 & 0x20000000000L) != 0L)
902 return jjStartNfaWithStates_1(4, 41, 14);
903 else if ((active0 & 0x8000000000000L) != 0L)
904 return jjStartNfaWithStates_1(4, 51, 14);
905 return jjMoveStringLiteralDfa5_1(active0, 0x100000000000000L);
908 return jjMoveStringLiteralDfa5_1(active0, 0x2000000000000000L);
911 return jjMoveStringLiteralDfa5_1(active0, 0x10000000000000L);
914 return jjMoveStringLiteralDfa5_1(active0, 0x2054100000L);
917 if ((active0 & 0x400000000L) != 0L)
918 return jjStartNfaWithStates_1(4, 34, 14);
922 return jjMoveStringLiteralDfa5_1(active0, 0x400000000000000L);
925 return jjMoveStringLiteralDfa5_1(active0, 0x20010000000000L);
928 if ((active0 & 0x800000000000L) != 0L)
929 return jjStartNfaWithStates_1(4, 47, 14);
930 return jjMoveStringLiteralDfa5_1(active0, 0x400000000000L);
933 if ((active0 & 0x10000L) != 0L)
934 return jjStartNfaWithStates_1(4, 16, 14);
938 if ((active0 & 0x800000L) != 0L)
939 return jjStartNfaWithStates_1(4, 23, 14);
940 else if ((active0 & 0x1000000000L) != 0L)
941 return jjStartNfaWithStates_1(4, 36, 14);
942 else if ((active0 & 0x800000000000000L) != 0L)
943 return jjStartNfaWithStates_1(4, 59, 14);
944 return jjMoveStringLiteralDfa5_1(active0, 0x20000L);
947 return jjMoveStringLiteralDfa5_1(active0, 0x400a000000L);
950 if ((active0 & 0x400000L) != 0L)
951 return jjStartNfaWithStates_1(4, 22, 14);
956 return jjStartNfa_1(3, active0, 0L);
958 static private final int jjMoveStringLiteralDfa5_1(long old0, long active0)
960 if (((active0 &= old0)) == 0L)
961 return jjStartNfa_1(3, old0, 0L);
962 try { curChar = input_stream.readChar(); }
963 catch(java.io.IOException e) {
964 jjStopStringLiteralDfa_1(4, active0, 0L);
971 return jjMoveStringLiteralDfa6_1(active0, 0x100000000000000L);
974 if ((active0 & 0x40000000L) != 0L)
975 return jjStartNfaWithStates_1(5, 30, 14);
979 return jjMoveStringLiteralDfa6_1(active0, 0x1000a000000L);
982 if ((active0 & 0x400000000000000L) != 0L)
983 return jjStartNfaWithStates_1(5, 58, 14);
984 return jjMoveStringLiteralDfa6_1(active0, 0x2000000000000000L);
987 if ((active0 & 0x100000L) != 0L)
988 return jjStartNfaWithStates_1(5, 20, 14);
992 if ((active0 & 0x20000000000000L) != 0L)
993 return jjStartNfaWithStates_1(5, 53, 14);
997 if ((active0 & 0x1000000000000L) != 0L)
998 return jjStartNfaWithStates_1(5, 48, 14);
1002 return jjMoveStringLiteralDfa6_1(active0, 0x10000000020000L);
1005 if ((active0 & 0x20000000L) != 0L)
1006 return jjStartNfaWithStates_1(5, 29, 14);
1007 return jjMoveStringLiteralDfa6_1(active0, 0x4000000000L);
1010 if ((active0 & 0x400000000000L) != 0L)
1011 return jjStartNfaWithStates_1(5, 46, 14);
1012 return jjMoveStringLiteralDfa6_1(active0, 0x2000000000L);
1015 return jjMoveStringLiteralDfa6_1(active0, 0x14000000L);
1018 if ((active0 & 0x40000000000000L) != 0L)
1019 return jjStartNfaWithStates_1(5, 54, 14);
1024 return jjStartNfa_1(4, active0, 0L);
1026 static private final int jjMoveStringLiteralDfa6_1(long old0, long active0)
1028 if (((active0 &= old0)) == 0L)
1029 return jjStartNfa_1(4, old0, 0L);
1030 try { curChar = input_stream.readChar(); }
1031 catch(java.io.IOException e) {
1032 jjStopStringLiteralDfa_1(5, active0, 0L);
1039 if ((active0 & 0x2000000L) != 0L)
1044 else if ((active0 & 0x4000000L) != 0L)
1049 return jjMoveStringLiteralDfa7_1(active0, 0x18000000L);
1052 return jjMoveStringLiteralDfa7_1(active0, 0x10000000000000L);
1055 if ((active0 & 0x100000000000000L) != 0L)
1056 return jjStartNfaWithStates_1(6, 56, 14);
1060 return jjMoveStringLiteralDfa7_1(active0, 0x20000L);
1063 if ((active0 & 0x2000000000000000L) != 0L)
1064 return jjStartNfaWithStates_1(6, 61, 14);
1068 if ((active0 & 0x10000000000L) != 0L)
1069 return jjStartNfaWithStates_1(6, 40, 14);
1073 if ((active0 & 0x4000000000L) != 0L)
1074 return jjStartNfaWithStates_1(6, 38, 14);
1078 return jjMoveStringLiteralDfa7_1(active0, 0x2000000000L);
1082 return jjStartNfa_1(5, active0, 0L);
1084 static private final int jjMoveStringLiteralDfa7_1(long old0, long active0)
1086 if (((active0 &= old0)) == 0L)
1087 return jjStartNfa_1(5, old0, 0L);
1088 try { curChar = input_stream.readChar(); }
1089 catch(java.io.IOException e) {
1090 jjStopStringLiteralDfa_1(6, active0, 0L);
1096 return jjMoveStringLiteralDfa8_1(active0, 0x18000000L);
1099 if ((active0 & 0x2000000000L) != 0L)
1100 return jjStartNfaWithStates_1(7, 37, 14);
1101 else if ((active0 & 0x10000000000000L) != 0L)
1102 return jjStartNfaWithStates_1(7, 52, 14);
1106 if ((active0 & 0x20000L) != 0L)
1107 return jjStartNfaWithStates_1(7, 17, 14);
1112 return jjStartNfa_1(6, active0, 0L);
1114 static private final int jjMoveStringLiteralDfa8_1(long old0, long active0)
1116 if (((active0 &= old0)) == 0L)
1117 return jjStartNfa_1(6, old0, 0L);
1118 try { curChar = input_stream.readChar(); }
1119 catch(java.io.IOException e) {
1120 jjStopStringLiteralDfa_1(7, active0, 0L);
1127 return jjMoveStringLiteralDfa9_1(active0, 0x18000000L);
1131 return jjStartNfa_1(7, active0, 0L);
1133 static private final int jjMoveStringLiteralDfa9_1(long old0, long active0)
1135 if (((active0 &= old0)) == 0L)
1136 return jjStartNfa_1(7, old0, 0L);
1137 try { curChar = input_stream.readChar(); }
1138 catch(java.io.IOException e) {
1139 jjStopStringLiteralDfa_1(8, active0, 0L);
1146 return jjMoveStringLiteralDfa10_1(active0, 0x18000000L);
1150 return jjStartNfa_1(8, active0, 0L);
1152 static private final int jjMoveStringLiteralDfa10_1(long old0, long active0)
1154 if (((active0 &= old0)) == 0L)
1155 return jjStartNfa_1(8, old0, 0L);
1156 try { curChar = input_stream.readChar(); }
1157 catch(java.io.IOException e) {
1158 jjStopStringLiteralDfa_1(9, active0, 0L);
1165 return jjMoveStringLiteralDfa11_1(active0, 0x18000000L);
1169 return jjStartNfa_1(9, active0, 0L);
1171 static private final int jjMoveStringLiteralDfa11_1(long old0, long active0)
1173 if (((active0 &= old0)) == 0L)
1174 return jjStartNfa_1(9, old0, 0L);
1175 try { curChar = input_stream.readChar(); }
1176 catch(java.io.IOException e) {
1177 jjStopStringLiteralDfa_1(10, active0, 0L);
1184 if ((active0 & 0x8000000L) != 0L)
1185 return jjStartNfaWithStates_1(11, 27, 14);
1186 else if ((active0 & 0x10000000L) != 0L)
1187 return jjStartNfaWithStates_1(11, 28, 14);
1192 return jjStartNfa_1(10, active0, 0L);
1194 static final long[] jjbitVec0 = {
1195 0x0L, 0x0L, 0xffffffffffffffffL, 0xffffffffffffffffL
1197 static private final int jjMoveNfa_1(int startState, int curPos)
1203 jjstateSet[0] = startState;
1204 int j, kind = 0x7fffffff;
1207 if (++jjround == 0x7fffffff)
1211 long l = 1L << curChar;
1214 switch(jjstateSet[--i])
1217 if ((0x3ff000000000000L & l) != 0L)
1218 jjCheckNAddStates(2, 8);
1219 else if (curChar == 39)
1220 jjCheckNAddStates(9, 12);
1221 else if (curChar == 34)
1222 jjCheckNAddStates(13, 18);
1223 else if (curChar == 36)
1224 jjstateSet[jjnewStateCnt++] = 16;
1225 else if (curChar == 46)
1227 else if (curChar == 47)
1228 jjstateSet[jjnewStateCnt++] = 2;
1229 if ((0x3fe000000000000L & l) != 0L)
1233 jjCheckNAddTwoStates(5, 6);
1235 else if (curChar == 48)
1239 jjCheckNAddStates(19, 21);
1244 jjstateSet[jjnewStateCnt++] = 1;
1247 if ((0xffff7fffffffffffL & l) != 0L && kind > 10)
1252 jjstateSet[jjnewStateCnt++] = 0;
1255 if ((0x3fe000000000000L & l) == 0L)
1259 jjCheckNAddTwoStates(5, 6);
1262 if ((0x3ff000000000000L & l) == 0L)
1266 jjCheckNAddTwoStates(5, 6);
1273 if ((0x3ff000000000000L & l) == 0L)
1277 jjCheckNAddStates(22, 24);
1280 if ((0x280000000000L & l) != 0L)
1284 if ((0x3ff000000000000L & l) == 0L)
1288 jjCheckNAddTwoStates(11, 12);
1291 if ((0x3ff000000000000L & l) == 0L)
1295 jjstateSet[jjnewStateCnt++] = 14;
1299 jjstateSet[jjnewStateCnt++] = 16;
1302 if ((0x3ff000000000000L & l) == 0L)
1306 jjstateSet[jjnewStateCnt++] = 17;
1309 if ((0x3ff000000000000L & l) != 0L)
1310 jjCheckNAddStates(2, 8);
1313 if ((0x3ff000000000000L & l) != 0L)
1314 jjCheckNAddTwoStates(19, 20);
1321 jjCheckNAddStates(25, 27);
1324 if ((0x3ff000000000000L & l) == 0L)
1328 jjCheckNAddStates(25, 27);
1331 if ((0x280000000000L & l) != 0L)
1335 if ((0x3ff000000000000L & l) == 0L)
1339 jjCheckNAddTwoStates(24, 12);
1342 if ((0x3ff000000000000L & l) != 0L)
1343 jjCheckNAddTwoStates(25, 26);
1346 if ((0x280000000000L & l) != 0L)
1350 if ((0x3ff000000000000L & l) == 0L)
1354 jjCheckNAddTwoStates(28, 12);
1357 if ((0x3ff000000000000L & l) != 0L)
1358 jjCheckNAddStates(28, 30);
1361 if ((0x280000000000L & l) != 0L)
1365 if ((0x3ff000000000000L & l) != 0L)
1366 jjCheckNAddTwoStates(32, 12);
1373 jjCheckNAddStates(19, 21);
1376 if ((0x3ff000000000000L & l) == 0L)
1380 jjCheckNAddTwoStates(35, 6);
1383 if ((0xff000000000000L & l) == 0L)
1387 jjCheckNAddTwoStates(36, 6);
1391 jjCheckNAddStates(13, 18);
1394 if ((0xfffffffbffffffffL & l) != 0L)
1395 jjCheckNAddStates(31, 33);
1399 jjCheckNAddStates(31, 33);
1402 if (curChar == 34 && kind > 70)
1406 if ((0xfffffffbffffffffL & l) != 0L)
1407 jjCheckNAddStates(34, 36);
1411 jjCheckNAddStates(34, 36);
1414 if (curChar == 34 && kind > 71)
1419 jjCheckNAddStates(9, 12);
1422 if ((0xffffff7fffffffffL & l) != 0L)
1423 jjCheckNAddTwoStates(47, 48);
1426 if (curChar == 39 && kind > 70)
1430 if ((0xffffff7fffffffffL & l) != 0L)
1431 jjCheckNAddTwoStates(49, 50);
1434 if (curChar == 39 && kind > 72)
1438 jjAddStates(37, 38);
1441 jjAddStates(39, 40);
1445 } while(i != startsAt);
1447 else if (curChar < 128)
1449 long l = 1L << (curChar & 077);
1452 switch(jjstateSet[--i])
1455 if ((0x7fffffe87fffffeL & l) != 0L)
1461 else if (curChar == 96)
1462 jjCheckNAddStates(41, 44);
1469 if ((0x100000001000L & l) != 0L && kind > 64)
1473 if ((0x2000000020L & l) != 0L)
1474 jjAddStates(45, 46);
1477 if ((0x5000000050L & l) != 0L && kind > 68)
1482 if ((0x7fffffe87fffffeL & l) == 0L)
1490 if ((0x7fffffe87fffffeL & l) == 0L)
1497 if ((0x2000000020L & l) != 0L)
1498 jjAddStates(47, 48);
1501 if ((0x2000000020L & l) != 0L)
1502 jjAddStates(49, 50);
1505 if ((0x2000000020L & l) != 0L)
1506 jjAddStates(51, 52);
1509 if ((0x100000001000000L & l) != 0L)
1513 if ((0x7e0000007eL & l) == 0L)
1517 jjCheckNAddTwoStates(35, 6);
1520 jjAddStates(31, 33);
1524 jjstateSet[jjnewStateCnt++] = 39;
1527 jjAddStates(34, 36);
1531 jjstateSet[jjnewStateCnt++] = 43;
1534 jjAddStates(53, 54);
1537 jjAddStates(55, 56);
1541 jjCheckNAddStates(41, 44);
1544 if ((0xfffffffeffffffffL & l) != 0L)
1545 jjCheckNAddTwoStates(52, 53);
1548 if (curChar == 96 && kind > 70)
1552 if ((0xfffffffeffffffffL & l) != 0L)
1553 jjCheckNAddTwoStates(54, 55);
1556 if (curChar == 96 && kind > 73)
1561 } while(i != startsAt);
1565 int i2 = (curChar & 0xff) >> 6;
1566 long l2 = 1L << (curChar & 077);
1569 switch(jjstateSet[--i])
1572 if ((jjbitVec0[i2] & l2) != 0L && kind > 10)
1576 if ((jjbitVec0[i2] & l2) != 0L)
1577 jjAddStates(31, 33);
1580 if ((jjbitVec0[i2] & l2) != 0L)
1581 jjAddStates(34, 36);
1584 if ((jjbitVec0[i2] & l2) != 0L)
1585 jjAddStates(53, 54);
1588 if ((jjbitVec0[i2] & l2) != 0L)
1589 jjAddStates(55, 56);
1592 if ((jjbitVec0[i2] & l2) != 0L)
1593 jjAddStates(37, 38);
1596 if ((jjbitVec0[i2] & l2) != 0L)
1597 jjAddStates(39, 40);
1601 } while(i != startsAt);
1603 if (kind != 0x7fffffff)
1605 jjmatchedKind = kind;
1606 jjmatchedPos = curPos;
1610 if ((i = jjnewStateCnt) == (startsAt = 56 - (jjnewStateCnt = startsAt)))
1612 try { curChar = input_stream.readChar(); }
1613 catch(java.io.IOException e) { return curPos; }
1616 static private final int jjMoveStringLiteralDfa0_3()
1621 return jjMoveStringLiteralDfa1_3(0x2000L);
1626 static private final int jjMoveStringLiteralDfa1_3(long active0)
1628 try { curChar = input_stream.readChar(); }
1629 catch(java.io.IOException e) {
1635 if ((active0 & 0x2000L) != 0L)
1636 return jjStopAtPos(1, 13);
1643 static final int[] jjnextStates = {
1644 4, 5, 19, 20, 25, 26, 29, 30, 12, 47, 48, 49, 50, 38, 40, 41,
1645 42, 44, 45, 34, 36, 6, 8, 9, 12, 21, 22, 12, 29, 30, 12, 38,
1646 40, 41, 42, 44, 45, 52, 53, 54, 55, 52, 53, 54, 55, 10, 11, 23,
1647 24, 27, 28, 31, 32, 47, 48, 49, 50,
1649 public static final String[] jjstrLiteralImages = {
1650 "", null, "\77\76", null, null, null, null, null, null, null, null, null, null,
1651 null, null, null, null, null, null, null, null, null, null, null, null, null, null,
1652 null, null, null, null, "\55\76", "\72\72", "\75\76", null, null, null, null, null,
1653 null, null, null, null, null, null, null, null, null, null, null, null, null, null,
1654 null, null, null, null, null, null, null, null, null, null, null, null, null, null,
1655 null, null, null, null, null, null, null, null, null, null, null, "\50", "\51",
1656 "\173", "\175", "\133", "\135", "\73", "\54", "\56", "\100", "\44", "\75", "\76",
1657 "\74", "\41", "\77", "\72", "\75\75", "\74\75", "\76\75", "\41\75", "\174\174",
1658 "\46\46", "\53\53", "\55\55", "\53", "\55", "\52", "\57", "\46", "\174", "\136", "\45",
1659 "\74\74", "\76\76", "\76\76\76", "\53\75", "\55\75", "\52\75", "\57\75", "\46\75",
1660 "\174\75", "\136\75", "\56\75", "\45\75", "\74\74\75", "\76\76\75", "\76\76\76\75", null,
1662 public static final String[] lexStateNames = {
1665 "IN_SINGLE_LINE_COMMENT",
1666 "IN_FORMAL_COMMENT",
1667 "IN_MULTI_LINE_COMMENT",
1669 public static final int[] jjnewLexState = {
1670 -1, 1, 0, -1, -1, -1, -1, -1, -1, 2, 3, 4, 1, 1, 1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
1671 -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
1672 -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
1673 -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
1674 -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
1677 static final long[] jjtoToken = {
1678 0xffffffffffff0007L, 0xffffffffffffc7d1L, 0x0L,
1680 static final long[] jjtoSkip = {
1681 0x71f8L, 0x0L, 0x0L,
1683 static final long[] jjtoSpecial = {
1684 0x7000L, 0x0L, 0x0L,
1686 static final long[] jjtoMore = {
1687 0x8e00L, 0x0L, 0x0L,
1689 static private SimpleCharStream input_stream;
1690 static private final int[] jjrounds = new int[56];
1691 static private final int[] jjstateSet = new int[112];
1692 static StringBuffer image;
1693 static int jjimageLen;
1694 static int lengthOfMatch;
1695 static protected char curChar;
1696 public PHPParserTokenManager(SimpleCharStream stream)
1698 if (input_stream != null)
1699 throw new TokenMgrError("ERROR: Second call to constructor of static lexer. You must use ReInit() to initialize the static variables.", TokenMgrError.STATIC_LEXER_ERROR);
1700 input_stream = stream;
1702 public PHPParserTokenManager(SimpleCharStream stream, int lexState)
1707 static public void ReInit(SimpleCharStream stream)
1709 jjmatchedPos = jjnewStateCnt = 0;
1710 curLexState = defaultLexState;
1711 input_stream = stream;
1714 static private final void ReInitRounds()
1717 jjround = 0x80000001;
1718 for (i = 56; i-- > 0;)
1719 jjrounds[i] = 0x80000000;
1721 static public void ReInit(SimpleCharStream stream, int lexState)
1726 static public void SwitchTo(int lexState)
1728 if (lexState >= 5 || lexState < 0)
1729 throw new TokenMgrError("Error: Ignoring invalid lexical state : " + lexState + ". State unchanged.", TokenMgrError.INVALID_LEXICAL_STATE);
1731 curLexState = lexState;
1734 static private final Token jjFillToken()
1736 Token t = Token.newToken(jjmatchedKind);
1737 t.kind = jjmatchedKind;
1738 String im = jjstrLiteralImages[jjmatchedKind];
1739 t.image = (im == null) ? input_stream.GetImage() : im;
1740 t.beginLine = input_stream.getBeginLine();
1741 t.beginColumn = input_stream.getBeginColumn();
1742 t.endLine = input_stream.getEndLine();
1743 t.endColumn = input_stream.getEndColumn();
1747 static int curLexState = 0;
1748 static int defaultLexState = 0;
1749 static int jjnewStateCnt;
1751 static int jjmatchedPos;
1752 static int jjmatchedKind;
1754 public static final Token getNextToken()
1757 Token specialToken = null;
1766 curChar = input_stream.BeginToken();
1768 catch(java.io.IOException e)
1771 matchedToken = jjFillToken();
1772 matchedToken.specialToken = specialToken;
1773 return matchedToken;
1783 jjmatchedKind = 0x7fffffff;
1785 curPos = jjMoveStringLiteralDfa0_0();
1786 if (jjmatchedPos == 0 && jjmatchedKind > 3)
1792 try { input_stream.backup(0);
1793 while (curChar <= 32 && (0x100003600L & (1L << curChar)) != 0L)
1794 curChar = input_stream.BeginToken();
1796 catch (java.io.IOException e1) { continue EOFLoop; }
1797 jjmatchedKind = 0x7fffffff;
1799 curPos = jjMoveStringLiteralDfa0_1();
1802 jjmatchedKind = 0x7fffffff;
1804 curPos = jjMoveStringLiteralDfa0_2();
1805 if (jjmatchedPos == 0 && jjmatchedKind > 15)
1811 jjmatchedKind = 0x7fffffff;
1813 curPos = jjMoveStringLiteralDfa0_3();
1814 if (jjmatchedPos == 0 && jjmatchedKind > 15)
1820 jjmatchedKind = 0x7fffffff;
1822 curPos = jjMoveStringLiteralDfa0_4();
1823 if (jjmatchedPos == 0 && jjmatchedKind > 15)
1829 if (jjmatchedKind != 0x7fffffff)
1831 if (jjmatchedPos + 1 < curPos)
1832 input_stream.backup(curPos - jjmatchedPos - 1);
1833 if ((jjtoToken[jjmatchedKind >> 6] & (1L << (jjmatchedKind & 077))) != 0L)
1835 matchedToken = jjFillToken();
1836 matchedToken.specialToken = specialToken;
1837 if (jjnewLexState[jjmatchedKind] != -1)
1838 curLexState = jjnewLexState[jjmatchedKind];
1839 return matchedToken;
1841 else if ((jjtoSkip[jjmatchedKind >> 6] & (1L << (jjmatchedKind & 077))) != 0L)
1843 if ((jjtoSpecial[jjmatchedKind >> 6] & (1L << (jjmatchedKind & 077))) != 0L)
1845 matchedToken = jjFillToken();
1846 if (specialToken == null)
1847 specialToken = matchedToken;
1850 matchedToken.specialToken = specialToken;
1851 specialToken = (specialToken.next = matchedToken);
1853 SkipLexicalActions(matchedToken);
1856 SkipLexicalActions(null);
1857 if (jjnewLexState[jjmatchedKind] != -1)
1858 curLexState = jjnewLexState[jjmatchedKind];
1861 MoreLexicalActions();
1862 if (jjnewLexState[jjmatchedKind] != -1)
1863 curLexState = jjnewLexState[jjmatchedKind];
1865 jjmatchedKind = 0x7fffffff;
1867 curChar = input_stream.readChar();
1870 catch (java.io.IOException e1) { }
1872 int error_line = input_stream.getEndLine();
1873 int error_column = input_stream.getEndColumn();
1874 String error_after = null;
1875 boolean EOFSeen = false;
1876 try { input_stream.readChar(); input_stream.backup(1); }
1877 catch (java.io.IOException e1) {
1879 error_after = curPos <= 1 ? "" : input_stream.GetImage();
1880 if (curChar == '\n' || curChar == '\r') {
1888 input_stream.backup(1);
1889 error_after = curPos <= 1 ? "" : input_stream.GetImage();
1891 throw new TokenMgrError(EOFSeen, curLexState, error_line, error_column, error_after, curChar, TokenMgrError.LEXICAL_ERROR);
1896 static final void SkipLexicalActions(Token matchedToken)
1898 switch(jjmatchedKind)
1904 static final void MoreLexicalActions()
1906 jjimageLen += (lengthOfMatch = jjmatchedPos + 1);
1907 switch(jjmatchedKind)
1911 image = new StringBuffer(new String(input_stream.GetSuffix(jjimageLen)));
1913 image.append(new String(input_stream.GetSuffix(jjimageLen)));
1915 input_stream.backup(1);