X-Git-Url: http://secure.phpeclipse.com diff --git a/net.sourceforge.phpeclipse/src/test/PHPParserTokenManager.java b/net.sourceforge.phpeclipse/src/test/PHPParserTokenManager.java index bbdad0b..d651379 100644 --- a/net.sourceforge.phpeclipse/src/test/PHPParserTokenManager.java +++ b/net.sourceforge.phpeclipse/src/test/PHPParserTokenManager.java @@ -1,5 +1,22 @@ /* Generated By:JavaCC: Do not edit this line. PHPParserTokenManager.java */ package test; +import org.eclipse.core.resources.IFile; +import org.eclipse.core.resources.IMarker; +import org.eclipse.core.runtime.CoreException; +import org.eclipse.ui.texteditor.MarkerUtilities; +import org.eclipse.jface.preference.IPreferenceStore; +import java.util.Hashtable; +import java.util.ArrayList; +import java.io.StringReader; +import java.io.*; +import java.text.MessageFormat; +import net.sourceforge.phpeclipse.actions.PHPStartApacheAction; +import net.sourceforge.phpeclipse.PHPeclipsePlugin; +import net.sourceforge.phpdt.internal.compiler.ast.*; +import net.sourceforge.phpdt.internal.compiler.parser.OutlineableWithChildren; +import net.sourceforge.phpdt.internal.compiler.parser.Outlineable; +import net.sourceforge.phpdt.internal.compiler.parser.PHPOutlineInfo; +import net.sourceforge.phpdt.internal.corext.Assert; public class PHPParserTokenManager implements PHPParserConstants { @@ -7,19 +24,19 @@ public class PHPParserTokenManager implements PHPParserConstants // CharStream class to set corresponding fields in each Token (which was // also extended with new fields). By default Jack doesn't supply absolute // offsets, just line/column offsets - static void CommonTokenAction(Token t) { - t.sourceStart = input_stream.beginOffset; - t.sourceEnd = input_stream.endOffset; + void CommonTokenAction(Token t) { + t.sourceStart = input_stream.getBeginOffset(); + t.sourceEnd = input_stream.getBeginOffset(); } - public static java.io.PrintStream debugStream = System.out; - public static void setDebugStream(java.io.PrintStream ds) { debugStream = ds; } -static private final int jjStopAtPos(int pos, int kind) + public java.io.PrintStream debugStream = System.out; + public void setDebugStream(java.io.PrintStream ds) { debugStream = ds; } +private final int jjStopAtPos(int pos, int kind) { jjmatchedKind = kind; jjmatchedPos = pos; return pos + 1; } -static private final int jjMoveStringLiteralDfa0_5() +private final int jjMoveStringLiteralDfa0_5() { switch(curChar) { @@ -32,7 +49,7 @@ static private final int jjMoveStringLiteralDfa0_5() return 1; } } -static private final int jjMoveStringLiteralDfa1_5(long active0) +private final int jjMoveStringLiteralDfa1_5(long active0) { try { curChar = input_stream.readChar(); } catch(java.io.IOException e) { @@ -52,7 +69,7 @@ static private final int jjMoveStringLiteralDfa1_5(long active0) } return 2; } -static private final int jjMoveStringLiteralDfa2_5(long old0, long active0) +private final int jjMoveStringLiteralDfa2_5(long old0, long active0) { if (((active0 &= old0)) == 0L) return 2; @@ -69,7 +86,7 @@ static private final int jjMoveStringLiteralDfa2_5(long old0, long active0) return 3; } } -static private final int jjMoveStringLiteralDfa3_5(long old0, long active0) +private final int jjMoveStringLiteralDfa3_5(long old0, long active0) { if (((active0 &= old0)) == 0L) return 3; @@ -89,7 +106,7 @@ static private final int jjMoveStringLiteralDfa3_5(long old0, long active0) } return 4; } -static private final int jjMoveStringLiteralDfa0_8() +private final int jjMoveStringLiteralDfa0_8() { switch(curChar) { @@ -99,7 +116,7 @@ static private final int jjMoveStringLiteralDfa0_8() return 1; } } -private static final int jjStopStringLiteralDfa_9(int pos, long active0, long active1) +private final int jjStopStringLiteralDfa_9(int pos, long active0, long active1) { switch (pos) { @@ -107,11 +124,11 @@ private static final int jjStopStringLiteralDfa_9(int pos, long active0, long ac return -1; } } -private static final int jjStartNfa_9(int pos, long active0, long active1) +private final int jjStartNfa_9(int pos, long active0, long active1) { return jjMoveNfa_9(jjStopStringLiteralDfa_9(pos, active0, active1), pos + 1); } -static private final int jjStartNfaWithStates_9(int pos, int kind, int state) +private final int jjStartNfaWithStates_9(int pos, int kind, int state) { jjmatchedKind = kind; jjmatchedPos = pos; @@ -119,7 +136,7 @@ static private final int jjStartNfaWithStates_9(int pos, int kind, int state) catch(java.io.IOException e) { return pos + 1; } return jjMoveNfa_9(state, pos + 1); } -static private final int jjMoveStringLiteralDfa0_9() +private final int jjMoveStringLiteralDfa0_9() { switch(curChar) { @@ -129,7 +146,7 @@ static private final int jjMoveStringLiteralDfa0_9() return jjMoveNfa_9(0, 0); } } -static private final void jjCheckNAdd(int state) +private final void jjCheckNAdd(int state) { if (jjrounds[state] != jjround) { @@ -137,24 +154,24 @@ static private final void jjCheckNAdd(int state) jjrounds[state] = jjround; } } -static private final void jjAddStates(int start, int end) +private final void jjAddStates(int start, int end) { do { jjstateSet[jjnewStateCnt++] = jjnextStates[start]; } while (start++ != end); } -static private final void jjCheckNAddTwoStates(int state1, int state2) +private final void jjCheckNAddTwoStates(int state1, int state2) { jjCheckNAdd(state1); jjCheckNAdd(state2); } -static private final void jjCheckNAddStates(int start, int end) +private final void jjCheckNAddStates(int start, int end) { do { jjCheckNAdd(jjnextStates[start]); } while (start++ != end); } -static private final void jjCheckNAddStates(int start) +private final void jjCheckNAddStates(int start) { jjCheckNAdd(jjnextStates[start]); jjCheckNAdd(jjnextStates[start + 1]); @@ -162,7 +179,7 @@ static private final void jjCheckNAddStates(int start) static final long[] jjbitVec0 = { 0x0L, 0x0L, 0xffffffffffffffffL, 0xffffffffffffffffL }; -static private final int jjMoveNfa_9(int startState, int curPos) +private final int jjMoveNfa_9(int startState, int curPos) { int[] nextStates; int startsAt = 0; @@ -238,7 +255,7 @@ static private final int jjMoveNfa_9(int startState, int curPos) catch(java.io.IOException e) { return curPos; } } } -static private final int jjMoveStringLiteralDfa0_0() +private final int jjMoveStringLiteralDfa0_0() { switch(curChar) { @@ -251,7 +268,7 @@ static private final int jjMoveStringLiteralDfa0_0() return 1; } } -static private final int jjMoveStringLiteralDfa1_0(long active0) +private final int jjMoveStringLiteralDfa1_0(long active0) { try { curChar = input_stream.readChar(); } catch(java.io.IOException e) { @@ -273,7 +290,7 @@ static private final int jjMoveStringLiteralDfa1_0(long active0) return 2; } } -static private final int jjMoveStringLiteralDfa2_0(long old0, long active0) +private final int jjMoveStringLiteralDfa2_0(long old0, long active0) { if (((active0 &= old0)) == 0L) return 2; @@ -298,7 +315,7 @@ static private final int jjMoveStringLiteralDfa2_0(long old0, long active0) } return 3; } -static private final int jjMoveStringLiteralDfa3_0(long old0, long active0) +private final int jjMoveStringLiteralDfa3_0(long old0, long active0) { if (((active0 &= old0)) == 0L) return 3; @@ -321,7 +338,7 @@ static private final int jjMoveStringLiteralDfa3_0(long old0, long active0) } return 4; } -static private final int jjMoveStringLiteralDfa4_0(long old0, long active0) +private final int jjMoveStringLiteralDfa4_0(long old0, long active0) { if (((active0 &= old0)) == 0L) return 4; @@ -341,7 +358,7 @@ static private final int jjMoveStringLiteralDfa4_0(long old0, long active0) } return 5; } -static private final int jjMoveStringLiteralDfa0_4() +private final int jjMoveStringLiteralDfa0_4() { switch(curChar) { @@ -354,7 +371,7 @@ static private final int jjMoveStringLiteralDfa0_4() return 1; } } -static private final int jjMoveStringLiteralDfa1_4(long active0) +private final int jjMoveStringLiteralDfa1_4(long active0) { try { curChar = input_stream.readChar(); } catch(java.io.IOException e) { @@ -374,7 +391,7 @@ static private final int jjMoveStringLiteralDfa1_4(long active0) } return 2; } -static private final int jjMoveStringLiteralDfa2_4(long old0, long active0) +private final int jjMoveStringLiteralDfa2_4(long old0, long active0) { if (((active0 &= old0)) == 0L) return 2; @@ -391,7 +408,7 @@ static private final int jjMoveStringLiteralDfa2_4(long old0, long active0) return 3; } } -static private final int jjMoveStringLiteralDfa3_4(long old0, long active0) +private final int jjMoveStringLiteralDfa3_4(long old0, long active0) { if (((active0 &= old0)) == 0L) return 3; @@ -411,7 +428,7 @@ static private final int jjMoveStringLiteralDfa3_4(long old0, long active0) } return 4; } -private static final int jjStopStringLiteralDfa_3(int pos, long active0, long active1, long active2) +private final int jjStopStringLiteralDfa_3(int pos, long active0, long active1, long active2) { switch (pos) { @@ -439,11 +456,11 @@ private static final int jjStopStringLiteralDfa_3(int pos, long active0, long ac return -1; } } -private static final int jjStartNfa_3(int pos, long active0, long active1, long active2) +private final int jjStartNfa_3(int pos, long active0, long active1, long active2) { return jjMoveNfa_3(jjStopStringLiteralDfa_3(pos, active0, active1, active2), pos + 1); } -static private final int jjStartNfaWithStates_3(int pos, int kind, int state) +private final int jjStartNfaWithStates_3(int pos, int kind, int state) { jjmatchedKind = kind; jjmatchedPos = pos; @@ -451,7 +468,7 @@ static private final int jjStartNfaWithStates_3(int pos, int kind, int state) catch(java.io.IOException e) { return pos + 1; } return jjMoveNfa_3(state, pos + 1); } -static private final int jjMoveStringLiteralDfa0_3() +private final int jjMoveStringLiteralDfa0_3() { switch(curChar) { @@ -543,7 +560,7 @@ static private final int jjMoveStringLiteralDfa0_3() return jjMoveNfa_3(0, 0); } } -static private final int jjMoveStringLiteralDfa1_3(long active0, long active1, long active2) +private final int jjMoveStringLiteralDfa1_3(long active0, long active1, long active2) { try { curChar = input_stream.readChar(); } catch(java.io.IOException e) { @@ -643,7 +660,7 @@ static private final int jjMoveStringLiteralDfa1_3(long active0, long active1, l } return jjStartNfa_3(0, active0, active1, active2); } -static private final int jjMoveStringLiteralDfa2_3(long old0, long active0, long old1, long active1, long old2, long active2) +private final int jjMoveStringLiteralDfa2_3(long old0, long active0, long old1, long active1, long old2, long active2) { if (((active0 &= old0) | (active1 &= old1) | (active2 &= old2)) == 0L) return jjStartNfa_3(0, old0, old1, old2); @@ -678,7 +695,7 @@ static private final int jjMoveStringLiteralDfa2_3(long old0, long active0, long } return jjStartNfa_3(1, 0L, active1, active2); } -static private final int jjMoveNfa_3(int startState, int curPos) +private final int jjMoveNfa_3(int startState, int curPos) { int[] nextStates; int startsAt = 0; @@ -759,7 +776,7 @@ static private final int jjMoveNfa_3(int startState, int curPos) catch(java.io.IOException e) { return curPos; } } } -private static final int jjStopStringLiteralDfa_6(int pos, long active0, long active1) +private final int jjStopStringLiteralDfa_6(int pos, long active0, long active1) { switch (pos) { @@ -767,11 +784,11 @@ private static final int jjStopStringLiteralDfa_6(int pos, long active0, long ac return -1; } } -private static final int jjStartNfa_6(int pos, long active0, long active1) +private final int jjStartNfa_6(int pos, long active0, long active1) { return jjMoveNfa_6(jjStopStringLiteralDfa_6(pos, active0, active1), pos + 1); } -static private final int jjStartNfaWithStates_6(int pos, int kind, int state) +private final int jjStartNfaWithStates_6(int pos, int kind, int state) { jjmatchedKind = kind; jjmatchedPos = pos; @@ -779,7 +796,7 @@ static private final int jjStartNfaWithStates_6(int pos, int kind, int state) catch(java.io.IOException e) { return pos + 1; } return jjMoveNfa_6(state, pos + 1); } -static private final int jjMoveStringLiteralDfa0_6() +private final int jjMoveStringLiteralDfa0_6() { switch(curChar) { @@ -793,7 +810,7 @@ static private final int jjMoveStringLiteralDfa0_6() return jjMoveNfa_6(0, 0); } } -static private final int jjMoveNfa_6(int startState, int curPos) +private final int jjMoveNfa_6(int startState, int curPos) { int[] nextStates; int startsAt = 0; @@ -867,7 +884,7 @@ static private final int jjMoveNfa_6(int startState, int curPos) catch(java.io.IOException e) { return curPos; } } } -private static final int jjStopStringLiteralDfa_2(int pos, long active0) +private final int jjStopStringLiteralDfa_2(int pos, long active0) { switch (pos) { @@ -875,11 +892,11 @@ private static final int jjStopStringLiteralDfa_2(int pos, long active0) return -1; } } -private static final int jjStartNfa_2(int pos, long active0) +private final int jjStartNfa_2(int pos, long active0) { return jjMoveNfa_2(jjStopStringLiteralDfa_2(pos, active0), pos + 1); } -static private final int jjStartNfaWithStates_2(int pos, int kind, int state) +private final int jjStartNfaWithStates_2(int pos, int kind, int state) { jjmatchedKind = kind; jjmatchedPos = pos; @@ -887,7 +904,7 @@ static private final int jjStartNfaWithStates_2(int pos, int kind, int state) catch(java.io.IOException e) { return pos + 1; } return jjMoveNfa_2(state, pos + 1); } -static private final int jjMoveStringLiteralDfa0_2() +private final int jjMoveStringLiteralDfa0_2() { switch(curChar) { @@ -900,7 +917,7 @@ static private final int jjMoveStringLiteralDfa0_2() return jjMoveNfa_2(0, 0); } } -static private final int jjMoveStringLiteralDfa1_2(long active0) +private final int jjMoveStringLiteralDfa1_2(long active0) { try { curChar = input_stream.readChar(); } catch(java.io.IOException e) { @@ -921,7 +938,7 @@ static private final int jjMoveStringLiteralDfa1_2(long active0) } return jjStartNfa_2(0, active0); } -static private final int jjMoveStringLiteralDfa2_2(long old0, long active0) +private final int jjMoveStringLiteralDfa2_2(long old0, long active0) { if (((active0 &= old0)) == 0L) return jjStartNfa_2(0, old0); @@ -940,7 +957,7 @@ static private final int jjMoveStringLiteralDfa2_2(long old0, long active0) } return jjStartNfa_2(1, active0); } -static private final int jjMoveStringLiteralDfa3_2(long old0, long active0) +private final int jjMoveStringLiteralDfa3_2(long old0, long active0) { if (((active0 &= old0)) == 0L) return jjStartNfa_2(1, old0); @@ -961,7 +978,7 @@ static private final int jjMoveStringLiteralDfa3_2(long old0, long active0) } return jjStartNfa_2(2, active0); } -static private final int jjMoveNfa_2(int startState, int curPos) +private final int jjMoveNfa_2(int startState, int curPos) { int[] nextStates; int startsAt = 0; @@ -1037,7 +1054,7 @@ static private final int jjMoveNfa_2(int startState, int curPos) catch(java.io.IOException e) { return curPos; } } } -private static final int jjStopStringLiteralDfa_1(int pos, long active0, long active1, long active2) +private final int jjStopStringLiteralDfa_1(int pos, long active0, long active1, long active2) { switch (pos) { @@ -1166,11 +1183,11 @@ private static final int jjStopStringLiteralDfa_1(int pos, long active0, long ac return -1; } } -private static final int jjStartNfa_1(int pos, long active0, long active1, long active2) +private final int jjStartNfa_1(int pos, long active0, long active1, long active2) { return jjMoveNfa_1(jjStopStringLiteralDfa_1(pos, active0, active1, active2), pos + 1); } -static private final int jjStartNfaWithStates_1(int pos, int kind, int state) +private final int jjStartNfaWithStates_1(int pos, int kind, int state) { jjmatchedKind = kind; jjmatchedPos = pos; @@ -1178,7 +1195,7 @@ static private final int jjStartNfaWithStates_1(int pos, int kind, int state) catch(java.io.IOException e) { return pos + 1; } return jjMoveNfa_1(state, pos + 1); } -static private final int jjMoveStringLiteralDfa0_1() +private final int jjMoveStringLiteralDfa0_1() { switch(curChar) { @@ -1309,7 +1326,7 @@ static private final int jjMoveStringLiteralDfa0_1() return jjMoveNfa_1(3, 0); } } -static private final int jjMoveStringLiteralDfa1_1(long active0, long active1, long active2) +private final int jjMoveStringLiteralDfa1_1(long active0, long active1, long active2) { try { curChar = input_stream.readChar(); } catch(java.io.IOException e) { @@ -1468,7 +1485,7 @@ static private final int jjMoveStringLiteralDfa1_1(long active0, long active1, l } return jjStartNfa_1(0, active0, active1, active2); } -static private final int jjMoveStringLiteralDfa2_1(long old0, long active0, long old1, long active1, long old2, long active2) +private final int jjMoveStringLiteralDfa2_1(long old0, long active0, long old1, long active1, long old2, long active2) { if (((active0 &= old0) | (active1 &= old1) | (active2 &= old2)) == 0L) return jjStartNfa_1(0, old0, old1, old2); @@ -1568,7 +1585,7 @@ static private final int jjMoveStringLiteralDfa2_1(long old0, long active0, long } return jjStartNfa_1(1, active0, active1, active2); } -static private final int jjMoveStringLiteralDfa3_1(long old0, long active0, long old1, long active1, long old2, long active2) +private final int jjMoveStringLiteralDfa3_1(long old0, long active0, long old1, long active1, long old2, long active2) { if (((active0 &= old0) | (active1 &= old1) | (active2 &= old2)) == 0L) return jjStartNfa_1(1, old0, old1, old2); @@ -1649,7 +1666,7 @@ static private final int jjMoveStringLiteralDfa3_1(long old0, long active0, long } return jjStartNfa_1(2, active0, active1, 0L); } -static private final int jjMoveStringLiteralDfa4_1(long old0, long active0, long old1, long active1) +private final int jjMoveStringLiteralDfa4_1(long old0, long active0, long old1, long active1) { if (((active0 &= old0) | (active1 &= old1)) == 0L) return jjStartNfa_1(2, old0, old1, 0L); @@ -1736,7 +1753,7 @@ static private final int jjMoveStringLiteralDfa4_1(long old0, long active0, long } return jjStartNfa_1(3, active0, active1, 0L); } -static private final int jjMoveStringLiteralDfa5_1(long old0, long active0, long old1, long active1) +private final int jjMoveStringLiteralDfa5_1(long old0, long active0, long old1, long active1) { if (((active0 &= old0) | (active1 &= old1)) == 0L) return jjStartNfa_1(3, old0, old1, 0L); @@ -1808,7 +1825,7 @@ static private final int jjMoveStringLiteralDfa5_1(long old0, long active0, long } return jjStartNfa_1(4, active0, active1, 0L); } -static private final int jjMoveStringLiteralDfa6_1(long old0, long active0, long old1, long active1) +private final int jjMoveStringLiteralDfa6_1(long old0, long active0, long old1, long active1) { if (((active0 &= old0) | (active1 &= old1)) == 0L) return jjStartNfa_1(4, old0, old1, 0L); @@ -1871,7 +1888,7 @@ static private final int jjMoveStringLiteralDfa6_1(long old0, long active0, long } return jjStartNfa_1(5, active0, active1, 0L); } -static private final int jjMoveStringLiteralDfa7_1(long old0, long active0, long old1, long active1) +private final int jjMoveStringLiteralDfa7_1(long old0, long active0, long old1, long active1) { if (((active0 &= old0) | (active1 &= old1)) == 0L) return jjStartNfa_1(5, old0, old1, 0L); @@ -1904,7 +1921,7 @@ static private final int jjMoveStringLiteralDfa7_1(long old0, long active0, long } return jjStartNfa_1(6, active0, active1, 0L); } -static private final int jjMoveStringLiteralDfa8_1(long old0, long active0, long old1, long active1) +private final int jjMoveStringLiteralDfa8_1(long old0, long active0, long old1, long active1) { if (((active0 &= old0) | (active1 &= old1)) == 0L) return jjStartNfa_1(6, old0, old1, 0L); @@ -1928,7 +1945,7 @@ static private final int jjMoveStringLiteralDfa8_1(long old0, long active0, long } return jjStartNfa_1(7, active0, active1, 0L); } -static private final int jjMoveStringLiteralDfa9_1(long old0, long active0, long old1, long active1) +private final int jjMoveStringLiteralDfa9_1(long old0, long active0, long old1, long active1) { if (((active0 &= old0) | (active1 &= old1)) == 0L) return jjStartNfa_1(7, old0, old1, 0L); @@ -1947,7 +1964,7 @@ static private final int jjMoveStringLiteralDfa9_1(long old0, long active0, long } return jjStartNfa_1(8, active0, 0L, 0L); } -static private final int jjMoveStringLiteralDfa10_1(long old0, long active0) +private final int jjMoveStringLiteralDfa10_1(long old0, long active0) { if (((active0 &= old0)) == 0L) return jjStartNfa_1(8, old0, 0L, 0L); @@ -1966,7 +1983,7 @@ static private final int jjMoveStringLiteralDfa10_1(long old0, long active0) } return jjStartNfa_1(9, active0, 0L, 0L); } -static private final int jjMoveStringLiteralDfa11_1(long old0, long active0) +private final int jjMoveStringLiteralDfa11_1(long old0, long active0) { if (((active0 &= old0)) == 0L) return jjStartNfa_1(9, old0, 0L, 0L); @@ -1989,7 +2006,7 @@ static private final int jjMoveStringLiteralDfa11_1(long old0, long active0) } return jjStartNfa_1(10, active0, 0L, 0L); } -static private final int jjMoveNfa_1(int startState, int curPos) +private final int jjMoveNfa_1(int startState, int curPos) { int[] nextStates; int startsAt = 0; @@ -2385,7 +2402,7 @@ static private final int jjMoveNfa_1(int startState, int curPos) catch(java.io.IOException e) { return curPos; } } } -private static final int jjStopStringLiteralDfa_7(int pos, long active0, long active1) +private final int jjStopStringLiteralDfa_7(int pos, long active0, long active1) { switch (pos) { @@ -2393,11 +2410,11 @@ private static final int jjStopStringLiteralDfa_7(int pos, long active0, long ac return -1; } } -private static final int jjStartNfa_7(int pos, long active0, long active1) +private final int jjStartNfa_7(int pos, long active0, long active1) { return jjMoveNfa_7(jjStopStringLiteralDfa_7(pos, active0, active1), pos + 1); } -static private final int jjStartNfaWithStates_7(int pos, int kind, int state) +private final int jjStartNfaWithStates_7(int pos, int kind, int state) { jjmatchedKind = kind; jjmatchedPos = pos; @@ -2405,7 +2422,7 @@ static private final int jjStartNfaWithStates_7(int pos, int kind, int state) catch(java.io.IOException e) { return pos + 1; } return jjMoveNfa_7(state, pos + 1); } -static private final int jjMoveStringLiteralDfa0_7() +private final int jjMoveStringLiteralDfa0_7() { switch(curChar) { @@ -2417,7 +2434,7 @@ static private final int jjMoveStringLiteralDfa0_7() return jjMoveNfa_7(0, 0); } } -static private final int jjMoveNfa_7(int startState, int curPos) +private final int jjMoveNfa_7(int startState, int curPos) { int[] nextStates; int startsAt = 0; @@ -2575,17 +2592,17 @@ static final long[] jjtoSpecial = { static final long[] jjtoMore = { 0x4000000L, 0x0L, 0x0L, }; -static protected SimpleCharStream input_stream; -static private final int[] jjrounds = new int[52]; -static private final int[] jjstateSet = new int[104]; -static StringBuffer image; -static int jjimageLen; -static int lengthOfMatch; -static protected char curChar; +protected SimpleCharStream input_stream; +private final int[] jjrounds = new int[52]; +private final int[] jjstateSet = new int[104]; +StringBuffer image; +int jjimageLen; +int lengthOfMatch; +protected char curChar; public PHPParserTokenManager(SimpleCharStream stream) { - if (input_stream != null) - throw new TokenMgrError("ERROR: Second call to constructor of static lexer. You must use ReInit() to initialize the static variables.", TokenMgrError.STATIC_LEXER_ERROR); + if (SimpleCharStream.staticFlag) + throw new Error("ERROR: Cannot use a static CharStream class with a non-static lexical analyzer."); input_stream = stream; } public PHPParserTokenManager(SimpleCharStream stream, int lexState) @@ -2593,26 +2610,26 @@ public PHPParserTokenManager(SimpleCharStream stream, int lexState) this(stream); SwitchTo(lexState); } -static public void ReInit(SimpleCharStream stream) +public void ReInit(SimpleCharStream stream) { jjmatchedPos = jjnewStateCnt = 0; curLexState = defaultLexState; input_stream = stream; ReInitRounds(); } -static private final void ReInitRounds() +private final void ReInitRounds() { int i; jjround = 0x80000001; for (i = 52; i-- > 0;) jjrounds[i] = 0x80000000; } -static public void ReInit(SimpleCharStream stream, int lexState) +public void ReInit(SimpleCharStream stream, int lexState) { ReInit(stream); SwitchTo(lexState); } -static public void SwitchTo(int lexState) +public void SwitchTo(int lexState) { if (lexState >= 10 || lexState < 0) throw new TokenMgrError("Error: Ignoring invalid lexical state : " + lexState + ". State unchanged.", TokenMgrError.INVALID_LEXICAL_STATE); @@ -2620,7 +2637,7 @@ static public void SwitchTo(int lexState) curLexState = lexState; } -static protected Token jjFillToken() +protected Token jjFillToken() { Token t = Token.newToken(jjmatchedKind); t.kind = jjmatchedKind; @@ -2642,14 +2659,14 @@ static protected Token jjFillToken() return t; } -static int curLexState = 0; -static int defaultLexState = 0; -static int jjnewStateCnt; -static int jjround; -static int jjmatchedPos; -static int jjmatchedKind; +int curLexState = 0; +int defaultLexState = 0; +int jjnewStateCnt; +int jjround; +int jjmatchedPos; +int jjmatchedKind; -public static Token getNextToken() +public Token getNextToken() { int kind; Token specialToken = null; @@ -2837,7 +2854,7 @@ public static Token getNextToken() } } -static void SkipLexicalActions(Token matchedToken) +void SkipLexicalActions(Token matchedToken) { switch(jjmatchedKind) { @@ -2852,7 +2869,7 @@ static void SkipLexicalActions(Token matchedToken) break; } } -static void TokenLexicalActions(Token matchedToken) +void TokenLexicalActions(Token matchedToken) { switch(jjmatchedKind) {