Remove extraneous ';' (empty statement), remove unnecessary null checks and dead code

This commit is contained in:
Sam Harwell 2012-07-18 15:42:20 -05:00
parent 3b9940b02a
commit 84e1025801
6 changed files with 7 additions and 7 deletions

View File

@ -37,7 +37,7 @@ public abstract class OutputModelObject {
public OutputModelFactory factory;
public GrammarAST ast;
public OutputModelObject() {;}
public OutputModelObject() {}
public OutputModelObject(OutputModelFactory factory) { this(factory, null); }

View File

@ -39,7 +39,7 @@ import org.antlr.v4.tool.ast.TerminalAST;
public class GrammarASTAdaptor extends CommonTreeAdaptor {
org.antlr.runtime.CharStream input; // where we can find chars ref'd by tokens in tree
public GrammarASTAdaptor() { ; }
public GrammarASTAdaptor() { }
public GrammarASTAdaptor(org.antlr.runtime.CharStream input) { this.input = input; }
@Override

View File

@ -35,7 +35,7 @@ import org.antlr.runtime.*;
public class v4ParserException extends RecognitionException {
public String msg;
/** Used for remote debugger deserialization */
public v4ParserException() {;}
public v4ParserException() {}
public v4ParserException(String msg, IntStream input) {
super(input);

View File

@ -107,11 +107,11 @@ public class ActionSniffer extends BlankActionSplitterListener {
public void trackRef(Token x) {
List<TerminalAST> xRefs = alt.tokenRefs.get(x.getText());
if ( alt!=null && xRefs!=null ) {
if ( xRefs!=null ) {
alt.tokenRefsInActions.map(x.getText(), node);
}
List<GrammarAST> rRefs = alt.ruleRefs.get(x.getText());
if ( alt!=null && rRefs!=null ) {
if ( rRefs!=null ) {
alt.ruleRefsInActions.map(x.getText(), node);
}
}

View File

@ -82,7 +82,7 @@ public class SemanticPipeline {
basics.process();
// don't continue if we get errors in this basic check
if ( false ) return;
//if ( false ) return;
// TRANSFORM LEFT-RECURSIVE RULES
LeftRecursiveRuleTransformer lrtrans =

View File

@ -48,7 +48,7 @@ public class Attribute {
/** Who contains us? */
public AttributeDict dict;
public Attribute() {;}
public Attribute() {}
public Attribute(String name) { this(name,null); }