NichtHaskell/Source/gen/DecafParser.java

2864 lines
94 KiB
Java
Raw Normal View History

package gen;// Generated from C:/Users/dh10krj/OneDrive - Durr Group/Dokumente/S4/Compilerbau/projekt/NichtHaskell/Source/Decaf.g4 by ANTLR 4.13.1
2024-05-09 12:22:45 +00:00
import org.antlr.v4.runtime.atn.*;
import org.antlr.v4.runtime.dfa.DFA;
import org.antlr.v4.runtime.*;
import org.antlr.v4.runtime.misc.*;
import org.antlr.v4.runtime.tree.*;
import java.util.List;
import java.util.Iterator;
import java.util.ArrayList;
@SuppressWarnings({"all", "warnings", "unchecked", "unused", "cast", "CheckReturnValue"})
public class DecafParser extends Parser {
static { RuntimeMetaData.checkVersion("4.13.1", RuntimeMetaData.VERSION); }
protected static final DFA[] _decisionToDFA;
protected static final PredictionContextCache _sharedContextCache =
new PredictionContextCache();
public static final int
AccessModifierPublic=1, MainMethodDecl=2, DotOperator=3, LineOperator=4,
ComparisonOperator=5, LogicalOpertor=6, Assign=7, Minus=8, Plus=9, Multipilkation=10,
Division=11, Modulo=12, Greater=13, Less=14, GreaterEqual=15, LessEqual=16,
Equal=17, NotEqual=18, Not=19, And=20, Or=21, Dot=22, OpenRoundBracket=23,
ClosedRoundBracket=24, OpenCurlyBracket=25, ClosedCurlyBracket=26, Semicolon=27,
Comma=28, Class=29, This=30, While=31, If=32, Else=33, Return=34, New=35,
Identifier=36, Void=37, Int=38, Boolean=39, Char=40, IntValue=41, CharValue=42,
BooleanValue=43, NullValue=44, WS=45;
public static final int
RULE_program = 0, RULE_classdecl = 1, RULE_constuctorDecl = 2, RULE_methodDecl = 3,
RULE_fieldDecl = 4, RULE_parameterList = 5, RULE_parameter = 6, RULE_expression = 7,
RULE_subExpression = 8, RULE_assignableExpr = 9, RULE_instVar = 10, RULE_methodCall = 11,
RULE_argumentList = 12, RULE_subReceiver = 13, RULE_receiver = 14, RULE_receivingMethod = 15,
RULE_binaryExpr = 16, RULE_calcExpr = 17, RULE_dotExpr = 18, RULE_dotSubExpr = 19,
RULE_nonCalcExpr = 20, RULE_nonCalcOperator = 21, RULE_stmtExpr = 22,
RULE_statement = 23, RULE_returnStmt = 24, RULE_localVarDecl = 25, RULE_block = 26,
RULE_whileStmt = 27, RULE_ifElseStmt = 28, RULE_ifStmt = 29, RULE_elseStmt = 30,
RULE_assign = 31, RULE_newDecl = 32, RULE_type = 33, RULE_value = 34;
private static String[] makeRuleNames() {
return new String[] {
"program", "classdecl", "constuctorDecl", "methodDecl", "fieldDecl",
"parameterList", "parameter", "expression", "subExpression", "assignableExpr",
"instVar", "methodCall", "argumentList", "subReceiver", "receiver", "receivingMethod",
"binaryExpr", "calcExpr", "dotExpr", "dotSubExpr", "nonCalcExpr", "nonCalcOperator",
"stmtExpr", "statement", "returnStmt", "localVarDecl", "block", "whileStmt",
"ifElseStmt", "ifStmt", "elseStmt", "assign", "newDecl", "type", "value"
};
}
public static final String[] ruleNames = makeRuleNames();
private static String[] makeLiteralNames() {
return new String[] {
null, "'public'", "'public static void main(String[] args)'", null, null,
null, null, "'='", "'-'", "'+'", "'*'", "'/'", "'%'", "'>'", "'<'", "'>='",
"'<='", "'=='", "'!='", "'!'", "'&&'", "'||'", "'.'", "'('", "')'", "'{'",
"'}'", "';'", "','", "'class'", "'this'", "'while'", "'if'", "'else'",
"'return'", "'new'", null, "'void'", "'int'", "'bool'", "'char'", null,
null, null, "'null'"
};
}
private static final String[] _LITERAL_NAMES = makeLiteralNames();
private static String[] makeSymbolicNames() {
return new String[] {
null, "AccessModifierPublic", "MainMethodDecl", "DotOperator", "LineOperator",
"ComparisonOperator", "LogicalOpertor", "Assign", "Minus", "Plus", "Multipilkation",
"Division", "Modulo", "Greater", "Less", "GreaterEqual", "LessEqual",
"Equal", "NotEqual", "Not", "And", "Or", "Dot", "OpenRoundBracket", "ClosedRoundBracket",
"OpenCurlyBracket", "ClosedCurlyBracket", "Semicolon", "Comma", "Class",
"This", "While", "If", "Else", "Return", "New", "Identifier", "Void",
"Int", "Boolean", "Char", "IntValue", "CharValue", "BooleanValue", "NullValue",
"WS"
};
}
private static final String[] _SYMBOLIC_NAMES = makeSymbolicNames();
public static final Vocabulary VOCABULARY = new VocabularyImpl(_LITERAL_NAMES, _SYMBOLIC_NAMES);
/**
* @deprecated Use {@link #VOCABULARY} instead.
*/
@Deprecated
public static final String[] tokenNames;
static {
tokenNames = new String[_SYMBOLIC_NAMES.length];
for (int i = 0; i < tokenNames.length; i++) {
tokenNames[i] = VOCABULARY.getLiteralName(i);
if (tokenNames[i] == null) {
tokenNames[i] = VOCABULARY.getSymbolicName(i);
}
if (tokenNames[i] == null) {
tokenNames[i] = "<INVALID>";
}
}
}
@Override
@Deprecated
public String[] getTokenNames() {
return tokenNames;
}
@Override
public Vocabulary getVocabulary() {
return VOCABULARY;
}
@Override
public String getGrammarFileName() { return "Decaf.g4"; }
@Override
public String[] getRuleNames() { return ruleNames; }
@Override
public String getSerializedATN() { return _serializedATN; }
@Override
public ATN getATN() { return _ATN; }
public DecafParser(TokenStream input) {
super(input);
_interp = new ParserATNSimulator(this,_ATN,_decisionToDFA,_sharedContextCache);
}
@SuppressWarnings("CheckReturnValue")
public static class ProgramContext extends ParserRuleContext {
public List<ClassdeclContext> classdecl() {
return getRuleContexts(ClassdeclContext.class);
}
public ClassdeclContext classdecl(int i) {
return getRuleContext(ClassdeclContext.class,i);
}
public ProgramContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_program; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof DecafListener ) ((DecafListener)listener).enterProgram(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof DecafListener ) ((DecafListener)listener).exitProgram(this);
}
@Override
public <T> T accept(ParseTreeVisitor<? extends T> visitor) {
if ( visitor instanceof DecafVisitor ) return ((DecafVisitor<? extends T>)visitor).visitProgram(this);
else return visitor.visitChildren(this);
}
}
public final ProgramContext program() throws RecognitionException {
ProgramContext _localctx = new ProgramContext(_ctx, getState());
enterRule(_localctx, 0, RULE_program);
int _la;
try {
enterOuterAlt(_localctx, 1);
{
setState(71);
_errHandler.sync(this);
_la = _input.LA(1);
do {
{
{
setState(70);
classdecl();
}
}
setState(73);
_errHandler.sync(this);
_la = _input.LA(1);
} while ( _la==AccessModifierPublic || _la==Class );
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
@SuppressWarnings("CheckReturnValue")
public static class ClassdeclContext extends ParserRuleContext {
public TerminalNode Class() { return getToken(DecafParser.Class, 0); }
public TerminalNode Identifier() { return getToken(DecafParser.Identifier, 0); }
public TerminalNode OpenCurlyBracket() { return getToken(DecafParser.OpenCurlyBracket, 0); }
public TerminalNode ClosedCurlyBracket() { return getToken(DecafParser.ClosedCurlyBracket, 0); }
public TerminalNode AccessModifierPublic() { return getToken(DecafParser.AccessModifierPublic, 0); }
public List<ConstuctorDeclContext> constuctorDecl() {
return getRuleContexts(ConstuctorDeclContext.class);
}
public ConstuctorDeclContext constuctorDecl(int i) {
return getRuleContext(ConstuctorDeclContext.class,i);
}
public List<FieldDeclContext> fieldDecl() {
return getRuleContexts(FieldDeclContext.class);
}
public FieldDeclContext fieldDecl(int i) {
return getRuleContext(FieldDeclContext.class,i);
}
public List<MethodDeclContext> methodDecl() {
return getRuleContexts(MethodDeclContext.class);
}
public MethodDeclContext methodDecl(int i) {
return getRuleContext(MethodDeclContext.class,i);
}
public TerminalNode MainMethodDecl() { return getToken(DecafParser.MainMethodDecl, 0); }
public BlockContext block() {
return getRuleContext(BlockContext.class,0);
}
public ClassdeclContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_classdecl; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof DecafListener ) ((DecafListener)listener).enterClassdecl(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof DecafListener ) ((DecafListener)listener).exitClassdecl(this);
}
@Override
public <T> T accept(ParseTreeVisitor<? extends T> visitor) {
if ( visitor instanceof DecafVisitor ) return ((DecafVisitor<? extends T>)visitor).visitClassdecl(this);
else return visitor.visitChildren(this);
}
}
public final ClassdeclContext classdecl() throws RecognitionException {
ClassdeclContext _localctx = new ClassdeclContext(_ctx, getState());
enterRule(_localctx, 2, RULE_classdecl);
int _la;
try {
enterOuterAlt(_localctx, 1);
{
setState(76);
_errHandler.sync(this);
_la = _input.LA(1);
if (_la==AccessModifierPublic) {
{
setState(75);
match(AccessModifierPublic);
}
}
setState(78);
match(Class);
setState(79);
match(Identifier);
setState(80);
match(OpenCurlyBracket);
setState(86);
_errHandler.sync(this);
_la = _input.LA(1);
while ((((_la) & ~0x3f) == 0 && ((1L << _la) & 2130303778818L) != 0)) {
{
setState(84);
_errHandler.sync(this);
switch ( getInterpreter().adaptivePredict(_input,2,_ctx) ) {
case 1:
{
setState(81);
constuctorDecl();
}
break;
case 2:
{
setState(82);
fieldDecl();
}
break;
case 3:
{
setState(83);
methodDecl();
}
break;
}
}
setState(88);
_errHandler.sync(this);
_la = _input.LA(1);
}
setState(91);
_errHandler.sync(this);
_la = _input.LA(1);
if (_la==MainMethodDecl) {
{
setState(89);
match(MainMethodDecl);
setState(90);
block();
}
}
setState(93);
match(ClosedCurlyBracket);
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
@SuppressWarnings("CheckReturnValue")
public static class ConstuctorDeclContext extends ParserRuleContext {
public TerminalNode Identifier() { return getToken(DecafParser.Identifier, 0); }
public TerminalNode OpenRoundBracket() { return getToken(DecafParser.OpenRoundBracket, 0); }
public TerminalNode ClosedRoundBracket() { return getToken(DecafParser.ClosedRoundBracket, 0); }
public BlockContext block() {
return getRuleContext(BlockContext.class,0);
}
public TerminalNode AccessModifierPublic() { return getToken(DecafParser.AccessModifierPublic, 0); }
public ParameterListContext parameterList() {
return getRuleContext(ParameterListContext.class,0);
}
public ConstuctorDeclContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_constuctorDecl; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof DecafListener ) ((DecafListener)listener).enterConstuctorDecl(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof DecafListener ) ((DecafListener)listener).exitConstuctorDecl(this);
}
@Override
public <T> T accept(ParseTreeVisitor<? extends T> visitor) {
if ( visitor instanceof DecafVisitor ) return ((DecafVisitor<? extends T>)visitor).visitConstuctorDecl(this);
else return visitor.visitChildren(this);
}
}
public final ConstuctorDeclContext constuctorDecl() throws RecognitionException {
ConstuctorDeclContext _localctx = new ConstuctorDeclContext(_ctx, getState());
enterRule(_localctx, 4, RULE_constuctorDecl);
int _la;
try {
enterOuterAlt(_localctx, 1);
{
setState(96);
_errHandler.sync(this);
_la = _input.LA(1);
if (_la==AccessModifierPublic) {
{
setState(95);
match(AccessModifierPublic);
}
}
setState(98);
match(Identifier);
setState(99);
match(OpenRoundBracket);
setState(101);
_errHandler.sync(this);
_la = _input.LA(1);
if ((((_la) & ~0x3f) == 0 && ((1L << _la) & 1992864825344L) != 0)) {
{
setState(100);
parameterList();
}
}
setState(103);
match(ClosedRoundBracket);
setState(104);
block();
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
@SuppressWarnings("CheckReturnValue")
public static class MethodDeclContext extends ParserRuleContext {
public TerminalNode Identifier() { return getToken(DecafParser.Identifier, 0); }
public TerminalNode OpenRoundBracket() { return getToken(DecafParser.OpenRoundBracket, 0); }
public TerminalNode ClosedRoundBracket() { return getToken(DecafParser.ClosedRoundBracket, 0); }
public BlockContext block() {
return getRuleContext(BlockContext.class,0);
}
public TypeContext type() {
return getRuleContext(TypeContext.class,0);
}
public TerminalNode Void() { return getToken(DecafParser.Void, 0); }
public TerminalNode AccessModifierPublic() { return getToken(DecafParser.AccessModifierPublic, 0); }
public ParameterListContext parameterList() {
return getRuleContext(ParameterListContext.class,0);
}
public MethodDeclContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_methodDecl; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof DecafListener ) ((DecafListener)listener).enterMethodDecl(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof DecafListener ) ((DecafListener)listener).exitMethodDecl(this);
}
@Override
public <T> T accept(ParseTreeVisitor<? extends T> visitor) {
if ( visitor instanceof DecafVisitor ) return ((DecafVisitor<? extends T>)visitor).visitMethodDecl(this);
else return visitor.visitChildren(this);
}
}
public final MethodDeclContext methodDecl() throws RecognitionException {
MethodDeclContext _localctx = new MethodDeclContext(_ctx, getState());
enterRule(_localctx, 6, RULE_methodDecl);
int _la;
try {
enterOuterAlt(_localctx, 1);
{
setState(107);
_errHandler.sync(this);
_la = _input.LA(1);
if (_la==AccessModifierPublic) {
{
setState(106);
match(AccessModifierPublic);
}
}
setState(111);
_errHandler.sync(this);
switch (_input.LA(1)) {
case Identifier:
case Int:
case Boolean:
case Char:
{
setState(109);
type();
}
break;
case Void:
{
setState(110);
match(Void);
}
break;
default:
throw new NoViableAltException(this);
}
setState(113);
match(Identifier);
setState(114);
match(OpenRoundBracket);
setState(116);
_errHandler.sync(this);
_la = _input.LA(1);
if ((((_la) & ~0x3f) == 0 && ((1L << _la) & 1992864825344L) != 0)) {
{
setState(115);
parameterList();
}
}
setState(118);
match(ClosedRoundBracket);
setState(119);
block();
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
@SuppressWarnings("CheckReturnValue")
public static class FieldDeclContext extends ParserRuleContext {
public TypeContext type() {
return getRuleContext(TypeContext.class,0);
}
public TerminalNode Identifier() { return getToken(DecafParser.Identifier, 0); }
public TerminalNode Semicolon() { return getToken(DecafParser.Semicolon, 0); }
public TerminalNode AccessModifierPublic() { return getToken(DecafParser.AccessModifierPublic, 0); }
public FieldDeclContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_fieldDecl; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof DecafListener ) ((DecafListener)listener).enterFieldDecl(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof DecafListener ) ((DecafListener)listener).exitFieldDecl(this);
}
@Override
public <T> T accept(ParseTreeVisitor<? extends T> visitor) {
if ( visitor instanceof DecafVisitor ) return ((DecafVisitor<? extends T>)visitor).visitFieldDecl(this);
else return visitor.visitChildren(this);
}
}
public final FieldDeclContext fieldDecl() throws RecognitionException {
FieldDeclContext _localctx = new FieldDeclContext(_ctx, getState());
enterRule(_localctx, 8, RULE_fieldDecl);
int _la;
try {
enterOuterAlt(_localctx, 1);
{
setState(122);
_errHandler.sync(this);
_la = _input.LA(1);
if (_la==AccessModifierPublic) {
{
setState(121);
match(AccessModifierPublic);
}
}
setState(124);
type();
setState(125);
match(Identifier);
setState(126);
match(Semicolon);
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
@SuppressWarnings("CheckReturnValue")
public static class ParameterListContext extends ParserRuleContext {
public List<ParameterContext> parameter() {
return getRuleContexts(ParameterContext.class);
}
public ParameterContext parameter(int i) {
return getRuleContext(ParameterContext.class,i);
}
public List<TerminalNode> Comma() { return getTokens(DecafParser.Comma); }
public TerminalNode Comma(int i) {
return getToken(DecafParser.Comma, i);
}
public ParameterListContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_parameterList; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof DecafListener ) ((DecafListener)listener).enterParameterList(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof DecafListener ) ((DecafListener)listener).exitParameterList(this);
}
@Override
public <T> T accept(ParseTreeVisitor<? extends T> visitor) {
if ( visitor instanceof DecafVisitor ) return ((DecafVisitor<? extends T>)visitor).visitParameterList(this);
else return visitor.visitChildren(this);
}
}
public final ParameterListContext parameterList() throws RecognitionException {
ParameterListContext _localctx = new ParameterListContext(_ctx, getState());
enterRule(_localctx, 10, RULE_parameterList);
int _la;
try {
enterOuterAlt(_localctx, 1);
{
setState(128);
parameter();
setState(133);
_errHandler.sync(this);
_la = _input.LA(1);
while (_la==Comma) {
{
{
setState(129);
match(Comma);
setState(130);
parameter();
}
}
setState(135);
_errHandler.sync(this);
_la = _input.LA(1);
}
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
@SuppressWarnings("CheckReturnValue")
public static class ParameterContext extends ParserRuleContext {
public TypeContext type() {
return getRuleContext(TypeContext.class,0);
}
public TerminalNode Identifier() { return getToken(DecafParser.Identifier, 0); }
public ParameterContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_parameter; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof DecafListener ) ((DecafListener)listener).enterParameter(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof DecafListener ) ((DecafListener)listener).exitParameter(this);
}
@Override
public <T> T accept(ParseTreeVisitor<? extends T> visitor) {
if ( visitor instanceof DecafVisitor ) return ((DecafVisitor<? extends T>)visitor).visitParameter(this);
else return visitor.visitChildren(this);
}
}
public final ParameterContext parameter() throws RecognitionException {
ParameterContext _localctx = new ParameterContext(_ctx, getState());
enterRule(_localctx, 12, RULE_parameter);
try {
enterOuterAlt(_localctx, 1);
{
setState(136);
type();
setState(137);
match(Identifier);
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
@SuppressWarnings("CheckReturnValue")
public static class ExpressionContext extends ParserRuleContext {
public SubExpressionContext subExpression() {
return getRuleContext(SubExpressionContext.class,0);
}
public BinaryExprContext binaryExpr() {
return getRuleContext(BinaryExprContext.class,0);
}
public ExpressionContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_expression; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof DecafListener ) ((DecafListener)listener).enterExpression(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof DecafListener ) ((DecafListener)listener).exitExpression(this);
}
@Override
public <T> T accept(ParseTreeVisitor<? extends T> visitor) {
if ( visitor instanceof DecafVisitor ) return ((DecafVisitor<? extends T>)visitor).visitExpression(this);
else return visitor.visitChildren(this);
}
}
public final ExpressionContext expression() throws RecognitionException {
ExpressionContext _localctx = new ExpressionContext(_ctx, getState());
enterRule(_localctx, 14, RULE_expression);
try {
setState(141);
_errHandler.sync(this);
switch ( getInterpreter().adaptivePredict(_input,12,_ctx) ) {
case 1:
enterOuterAlt(_localctx, 1);
{
setState(139);
subExpression();
}
break;
case 2:
enterOuterAlt(_localctx, 2);
{
setState(140);
binaryExpr();
}
break;
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
@SuppressWarnings("CheckReturnValue")
public static class SubExpressionContext extends ParserRuleContext {
public TerminalNode This() { return getToken(DecafParser.This, 0); }
public AssignableExprContext assignableExpr() {
return getRuleContext(AssignableExprContext.class,0);
}
public StmtExprContext stmtExpr() {
return getRuleContext(StmtExprContext.class,0);
}
public TerminalNode OpenRoundBracket() { return getToken(DecafParser.OpenRoundBracket, 0); }
public SubExpressionContext subExpression() {
return getRuleContext(SubExpressionContext.class,0);
}
public TerminalNode ClosedRoundBracket() { return getToken(DecafParser.ClosedRoundBracket, 0); }
public SubExpressionContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_subExpression; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof DecafListener ) ((DecafListener)listener).enterSubExpression(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof DecafListener ) ((DecafListener)listener).exitSubExpression(this);
}
@Override
public <T> T accept(ParseTreeVisitor<? extends T> visitor) {
if ( visitor instanceof DecafVisitor ) return ((DecafVisitor<? extends T>)visitor).visitSubExpression(this);
else return visitor.visitChildren(this);
}
}
public final SubExpressionContext subExpression() throws RecognitionException {
SubExpressionContext _localctx = new SubExpressionContext(_ctx, getState());
enterRule(_localctx, 16, RULE_subExpression);
try {
setState(150);
_errHandler.sync(this);
switch ( getInterpreter().adaptivePredict(_input,13,_ctx) ) {
case 1:
enterOuterAlt(_localctx, 1);
{
setState(143);
match(This);
}
break;
case 2:
enterOuterAlt(_localctx, 2);
{
setState(144);
assignableExpr();
}
break;
case 3:
enterOuterAlt(_localctx, 3);
{
setState(145);
stmtExpr();
}
break;
case 4:
enterOuterAlt(_localctx, 4);
{
setState(146);
match(OpenRoundBracket);
setState(147);
subExpression();
setState(148);
match(ClosedRoundBracket);
}
break;
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
@SuppressWarnings("CheckReturnValue")
public static class AssignableExprContext extends ParserRuleContext {
public TerminalNode Identifier() { return getToken(DecafParser.Identifier, 0); }
public InstVarContext instVar() {
return getRuleContext(InstVarContext.class,0);
}
public AssignableExprContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_assignableExpr; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof DecafListener ) ((DecafListener)listener).enterAssignableExpr(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof DecafListener ) ((DecafListener)listener).exitAssignableExpr(this);
}
@Override
public <T> T accept(ParseTreeVisitor<? extends T> visitor) {
if ( visitor instanceof DecafVisitor ) return ((DecafVisitor<? extends T>)visitor).visitAssignableExpr(this);
else return visitor.visitChildren(this);
}
}
public final AssignableExprContext assignableExpr() throws RecognitionException {
AssignableExprContext _localctx = new AssignableExprContext(_ctx, getState());
enterRule(_localctx, 18, RULE_assignableExpr);
try {
setState(154);
_errHandler.sync(this);
switch ( getInterpreter().adaptivePredict(_input,14,_ctx) ) {
case 1:
enterOuterAlt(_localctx, 1);
{
setState(152);
match(Identifier);
}
break;
case 2:
enterOuterAlt(_localctx, 2);
{
setState(153);
instVar();
}
break;
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
@SuppressWarnings("CheckReturnValue")
public static class InstVarContext extends ParserRuleContext {
public TerminalNode Identifier() { return getToken(DecafParser.Identifier, 0); }
public SubReceiverContext subReceiver() {
return getRuleContext(SubReceiverContext.class,0);
}
public List<ReceivingMethodContext> receivingMethod() {
return getRuleContexts(ReceivingMethodContext.class);
}
public ReceivingMethodContext receivingMethod(int i) {
return getRuleContext(ReceivingMethodContext.class,i);
}
public InstVarContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_instVar; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof DecafListener ) ((DecafListener)listener).enterInstVar(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof DecafListener ) ((DecafListener)listener).exitInstVar(this);
}
@Override
public <T> T accept(ParseTreeVisitor<? extends T> visitor) {
if ( visitor instanceof DecafVisitor ) return ((DecafVisitor<? extends T>)visitor).visitInstVar(this);
else return visitor.visitChildren(this);
}
}
public final InstVarContext instVar() throws RecognitionException {
InstVarContext _localctx = new InstVarContext(_ctx, getState());
enterRule(_localctx, 20, RULE_instVar);
try {
int _alt;
enterOuterAlt(_localctx, 1);
{
setState(157);
_errHandler.sync(this);
switch ( getInterpreter().adaptivePredict(_input,15,_ctx) ) {
case 1:
{
setState(156);
subReceiver();
}
break;
}
setState(162);
_errHandler.sync(this);
_alt = getInterpreter().adaptivePredict(_input,16,_ctx);
while ( _alt!=2 && _alt!=org.antlr.v4.runtime.atn.ATN.INVALID_ALT_NUMBER ) {
if ( _alt==1 ) {
{
{
setState(159);
receivingMethod();
}
}
}
setState(164);
_errHandler.sync(this);
_alt = getInterpreter().adaptivePredict(_input,16,_ctx);
}
setState(165);
match(Identifier);
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
@SuppressWarnings("CheckReturnValue")
public static class MethodCallContext extends ParserRuleContext {
public TerminalNode Identifier() { return getToken(DecafParser.Identifier, 0); }
public TerminalNode OpenRoundBracket() { return getToken(DecafParser.OpenRoundBracket, 0); }
public ArgumentListContext argumentList() {
return getRuleContext(ArgumentListContext.class,0);
}
public TerminalNode ClosedRoundBracket() { return getToken(DecafParser.ClosedRoundBracket, 0); }
public ReceiverContext receiver() {
return getRuleContext(ReceiverContext.class,0);
}
public List<ReceivingMethodContext> receivingMethod() {
return getRuleContexts(ReceivingMethodContext.class);
}
public ReceivingMethodContext receivingMethod(int i) {
return getRuleContext(ReceivingMethodContext.class,i);
}
public MethodCallContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_methodCall; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof DecafListener ) ((DecafListener)listener).enterMethodCall(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof DecafListener ) ((DecafListener)listener).exitMethodCall(this);
}
@Override
public <T> T accept(ParseTreeVisitor<? extends T> visitor) {
if ( visitor instanceof DecafVisitor ) return ((DecafVisitor<? extends T>)visitor).visitMethodCall(this);
else return visitor.visitChildren(this);
}
}
public final MethodCallContext methodCall() throws RecognitionException {
MethodCallContext _localctx = new MethodCallContext(_ctx, getState());
enterRule(_localctx, 22, RULE_methodCall);
try {
int _alt;
enterOuterAlt(_localctx, 1);
{
setState(168);
_errHandler.sync(this);
switch ( getInterpreter().adaptivePredict(_input,17,_ctx) ) {
case 1:
{
setState(167);
receiver();
}
break;
}
setState(173);
_errHandler.sync(this);
_alt = getInterpreter().adaptivePredict(_input,18,_ctx);
while ( _alt!=2 && _alt!=org.antlr.v4.runtime.atn.ATN.INVALID_ALT_NUMBER ) {
if ( _alt==1 ) {
{
{
setState(170);
receivingMethod();
}
}
}
setState(175);
_errHandler.sync(this);
_alt = getInterpreter().adaptivePredict(_input,18,_ctx);
}
setState(176);
match(Identifier);
setState(177);
match(OpenRoundBracket);
setState(178);
argumentList();
setState(179);
match(ClosedRoundBracket);
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
@SuppressWarnings("CheckReturnValue")
public static class ArgumentListContext extends ParserRuleContext {
public List<ExpressionContext> expression() {
return getRuleContexts(ExpressionContext.class);
}
public ExpressionContext expression(int i) {
return getRuleContext(ExpressionContext.class,i);
}
public List<TerminalNode> Comma() { return getTokens(DecafParser.Comma); }
public TerminalNode Comma(int i) {
return getToken(DecafParser.Comma, i);
}
public ArgumentListContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_argumentList; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof DecafListener ) ((DecafListener)listener).enterArgumentList(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof DecafListener ) ((DecafListener)listener).exitArgumentList(this);
}
@Override
public <T> T accept(ParseTreeVisitor<? extends T> visitor) {
if ( visitor instanceof DecafVisitor ) return ((DecafVisitor<? extends T>)visitor).visitArgumentList(this);
else return visitor.visitChildren(this);
}
}
public final ArgumentListContext argumentList() throws RecognitionException {
ArgumentListContext _localctx = new ArgumentListContext(_ctx, getState());
enterRule(_localctx, 24, RULE_argumentList);
int _la;
try {
setState(191);
_errHandler.sync(this);
switch ( getInterpreter().adaptivePredict(_input,21,_ctx) ) {
case 1:
enterOuterAlt(_localctx, 1);
{
setState(182);
_errHandler.sync(this);
_la = _input.LA(1);
if ((((_la) & ~0x3f) == 0 && ((1L << _la) & 33089510703104L) != 0)) {
{
setState(181);
expression();
}
}
}
break;
case 2:
enterOuterAlt(_localctx, 2);
{
setState(184);
expression();
setState(187);
_errHandler.sync(this);
_la = _input.LA(1);
do {
{
{
setState(185);
match(Comma);
setState(186);
expression();
}
}
setState(189);
_errHandler.sync(this);
_la = _input.LA(1);
} while ( _la==Comma );
}
break;
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
@SuppressWarnings("CheckReturnValue")
public static class SubReceiverContext extends ParserRuleContext {
public TerminalNode Dot() { return getToken(DecafParser.Dot, 0); }
public TerminalNode This() { return getToken(DecafParser.This, 0); }
public NewDeclContext newDecl() {
return getRuleContext(NewDeclContext.class,0);
}
public TerminalNode Identifier() { return getToken(DecafParser.Identifier, 0); }
public SubReceiverContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_subReceiver; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof DecafListener ) ((DecafListener)listener).enterSubReceiver(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof DecafListener ) ((DecafListener)listener).exitSubReceiver(this);
}
@Override
public <T> T accept(ParseTreeVisitor<? extends T> visitor) {
if ( visitor instanceof DecafVisitor ) return ((DecafVisitor<? extends T>)visitor).visitSubReceiver(this);
else return visitor.visitChildren(this);
}
}
public final SubReceiverContext subReceiver() throws RecognitionException {
SubReceiverContext _localctx = new SubReceiverContext(_ctx, getState());
enterRule(_localctx, 26, RULE_subReceiver);
try {
enterOuterAlt(_localctx, 1);
{
{
setState(196);
_errHandler.sync(this);
switch (_input.LA(1)) {
case This:
{
setState(193);
match(This);
}
break;
case New:
{
setState(194);
newDecl();
}
break;
case Identifier:
{
setState(195);
match(Identifier);
}
break;
default:
throw new NoViableAltException(this);
}
setState(198);
match(Dot);
}
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
@SuppressWarnings("CheckReturnValue")
public static class ReceiverContext extends ParserRuleContext {
public TerminalNode Dot() { return getToken(DecafParser.Dot, 0); }
public TerminalNode This() { return getToken(DecafParser.This, 0); }
public InstVarContext instVar() {
return getRuleContext(InstVarContext.class,0);
}
public NewDeclContext newDecl() {
return getRuleContext(NewDeclContext.class,0);
}
public TerminalNode Identifier() { return getToken(DecafParser.Identifier, 0); }
public ReceiverContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_receiver; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof DecafListener ) ((DecafListener)listener).enterReceiver(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof DecafListener ) ((DecafListener)listener).exitReceiver(this);
}
@Override
public <T> T accept(ParseTreeVisitor<? extends T> visitor) {
if ( visitor instanceof DecafVisitor ) return ((DecafVisitor<? extends T>)visitor).visitReceiver(this);
else return visitor.visitChildren(this);
}
}
public final ReceiverContext receiver() throws RecognitionException {
ReceiverContext _localctx = new ReceiverContext(_ctx, getState());
enterRule(_localctx, 28, RULE_receiver);
try {
enterOuterAlt(_localctx, 1);
{
{
setState(204);
_errHandler.sync(this);
switch ( getInterpreter().adaptivePredict(_input,23,_ctx) ) {
case 1:
{
setState(200);
match(This);
}
break;
case 2:
{
setState(201);
instVar();
}
break;
case 3:
{
setState(202);
newDecl();
}
break;
case 4:
{
setState(203);
match(Identifier);
}
break;
}
setState(206);
match(Dot);
}
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
@SuppressWarnings("CheckReturnValue")
public static class ReceivingMethodContext extends ParserRuleContext {
public TerminalNode Identifier() { return getToken(DecafParser.Identifier, 0); }
public TerminalNode OpenRoundBracket() { return getToken(DecafParser.OpenRoundBracket, 0); }
public ArgumentListContext argumentList() {
return getRuleContext(ArgumentListContext.class,0);
}
public TerminalNode ClosedRoundBracket() { return getToken(DecafParser.ClosedRoundBracket, 0); }
public TerminalNode Dot() { return getToken(DecafParser.Dot, 0); }
public ReceivingMethodContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_receivingMethod; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof DecafListener ) ((DecafListener)listener).enterReceivingMethod(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof DecafListener ) ((DecafListener)listener).exitReceivingMethod(this);
}
@Override
public <T> T accept(ParseTreeVisitor<? extends T> visitor) {
if ( visitor instanceof DecafVisitor ) return ((DecafVisitor<? extends T>)visitor).visitReceivingMethod(this);
else return visitor.visitChildren(this);
}
}
public final ReceivingMethodContext receivingMethod() throws RecognitionException {
ReceivingMethodContext _localctx = new ReceivingMethodContext(_ctx, getState());
enterRule(_localctx, 30, RULE_receivingMethod);
try {
enterOuterAlt(_localctx, 1);
{
setState(208);
match(Identifier);
setState(209);
match(OpenRoundBracket);
setState(210);
argumentList();
setState(211);
match(ClosedRoundBracket);
setState(212);
match(Dot);
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
@SuppressWarnings("CheckReturnValue")
public static class BinaryExprContext extends ParserRuleContext {
public CalcExprContext calcExpr() {
return getRuleContext(CalcExprContext.class,0);
}
public NonCalcExprContext nonCalcExpr() {
return getRuleContext(NonCalcExprContext.class,0);
}
public ValueContext value() {
return getRuleContext(ValueContext.class,0);
}
public TerminalNode Not() { return getToken(DecafParser.Not, 0); }
public BinaryExprContext binaryExpr() {
return getRuleContext(BinaryExprContext.class,0);
}
public BinaryExprContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_binaryExpr; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof DecafListener ) ((DecafListener)listener).enterBinaryExpr(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof DecafListener ) ((DecafListener)listener).exitBinaryExpr(this);
}
@Override
public <T> T accept(ParseTreeVisitor<? extends T> visitor) {
if ( visitor instanceof DecafVisitor ) return ((DecafVisitor<? extends T>)visitor).visitBinaryExpr(this);
else return visitor.visitChildren(this);
}
}
public final BinaryExprContext binaryExpr() throws RecognitionException {
BinaryExprContext _localctx = new BinaryExprContext(_ctx, getState());
enterRule(_localctx, 32, RULE_binaryExpr);
try {
setState(219);
_errHandler.sync(this);
switch ( getInterpreter().adaptivePredict(_input,24,_ctx) ) {
case 1:
enterOuterAlt(_localctx, 1);
{
setState(214);
calcExpr(0);
}
break;
case 2:
enterOuterAlt(_localctx, 2);
{
setState(215);
nonCalcExpr();
}
break;
case 3:
enterOuterAlt(_localctx, 3);
{
setState(216);
value();
}
break;
case 4:
enterOuterAlt(_localctx, 4);
{
setState(217);
match(Not);
setState(218);
binaryExpr();
}
break;
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
@SuppressWarnings("CheckReturnValue")
public static class CalcExprContext extends ParserRuleContext {
public DotExprContext dotExpr() {
return getRuleContext(DotExprContext.class,0);
}
public CalcExprContext calcExpr() {
return getRuleContext(CalcExprContext.class,0);
}
public TerminalNode LineOperator() { return getToken(DecafParser.LineOperator, 0); }
public CalcExprContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_calcExpr; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof DecafListener ) ((DecafListener)listener).enterCalcExpr(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof DecafListener ) ((DecafListener)listener).exitCalcExpr(this);
}
@Override
public <T> T accept(ParseTreeVisitor<? extends T> visitor) {
if ( visitor instanceof DecafVisitor ) return ((DecafVisitor<? extends T>)visitor).visitCalcExpr(this);
else return visitor.visitChildren(this);
}
}
public final CalcExprContext calcExpr() throws RecognitionException {
return calcExpr(0);
}
private CalcExprContext calcExpr(int _p) throws RecognitionException {
ParserRuleContext _parentctx = _ctx;
int _parentState = getState();
CalcExprContext _localctx = new CalcExprContext(_ctx, _parentState);
CalcExprContext _prevctx = _localctx;
int _startState = 34;
enterRecursionRule(_localctx, 34, RULE_calcExpr, _p);
try {
int _alt;
enterOuterAlt(_localctx, 1);
{
{
setState(222);
dotExpr(0);
}
_ctx.stop = _input.LT(-1);
setState(229);
_errHandler.sync(this);
_alt = getInterpreter().adaptivePredict(_input,25,_ctx);
while ( _alt!=2 && _alt!=org.antlr.v4.runtime.atn.ATN.INVALID_ALT_NUMBER ) {
if ( _alt==1 ) {
if ( _parseListeners!=null ) triggerExitRuleEvent();
_prevctx = _localctx;
{
{
_localctx = new CalcExprContext(_parentctx, _parentState);
pushNewRecursionContext(_localctx, _startState, RULE_calcExpr);
setState(224);
if (!(precpred(_ctx, 2))) throw new FailedPredicateException(this, "precpred(_ctx, 2)");
setState(225);
match(LineOperator);
setState(226);
dotExpr(0);
}
}
}
setState(231);
_errHandler.sync(this);
_alt = getInterpreter().adaptivePredict(_input,25,_ctx);
}
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
unrollRecursionContexts(_parentctx);
}
return _localctx;
}
@SuppressWarnings("CheckReturnValue")
public static class DotExprContext extends ParserRuleContext {
public DotSubExprContext dotSubExpr() {
return getRuleContext(DotSubExprContext.class,0);
}
public DotExprContext dotExpr() {
return getRuleContext(DotExprContext.class,0);
}
public TerminalNode DotOperator() { return getToken(DecafParser.DotOperator, 0); }
public DotExprContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_dotExpr; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof DecafListener ) ((DecafListener)listener).enterDotExpr(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof DecafListener ) ((DecafListener)listener).exitDotExpr(this);
}
@Override
public <T> T accept(ParseTreeVisitor<? extends T> visitor) {
if ( visitor instanceof DecafVisitor ) return ((DecafVisitor<? extends T>)visitor).visitDotExpr(this);
else return visitor.visitChildren(this);
}
}
public final DotExprContext dotExpr() throws RecognitionException {
return dotExpr(0);
}
private DotExprContext dotExpr(int _p) throws RecognitionException {
ParserRuleContext _parentctx = _ctx;
int _parentState = getState();
DotExprContext _localctx = new DotExprContext(_ctx, _parentState);
DotExprContext _prevctx = _localctx;
int _startState = 36;
enterRecursionRule(_localctx, 36, RULE_dotExpr, _p);
try {
int _alt;
enterOuterAlt(_localctx, 1);
{
{
setState(233);
dotSubExpr();
}
_ctx.stop = _input.LT(-1);
setState(240);
_errHandler.sync(this);
_alt = getInterpreter().adaptivePredict(_input,26,_ctx);
while ( _alt!=2 && _alt!=org.antlr.v4.runtime.atn.ATN.INVALID_ALT_NUMBER ) {
if ( _alt==1 ) {
if ( _parseListeners!=null ) triggerExitRuleEvent();
_prevctx = _localctx;
{
{
_localctx = new DotExprContext(_parentctx, _parentState);
pushNewRecursionContext(_localctx, _startState, RULE_dotExpr);
setState(235);
if (!(precpred(_ctx, 2))) throw new FailedPredicateException(this, "precpred(_ctx, 2)");
setState(236);
match(DotOperator);
setState(237);
dotSubExpr();
}
}
}
setState(242);
_errHandler.sync(this);
_alt = getInterpreter().adaptivePredict(_input,26,_ctx);
}
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
unrollRecursionContexts(_parentctx);
}
return _localctx;
}
@SuppressWarnings("CheckReturnValue")
public static class DotSubExprContext extends ParserRuleContext {
public TerminalNode IntValue() { return getToken(DecafParser.IntValue, 0); }
public TerminalNode Identifier() { return getToken(DecafParser.Identifier, 0); }
public InstVarContext instVar() {
return getRuleContext(InstVarContext.class,0);
}
public MethodCallContext methodCall() {
return getRuleContext(MethodCallContext.class,0);
}
public TerminalNode OpenRoundBracket() { return getToken(DecafParser.OpenRoundBracket, 0); }
public CalcExprContext calcExpr() {
return getRuleContext(CalcExprContext.class,0);
}
public TerminalNode ClosedRoundBracket() { return getToken(DecafParser.ClosedRoundBracket, 0); }
public DotSubExprContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_dotSubExpr; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof DecafListener ) ((DecafListener)listener).enterDotSubExpr(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof DecafListener ) ((DecafListener)listener).exitDotSubExpr(this);
}
@Override
public <T> T accept(ParseTreeVisitor<? extends T> visitor) {
if ( visitor instanceof DecafVisitor ) return ((DecafVisitor<? extends T>)visitor).visitDotSubExpr(this);
else return visitor.visitChildren(this);
}
}
public final DotSubExprContext dotSubExpr() throws RecognitionException {
DotSubExprContext _localctx = new DotSubExprContext(_ctx, getState());
enterRule(_localctx, 38, RULE_dotSubExpr);
try {
setState(251);
_errHandler.sync(this);
switch ( getInterpreter().adaptivePredict(_input,27,_ctx) ) {
case 1:
enterOuterAlt(_localctx, 1);
{
setState(243);
match(IntValue);
}
break;
case 2:
enterOuterAlt(_localctx, 2);
{
setState(244);
match(Identifier);
}
break;
case 3:
enterOuterAlt(_localctx, 3);
{
setState(245);
instVar();
}
break;
case 4:
enterOuterAlt(_localctx, 4);
{
setState(246);
methodCall();
}
break;
case 5:
enterOuterAlt(_localctx, 5);
{
setState(247);
match(OpenRoundBracket);
setState(248);
calcExpr(0);
setState(249);
match(ClosedRoundBracket);
}
break;
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
@SuppressWarnings("CheckReturnValue")
public static class NonCalcExprContext extends ParserRuleContext {
public SubExpressionContext subExpression() {
return getRuleContext(SubExpressionContext.class,0);
}
public NonCalcOperatorContext nonCalcOperator() {
return getRuleContext(NonCalcOperatorContext.class,0);
}
public ExpressionContext expression() {
return getRuleContext(ExpressionContext.class,0);
}
public NonCalcExprContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_nonCalcExpr; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof DecafListener ) ((DecafListener)listener).enterNonCalcExpr(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof DecafListener ) ((DecafListener)listener).exitNonCalcExpr(this);
}
@Override
public <T> T accept(ParseTreeVisitor<? extends T> visitor) {
if ( visitor instanceof DecafVisitor ) return ((DecafVisitor<? extends T>)visitor).visitNonCalcExpr(this);
else return visitor.visitChildren(this);
}
}
public final NonCalcExprContext nonCalcExpr() throws RecognitionException {
NonCalcExprContext _localctx = new NonCalcExprContext(_ctx, getState());
enterRule(_localctx, 40, RULE_nonCalcExpr);
try {
enterOuterAlt(_localctx, 1);
{
setState(253);
subExpression();
setState(254);
nonCalcOperator();
setState(255);
expression();
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
@SuppressWarnings("CheckReturnValue")
public static class NonCalcOperatorContext extends ParserRuleContext {
public TerminalNode LogicalOpertor() { return getToken(DecafParser.LogicalOpertor, 0); }
public TerminalNode ComparisonOperator() { return getToken(DecafParser.ComparisonOperator, 0); }
public NonCalcOperatorContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_nonCalcOperator; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof DecafListener ) ((DecafListener)listener).enterNonCalcOperator(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof DecafListener ) ((DecafListener)listener).exitNonCalcOperator(this);
}
@Override
public <T> T accept(ParseTreeVisitor<? extends T> visitor) {
if ( visitor instanceof DecafVisitor ) return ((DecafVisitor<? extends T>)visitor).visitNonCalcOperator(this);
else return visitor.visitChildren(this);
}
}
public final NonCalcOperatorContext nonCalcOperator() throws RecognitionException {
NonCalcOperatorContext _localctx = new NonCalcOperatorContext(_ctx, getState());
enterRule(_localctx, 42, RULE_nonCalcOperator);
int _la;
try {
enterOuterAlt(_localctx, 1);
{
setState(257);
_la = _input.LA(1);
if ( !(_la==ComparisonOperator || _la==LogicalOpertor) ) {
_errHandler.recoverInline(this);
}
else {
if ( _input.LA(1)==Token.EOF ) matchedEOF = true;
_errHandler.reportMatch(this);
consume();
}
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
@SuppressWarnings("CheckReturnValue")
public static class StmtExprContext extends ParserRuleContext {
public AssignContext assign() {
return getRuleContext(AssignContext.class,0);
}
public NewDeclContext newDecl() {
return getRuleContext(NewDeclContext.class,0);
}
public MethodCallContext methodCall() {
return getRuleContext(MethodCallContext.class,0);
}
public StmtExprContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_stmtExpr; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof DecafListener ) ((DecafListener)listener).enterStmtExpr(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof DecafListener ) ((DecafListener)listener).exitStmtExpr(this);
}
@Override
public <T> T accept(ParseTreeVisitor<? extends T> visitor) {
if ( visitor instanceof DecafVisitor ) return ((DecafVisitor<? extends T>)visitor).visitStmtExpr(this);
else return visitor.visitChildren(this);
}
}
public final StmtExprContext stmtExpr() throws RecognitionException {
StmtExprContext _localctx = new StmtExprContext(_ctx, getState());
enterRule(_localctx, 44, RULE_stmtExpr);
try {
setState(262);
_errHandler.sync(this);
switch ( getInterpreter().adaptivePredict(_input,28,_ctx) ) {
case 1:
enterOuterAlt(_localctx, 1);
{
setState(259);
assign();
}
break;
case 2:
enterOuterAlt(_localctx, 2);
{
setState(260);
newDecl();
}
break;
case 3:
enterOuterAlt(_localctx, 3);
{
setState(261);
methodCall();
}
break;
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
@SuppressWarnings("CheckReturnValue")
public static class StatementContext extends ParserRuleContext {
public ReturnStmtContext returnStmt() {
return getRuleContext(ReturnStmtContext.class,0);
}
public TerminalNode Semicolon() { return getToken(DecafParser.Semicolon, 0); }
public LocalVarDeclContext localVarDecl() {
return getRuleContext(LocalVarDeclContext.class,0);
}
public BlockContext block() {
return getRuleContext(BlockContext.class,0);
}
public WhileStmtContext whileStmt() {
return getRuleContext(WhileStmtContext.class,0);
}
public IfElseStmtContext ifElseStmt() {
return getRuleContext(IfElseStmtContext.class,0);
}
public StmtExprContext stmtExpr() {
return getRuleContext(StmtExprContext.class,0);
}
public StatementContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_statement; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof DecafListener ) ((DecafListener)listener).enterStatement(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof DecafListener ) ((DecafListener)listener).exitStatement(this);
}
@Override
public <T> T accept(ParseTreeVisitor<? extends T> visitor) {
if ( visitor instanceof DecafVisitor ) return ((DecafVisitor<? extends T>)visitor).visitStatement(this);
else return visitor.visitChildren(this);
}
}
public final StatementContext statement() throws RecognitionException {
StatementContext _localctx = new StatementContext(_ctx, getState());
enterRule(_localctx, 46, RULE_statement);
try {
setState(276);
_errHandler.sync(this);
switch ( getInterpreter().adaptivePredict(_input,29,_ctx) ) {
case 1:
enterOuterAlt(_localctx, 1);
{
setState(264);
returnStmt();
setState(265);
match(Semicolon);
}
break;
case 2:
enterOuterAlt(_localctx, 2);
{
setState(267);
localVarDecl();
setState(268);
match(Semicolon);
}
break;
case 3:
enterOuterAlt(_localctx, 3);
{
setState(270);
block();
}
break;
case 4:
enterOuterAlt(_localctx, 4);
{
setState(271);
whileStmt();
}
break;
case 5:
enterOuterAlt(_localctx, 5);
{
setState(272);
ifElseStmt();
}
break;
case 6:
enterOuterAlt(_localctx, 6);
{
setState(273);
stmtExpr();
setState(274);
match(Semicolon);
}
break;
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
@SuppressWarnings("CheckReturnValue")
public static class ReturnStmtContext extends ParserRuleContext {
public TerminalNode Return() { return getToken(DecafParser.Return, 0); }
public ExpressionContext expression() {
return getRuleContext(ExpressionContext.class,0);
}
public ReturnStmtContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_returnStmt; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof DecafListener ) ((DecafListener)listener).enterReturnStmt(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof DecafListener ) ((DecafListener)listener).exitReturnStmt(this);
}
@Override
public <T> T accept(ParseTreeVisitor<? extends T> visitor) {
if ( visitor instanceof DecafVisitor ) return ((DecafVisitor<? extends T>)visitor).visitReturnStmt(this);
else return visitor.visitChildren(this);
}
}
public final ReturnStmtContext returnStmt() throws RecognitionException {
ReturnStmtContext _localctx = new ReturnStmtContext(_ctx, getState());
enterRule(_localctx, 48, RULE_returnStmt);
int _la;
try {
enterOuterAlt(_localctx, 1);
{
setState(278);
match(Return);
setState(280);
_errHandler.sync(this);
_la = _input.LA(1);
if ((((_la) & ~0x3f) == 0 && ((1L << _la) & 33089510703104L) != 0)) {
{
setState(279);
expression();
}
}
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
@SuppressWarnings("CheckReturnValue")
public static class LocalVarDeclContext extends ParserRuleContext {
public TypeContext type() {
return getRuleContext(TypeContext.class,0);
}
public TerminalNode Identifier() { return getToken(DecafParser.Identifier, 0); }
public TerminalNode Assign() { return getToken(DecafParser.Assign, 0); }
public ExpressionContext expression() {
return getRuleContext(ExpressionContext.class,0);
}
public LocalVarDeclContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_localVarDecl; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof DecafListener ) ((DecafListener)listener).enterLocalVarDecl(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof DecafListener ) ((DecafListener)listener).exitLocalVarDecl(this);
}
@Override
public <T> T accept(ParseTreeVisitor<? extends T> visitor) {
if ( visitor instanceof DecafVisitor ) return ((DecafVisitor<? extends T>)visitor).visitLocalVarDecl(this);
else return visitor.visitChildren(this);
}
}
public final LocalVarDeclContext localVarDecl() throws RecognitionException {
LocalVarDeclContext _localctx = new LocalVarDeclContext(_ctx, getState());
enterRule(_localctx, 50, RULE_localVarDecl);
int _la;
try {
enterOuterAlt(_localctx, 1);
{
setState(282);
type();
setState(283);
match(Identifier);
setState(286);
_errHandler.sync(this);
_la = _input.LA(1);
if (_la==Assign) {
{
setState(284);
match(Assign);
setState(285);
expression();
}
}
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
@SuppressWarnings("CheckReturnValue")
public static class BlockContext extends ParserRuleContext {
public TerminalNode OpenCurlyBracket() { return getToken(DecafParser.OpenCurlyBracket, 0); }
public TerminalNode ClosedCurlyBracket() { return getToken(DecafParser.ClosedCurlyBracket, 0); }
public List<StatementContext> statement() {
return getRuleContexts(StatementContext.class);
}
public StatementContext statement(int i) {
return getRuleContext(StatementContext.class,i);
}
public BlockContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_block; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof DecafListener ) ((DecafListener)listener).enterBlock(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof DecafListener ) ((DecafListener)listener).exitBlock(this);
}
@Override
public <T> T accept(ParseTreeVisitor<? extends T> visitor) {
if ( visitor instanceof DecafVisitor ) return ((DecafVisitor<? extends T>)visitor).visitBlock(this);
else return visitor.visitChildren(this);
}
}
public final BlockContext block() throws RecognitionException {
BlockContext _localctx = new BlockContext(_ctx, getState());
enterRule(_localctx, 52, RULE_block);
int _la;
try {
enterOuterAlt(_localctx, 1);
{
setState(288);
match(OpenCurlyBracket);
setState(292);
_errHandler.sync(this);
_la = _input.LA(1);
while ((((_la) & ~0x3f) == 0 && ((1L << _la) & 2051954180096L) != 0)) {
{
{
setState(289);
statement();
}
}
setState(294);
_errHandler.sync(this);
_la = _input.LA(1);
}
setState(295);
match(ClosedCurlyBracket);
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
@SuppressWarnings("CheckReturnValue")
public static class WhileStmtContext extends ParserRuleContext {
public TerminalNode While() { return getToken(DecafParser.While, 0); }
public TerminalNode OpenRoundBracket() { return getToken(DecafParser.OpenRoundBracket, 0); }
public ExpressionContext expression() {
return getRuleContext(ExpressionContext.class,0);
}
public TerminalNode ClosedRoundBracket() { return getToken(DecafParser.ClosedRoundBracket, 0); }
public StatementContext statement() {
return getRuleContext(StatementContext.class,0);
}
public WhileStmtContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_whileStmt; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof DecafListener ) ((DecafListener)listener).enterWhileStmt(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof DecafListener ) ((DecafListener)listener).exitWhileStmt(this);
}
@Override
public <T> T accept(ParseTreeVisitor<? extends T> visitor) {
if ( visitor instanceof DecafVisitor ) return ((DecafVisitor<? extends T>)visitor).visitWhileStmt(this);
else return visitor.visitChildren(this);
}
}
public final WhileStmtContext whileStmt() throws RecognitionException {
WhileStmtContext _localctx = new WhileStmtContext(_ctx, getState());
enterRule(_localctx, 54, RULE_whileStmt);
try {
enterOuterAlt(_localctx, 1);
{
setState(297);
match(While);
setState(298);
match(OpenRoundBracket);
setState(299);
expression();
setState(300);
match(ClosedRoundBracket);
setState(301);
statement();
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
@SuppressWarnings("CheckReturnValue")
public static class IfElseStmtContext extends ParserRuleContext {
public IfStmtContext ifStmt() {
return getRuleContext(IfStmtContext.class,0);
}
public ElseStmtContext elseStmt() {
return getRuleContext(ElseStmtContext.class,0);
}
public IfElseStmtContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_ifElseStmt; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof DecafListener ) ((DecafListener)listener).enterIfElseStmt(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof DecafListener ) ((DecafListener)listener).exitIfElseStmt(this);
}
@Override
public <T> T accept(ParseTreeVisitor<? extends T> visitor) {
if ( visitor instanceof DecafVisitor ) return ((DecafVisitor<? extends T>)visitor).visitIfElseStmt(this);
else return visitor.visitChildren(this);
}
}
public final IfElseStmtContext ifElseStmt() throws RecognitionException {
IfElseStmtContext _localctx = new IfElseStmtContext(_ctx, getState());
enterRule(_localctx, 56, RULE_ifElseStmt);
try {
enterOuterAlt(_localctx, 1);
{
setState(303);
ifStmt();
setState(305);
_errHandler.sync(this);
switch ( getInterpreter().adaptivePredict(_input,33,_ctx) ) {
case 1:
{
setState(304);
elseStmt();
}
break;
}
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
@SuppressWarnings("CheckReturnValue")
public static class IfStmtContext extends ParserRuleContext {
public TerminalNode If() { return getToken(DecafParser.If, 0); }
public TerminalNode OpenRoundBracket() { return getToken(DecafParser.OpenRoundBracket, 0); }
public ExpressionContext expression() {
return getRuleContext(ExpressionContext.class,0);
}
public TerminalNode ClosedRoundBracket() { return getToken(DecafParser.ClosedRoundBracket, 0); }
public StatementContext statement() {
return getRuleContext(StatementContext.class,0);
}
public IfStmtContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_ifStmt; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof DecafListener ) ((DecafListener)listener).enterIfStmt(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof DecafListener ) ((DecafListener)listener).exitIfStmt(this);
}
@Override
public <T> T accept(ParseTreeVisitor<? extends T> visitor) {
if ( visitor instanceof DecafVisitor ) return ((DecafVisitor<? extends T>)visitor).visitIfStmt(this);
else return visitor.visitChildren(this);
}
}
public final IfStmtContext ifStmt() throws RecognitionException {
IfStmtContext _localctx = new IfStmtContext(_ctx, getState());
enterRule(_localctx, 58, RULE_ifStmt);
try {
enterOuterAlt(_localctx, 1);
{
setState(307);
match(If);
setState(308);
match(OpenRoundBracket);
setState(309);
expression();
setState(310);
match(ClosedRoundBracket);
setState(311);
statement();
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
@SuppressWarnings("CheckReturnValue")
public static class ElseStmtContext extends ParserRuleContext {
public TerminalNode Else() { return getToken(DecafParser.Else, 0); }
public StatementContext statement() {
return getRuleContext(StatementContext.class,0);
}
public ElseStmtContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_elseStmt; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof DecafListener ) ((DecafListener)listener).enterElseStmt(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof DecafListener ) ((DecafListener)listener).exitElseStmt(this);
}
@Override
public <T> T accept(ParseTreeVisitor<? extends T> visitor) {
if ( visitor instanceof DecafVisitor ) return ((DecafVisitor<? extends T>)visitor).visitElseStmt(this);
else return visitor.visitChildren(this);
}
}
public final ElseStmtContext elseStmt() throws RecognitionException {
ElseStmtContext _localctx = new ElseStmtContext(_ctx, getState());
enterRule(_localctx, 60, RULE_elseStmt);
try {
enterOuterAlt(_localctx, 1);
{
setState(313);
match(Else);
setState(314);
statement();
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
@SuppressWarnings("CheckReturnValue")
public static class AssignContext extends ParserRuleContext {
public AssignableExprContext assignableExpr() {
return getRuleContext(AssignableExprContext.class,0);
}
public TerminalNode Assign() { return getToken(DecafParser.Assign, 0); }
public ExpressionContext expression() {
return getRuleContext(ExpressionContext.class,0);
}
public AssignContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_assign; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof DecafListener ) ((DecafListener)listener).enterAssign(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof DecafListener ) ((DecafListener)listener).exitAssign(this);
}
@Override
public <T> T accept(ParseTreeVisitor<? extends T> visitor) {
if ( visitor instanceof DecafVisitor ) return ((DecafVisitor<? extends T>)visitor).visitAssign(this);
else return visitor.visitChildren(this);
}
}
public final AssignContext assign() throws RecognitionException {
AssignContext _localctx = new AssignContext(_ctx, getState());
enterRule(_localctx, 62, RULE_assign);
try {
enterOuterAlt(_localctx, 1);
{
setState(316);
assignableExpr();
setState(317);
match(Assign);
setState(318);
expression();
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
@SuppressWarnings("CheckReturnValue")
public static class NewDeclContext extends ParserRuleContext {
public TerminalNode New() { return getToken(DecafParser.New, 0); }
public TerminalNode Identifier() { return getToken(DecafParser.Identifier, 0); }
public TerminalNode OpenRoundBracket() { return getToken(DecafParser.OpenRoundBracket, 0); }
public ArgumentListContext argumentList() {
return getRuleContext(ArgumentListContext.class,0);
}
public TerminalNode ClosedRoundBracket() { return getToken(DecafParser.ClosedRoundBracket, 0); }
public NewDeclContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_newDecl; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof DecafListener ) ((DecafListener)listener).enterNewDecl(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof DecafListener ) ((DecafListener)listener).exitNewDecl(this);
}
@Override
public <T> T accept(ParseTreeVisitor<? extends T> visitor) {
if ( visitor instanceof DecafVisitor ) return ((DecafVisitor<? extends T>)visitor).visitNewDecl(this);
else return visitor.visitChildren(this);
}
}
public final NewDeclContext newDecl() throws RecognitionException {
NewDeclContext _localctx = new NewDeclContext(_ctx, getState());
enterRule(_localctx, 64, RULE_newDecl);
try {
enterOuterAlt(_localctx, 1);
{
setState(320);
match(New);
setState(321);
match(Identifier);
setState(322);
match(OpenRoundBracket);
setState(323);
argumentList();
setState(324);
match(ClosedRoundBracket);
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
@SuppressWarnings("CheckReturnValue")
public static class TypeContext extends ParserRuleContext {
public TerminalNode Int() { return getToken(DecafParser.Int, 0); }
public TerminalNode Boolean() { return getToken(DecafParser.Boolean, 0); }
public TerminalNode Char() { return getToken(DecafParser.Char, 0); }
public TerminalNode Identifier() { return getToken(DecafParser.Identifier, 0); }
public TypeContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_type; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof DecafListener ) ((DecafListener)listener).enterType(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof DecafListener ) ((DecafListener)listener).exitType(this);
}
@Override
public <T> T accept(ParseTreeVisitor<? extends T> visitor) {
if ( visitor instanceof DecafVisitor ) return ((DecafVisitor<? extends T>)visitor).visitType(this);
else return visitor.visitChildren(this);
}
}
public final TypeContext type() throws RecognitionException {
TypeContext _localctx = new TypeContext(_ctx, getState());
enterRule(_localctx, 66, RULE_type);
int _la;
try {
enterOuterAlt(_localctx, 1);
{
setState(326);
_la = _input.LA(1);
if ( !((((_la) & ~0x3f) == 0 && ((1L << _la) & 1992864825344L) != 0)) ) {
_errHandler.recoverInline(this);
}
else {
if ( _input.LA(1)==Token.EOF ) matchedEOF = true;
_errHandler.reportMatch(this);
consume();
}
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
@SuppressWarnings("CheckReturnValue")
public static class ValueContext extends ParserRuleContext {
public TerminalNode IntValue() { return getToken(DecafParser.IntValue, 0); }
public TerminalNode BooleanValue() { return getToken(DecafParser.BooleanValue, 0); }
public TerminalNode CharValue() { return getToken(DecafParser.CharValue, 0); }
public TerminalNode NullValue() { return getToken(DecafParser.NullValue, 0); }
public ValueContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_value; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof DecafListener ) ((DecafListener)listener).enterValue(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof DecafListener ) ((DecafListener)listener).exitValue(this);
}
@Override
public <T> T accept(ParseTreeVisitor<? extends T> visitor) {
if ( visitor instanceof DecafVisitor ) return ((DecafVisitor<? extends T>)visitor).visitValue(this);
else return visitor.visitChildren(this);
}
}
public final ValueContext value() throws RecognitionException {
ValueContext _localctx = new ValueContext(_ctx, getState());
enterRule(_localctx, 68, RULE_value);
int _la;
try {
enterOuterAlt(_localctx, 1);
{
setState(328);
_la = _input.LA(1);
if ( !((((_la) & ~0x3f) == 0 && ((1L << _la) & 32985348833280L) != 0)) ) {
_errHandler.recoverInline(this);
}
else {
if ( _input.LA(1)==Token.EOF ) matchedEOF = true;
_errHandler.reportMatch(this);
consume();
}
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public boolean sempred(RuleContext _localctx, int ruleIndex, int predIndex) {
switch (ruleIndex) {
case 17:
return calcExpr_sempred((CalcExprContext)_localctx, predIndex);
case 18:
return dotExpr_sempred((DotExprContext)_localctx, predIndex);
}
return true;
}
private boolean calcExpr_sempred(CalcExprContext _localctx, int predIndex) {
switch (predIndex) {
case 0:
return precpred(_ctx, 2);
}
return true;
}
private boolean dotExpr_sempred(DotExprContext _localctx, int predIndex) {
switch (predIndex) {
case 1:
return precpred(_ctx, 2);
}
return true;
}
public static final String _serializedATN =
"\u0004\u0001-\u014b\u0002\u0000\u0007\u0000\u0002\u0001\u0007\u0001\u0002"+
"\u0002\u0007\u0002\u0002\u0003\u0007\u0003\u0002\u0004\u0007\u0004\u0002"+
"\u0005\u0007\u0005\u0002\u0006\u0007\u0006\u0002\u0007\u0007\u0007\u0002"+
"\b\u0007\b\u0002\t\u0007\t\u0002\n\u0007\n\u0002\u000b\u0007\u000b\u0002"+
"\f\u0007\f\u0002\r\u0007\r\u0002\u000e\u0007\u000e\u0002\u000f\u0007\u000f"+
"\u0002\u0010\u0007\u0010\u0002\u0011\u0007\u0011\u0002\u0012\u0007\u0012"+
"\u0002\u0013\u0007\u0013\u0002\u0014\u0007\u0014\u0002\u0015\u0007\u0015"+
"\u0002\u0016\u0007\u0016\u0002\u0017\u0007\u0017\u0002\u0018\u0007\u0018"+
"\u0002\u0019\u0007\u0019\u0002\u001a\u0007\u001a\u0002\u001b\u0007\u001b"+
"\u0002\u001c\u0007\u001c\u0002\u001d\u0007\u001d\u0002\u001e\u0007\u001e"+
"\u0002\u001f\u0007\u001f\u0002 \u0007 \u0002!\u0007!\u0002\"\u0007\"\u0001"+
"\u0000\u0004\u0000H\b\u0000\u000b\u0000\f\u0000I\u0001\u0001\u0003\u0001"+
"M\b\u0001\u0001\u0001\u0001\u0001\u0001\u0001\u0001\u0001\u0001\u0001"+
"\u0001\u0001\u0005\u0001U\b\u0001\n\u0001\f\u0001X\t\u0001\u0001\u0001"+
"\u0001\u0001\u0003\u0001\\\b\u0001\u0001\u0001\u0001\u0001\u0001\u0002"+
"\u0003\u0002a\b\u0002\u0001\u0002\u0001\u0002\u0001\u0002\u0003\u0002"+
"f\b\u0002\u0001\u0002\u0001\u0002\u0001\u0002\u0001\u0003\u0003\u0003"+
"l\b\u0003\u0001\u0003\u0001\u0003\u0003\u0003p\b\u0003\u0001\u0003\u0001"+
"\u0003\u0001\u0003\u0003\u0003u\b\u0003\u0001\u0003\u0001\u0003\u0001"+
"\u0003\u0001\u0004\u0003\u0004{\b\u0004\u0001\u0004\u0001\u0004\u0001"+
"\u0004\u0001\u0004\u0001\u0005\u0001\u0005\u0001\u0005\u0005\u0005\u0084"+
"\b\u0005\n\u0005\f\u0005\u0087\t\u0005\u0001\u0006\u0001\u0006\u0001\u0006"+
"\u0001\u0007\u0001\u0007\u0003\u0007\u008e\b\u0007\u0001\b\u0001\b\u0001"+
"\b\u0001\b\u0001\b\u0001\b\u0001\b\u0003\b\u0097\b\b\u0001\t\u0001\t\u0003"+
"\t\u009b\b\t\u0001\n\u0003\n\u009e\b\n\u0001\n\u0005\n\u00a1\b\n\n\n\f"+
"\n\u00a4\t\n\u0001\n\u0001\n\u0001\u000b\u0003\u000b\u00a9\b\u000b\u0001"+
"\u000b\u0005\u000b\u00ac\b\u000b\n\u000b\f\u000b\u00af\t\u000b\u0001\u000b"+
"\u0001\u000b\u0001\u000b\u0001\u000b\u0001\u000b\u0001\f\u0003\f\u00b7"+
"\b\f\u0001\f\u0001\f\u0001\f\u0004\f\u00bc\b\f\u000b\f\f\f\u00bd\u0003"+
"\f\u00c0\b\f\u0001\r\u0001\r\u0001\r\u0003\r\u00c5\b\r\u0001\r\u0001\r"+
"\u0001\u000e\u0001\u000e\u0001\u000e\u0001\u000e\u0003\u000e\u00cd\b\u000e"+
"\u0001\u000e\u0001\u000e\u0001\u000f\u0001\u000f\u0001\u000f\u0001\u000f"+
"\u0001\u000f\u0001\u000f\u0001\u0010\u0001\u0010\u0001\u0010\u0001\u0010"+
"\u0001\u0010\u0003\u0010\u00dc\b\u0010\u0001\u0011\u0001\u0011\u0001\u0011"+
"\u0001\u0011\u0001\u0011\u0001\u0011\u0005\u0011\u00e4\b\u0011\n\u0011"+
"\f\u0011\u00e7\t\u0011\u0001\u0012\u0001\u0012\u0001\u0012\u0001\u0012"+
"\u0001\u0012\u0001\u0012\u0005\u0012\u00ef\b\u0012\n\u0012\f\u0012\u00f2"+
"\t\u0012\u0001\u0013\u0001\u0013\u0001\u0013\u0001\u0013\u0001\u0013\u0001"+
"\u0013\u0001\u0013\u0001\u0013\u0003\u0013\u00fc\b\u0013\u0001\u0014\u0001"+
"\u0014\u0001\u0014\u0001\u0014\u0001\u0015\u0001\u0015\u0001\u0016\u0001"+
"\u0016\u0001\u0016\u0003\u0016\u0107\b\u0016\u0001\u0017\u0001\u0017\u0001"+
"\u0017\u0001\u0017\u0001\u0017\u0001\u0017\u0001\u0017\u0001\u0017\u0001"+
"\u0017\u0001\u0017\u0001\u0017\u0001\u0017\u0003\u0017\u0115\b\u0017\u0001"+
"\u0018\u0001\u0018\u0003\u0018\u0119\b\u0018\u0001\u0019\u0001\u0019\u0001"+
"\u0019\u0001\u0019\u0003\u0019\u011f\b\u0019\u0001\u001a\u0001\u001a\u0005"+
"\u001a\u0123\b\u001a\n\u001a\f\u001a\u0126\t\u001a\u0001\u001a\u0001\u001a"+
"\u0001\u001b\u0001\u001b\u0001\u001b\u0001\u001b\u0001\u001b\u0001\u001b"+
"\u0001\u001c\u0001\u001c\u0003\u001c\u0132\b\u001c\u0001\u001d\u0001\u001d"+
"\u0001\u001d\u0001\u001d\u0001\u001d\u0001\u001d\u0001\u001e\u0001\u001e"+
"\u0001\u001e\u0001\u001f\u0001\u001f\u0001\u001f\u0001\u001f\u0001 \u0001"+
" \u0001 \u0001 \u0001 \u0001 \u0001!\u0001!\u0001\"\u0001\"\u0001\"\u0000"+
"\u0002\"$#\u0000\u0002\u0004\u0006\b\n\f\u000e\u0010\u0012\u0014\u0016"+
"\u0018\u001a\u001c\u001e \"$&(*,.02468:<>@BD\u0000\u0003\u0001\u0000\u0005"+
"\u0006\u0002\u0000$$&(\u0001\u0000),\u0159\u0000G\u0001\u0000\u0000\u0000"+
"\u0002L\u0001\u0000\u0000\u0000\u0004`\u0001\u0000\u0000\u0000\u0006k"+
"\u0001\u0000\u0000\u0000\bz\u0001\u0000\u0000\u0000\n\u0080\u0001\u0000"+
"\u0000\u0000\f\u0088\u0001\u0000\u0000\u0000\u000e\u008d\u0001\u0000\u0000"+
"\u0000\u0010\u0096\u0001\u0000\u0000\u0000\u0012\u009a\u0001\u0000\u0000"+
"\u0000\u0014\u009d\u0001\u0000\u0000\u0000\u0016\u00a8\u0001\u0000\u0000"+
"\u0000\u0018\u00bf\u0001\u0000\u0000\u0000\u001a\u00c4\u0001\u0000\u0000"+
"\u0000\u001c\u00cc\u0001\u0000\u0000\u0000\u001e\u00d0\u0001\u0000\u0000"+
"\u0000 \u00db\u0001\u0000\u0000\u0000\"\u00dd\u0001\u0000\u0000\u0000"+
"$\u00e8\u0001\u0000\u0000\u0000&\u00fb\u0001\u0000\u0000\u0000(\u00fd"+
"\u0001\u0000\u0000\u0000*\u0101\u0001\u0000\u0000\u0000,\u0106\u0001\u0000"+
"\u0000\u0000.\u0114\u0001\u0000\u0000\u00000\u0116\u0001\u0000\u0000\u0000"+
"2\u011a\u0001\u0000\u0000\u00004\u0120\u0001\u0000\u0000\u00006\u0129"+
"\u0001\u0000\u0000\u00008\u012f\u0001\u0000\u0000\u0000:\u0133\u0001\u0000"+
"\u0000\u0000<\u0139\u0001\u0000\u0000\u0000>\u013c\u0001\u0000\u0000\u0000"+
"@\u0140\u0001\u0000\u0000\u0000B\u0146\u0001\u0000\u0000\u0000D\u0148"+
"\u0001\u0000\u0000\u0000FH\u0003\u0002\u0001\u0000GF\u0001\u0000\u0000"+
"\u0000HI\u0001\u0000\u0000\u0000IG\u0001\u0000\u0000\u0000IJ\u0001\u0000"+
"\u0000\u0000J\u0001\u0001\u0000\u0000\u0000KM\u0005\u0001\u0000\u0000"+
"LK\u0001\u0000\u0000\u0000LM\u0001\u0000\u0000\u0000MN\u0001\u0000\u0000"+
"\u0000NO\u0005\u001d\u0000\u0000OP\u0005$\u0000\u0000PV\u0005\u0019\u0000"+
"\u0000QU\u0003\u0004\u0002\u0000RU\u0003\b\u0004\u0000SU\u0003\u0006\u0003"+
"\u0000TQ\u0001\u0000\u0000\u0000TR\u0001\u0000\u0000\u0000TS\u0001\u0000"+
"\u0000\u0000UX\u0001\u0000\u0000\u0000VT\u0001\u0000\u0000\u0000VW\u0001"+
"\u0000\u0000\u0000W[\u0001\u0000\u0000\u0000XV\u0001\u0000\u0000\u0000"+
"YZ\u0005\u0002\u0000\u0000Z\\\u00034\u001a\u0000[Y\u0001\u0000\u0000\u0000"+
"[\\\u0001\u0000\u0000\u0000\\]\u0001\u0000\u0000\u0000]^\u0005\u001a\u0000"+
"\u0000^\u0003\u0001\u0000\u0000\u0000_a\u0005\u0001\u0000\u0000`_\u0001"+
"\u0000\u0000\u0000`a\u0001\u0000\u0000\u0000ab\u0001\u0000\u0000\u0000"+
"bc\u0005$\u0000\u0000ce\u0005\u0017\u0000\u0000df\u0003\n\u0005\u0000"+
"ed\u0001\u0000\u0000\u0000ef\u0001\u0000\u0000\u0000fg\u0001\u0000\u0000"+
"\u0000gh\u0005\u0018\u0000\u0000hi\u00034\u001a\u0000i\u0005\u0001\u0000"+
"\u0000\u0000jl\u0005\u0001\u0000\u0000kj\u0001\u0000\u0000\u0000kl\u0001"+
"\u0000\u0000\u0000lo\u0001\u0000\u0000\u0000mp\u0003B!\u0000np\u0005%"+
"\u0000\u0000om\u0001\u0000\u0000\u0000on\u0001\u0000\u0000\u0000pq\u0001"+
"\u0000\u0000\u0000qr\u0005$\u0000\u0000rt\u0005\u0017\u0000\u0000su\u0003"+
"\n\u0005\u0000ts\u0001\u0000\u0000\u0000tu\u0001\u0000\u0000\u0000uv\u0001"+
"\u0000\u0000\u0000vw\u0005\u0018\u0000\u0000wx\u00034\u001a\u0000x\u0007"+
"\u0001\u0000\u0000\u0000y{\u0005\u0001\u0000\u0000zy\u0001\u0000\u0000"+
"\u0000z{\u0001\u0000\u0000\u0000{|\u0001\u0000\u0000\u0000|}\u0003B!\u0000"+
"}~\u0005$\u0000\u0000~\u007f\u0005\u001b\u0000\u0000\u007f\t\u0001\u0000"+
"\u0000\u0000\u0080\u0085\u0003\f\u0006\u0000\u0081\u0082\u0005\u001c\u0000"+
"\u0000\u0082\u0084\u0003\f\u0006\u0000\u0083\u0081\u0001\u0000\u0000\u0000"+
"\u0084\u0087\u0001\u0000\u0000\u0000\u0085\u0083\u0001\u0000\u0000\u0000"+
"\u0085\u0086\u0001\u0000\u0000\u0000\u0086\u000b\u0001\u0000\u0000\u0000"+
"\u0087\u0085\u0001\u0000\u0000\u0000\u0088\u0089\u0003B!\u0000\u0089\u008a"+
"\u0005$\u0000\u0000\u008a\r\u0001\u0000\u0000\u0000\u008b\u008e\u0003"+
"\u0010\b\u0000\u008c\u008e\u0003 \u0010\u0000\u008d\u008b\u0001\u0000"+
"\u0000\u0000\u008d\u008c\u0001\u0000\u0000\u0000\u008e\u000f\u0001\u0000"+
"\u0000\u0000\u008f\u0097\u0005\u001e\u0000\u0000\u0090\u0097\u0003\u0012"+
"\t\u0000\u0091\u0097\u0003,\u0016\u0000\u0092\u0093\u0005\u0017\u0000"+
"\u0000\u0093\u0094\u0003\u0010\b\u0000\u0094\u0095\u0005\u0018\u0000\u0000"+
"\u0095\u0097\u0001\u0000\u0000\u0000\u0096\u008f\u0001\u0000\u0000\u0000"+
"\u0096\u0090\u0001\u0000\u0000\u0000\u0096\u0091\u0001\u0000\u0000\u0000"+
"\u0096\u0092\u0001\u0000\u0000\u0000\u0097\u0011\u0001\u0000\u0000\u0000"+
"\u0098\u009b\u0005$\u0000\u0000\u0099\u009b\u0003\u0014\n\u0000\u009a"+
"\u0098\u0001\u0000\u0000\u0000\u009a\u0099\u0001\u0000\u0000\u0000\u009b"+
"\u0013\u0001\u0000\u0000\u0000\u009c\u009e\u0003\u001a\r\u0000\u009d\u009c"+
"\u0001\u0000\u0000\u0000\u009d\u009e\u0001\u0000\u0000\u0000\u009e\u00a2"+
"\u0001\u0000\u0000\u0000\u009f\u00a1\u0003\u001e\u000f\u0000\u00a0\u009f"+
"\u0001\u0000\u0000\u0000\u00a1\u00a4\u0001\u0000\u0000\u0000\u00a2\u00a0"+
"\u0001\u0000\u0000\u0000\u00a2\u00a3\u0001\u0000\u0000\u0000\u00a3\u00a5"+
"\u0001\u0000\u0000\u0000\u00a4\u00a2\u0001\u0000\u0000\u0000\u00a5\u00a6"+
"\u0005$\u0000\u0000\u00a6\u0015\u0001\u0000\u0000\u0000\u00a7\u00a9\u0003"+
"\u001c\u000e\u0000\u00a8\u00a7\u0001\u0000\u0000\u0000\u00a8\u00a9\u0001"+
"\u0000\u0000\u0000\u00a9\u00ad\u0001\u0000\u0000\u0000\u00aa\u00ac\u0003"+
"\u001e\u000f\u0000\u00ab\u00aa\u0001\u0000\u0000\u0000\u00ac\u00af\u0001"+
"\u0000\u0000\u0000\u00ad\u00ab\u0001\u0000\u0000\u0000\u00ad\u00ae\u0001"+
"\u0000\u0000\u0000\u00ae\u00b0\u0001\u0000\u0000\u0000\u00af\u00ad\u0001"+
"\u0000\u0000\u0000\u00b0\u00b1\u0005$\u0000\u0000\u00b1\u00b2\u0005\u0017"+
"\u0000\u0000\u00b2\u00b3\u0003\u0018\f\u0000\u00b3\u00b4\u0005\u0018\u0000"+
"\u0000\u00b4\u0017\u0001\u0000\u0000\u0000\u00b5\u00b7\u0003\u000e\u0007"+
"\u0000\u00b6\u00b5\u0001\u0000\u0000\u0000\u00b6\u00b7\u0001\u0000\u0000"+
"\u0000\u00b7\u00c0\u0001\u0000\u0000\u0000\u00b8\u00bb\u0003\u000e\u0007"+
"\u0000\u00b9\u00ba\u0005\u001c\u0000\u0000\u00ba\u00bc\u0003\u000e\u0007"+
"\u0000\u00bb\u00b9\u0001\u0000\u0000\u0000\u00bc\u00bd\u0001\u0000\u0000"+
"\u0000\u00bd\u00bb\u0001\u0000\u0000\u0000\u00bd\u00be\u0001\u0000\u0000"+
"\u0000\u00be\u00c0\u0001\u0000\u0000\u0000\u00bf\u00b6\u0001\u0000\u0000"+
"\u0000\u00bf\u00b8\u0001\u0000\u0000\u0000\u00c0\u0019\u0001\u0000\u0000"+
"\u0000\u00c1\u00c5\u0005\u001e\u0000\u0000\u00c2\u00c5\u0003@ \u0000\u00c3"+
"\u00c5\u0005$\u0000\u0000\u00c4\u00c1\u0001\u0000\u0000\u0000\u00c4\u00c2"+
"\u0001\u0000\u0000\u0000\u00c4\u00c3\u0001\u0000\u0000\u0000\u00c5\u00c6"+
"\u0001\u0000\u0000\u0000\u00c6\u00c7\u0005\u0016\u0000\u0000\u00c7\u001b"+
"\u0001\u0000\u0000\u0000\u00c8\u00cd\u0005\u001e\u0000\u0000\u00c9\u00cd"+
"\u0003\u0014\n\u0000\u00ca\u00cd\u0003@ \u0000\u00cb\u00cd\u0005$\u0000"+
"\u0000\u00cc\u00c8\u0001\u0000\u0000\u0000\u00cc\u00c9\u0001\u0000\u0000"+
"\u0000\u00cc\u00ca\u0001\u0000\u0000\u0000\u00cc\u00cb\u0001\u0000\u0000"+
"\u0000\u00cd\u00ce\u0001\u0000\u0000\u0000\u00ce\u00cf\u0005\u0016\u0000"+
"\u0000\u00cf\u001d\u0001\u0000\u0000\u0000\u00d0\u00d1\u0005$\u0000\u0000"+
"\u00d1\u00d2\u0005\u0017\u0000\u0000\u00d2\u00d3\u0003\u0018\f\u0000\u00d3"+
"\u00d4\u0005\u0018\u0000\u0000\u00d4\u00d5\u0005\u0016\u0000\u0000\u00d5"+
"\u001f\u0001\u0000\u0000\u0000\u00d6\u00dc\u0003\"\u0011\u0000\u00d7\u00dc"+
"\u0003(\u0014\u0000\u00d8\u00dc\u0003D\"\u0000\u00d9\u00da\u0005\u0013"+
"\u0000\u0000\u00da\u00dc\u0003 \u0010\u0000\u00db\u00d6\u0001\u0000\u0000"+
"\u0000\u00db\u00d7\u0001\u0000\u0000\u0000\u00db\u00d8\u0001\u0000\u0000"+
"\u0000\u00db\u00d9\u0001\u0000\u0000\u0000\u00dc!\u0001\u0000\u0000\u0000"+
"\u00dd\u00de\u0006\u0011\uffff\uffff\u0000\u00de\u00df\u0003$\u0012\u0000"+
"\u00df\u00e5\u0001\u0000\u0000\u0000\u00e0\u00e1\n\u0002\u0000\u0000\u00e1"+
"\u00e2\u0005\u0004\u0000\u0000\u00e2\u00e4\u0003$\u0012\u0000\u00e3\u00e0"+
"\u0001\u0000\u0000\u0000\u00e4\u00e7\u0001\u0000\u0000\u0000\u00e5\u00e3"+
"\u0001\u0000\u0000\u0000\u00e5\u00e6\u0001\u0000\u0000\u0000\u00e6#\u0001"+
"\u0000\u0000\u0000\u00e7\u00e5\u0001\u0000\u0000\u0000\u00e8\u00e9\u0006"+
"\u0012\uffff\uffff\u0000\u00e9\u00ea\u0003&\u0013\u0000\u00ea\u00f0\u0001"+
"\u0000\u0000\u0000\u00eb\u00ec\n\u0002\u0000\u0000\u00ec\u00ed\u0005\u0003"+
"\u0000\u0000\u00ed\u00ef\u0003&\u0013\u0000\u00ee\u00eb\u0001\u0000\u0000"+
"\u0000\u00ef\u00f2\u0001\u0000\u0000\u0000\u00f0\u00ee\u0001\u0000\u0000"+
"\u0000\u00f0\u00f1\u0001\u0000\u0000\u0000\u00f1%\u0001\u0000\u0000\u0000"+
"\u00f2\u00f0\u0001\u0000\u0000\u0000\u00f3\u00fc\u0005)\u0000\u0000\u00f4"+
"\u00fc\u0005$\u0000\u0000\u00f5\u00fc\u0003\u0014\n\u0000\u00f6\u00fc"+
"\u0003\u0016\u000b\u0000\u00f7\u00f8\u0005\u0017\u0000\u0000\u00f8\u00f9"+
"\u0003\"\u0011\u0000\u00f9\u00fa\u0005\u0018\u0000\u0000\u00fa\u00fc\u0001"+
"\u0000\u0000\u0000\u00fb\u00f3\u0001\u0000\u0000\u0000\u00fb\u00f4\u0001"+
"\u0000\u0000\u0000\u00fb\u00f5\u0001\u0000\u0000\u0000\u00fb\u00f6\u0001"+
"\u0000\u0000\u0000\u00fb\u00f7\u0001\u0000\u0000\u0000\u00fc\'\u0001\u0000"+
"\u0000\u0000\u00fd\u00fe\u0003\u0010\b\u0000\u00fe\u00ff\u0003*\u0015"+
"\u0000\u00ff\u0100\u0003\u000e\u0007\u0000\u0100)\u0001\u0000\u0000\u0000"+
"\u0101\u0102\u0007\u0000\u0000\u0000\u0102+\u0001\u0000\u0000\u0000\u0103"+
"\u0107\u0003>\u001f\u0000\u0104\u0107\u0003@ \u0000\u0105\u0107\u0003"+
"\u0016\u000b\u0000\u0106\u0103\u0001\u0000\u0000\u0000\u0106\u0104\u0001"+
"\u0000\u0000\u0000\u0106\u0105\u0001\u0000\u0000\u0000\u0107-\u0001\u0000"+
"\u0000\u0000\u0108\u0109\u00030\u0018\u0000\u0109\u010a\u0005\u001b\u0000"+
"\u0000\u010a\u0115\u0001\u0000\u0000\u0000\u010b\u010c\u00032\u0019\u0000"+
"\u010c\u010d\u0005\u001b\u0000\u0000\u010d\u0115\u0001\u0000\u0000\u0000"+
"\u010e\u0115\u00034\u001a\u0000\u010f\u0115\u00036\u001b\u0000\u0110\u0115"+
"\u00038\u001c\u0000\u0111\u0112\u0003,\u0016\u0000\u0112\u0113\u0005\u001b"+
"\u0000\u0000\u0113\u0115\u0001\u0000\u0000\u0000\u0114\u0108\u0001\u0000"+
"\u0000\u0000\u0114\u010b\u0001\u0000\u0000\u0000\u0114\u010e\u0001\u0000"+
"\u0000\u0000\u0114\u010f\u0001\u0000\u0000\u0000\u0114\u0110\u0001\u0000"+
"\u0000\u0000\u0114\u0111\u0001\u0000\u0000\u0000\u0115/\u0001\u0000\u0000"+
"\u0000\u0116\u0118\u0005\"\u0000\u0000\u0117\u0119\u0003\u000e\u0007\u0000"+
"\u0118\u0117\u0001\u0000\u0000\u0000\u0118\u0119\u0001\u0000\u0000\u0000"+
"\u01191\u0001\u0000\u0000\u0000\u011a\u011b\u0003B!\u0000\u011b\u011e"+
"\u0005$\u0000\u0000\u011c\u011d\u0005\u0007\u0000\u0000\u011d\u011f\u0003"+
"\u000e\u0007\u0000\u011e\u011c\u0001\u0000\u0000\u0000\u011e\u011f\u0001"+
"\u0000\u0000\u0000\u011f3\u0001\u0000\u0000\u0000\u0120\u0124\u0005\u0019"+
"\u0000\u0000\u0121\u0123\u0003.\u0017\u0000\u0122\u0121\u0001\u0000\u0000"+
"\u0000\u0123\u0126\u0001\u0000\u0000\u0000\u0124\u0122\u0001\u0000\u0000"+
"\u0000\u0124\u0125\u0001\u0000\u0000\u0000\u0125\u0127\u0001\u0000\u0000"+
"\u0000\u0126\u0124\u0001\u0000\u0000\u0000\u0127\u0128\u0005\u001a\u0000"+
"\u0000\u01285\u0001\u0000\u0000\u0000\u0129\u012a\u0005\u001f\u0000\u0000"+
"\u012a\u012b\u0005\u0017\u0000\u0000\u012b\u012c\u0003\u000e\u0007\u0000"+
"\u012c\u012d\u0005\u0018\u0000\u0000\u012d\u012e\u0003.\u0017\u0000\u012e"+
"7\u0001\u0000\u0000\u0000\u012f\u0131\u0003:\u001d\u0000\u0130\u0132\u0003"+
"<\u001e\u0000\u0131\u0130\u0001\u0000\u0000\u0000\u0131\u0132\u0001\u0000"+
"\u0000\u0000\u01329\u0001\u0000\u0000\u0000\u0133\u0134\u0005 \u0000\u0000"+
"\u0134\u0135\u0005\u0017\u0000\u0000\u0135\u0136\u0003\u000e\u0007\u0000"+
"\u0136\u0137\u0005\u0018\u0000\u0000\u0137\u0138\u0003.\u0017\u0000\u0138"+
";\u0001\u0000\u0000\u0000\u0139\u013a\u0005!\u0000\u0000\u013a\u013b\u0003"+
".\u0017\u0000\u013b=\u0001\u0000\u0000\u0000\u013c\u013d\u0003\u0012\t"+
"\u0000\u013d\u013e\u0005\u0007\u0000\u0000\u013e\u013f\u0003\u000e\u0007"+
"\u0000\u013f?\u0001\u0000\u0000\u0000\u0140\u0141\u0005#\u0000\u0000\u0141"+
"\u0142\u0005$\u0000\u0000\u0142\u0143\u0005\u0017\u0000\u0000\u0143\u0144"+
"\u0003\u0018\f\u0000\u0144\u0145\u0005\u0018\u0000\u0000\u0145A\u0001"+
"\u0000\u0000\u0000\u0146\u0147\u0007\u0001\u0000\u0000\u0147C\u0001\u0000"+
"\u0000\u0000\u0148\u0149\u0007\u0002\u0000\u0000\u0149E\u0001\u0000\u0000"+
"\u0000\"ILTV[`ekotz\u0085\u008d\u0096\u009a\u009d\u00a2\u00a8\u00ad\u00b6"+
"\u00bd\u00bf\u00c4\u00cc\u00db\u00e5\u00f0\u00fb\u0106\u0114\u0118\u011e"+
"\u0124\u0131";
public static final ATN _ATN =
new ATNDeserializer().deserialize(_serializedATN.toCharArray());
static {
_decisionToDFA = new DFA[_ATN.getNumberOfDecisions()];
for (int i = 0; i < _ATN.getNumberOfDecisions(); i++) {
_decisionToDFA[i] = new DFA(_ATN.getDecisionState(i), i);
}
}
}