Skip to content

Commit

Permalink
Remove doubtful and not used static fields
Browse files Browse the repository at this point in the history
Signed-off-by: Ivan Kochurkin <kvanttt@gmail.com>
  • Loading branch information
KvanTTT authored and parrt committed Jun 26, 2022
1 parent ded070b commit a400163
Show file tree
Hide file tree
Showing 4 changed files with 0 additions and 13 deletions.
5 changes: 0 additions & 5 deletions runtime/Java/src/org/antlr/v4/runtime/misc/Interval.java
Original file line number Diff line number Diff line change
Expand Up @@ -16,11 +16,6 @@ public class Interval {
public int a;
public int b;

public static int creates = 0;
public static int misses = 0;
public static int hits = 0;
public static int outOfRange = 0;

public Interval(int a, int b) { this.a=a; this.b=b; }

/** Interval objects are used readonly so share all with the
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -491,7 +491,6 @@ public class TestATNParserPrediction {
public void checkPredictedAlt(LexerGrammar lg, Grammar g, int decision,
String inputString, int expectedAlt)
{
Tool.internalOption_ShowATNConfigsInDFA = true;
ATN lexatn = createATN(lg, true);
LexerATNSimulator lexInterp =
new LexerATNSimulator(lexatn,new DFA[] { new DFA(lexatn.modeToStartState.get(Lexer.DEFAULT_MODE)) },new PredictionContextCache());
Expand Down
5 changes: 0 additions & 5 deletions tool/src/org/antlr/v4/Tool.java
Original file line number Diff line number Diff line change
Expand Up @@ -139,10 +139,6 @@ public Option(String fieldName, String name, OptionArgType argType, String descr
protected boolean haveOutputDir = false;
protected boolean return_dont_exit = false;

// The internal options are for my use on the command line during dev
public static boolean internalOption_PrintGrammarTree = false;
public static boolean internalOption_ShowATNConfigsInDFA = false;


public final String[] args;

Expand Down Expand Up @@ -365,7 +361,6 @@ public void process(Grammar g, boolean gencode) {

public void processNonCombinedGrammar(Grammar g, boolean gencode) {
if ( g.ast==null || g.ast.hasErrors ) return;
if ( internalOption_PrintGrammarTree ) System.out.println(g.ast.toStringTree());

boolean ruleFail = checkForRuleIssues(g);
if ( ruleFail ) return;
Expand Down
2 changes: 0 additions & 2 deletions tool/src/org/antlr/v4/misc/Utils.java
Original file line number Diff line number Diff line change
Expand Up @@ -31,8 +31,6 @@ public interface Func1<T1, TResult> {
TResult exec(T1 arg1);
}

static Integer[] ints = new Integer[INTEGER_POOL_MAX_VALUE+1];

public static String stripFileExtension(String name) {
if ( name==null ) return null;
int lastDot = name.lastIndexOf('.');
Expand Down

0 comments on commit a400163

Please sign in to comment.