Please wait. This can take some minutes ...
Many resources are needed to download a project. Please understand that we have to compensate our server costs. Thank you in advance.
Project price only 1 $
You can buy this project and download/modify it how often you want.
src2cpg_3.4.0.87.source-code.RubyParser Maven / Gradle / Ivy
// Generated from /home/runner/work/joern/joern/joern-cli/frontends/rubysrc2cpg/src/main/antlr4/io/joern/rubysrc2cpg/parser/RubyParser.g4 by ANTLR 4.7.2
package io.joern.rubysrc2cpg.parser;
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"})
public class RubyParser extends Parser {
static { RuntimeMetaData.checkVersion("4.7.2", RuntimeMetaData.VERSION); }
protected static final DFA[] _decisionToDFA;
protected static final PredictionContextCache _sharedContextCache =
new PredictionContextCache();
public static final int
STRING_INTERPOLATION_END=1, REGULAR_EXPRESSION_INTERPOLATION_END=2, REGULAR_EXPRESSION_START=3,
QUOTED_NON_EXPANDED_STRING_LITERAL_END=4, QUOTED_NON_EXPANDED_STRING_ARRAY_LITERAL_END=5,
QUOTED_NON_EXPANDED_SYMBOL_ARRAY_LITERAL_END=6, QUOTED_EXPANDED_REGULAR_EXPRESSION_END=7,
QUOTED_EXPANDED_STRING_LITERAL_END=8, QUOTED_EXPANDED_EXTERNAL_COMMAND_LITERAL_END=9,
QUOTED_EXPANDED_STRING_ARRAY_LITERAL_END=10, QUOTED_EXPANDED_SYMBOL_ARRAY_LITERAL_END=11,
DELIMITED_STRING_INTERPOLATION_END=12, DELIMITED_ARRAY_ITEM_INTERPOLATION_END=13,
NON_EXPANDED_LITERAL_CHARACTER_SEQUENCE=14, EXPANDED_LITERAL_CHARACTER_SEQUENCE=15,
LBRACK=16, RBRACK=17, LPAREN=18, RPAREN=19, LCURLY=20, RCURLY=21, COLON=22,
COLON2=23, COMMA=24, SEMI=25, DOT=26, DOT2=27, DOT3=28, QMARK=29, EQGT=30,
MINUSGT=31, EMARK=32, EMARKEQ=33, EMARKTILDE=34, AMP=35, AMP2=36, AMPDOT=37,
BAR=38, BAR2=39, EQ=40, EQ2=41, EQ3=42, CARET=43, LTEQGT=44, EQTILDE=45,
GT=46, GTEQ=47, LT=48, LTEQ=49, LT2=50, GT2=51, PLUS=52, MINUS=53, STAR=54,
STAR2=55, SLASH=56, PERCENT=57, TILDE=58, PLUSAT=59, MINUSAT=60, ASSIGNMENT_OPERATOR=61,
SINGLE_QUOTED_STRING_LITERAL=62, DOUBLE_QUOTED_STRING_START=63, QUOTED_NON_EXPANDED_STRING_LITERAL_START=64,
QUOTED_EXPANDED_STRING_LITERAL_START=65, QUOTED_EXPANDED_REGULAR_EXPRESSION_START=66,
QUOTED_EXPANDED_EXTERNAL_COMMAND_LITERAL_START=67, QUOTED_NON_EXPANDED_STRING_ARRAY_LITERAL_START=68,
QUOTED_EXPANDED_STRING_ARRAY_LITERAL_START=69, HERE_DOC_IDENTIFIER=70,
HERE_DOC=71, QUOTED_NON_EXPANDED_SYMBOL_ARRAY_LITERAL_START=72, QUOTED_EXPANDED_SYMBOL_ARRAY_LITERAL_START=73,
END_OF_PROGRAM_MARKER=74, DECIMAL_INTEGER_LITERAL=75, BINARY_INTEGER_LITERAL=76,
OCTAL_INTEGER_LITERAL=77, HEXADECIMAL_INTEGER_LITERAL=78, FLOAT_LITERAL_WITHOUT_EXPONENT=79,
FLOAT_LITERAL_WITH_EXPONENT=80, NL=81, WS=82, SYMBOL_LITERAL=83, LOCAL_VARIABLE_IDENTIFIER=84,
LINE__=85, ENCODING__=86, FILE__=87, BEGIN_=88, END_=89, ALIAS=90, AND=91,
BEGIN=92, BREAK=93, CASE=94, CLASS=95, DEF=96, IS_DEFINED=97, DO=98, ELSE=99,
ELSIF=100, END=101, ENSURE=102, FOR=103, FALSE=104, IF=105, IN=106, MODULE=107,
NEXT=108, NIL=109, NOT=110, OR=111, REDO=112, RESCUE=113, RETRY=114, RETURN=115,
SELF=116, SUPER=117, THEN=118, TRUE=119, UNDEF=120, UNLESS=121, UNTIL=122,
WHEN=123, WHILE=124, YIELD=125, GLOBAL_VARIABLE_IDENTIFIER=126, INSTANCE_VARIABLE_IDENTIFIER=127,
CLASS_VARIABLE_IDENTIFIER=128, CONSTANT_IDENTIFIER=129, ASSIGNMENT_LIKE_METHOD_IDENTIFIER=130,
SINGLE_LINE_COMMENT=131, MULTI_LINE_COMMENT=132, UNRECOGNIZED=133, DOUBLE_QUOTED_STRING_END=134,
DOUBLE_QUOTED_STRING_CHARACTER_SEQUENCE=135, INTERPOLATED_CHARACTER_SEQUENCE=136,
STRING_INTERPOLATION_BEGIN=137, DELIMITED_STRING_INTERPOLATION_BEGIN=138,
EXPANDED_VARIABLE_CHARACTER_SEQUENCE=139, EXPANDED_LITERAL_CHARACTER=140,
NON_EXPANDED_LITERAL_CHARACTER=141, DELIMITED_ARRAY_ITEM_INTERPOLATION_BEGIN=142,
EXPANDED_ARRAY_ITEM_SEPARATOR=143, EXPANDED_ARRAY_ITEM_CHARACTER=144,
NON_EXPANDED_ARRAY_ITEM_SEPARATOR=145, NON_EXPANDED_ARRAY_ITEM_CHARACTER=146,
REGULAR_EXPRESSION_END=147, REGULAR_EXPRESSION_BODY=148, REGULAR_EXPRESSION_INTERPOLATION_BEGIN=149,
DATA_SECTION_CONTENT=150;
public static final int
RULE_program = 0, RULE_compoundStatement = 1, RULE_statements = 2, RULE_statement = 3,
RULE_definedMethodNameOrSymbol = 4, RULE_singleAssignmentStatement = 5,
RULE_multipleAssignmentStatement = 6, RULE_leftHandSide = 7, RULE_multipleLeftHandSide = 8,
RULE_multipleLeftHandSideExceptPacking = 9, RULE_packingLeftHandSide = 10,
RULE_groupedLeftHandSide = 11, RULE_multipleLeftHandSideItem = 12, RULE_multipleRightHandSide = 13,
RULE_splattingRightHandSide = 14, RULE_methodIdentifier = 15, RULE_methodName = 16,
RULE_methodOnlyIdentifier = 17, RULE_methodInvocationWithoutParentheses = 18,
RULE_command = 19, RULE_commandArgument = 20, RULE_chainedCommandWithDoBlock = 21,
RULE_chainedMethodInvocation = 22, RULE_commandWithDoBlock = 23, RULE_bracketedArrayElementList = 24,
RULE_bracketedArrayElement = 25, RULE_indexingArgumentList = 26, RULE_indexingArgument = 27,
RULE_splattingArgument = 28, RULE_operatorExpressionList = 29, RULE_operatorExpressionList2 = 30,
RULE_argumentWithParentheses = 31, RULE_argumentList = 32, RULE_argumentListItem = 33,
RULE_splatArgList = 34, RULE_commandArgumentList = 35, RULE_primaryValueList = 36,
RULE_primaryValueListWithAssociation = 37, RULE_blockArgument = 38, RULE_expressionOrCommand = 39,
RULE_operatorExpression = 40, RULE_primary = 41, RULE_hashLiteral = 42,
RULE_primaryValue = 43, RULE_lambdaExpressionParameterList = 44, RULE_methodCallsWithParentheses = 45,
RULE_commandOrPrimaryValueClass = 46, RULE_commandOrPrimaryValue = 47,
RULE_block = 48, RULE_doBlock = 49, RULE_blockParameter = 50, RULE_blockParameterList = 51,
RULE_mandatoryOrOptionalOrGroupedParameterList = 52, RULE_mandatoryOrOptionalOrGroupedParameter = 53,
RULE_mandatoryOrGroupedParameterList = 54, RULE_mandatoryOrGroupedParameter = 55,
RULE_groupedParameterList = 56, RULE_thenClause = 57, RULE_elseClause = 58,
RULE_elsifClause = 59, RULE_whenClause = 60, RULE_whenArgument = 61, RULE_doClause = 62,
RULE_forVariable = 63, RULE_bodyStatement = 64, RULE_rescueClause = 65,
RULE_exceptionClassList = 66, RULE_exceptionVariableAssignment = 67, RULE_ensureClause = 68,
RULE_definedMethodName = 69, RULE_methodParameterPart = 70, RULE_parameterList = 71,
RULE_mandatoryOrOptionalParameterList = 72, RULE_mandatoryParameterList = 73,
RULE_mandatoryOrOptionalParameter = 74, RULE_mandatoryParameter = 75,
RULE_optionalParameter = 76, RULE_optionalParameterName = 77, RULE_arrayParameter = 78,
RULE_hashParameter = 79, RULE_procParameter = 80, RULE_procParameterName = 81,
RULE_classPath = 82, RULE_singletonObject = 83, RULE_variableReference = 84,
RULE_associationList = 85, RULE_association = 86, RULE_associationKey = 87,
RULE_associationHashArgument = 88, RULE_regexpLiteralContent = 89, RULE_singleQuotedString = 90,
RULE_singleOrDoubleQuotedString = 91, RULE_doubleQuotedString = 92, RULE_quotedExpandedExternalCommandString = 93,
RULE_doubleQuotedStringContent = 94, RULE_quotedNonExpandedLiteralString = 95,
RULE_quotedExpandedLiteralString = 96, RULE_quotedExpandedLiteralStringContent = 97,
RULE_quotedNonExpandedArrayElementContent = 98, RULE_quotedExpandedArrayElementContent = 99,
RULE_quotedExpandedArrayElement = 100, RULE_quotedNonExpandedArrayElementList = 101,
RULE_quotedExpandedArrayElementList = 102, RULE_symbol = 103, RULE_hereDoc = 104,
RULE_isDefinedKeyword = 105, RULE_assignmentOperator = 106, RULE_statementModifier = 107,
RULE_variable = 108, RULE_pseudoVariable = 109, RULE_unsignedNumericLiteral = 110,
RULE_unaryOperator = 111, RULE_multiplicativeOperator = 112, RULE_additiveOperator = 113,
RULE_bitwiseShiftOperator = 114, RULE_bitwiseOrOperator = 115, RULE_relationalOperator = 116,
RULE_equalityOperator = 117, RULE_rangeOperator = 118, RULE_keyword = 119;
private static String[] makeRuleNames() {
return new String[] {
"program", "compoundStatement", "statements", "statement", "definedMethodNameOrSymbol",
"singleAssignmentStatement", "multipleAssignmentStatement", "leftHandSide",
"multipleLeftHandSide", "multipleLeftHandSideExceptPacking", "packingLeftHandSide",
"groupedLeftHandSide", "multipleLeftHandSideItem", "multipleRightHandSide",
"splattingRightHandSide", "methodIdentifier", "methodName", "methodOnlyIdentifier",
"methodInvocationWithoutParentheses", "command", "commandArgument", "chainedCommandWithDoBlock",
"chainedMethodInvocation", "commandWithDoBlock", "bracketedArrayElementList",
"bracketedArrayElement", "indexingArgumentList", "indexingArgument",
"splattingArgument", "operatorExpressionList", "operatorExpressionList2",
"argumentWithParentheses", "argumentList", "argumentListItem", "splatArgList",
"commandArgumentList", "primaryValueList", "primaryValueListWithAssociation",
"blockArgument", "expressionOrCommand", "operatorExpression", "primary",
"hashLiteral", "primaryValue", "lambdaExpressionParameterList", "methodCallsWithParentheses",
"commandOrPrimaryValueClass", "commandOrPrimaryValue", "block", "doBlock",
"blockParameter", "blockParameterList", "mandatoryOrOptionalOrGroupedParameterList",
"mandatoryOrOptionalOrGroupedParameter", "mandatoryOrGroupedParameterList",
"mandatoryOrGroupedParameter", "groupedParameterList", "thenClause",
"elseClause", "elsifClause", "whenClause", "whenArgument", "doClause",
"forVariable", "bodyStatement", "rescueClause", "exceptionClassList",
"exceptionVariableAssignment", "ensureClause", "definedMethodName", "methodParameterPart",
"parameterList", "mandatoryOrOptionalParameterList", "mandatoryParameterList",
"mandatoryOrOptionalParameter", "mandatoryParameter", "optionalParameter",
"optionalParameterName", "arrayParameter", "hashParameter", "procParameter",
"procParameterName", "classPath", "singletonObject", "variableReference",
"associationList", "association", "associationKey", "associationHashArgument",
"regexpLiteralContent", "singleQuotedString", "singleOrDoubleQuotedString",
"doubleQuotedString", "quotedExpandedExternalCommandString", "doubleQuotedStringContent",
"quotedNonExpandedLiteralString", "quotedExpandedLiteralString", "quotedExpandedLiteralStringContent",
"quotedNonExpandedArrayElementContent", "quotedExpandedArrayElementContent",
"quotedExpandedArrayElement", "quotedNonExpandedArrayElementList", "quotedExpandedArrayElementList",
"symbol", "hereDoc", "isDefinedKeyword", "assignmentOperator", "statementModifier",
"variable", "pseudoVariable", "unsignedNumericLiteral", "unaryOperator",
"multiplicativeOperator", "additiveOperator", "bitwiseShiftOperator",
"bitwiseOrOperator", "relationalOperator", "equalityOperator", "rangeOperator",
"keyword"
};
}
public static final String[] ruleNames = makeRuleNames();
private static String[] makeLiteralNames() {
return new String[] {
null, null, null, null, null, null, null, null, null, null, null, null,
null, null, null, null, "'['", "']'", "'('", "')'", "'{'", "'}'", "':'",
"'::'", "','", "';'", "'.'", "'..'", "'...'", "'?'", "'=>'", "'->'",
"'!'", "'!='", "'!~'", "'&'", "'&&'", "'&.'", "'|'", "'||'", "'='", "'=='",
"'==='", "'^'", "'<=>'", "'=~'", "'>'", "'>='", "'<'", "'<='", "'<<'",
"'>>'", "'+'", "'-'", "'*'", "'**'", "'/'", "'%'", "'~'", "'+@'", "'-@'",
null, null, null, null, null, null, null, null, null, null, null, null,
null, null, null, null, null, null, null, null, null, null, null, null,
"'__LINE__'", "'__ENCODING__'", "'__FILE__'", "'BEGIN'", "'END'", "'alias'",
"'and'", "'begin'", "'break'", "'case'", "'class'", "'def'", "'defined?'",
"'do'", "'else'", "'elsif'", "'end'", "'ensure'", "'for'", "'false'",
"'if'", "'in'", "'module'", "'next'", "'nil'", "'not'", "'or'", "'redo'",
"'rescue'", "'retry'", "'return'", "'self'", "'super'", "'then'", "'true'",
"'undef'", "'unless'", "'until'", "'when'", "'while'", "'yield'"
};
}
private static final String[] _LITERAL_NAMES = makeLiteralNames();
private static String[] makeSymbolicNames() {
return new String[] {
null, "STRING_INTERPOLATION_END", "REGULAR_EXPRESSION_INTERPOLATION_END",
"REGULAR_EXPRESSION_START", "QUOTED_NON_EXPANDED_STRING_LITERAL_END",
"QUOTED_NON_EXPANDED_STRING_ARRAY_LITERAL_END", "QUOTED_NON_EXPANDED_SYMBOL_ARRAY_LITERAL_END",
"QUOTED_EXPANDED_REGULAR_EXPRESSION_END", "QUOTED_EXPANDED_STRING_LITERAL_END",
"QUOTED_EXPANDED_EXTERNAL_COMMAND_LITERAL_END", "QUOTED_EXPANDED_STRING_ARRAY_LITERAL_END",
"QUOTED_EXPANDED_SYMBOL_ARRAY_LITERAL_END", "DELIMITED_STRING_INTERPOLATION_END",
"DELIMITED_ARRAY_ITEM_INTERPOLATION_END", "NON_EXPANDED_LITERAL_CHARACTER_SEQUENCE",
"EXPANDED_LITERAL_CHARACTER_SEQUENCE", "LBRACK", "RBRACK", "LPAREN",
"RPAREN", "LCURLY", "RCURLY", "COLON", "COLON2", "COMMA", "SEMI", "DOT",
"DOT2", "DOT3", "QMARK", "EQGT", "MINUSGT", "EMARK", "EMARKEQ", "EMARKTILDE",
"AMP", "AMP2", "AMPDOT", "BAR", "BAR2", "EQ", "EQ2", "EQ3", "CARET",
"LTEQGT", "EQTILDE", "GT", "GTEQ", "LT", "LTEQ", "LT2", "GT2", "PLUS",
"MINUS", "STAR", "STAR2", "SLASH", "PERCENT", "TILDE", "PLUSAT", "MINUSAT",
"ASSIGNMENT_OPERATOR", "SINGLE_QUOTED_STRING_LITERAL", "DOUBLE_QUOTED_STRING_START",
"QUOTED_NON_EXPANDED_STRING_LITERAL_START", "QUOTED_EXPANDED_STRING_LITERAL_START",
"QUOTED_EXPANDED_REGULAR_EXPRESSION_START", "QUOTED_EXPANDED_EXTERNAL_COMMAND_LITERAL_START",
"QUOTED_NON_EXPANDED_STRING_ARRAY_LITERAL_START", "QUOTED_EXPANDED_STRING_ARRAY_LITERAL_START",
"HERE_DOC_IDENTIFIER", "HERE_DOC", "QUOTED_NON_EXPANDED_SYMBOL_ARRAY_LITERAL_START",
"QUOTED_EXPANDED_SYMBOL_ARRAY_LITERAL_START", "END_OF_PROGRAM_MARKER",
"DECIMAL_INTEGER_LITERAL", "BINARY_INTEGER_LITERAL", "OCTAL_INTEGER_LITERAL",
"HEXADECIMAL_INTEGER_LITERAL", "FLOAT_LITERAL_WITHOUT_EXPONENT", "FLOAT_LITERAL_WITH_EXPONENT",
"NL", "WS", "SYMBOL_LITERAL", "LOCAL_VARIABLE_IDENTIFIER", "LINE__",
"ENCODING__", "FILE__", "BEGIN_", "END_", "ALIAS", "AND", "BEGIN", "BREAK",
"CASE", "CLASS", "DEF", "IS_DEFINED", "DO", "ELSE", "ELSIF", "END", "ENSURE",
"FOR", "FALSE", "IF", "IN", "MODULE", "NEXT", "NIL", "NOT", "OR", "REDO",
"RESCUE", "RETRY", "RETURN", "SELF", "SUPER", "THEN", "TRUE", "UNDEF",
"UNLESS", "UNTIL", "WHEN", "WHILE", "YIELD", "GLOBAL_VARIABLE_IDENTIFIER",
"INSTANCE_VARIABLE_IDENTIFIER", "CLASS_VARIABLE_IDENTIFIER", "CONSTANT_IDENTIFIER",
"ASSIGNMENT_LIKE_METHOD_IDENTIFIER", "SINGLE_LINE_COMMENT", "MULTI_LINE_COMMENT",
"UNRECOGNIZED", "DOUBLE_QUOTED_STRING_END", "DOUBLE_QUOTED_STRING_CHARACTER_SEQUENCE",
"INTERPOLATED_CHARACTER_SEQUENCE", "STRING_INTERPOLATION_BEGIN", "DELIMITED_STRING_INTERPOLATION_BEGIN",
"EXPANDED_VARIABLE_CHARACTER_SEQUENCE", "EXPANDED_LITERAL_CHARACTER",
"NON_EXPANDED_LITERAL_CHARACTER", "DELIMITED_ARRAY_ITEM_INTERPOLATION_BEGIN",
"EXPANDED_ARRAY_ITEM_SEPARATOR", "EXPANDED_ARRAY_ITEM_CHARACTER", "NON_EXPANDED_ARRAY_ITEM_SEPARATOR",
"NON_EXPANDED_ARRAY_ITEM_CHARACTER", "REGULAR_EXPRESSION_END", "REGULAR_EXPRESSION_BODY",
"REGULAR_EXPRESSION_INTERPOLATION_BEGIN", "DATA_SECTION_CONTENT"
};
}
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] = "";
}
}
}
@Override
@Deprecated
public String[] getTokenNames() {
return tokenNames;
}
@Override
public Vocabulary getVocabulary() {
return VOCABULARY;
}
@Override
public String getGrammarFileName() { return "RubyParser.g4"; }
@Override
public String[] getRuleNames() { return ruleNames; }
@Override
public String getSerializedATN() { return _serializedATN; }
@Override
public ATN getATN() { return _ATN; }
public RubyParser(TokenStream input) {
super(input);
_interp = new ParserATNSimulator(this,_ATN,_decisionToDFA,_sharedContextCache);
}
public static class ProgramContext extends ParserRuleContext {
public CompoundStatementContext compoundStatement() {
return getRuleContext(CompoundStatementContext.class,0);
}
public TerminalNode EOF() { return getToken(RubyParser.EOF, 0); }
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 RubyParserListener ) ((RubyParserListener)listener).enterProgram(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).exitProgram(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof RubyParserVisitor ) return ((RubyParserVisitor 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);
try {
enterOuterAlt(_localctx, 1);
{
setState(240);
compoundStatement();
setState(241);
match(EOF);
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class CompoundStatementContext extends ParserRuleContext {
public StatementsContext statements() {
return getRuleContext(StatementsContext.class,0);
}
public List SEMI() { return getTokens(RubyParser.SEMI); }
public TerminalNode SEMI(int i) {
return getToken(RubyParser.SEMI, i);
}
public List NL() { return getTokens(RubyParser.NL); }
public TerminalNode NL(int i) {
return getToken(RubyParser.NL, i);
}
public CompoundStatementContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_compoundStatement; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).enterCompoundStatement(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).exitCompoundStatement(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof RubyParserVisitor ) return ((RubyParserVisitor extends T>)visitor).visitCompoundStatement(this);
else return visitor.visitChildren(this);
}
}
public final CompoundStatementContext compoundStatement() throws RecognitionException {
CompoundStatementContext _localctx = new CompoundStatementContext(_ctx, getState());
enterRule(_localctx, 2, RULE_compoundStatement);
int _la;
try {
enterOuterAlt(_localctx, 1);
{
setState(244);
_errHandler.sync(this);
switch ( getInterpreter().adaptivePredict(_input,0,_ctx) ) {
case 1:
{
setState(243);
statements();
}
break;
}
setState(249);
_errHandler.sync(this);
_la = _input.LA(1);
while (_la==SEMI || _la==NL) {
{
{
setState(246);
_la = _input.LA(1);
if ( !(_la==SEMI || _la==NL) ) {
_errHandler.recoverInline(this);
}
else {
if ( _input.LA(1)==Token.EOF ) matchedEOF = true;
_errHandler.reportMatch(this);
consume();
}
}
}
setState(251);
_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;
}
public static class StatementsContext extends ParserRuleContext {
public List statement() {
return getRuleContexts(StatementContext.class);
}
public StatementContext statement(int i) {
return getRuleContext(StatementContext.class,i);
}
public List SEMI() { return getTokens(RubyParser.SEMI); }
public TerminalNode SEMI(int i) {
return getToken(RubyParser.SEMI, i);
}
public List NL() { return getTokens(RubyParser.NL); }
public TerminalNode NL(int i) {
return getToken(RubyParser.NL, i);
}
public StatementsContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_statements; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).enterStatements(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).exitStatements(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof RubyParserVisitor ) return ((RubyParserVisitor extends T>)visitor).visitStatements(this);
else return visitor.visitChildren(this);
}
}
public final StatementsContext statements() throws RecognitionException {
StatementsContext _localctx = new StatementsContext(_ctx, getState());
enterRule(_localctx, 4, RULE_statements);
int _la;
try {
int _alt;
enterOuterAlt(_localctx, 1);
{
setState(255);
_errHandler.sync(this);
_la = _input.LA(1);
while (_la==SEMI || _la==NL) {
{
{
setState(252);
_la = _input.LA(1);
if ( !(_la==SEMI || _la==NL) ) {
_errHandler.recoverInline(this);
}
else {
if ( _input.LA(1)==Token.EOF ) matchedEOF = true;
_errHandler.reportMatch(this);
consume();
}
}
}
setState(257);
_errHandler.sync(this);
_la = _input.LA(1);
}
setState(258);
statement(0);
setState(267);
_errHandler.sync(this);
_alt = getInterpreter().adaptivePredict(_input,4,_ctx);
while ( _alt!=2 && _alt!=org.antlr.v4.runtime.atn.ATN.INVALID_ALT_NUMBER ) {
if ( _alt==1 ) {
{
{
setState(260);
_errHandler.sync(this);
_la = _input.LA(1);
do {
{
{
setState(259);
_la = _input.LA(1);
if ( !(_la==SEMI || _la==NL) ) {
_errHandler.recoverInline(this);
}
else {
if ( _input.LA(1)==Token.EOF ) matchedEOF = true;
_errHandler.reportMatch(this);
consume();
}
}
}
setState(262);
_errHandler.sync(this);
_la = _input.LA(1);
} while ( _la==SEMI || _la==NL );
setState(264);
statement(0);
}
}
}
setState(269);
_errHandler.sync(this);
_alt = getInterpreter().adaptivePredict(_input,4,_ctx);
}
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class StatementContext extends ParserRuleContext {
public StatementContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_statement; }
public StatementContext() { }
public void copyFrom(StatementContext ctx) {
super.copyFrom(ctx);
}
}
public static class SingleAssignmentStatementStatementContext extends StatementContext {
public SingleAssignmentStatementContext singleAssignmentStatement() {
return getRuleContext(SingleAssignmentStatementContext.class,0);
}
public SingleAssignmentStatementStatementContext(StatementContext ctx) { copyFrom(ctx); }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).enterSingleAssignmentStatementStatement(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).exitSingleAssignmentStatementStatement(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof RubyParserVisitor ) return ((RubyParserVisitor extends T>)visitor).visitSingleAssignmentStatementStatement(this);
else return visitor.visitChildren(this);
}
}
public static class ModifierStatementContext extends StatementContext {
public StatementContext statement() {
return getRuleContext(StatementContext.class,0);
}
public StatementModifierContext statementModifier() {
return getRuleContext(StatementModifierContext.class,0);
}
public ExpressionOrCommandContext expressionOrCommand() {
return getRuleContext(ExpressionOrCommandContext.class,0);
}
public List NL() { return getTokens(RubyParser.NL); }
public TerminalNode NL(int i) {
return getToken(RubyParser.NL, i);
}
public ModifierStatementContext(StatementContext ctx) { copyFrom(ctx); }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).enterModifierStatement(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).exitModifierStatement(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof RubyParserVisitor ) return ((RubyParserVisitor extends T>)visitor).visitModifierStatement(this);
else return visitor.visitChildren(this);
}
}
public static class AliasStatementContext extends StatementContext {
public DefinedMethodNameOrSymbolContext oldName;
public DefinedMethodNameOrSymbolContext newName;
public TerminalNode ALIAS() { return getToken(RubyParser.ALIAS, 0); }
public List definedMethodNameOrSymbol() {
return getRuleContexts(DefinedMethodNameOrSymbolContext.class);
}
public DefinedMethodNameOrSymbolContext definedMethodNameOrSymbol(int i) {
return getRuleContext(DefinedMethodNameOrSymbolContext.class,i);
}
public List NL() { return getTokens(RubyParser.NL); }
public TerminalNode NL(int i) {
return getToken(RubyParser.NL, i);
}
public AliasStatementContext(StatementContext ctx) { copyFrom(ctx); }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).enterAliasStatement(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).exitAliasStatement(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof RubyParserVisitor ) return ((RubyParserVisitor extends T>)visitor).visitAliasStatement(this);
else return visitor.visitChildren(this);
}
}
public static class UndefStatementContext extends StatementContext {
public TerminalNode UNDEF() { return getToken(RubyParser.UNDEF, 0); }
public List definedMethodNameOrSymbol() {
return getRuleContexts(DefinedMethodNameOrSymbolContext.class);
}
public DefinedMethodNameOrSymbolContext definedMethodNameOrSymbol(int i) {
return getRuleContext(DefinedMethodNameOrSymbolContext.class,i);
}
public List NL() { return getTokens(RubyParser.NL); }
public TerminalNode NL(int i) {
return getToken(RubyParser.NL, i);
}
public List COMMA() { return getTokens(RubyParser.COMMA); }
public TerminalNode COMMA(int i) {
return getToken(RubyParser.COMMA, i);
}
public UndefStatementContext(StatementContext ctx) { copyFrom(ctx); }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).enterUndefStatement(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).exitUndefStatement(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof RubyParserVisitor ) return ((RubyParserVisitor extends T>)visitor).visitUndefStatement(this);
else return visitor.visitChildren(this);
}
}
public static class ExpressionOrCommandStatementContext extends StatementContext {
public ExpressionOrCommandContext expressionOrCommand() {
return getRuleContext(ExpressionOrCommandContext.class,0);
}
public ExpressionOrCommandStatementContext(StatementContext ctx) { copyFrom(ctx); }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).enterExpressionOrCommandStatement(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).exitExpressionOrCommandStatement(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof RubyParserVisitor ) return ((RubyParserVisitor extends T>)visitor).visitExpressionOrCommandStatement(this);
else return visitor.visitChildren(this);
}
}
public static class MultipleAssignmentStatementStatementContext extends StatementContext {
public MultipleAssignmentStatementContext multipleAssignmentStatement() {
return getRuleContext(MultipleAssignmentStatementContext.class,0);
}
public MultipleAssignmentStatementStatementContext(StatementContext ctx) { copyFrom(ctx); }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).enterMultipleAssignmentStatementStatement(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).exitMultipleAssignmentStatementStatement(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof RubyParserVisitor ) return ((RubyParserVisitor extends T>)visitor).visitMultipleAssignmentStatementStatement(this);
else return visitor.visitChildren(this);
}
}
public final StatementContext statement() throws RecognitionException {
return statement(0);
}
private StatementContext statement(int _p) throws RecognitionException {
ParserRuleContext _parentctx = _ctx;
int _parentState = getState();
StatementContext _localctx = new StatementContext(_ctx, _parentState);
StatementContext _prevctx = _localctx;
int _startState = 6;
enterRecursionRule(_localctx, 6, RULE_statement, _p);
int _la;
try {
int _alt;
enterOuterAlt(_localctx, 1);
{
setState(305);
_errHandler.sync(this);
switch ( getInterpreter().adaptivePredict(_input,9,_ctx) ) {
case 1:
{
_localctx = new ExpressionOrCommandStatementContext(_localctx);
_ctx = _localctx;
_prevctx = _localctx;
setState(271);
expressionOrCommand(0);
}
break;
case 2:
{
_localctx = new AliasStatementContext(_localctx);
_ctx = _localctx;
_prevctx = _localctx;
setState(272);
match(ALIAS);
setState(276);
_errHandler.sync(this);
_la = _input.LA(1);
while (_la==NL) {
{
{
setState(273);
match(NL);
}
}
setState(278);
_errHandler.sync(this);
_la = _input.LA(1);
}
setState(279);
((AliasStatementContext)_localctx).oldName = definedMethodNameOrSymbol();
setState(280);
((AliasStatementContext)_localctx).newName = definedMethodNameOrSymbol();
}
break;
case 3:
{
_localctx = new UndefStatementContext(_localctx);
_ctx = _localctx;
_prevctx = _localctx;
setState(282);
match(UNDEF);
setState(286);
_errHandler.sync(this);
_la = _input.LA(1);
while (_la==NL) {
{
{
setState(283);
match(NL);
}
}
setState(288);
_errHandler.sync(this);
_la = _input.LA(1);
}
setState(289);
definedMethodNameOrSymbol();
setState(300);
_errHandler.sync(this);
_alt = getInterpreter().adaptivePredict(_input,8,_ctx);
while ( _alt!=2 && _alt!=org.antlr.v4.runtime.atn.ATN.INVALID_ALT_NUMBER ) {
if ( _alt==1 ) {
{
{
setState(290);
match(COMMA);
setState(294);
_errHandler.sync(this);
_la = _input.LA(1);
while (_la==NL) {
{
{
setState(291);
match(NL);
}
}
setState(296);
_errHandler.sync(this);
_la = _input.LA(1);
}
setState(297);
definedMethodNameOrSymbol();
}
}
}
setState(302);
_errHandler.sync(this);
_alt = getInterpreter().adaptivePredict(_input,8,_ctx);
}
}
break;
case 4:
{
_localctx = new SingleAssignmentStatementStatementContext(_localctx);
_ctx = _localctx;
_prevctx = _localctx;
setState(303);
singleAssignmentStatement();
}
break;
case 5:
{
_localctx = new MultipleAssignmentStatementStatementContext(_localctx);
_ctx = _localctx;
_prevctx = _localctx;
setState(304);
multipleAssignmentStatement();
}
break;
}
_ctx.stop = _input.LT(-1);
setState(319);
_errHandler.sync(this);
_alt = getInterpreter().adaptivePredict(_input,11,_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 ModifierStatementContext(new StatementContext(_parentctx, _parentState));
pushNewRecursionContext(_localctx, _startState, RULE_statement);
setState(307);
if (!(precpred(_ctx, 3))) throw new FailedPredicateException(this, "precpred(_ctx, 3)");
setState(308);
statementModifier();
setState(312);
_errHandler.sync(this);
_la = _input.LA(1);
while (_la==NL) {
{
{
setState(309);
match(NL);
}
}
setState(314);
_errHandler.sync(this);
_la = _input.LA(1);
}
setState(315);
expressionOrCommand(0);
}
}
}
setState(321);
_errHandler.sync(this);
_alt = getInterpreter().adaptivePredict(_input,11,_ctx);
}
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
unrollRecursionContexts(_parentctx);
}
return _localctx;
}
public static class DefinedMethodNameOrSymbolContext extends ParserRuleContext {
public DefinedMethodNameContext definedMethodName() {
return getRuleContext(DefinedMethodNameContext.class,0);
}
public SymbolContext symbol() {
return getRuleContext(SymbolContext.class,0);
}
public DefinedMethodNameOrSymbolContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_definedMethodNameOrSymbol; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).enterDefinedMethodNameOrSymbol(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).exitDefinedMethodNameOrSymbol(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof RubyParserVisitor ) return ((RubyParserVisitor extends T>)visitor).visitDefinedMethodNameOrSymbol(this);
else return visitor.visitChildren(this);
}
}
public final DefinedMethodNameOrSymbolContext definedMethodNameOrSymbol() throws RecognitionException {
DefinedMethodNameOrSymbolContext _localctx = new DefinedMethodNameOrSymbolContext(_ctx, getState());
enterRule(_localctx, 8, RULE_definedMethodNameOrSymbol);
try {
setState(324);
_errHandler.sync(this);
switch (_input.LA(1)) {
case LBRACK:
case EQ2:
case EQ3:
case LTEQGT:
case LT2:
case LOCAL_VARIABLE_IDENTIFIER:
case LINE__:
case ENCODING__:
case FILE__:
case BEGIN_:
case END_:
case ALIAS:
case AND:
case BEGIN:
case BREAK:
case CASE:
case CLASS:
case DEF:
case IS_DEFINED:
case DO:
case ELSE:
case ELSIF:
case END:
case ENSURE:
case FOR:
case FALSE:
case IF:
case IN:
case MODULE:
case NEXT:
case NIL:
case NOT:
case OR:
case REDO:
case RESCUE:
case RETRY:
case RETURN:
case SELF:
case SUPER:
case THEN:
case TRUE:
case UNDEF:
case UNLESS:
case UNTIL:
case WHEN:
case WHILE:
case YIELD:
case CONSTANT_IDENTIFIER:
case ASSIGNMENT_LIKE_METHOD_IDENTIFIER:
enterOuterAlt(_localctx, 1);
{
setState(322);
definedMethodName();
}
break;
case COLON:
case SYMBOL_LITERAL:
enterOuterAlt(_localctx, 2);
{
setState(323);
symbol();
}
break;
default:
throw new NoViableAltException(this);
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class SingleAssignmentStatementContext extends ParserRuleContext {
public VariableContext variable() {
return getRuleContext(VariableContext.class,0);
}
public AssignmentOperatorContext assignmentOperator() {
return getRuleContext(AssignmentOperatorContext.class,0);
}
public MethodInvocationWithoutParenthesesContext methodInvocationWithoutParentheses() {
return getRuleContext(MethodInvocationWithoutParenthesesContext.class,0);
}
public List NL() { return getTokens(RubyParser.NL); }
public TerminalNode NL(int i) {
return getToken(RubyParser.NL, i);
}
public TerminalNode COLON2() { return getToken(RubyParser.COLON2, 0); }
public TerminalNode CONSTANT_IDENTIFIER() { return getToken(RubyParser.CONSTANT_IDENTIFIER, 0); }
public PrimaryContext primary() {
return getRuleContext(PrimaryContext.class,0);
}
public TerminalNode LBRACK() { return getToken(RubyParser.LBRACK, 0); }
public TerminalNode RBRACK() { return getToken(RubyParser.RBRACK, 0); }
public IndexingArgumentListContext indexingArgumentList() {
return getRuleContext(IndexingArgumentListContext.class,0);
}
public MethodNameContext methodName() {
return getRuleContext(MethodNameContext.class,0);
}
public TerminalNode DOT() { return getToken(RubyParser.DOT, 0); }
public SingleAssignmentStatementContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_singleAssignmentStatement; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).enterSingleAssignmentStatement(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).exitSingleAssignmentStatement(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof RubyParserVisitor ) return ((RubyParserVisitor extends T>)visitor).visitSingleAssignmentStatement(this);
else return visitor.visitChildren(this);
}
}
public final SingleAssignmentStatementContext singleAssignmentStatement() throws RecognitionException {
SingleAssignmentStatementContext _localctx = new SingleAssignmentStatementContext(_ctx, getState());
enterRule(_localctx, 10, RULE_singleAssignmentStatement);
int _la;
try {
setState(374);
_errHandler.sync(this);
switch ( getInterpreter().adaptivePredict(_input,18,_ctx) ) {
case 1:
enterOuterAlt(_localctx, 1);
{
setState(326);
variable();
setState(327);
assignmentOperator();
setState(331);
_errHandler.sync(this);
_la = _input.LA(1);
while (_la==NL) {
{
{
setState(328);
match(NL);
}
}
setState(333);
_errHandler.sync(this);
_la = _input.LA(1);
}
setState(334);
methodInvocationWithoutParentheses();
}
break;
case 2:
enterOuterAlt(_localctx, 2);
{
setState(336);
match(COLON2);
setState(337);
match(CONSTANT_IDENTIFIER);
setState(338);
assignmentOperator();
setState(342);
_errHandler.sync(this);
_la = _input.LA(1);
while (_la==NL) {
{
{
setState(339);
match(NL);
}
}
setState(344);
_errHandler.sync(this);
_la = _input.LA(1);
}
setState(345);
methodInvocationWithoutParentheses();
}
break;
case 3:
enterOuterAlt(_localctx, 3);
{
setState(347);
primary();
setState(348);
match(LBRACK);
setState(350);
_errHandler.sync(this);
_la = _input.LA(1);
if (((((_la - 3)) & ~0x3f) == 0 && ((1L << (_la - 3)) & ((1L << (REGULAR_EXPRESSION_START - 3)) | (1L << (LBRACK - 3)) | (1L << (LPAREN - 3)) | (1L << (LCURLY - 3)) | (1L << (COLON - 3)) | (1L << (COLON2 - 3)) | (1L << (DOT2 - 3)) | (1L << (DOT3 - 3)) | (1L << (MINUSGT - 3)) | (1L << (EMARK - 3)) | (1L << (PLUS - 3)) | (1L << (MINUS - 3)) | (1L << (STAR - 3)) | (1L << (STAR2 - 3)) | (1L << (TILDE - 3)) | (1L << (SINGLE_QUOTED_STRING_LITERAL - 3)) | (1L << (DOUBLE_QUOTED_STRING_START - 3)) | (1L << (QUOTED_NON_EXPANDED_STRING_LITERAL_START - 3)) | (1L << (QUOTED_EXPANDED_STRING_LITERAL_START - 3)) | (1L << (QUOTED_EXPANDED_REGULAR_EXPRESSION_START - 3)))) != 0) || ((((_la - 67)) & ~0x3f) == 0 && ((1L << (_la - 67)) & ((1L << (QUOTED_EXPANDED_EXTERNAL_COMMAND_LITERAL_START - 67)) | (1L << (QUOTED_NON_EXPANDED_STRING_ARRAY_LITERAL_START - 67)) | (1L << (QUOTED_EXPANDED_STRING_ARRAY_LITERAL_START - 67)) | (1L << (HERE_DOC - 67)) | (1L << (QUOTED_NON_EXPANDED_SYMBOL_ARRAY_LITERAL_START - 67)) | (1L << (QUOTED_EXPANDED_SYMBOL_ARRAY_LITERAL_START - 67)) | (1L << (DECIMAL_INTEGER_LITERAL - 67)) | (1L << (BINARY_INTEGER_LITERAL - 67)) | (1L << (OCTAL_INTEGER_LITERAL - 67)) | (1L << (HEXADECIMAL_INTEGER_LITERAL - 67)) | (1L << (FLOAT_LITERAL_WITHOUT_EXPONENT - 67)) | (1L << (FLOAT_LITERAL_WITH_EXPONENT - 67)) | (1L << (SYMBOL_LITERAL - 67)) | (1L << (LOCAL_VARIABLE_IDENTIFIER - 67)) | (1L << (LINE__ - 67)) | (1L << (ENCODING__ - 67)) | (1L << (FILE__ - 67)) | (1L << (BEGIN_ - 67)) | (1L << (END_ - 67)) | (1L << (ALIAS - 67)) | (1L << (AND - 67)) | (1L << (BEGIN - 67)) | (1L << (BREAK - 67)) | (1L << (CASE - 67)) | (1L << (CLASS - 67)) | (1L << (DEF - 67)) | (1L << (IS_DEFINED - 67)) | (1L << (DO - 67)) | (1L << (ELSE - 67)) | (1L << (ELSIF - 67)) | (1L << (END - 67)) | (1L << (ENSURE - 67)) | (1L << (FOR - 67)) | (1L << (FALSE - 67)) | (1L << (IF - 67)) | (1L << (IN - 67)) | (1L << (MODULE - 67)) | (1L << (NEXT - 67)) | (1L << (NIL - 67)) | (1L << (NOT - 67)) | (1L << (OR - 67)) | (1L << (REDO - 67)) | (1L << (RESCUE - 67)) | (1L << (RETRY - 67)) | (1L << (RETURN - 67)) | (1L << (SELF - 67)) | (1L << (SUPER - 67)) | (1L << (THEN - 67)) | (1L << (TRUE - 67)) | (1L << (UNDEF - 67)) | (1L << (UNLESS - 67)) | (1L << (UNTIL - 67)) | (1L << (WHEN - 67)) | (1L << (WHILE - 67)) | (1L << (YIELD - 67)) | (1L << (GLOBAL_VARIABLE_IDENTIFIER - 67)) | (1L << (INSTANCE_VARIABLE_IDENTIFIER - 67)) | (1L << (CLASS_VARIABLE_IDENTIFIER - 67)) | (1L << (CONSTANT_IDENTIFIER - 67)))) != 0)) {
{
setState(349);
indexingArgumentList();
}
}
setState(352);
match(RBRACK);
setState(353);
assignmentOperator();
setState(357);
_errHandler.sync(this);
_la = _input.LA(1);
while (_la==NL) {
{
{
setState(354);
match(NL);
}
}
setState(359);
_errHandler.sync(this);
_la = _input.LA(1);
}
setState(360);
methodInvocationWithoutParentheses();
}
break;
case 4:
enterOuterAlt(_localctx, 4);
{
setState(362);
primary();
setState(363);
_la = _input.LA(1);
if ( !(_la==COLON2 || _la==DOT) ) {
_errHandler.recoverInline(this);
}
else {
if ( _input.LA(1)==Token.EOF ) matchedEOF = true;
_errHandler.reportMatch(this);
consume();
}
setState(364);
methodName();
setState(365);
assignmentOperator();
setState(369);
_errHandler.sync(this);
_la = _input.LA(1);
while (_la==NL) {
{
{
setState(366);
match(NL);
}
}
setState(371);
_errHandler.sync(this);
_la = _input.LA(1);
}
setState(372);
methodInvocationWithoutParentheses();
}
break;
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class MultipleAssignmentStatementContext extends ParserRuleContext {
public LeftHandSideContext leftHandSide() {
return getRuleContext(LeftHandSideContext.class,0);
}
public TerminalNode EQ() { return getToken(RubyParser.EQ, 0); }
public MultipleRightHandSideContext multipleRightHandSide() {
return getRuleContext(MultipleRightHandSideContext.class,0);
}
public List NL() { return getTokens(RubyParser.NL); }
public TerminalNode NL(int i) {
return getToken(RubyParser.NL, i);
}
public PackingLeftHandSideContext packingLeftHandSide() {
return getRuleContext(PackingLeftHandSideContext.class,0);
}
public MethodInvocationWithoutParenthesesContext methodInvocationWithoutParentheses() {
return getRuleContext(MethodInvocationWithoutParenthesesContext.class,0);
}
public OperatorExpressionContext operatorExpression() {
return getRuleContext(OperatorExpressionContext.class,0);
}
public MultipleLeftHandSideContext multipleLeftHandSide() {
return getRuleContext(MultipleLeftHandSideContext.class,0);
}
public MultipleLeftHandSideExceptPackingContext multipleLeftHandSideExceptPacking() {
return getRuleContext(MultipleLeftHandSideExceptPackingContext.class,0);
}
public MultipleAssignmentStatementContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_multipleAssignmentStatement; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).enterMultipleAssignmentStatement(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).exitMultipleAssignmentStatement(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof RubyParserVisitor ) return ((RubyParserVisitor extends T>)visitor).visitMultipleAssignmentStatement(this);
else return visitor.visitChildren(this);
}
}
public final MultipleAssignmentStatementContext multipleAssignmentStatement() throws RecognitionException {
MultipleAssignmentStatementContext _localctx = new MultipleAssignmentStatementContext(_ctx, getState());
enterRule(_localctx, 12, RULE_multipleAssignmentStatement);
int _la;
try {
setState(420);
_errHandler.sync(this);
switch ( getInterpreter().adaptivePredict(_input,25,_ctx) ) {
case 1:
enterOuterAlt(_localctx, 1);
{
setState(376);
leftHandSide();
setState(377);
match(EQ);
setState(381);
_errHandler.sync(this);
_la = _input.LA(1);
while (_la==NL) {
{
{
setState(378);
match(NL);
}
}
setState(383);
_errHandler.sync(this);
_la = _input.LA(1);
}
setState(384);
multipleRightHandSide();
}
break;
case 2:
enterOuterAlt(_localctx, 2);
{
setState(386);
packingLeftHandSide();
setState(387);
match(EQ);
setState(391);
_errHandler.sync(this);
_la = _input.LA(1);
while (_la==NL) {
{
{
setState(388);
match(NL);
}
}
setState(393);
_errHandler.sync(this);
_la = _input.LA(1);
}
setState(396);
_errHandler.sync(this);
switch ( getInterpreter().adaptivePredict(_input,21,_ctx) ) {
case 1:
{
setState(394);
methodInvocationWithoutParentheses();
}
break;
case 2:
{
setState(395);
operatorExpression(0);
}
break;
}
}
break;
case 3:
enterOuterAlt(_localctx, 3);
{
setState(398);
multipleLeftHandSide();
setState(399);
match(EQ);
setState(403);
_errHandler.sync(this);
_la = _input.LA(1);
while (_la==NL) {
{
{
setState(400);
match(NL);
}
}
setState(405);
_errHandler.sync(this);
_la = _input.LA(1);
}
setState(406);
multipleRightHandSide();
}
break;
case 4:
enterOuterAlt(_localctx, 4);
{
setState(408);
multipleLeftHandSideExceptPacking();
setState(409);
match(EQ);
setState(413);
_errHandler.sync(this);
_la = _input.LA(1);
while (_la==NL) {
{
{
setState(410);
match(NL);
}
}
setState(415);
_errHandler.sync(this);
_la = _input.LA(1);
}
setState(418);
_errHandler.sync(this);
switch ( getInterpreter().adaptivePredict(_input,24,_ctx) ) {
case 1:
{
setState(416);
methodInvocationWithoutParentheses();
}
break;
case 2:
{
setState(417);
operatorExpression(0);
}
break;
}
}
break;
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class LeftHandSideContext extends ParserRuleContext {
public LeftHandSideContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_leftHandSide; }
public LeftHandSideContext() { }
public void copyFrom(LeftHandSideContext ctx) {
super.copyFrom(ctx);
}
}
public static class QualifiedLeftHandSideContext extends LeftHandSideContext {
public TerminalNode COLON2() { return getToken(RubyParser.COLON2, 0); }
public TerminalNode CONSTANT_IDENTIFIER() { return getToken(RubyParser.CONSTANT_IDENTIFIER, 0); }
public QualifiedLeftHandSideContext(LeftHandSideContext ctx) { copyFrom(ctx); }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).enterQualifiedLeftHandSide(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).exitQualifiedLeftHandSide(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof RubyParserVisitor ) return ((RubyParserVisitor extends T>)visitor).visitQualifiedLeftHandSide(this);
else return visitor.visitChildren(this);
}
}
public static class VariableLeftHandSideContext extends LeftHandSideContext {
public VariableContext variable() {
return getRuleContext(VariableContext.class,0);
}
public TerminalNode EQ() { return getToken(RubyParser.EQ, 0); }
public PrimaryContext primary() {
return getRuleContext(PrimaryContext.class,0);
}
public VariableLeftHandSideContext(LeftHandSideContext ctx) { copyFrom(ctx); }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).enterVariableLeftHandSide(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).exitVariableLeftHandSide(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof RubyParserVisitor ) return ((RubyParserVisitor extends T>)visitor).visitVariableLeftHandSide(this);
else return visitor.visitChildren(this);
}
}
public static class IndexingLeftHandSideContext extends LeftHandSideContext {
public PrimaryContext primary() {
return getRuleContext(PrimaryContext.class,0);
}
public TerminalNode LBRACK() { return getToken(RubyParser.LBRACK, 0); }
public TerminalNode RBRACK() { return getToken(RubyParser.RBRACK, 0); }
public IndexingArgumentListContext indexingArgumentList() {
return getRuleContext(IndexingArgumentListContext.class,0);
}
public IndexingLeftHandSideContext(LeftHandSideContext ctx) { copyFrom(ctx); }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).enterIndexingLeftHandSide(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).exitIndexingLeftHandSide(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof RubyParserVisitor ) return ((RubyParserVisitor extends T>)visitor).visitIndexingLeftHandSide(this);
else return visitor.visitChildren(this);
}
}
public static class MemberAccessLeftHandSideContext extends LeftHandSideContext {
public PrimaryContext primary() {
return getRuleContext(PrimaryContext.class,0);
}
public TerminalNode DOT() { return getToken(RubyParser.DOT, 0); }
public TerminalNode COLON2() { return getToken(RubyParser.COLON2, 0); }
public TerminalNode LOCAL_VARIABLE_IDENTIFIER() { return getToken(RubyParser.LOCAL_VARIABLE_IDENTIFIER, 0); }
public TerminalNode CONSTANT_IDENTIFIER() { return getToken(RubyParser.CONSTANT_IDENTIFIER, 0); }
public MemberAccessLeftHandSideContext(LeftHandSideContext ctx) { copyFrom(ctx); }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).enterMemberAccessLeftHandSide(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).exitMemberAccessLeftHandSide(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof RubyParserVisitor ) return ((RubyParserVisitor extends T>)visitor).visitMemberAccessLeftHandSide(this);
else return visitor.visitChildren(this);
}
}
public final LeftHandSideContext leftHandSide() throws RecognitionException {
LeftHandSideContext _localctx = new LeftHandSideContext(_ctx, getState());
enterRule(_localctx, 14, RULE_leftHandSide);
int _la;
try {
setState(440);
_errHandler.sync(this);
switch ( getInterpreter().adaptivePredict(_input,28,_ctx) ) {
case 1:
_localctx = new VariableLeftHandSideContext(_localctx);
enterOuterAlt(_localctx, 1);
{
setState(422);
variable();
setState(425);
_errHandler.sync(this);
switch ( getInterpreter().adaptivePredict(_input,26,_ctx) ) {
case 1:
{
setState(423);
match(EQ);
setState(424);
primary();
}
break;
}
}
break;
case 2:
_localctx = new IndexingLeftHandSideContext(_localctx);
enterOuterAlt(_localctx, 2);
{
setState(427);
primary();
setState(428);
match(LBRACK);
setState(430);
_errHandler.sync(this);
_la = _input.LA(1);
if (((((_la - 3)) & ~0x3f) == 0 && ((1L << (_la - 3)) & ((1L << (REGULAR_EXPRESSION_START - 3)) | (1L << (LBRACK - 3)) | (1L << (LPAREN - 3)) | (1L << (LCURLY - 3)) | (1L << (COLON - 3)) | (1L << (COLON2 - 3)) | (1L << (DOT2 - 3)) | (1L << (DOT3 - 3)) | (1L << (MINUSGT - 3)) | (1L << (EMARK - 3)) | (1L << (PLUS - 3)) | (1L << (MINUS - 3)) | (1L << (STAR - 3)) | (1L << (STAR2 - 3)) | (1L << (TILDE - 3)) | (1L << (SINGLE_QUOTED_STRING_LITERAL - 3)) | (1L << (DOUBLE_QUOTED_STRING_START - 3)) | (1L << (QUOTED_NON_EXPANDED_STRING_LITERAL_START - 3)) | (1L << (QUOTED_EXPANDED_STRING_LITERAL_START - 3)) | (1L << (QUOTED_EXPANDED_REGULAR_EXPRESSION_START - 3)))) != 0) || ((((_la - 67)) & ~0x3f) == 0 && ((1L << (_la - 67)) & ((1L << (QUOTED_EXPANDED_EXTERNAL_COMMAND_LITERAL_START - 67)) | (1L << (QUOTED_NON_EXPANDED_STRING_ARRAY_LITERAL_START - 67)) | (1L << (QUOTED_EXPANDED_STRING_ARRAY_LITERAL_START - 67)) | (1L << (HERE_DOC - 67)) | (1L << (QUOTED_NON_EXPANDED_SYMBOL_ARRAY_LITERAL_START - 67)) | (1L << (QUOTED_EXPANDED_SYMBOL_ARRAY_LITERAL_START - 67)) | (1L << (DECIMAL_INTEGER_LITERAL - 67)) | (1L << (BINARY_INTEGER_LITERAL - 67)) | (1L << (OCTAL_INTEGER_LITERAL - 67)) | (1L << (HEXADECIMAL_INTEGER_LITERAL - 67)) | (1L << (FLOAT_LITERAL_WITHOUT_EXPONENT - 67)) | (1L << (FLOAT_LITERAL_WITH_EXPONENT - 67)) | (1L << (SYMBOL_LITERAL - 67)) | (1L << (LOCAL_VARIABLE_IDENTIFIER - 67)) | (1L << (LINE__ - 67)) | (1L << (ENCODING__ - 67)) | (1L << (FILE__ - 67)) | (1L << (BEGIN_ - 67)) | (1L << (END_ - 67)) | (1L << (ALIAS - 67)) | (1L << (AND - 67)) | (1L << (BEGIN - 67)) | (1L << (BREAK - 67)) | (1L << (CASE - 67)) | (1L << (CLASS - 67)) | (1L << (DEF - 67)) | (1L << (IS_DEFINED - 67)) | (1L << (DO - 67)) | (1L << (ELSE - 67)) | (1L << (ELSIF - 67)) | (1L << (END - 67)) | (1L << (ENSURE - 67)) | (1L << (FOR - 67)) | (1L << (FALSE - 67)) | (1L << (IF - 67)) | (1L << (IN - 67)) | (1L << (MODULE - 67)) | (1L << (NEXT - 67)) | (1L << (NIL - 67)) | (1L << (NOT - 67)) | (1L << (OR - 67)) | (1L << (REDO - 67)) | (1L << (RESCUE - 67)) | (1L << (RETRY - 67)) | (1L << (RETURN - 67)) | (1L << (SELF - 67)) | (1L << (SUPER - 67)) | (1L << (THEN - 67)) | (1L << (TRUE - 67)) | (1L << (UNDEF - 67)) | (1L << (UNLESS - 67)) | (1L << (UNTIL - 67)) | (1L << (WHEN - 67)) | (1L << (WHILE - 67)) | (1L << (YIELD - 67)) | (1L << (GLOBAL_VARIABLE_IDENTIFIER - 67)) | (1L << (INSTANCE_VARIABLE_IDENTIFIER - 67)) | (1L << (CLASS_VARIABLE_IDENTIFIER - 67)) | (1L << (CONSTANT_IDENTIFIER - 67)))) != 0)) {
{
setState(429);
indexingArgumentList();
}
}
setState(432);
match(RBRACK);
}
break;
case 3:
_localctx = new MemberAccessLeftHandSideContext(_localctx);
enterOuterAlt(_localctx, 3);
{
setState(434);
primary();
setState(435);
_la = _input.LA(1);
if ( !(_la==COLON2 || _la==DOT) ) {
_errHandler.recoverInline(this);
}
else {
if ( _input.LA(1)==Token.EOF ) matchedEOF = true;
_errHandler.reportMatch(this);
consume();
}
setState(436);
_la = _input.LA(1);
if ( !(_la==LOCAL_VARIABLE_IDENTIFIER || _la==CONSTANT_IDENTIFIER) ) {
_errHandler.recoverInline(this);
}
else {
if ( _input.LA(1)==Token.EOF ) matchedEOF = true;
_errHandler.reportMatch(this);
consume();
}
}
break;
case 4:
_localctx = new QualifiedLeftHandSideContext(_localctx);
enterOuterAlt(_localctx, 4);
{
setState(438);
match(COLON2);
setState(439);
match(CONSTANT_IDENTIFIER);
}
break;
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class MultipleLeftHandSideContext extends ParserRuleContext {
public List multipleLeftHandSideItem() {
return getRuleContexts(MultipleLeftHandSideItemContext.class);
}
public MultipleLeftHandSideItemContext multipleLeftHandSideItem(int i) {
return getRuleContext(MultipleLeftHandSideItemContext.class,i);
}
public List COMMA() { return getTokens(RubyParser.COMMA); }
public TerminalNode COMMA(int i) {
return getToken(RubyParser.COMMA, i);
}
public PackingLeftHandSideContext packingLeftHandSide() {
return getRuleContext(PackingLeftHandSideContext.class,0);
}
public ProcParameterContext procParameter() {
return getRuleContext(ProcParameterContext.class,0);
}
public List NL() { return getTokens(RubyParser.NL); }
public TerminalNode NL(int i) {
return getToken(RubyParser.NL, i);
}
public GroupedLeftHandSideContext groupedLeftHandSide() {
return getRuleContext(GroupedLeftHandSideContext.class,0);
}
public MultipleLeftHandSideContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_multipleLeftHandSide; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).enterMultipleLeftHandSide(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).exitMultipleLeftHandSide(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof RubyParserVisitor ) return ((RubyParserVisitor extends T>)visitor).visitMultipleLeftHandSide(this);
else return visitor.visitChildren(this);
}
}
public final MultipleLeftHandSideContext multipleLeftHandSide() throws RecognitionException {
MultipleLeftHandSideContext _localctx = new MultipleLeftHandSideContext(_ctx, getState());
enterRule(_localctx, 16, RULE_multipleLeftHandSide);
int _la;
try {
int _alt;
setState(479);
_errHandler.sync(this);
switch ( getInterpreter().adaptivePredict(_input,37,_ctx) ) {
case 1:
enterOuterAlt(_localctx, 1);
{
setState(445);
_errHandler.sync(this);
_alt = 1;
do {
switch (_alt) {
case 1:
{
{
setState(442);
multipleLeftHandSideItem();
setState(443);
match(COMMA);
}
}
break;
default:
throw new NoViableAltException(this);
}
setState(447);
_errHandler.sync(this);
_alt = getInterpreter().adaptivePredict(_input,29,_ctx);
} while ( _alt!=2 && _alt!=org.antlr.v4.runtime.atn.ATN.INVALID_ALT_NUMBER );
setState(450);
_errHandler.sync(this);
_la = _input.LA(1);
if (((((_la - 3)) & ~0x3f) == 0 && ((1L << (_la - 3)) & ((1L << (REGULAR_EXPRESSION_START - 3)) | (1L << (LBRACK - 3)) | (1L << (LPAREN - 3)) | (1L << (LCURLY - 3)) | (1L << (COLON - 3)) | (1L << (COLON2 - 3)) | (1L << (DOT2 - 3)) | (1L << (DOT3 - 3)) | (1L << (MINUSGT - 3)) | (1L << (EMARK - 3)) | (1L << (PLUS - 3)) | (1L << (MINUS - 3)) | (1L << (TILDE - 3)) | (1L << (SINGLE_QUOTED_STRING_LITERAL - 3)) | (1L << (DOUBLE_QUOTED_STRING_START - 3)) | (1L << (QUOTED_NON_EXPANDED_STRING_LITERAL_START - 3)) | (1L << (QUOTED_EXPANDED_STRING_LITERAL_START - 3)) | (1L << (QUOTED_EXPANDED_REGULAR_EXPRESSION_START - 3)))) != 0) || ((((_la - 67)) & ~0x3f) == 0 && ((1L << (_la - 67)) & ((1L << (QUOTED_EXPANDED_EXTERNAL_COMMAND_LITERAL_START - 67)) | (1L << (QUOTED_NON_EXPANDED_STRING_ARRAY_LITERAL_START - 67)) | (1L << (QUOTED_EXPANDED_STRING_ARRAY_LITERAL_START - 67)) | (1L << (HERE_DOC - 67)) | (1L << (QUOTED_NON_EXPANDED_SYMBOL_ARRAY_LITERAL_START - 67)) | (1L << (QUOTED_EXPANDED_SYMBOL_ARRAY_LITERAL_START - 67)) | (1L << (DECIMAL_INTEGER_LITERAL - 67)) | (1L << (BINARY_INTEGER_LITERAL - 67)) | (1L << (OCTAL_INTEGER_LITERAL - 67)) | (1L << (HEXADECIMAL_INTEGER_LITERAL - 67)) | (1L << (FLOAT_LITERAL_WITHOUT_EXPONENT - 67)) | (1L << (FLOAT_LITERAL_WITH_EXPONENT - 67)) | (1L << (SYMBOL_LITERAL - 67)) | (1L << (LOCAL_VARIABLE_IDENTIFIER - 67)) | (1L << (LINE__ - 67)) | (1L << (ENCODING__ - 67)) | (1L << (FILE__ - 67)) | (1L << (BEGIN - 67)) | (1L << (BREAK - 67)) | (1L << (CASE - 67)) | (1L << (CLASS - 67)) | (1L << (DEF - 67)) | (1L << (IS_DEFINED - 67)) | (1L << (FOR - 67)) | (1L << (FALSE - 67)) | (1L << (IF - 67)) | (1L << (MODULE - 67)) | (1L << (NEXT - 67)) | (1L << (NIL - 67)) | (1L << (REDO - 67)) | (1L << (RETRY - 67)) | (1L << (RETURN - 67)) | (1L << (SELF - 67)) | (1L << (SUPER - 67)) | (1L << (TRUE - 67)) | (1L << (UNLESS - 67)) | (1L << (UNTIL - 67)) | (1L << (WHILE - 67)) | (1L << (YIELD - 67)) | (1L << (GLOBAL_VARIABLE_IDENTIFIER - 67)) | (1L << (INSTANCE_VARIABLE_IDENTIFIER - 67)) | (1L << (CLASS_VARIABLE_IDENTIFIER - 67)) | (1L << (CONSTANT_IDENTIFIER - 67)))) != 0)) {
{
setState(449);
multipleLeftHandSideItem();
}
}
}
break;
case 2:
enterOuterAlt(_localctx, 2);
{
setState(455);
_errHandler.sync(this);
_la = _input.LA(1);
do {
{
{
setState(452);
multipleLeftHandSideItem();
setState(453);
match(COMMA);
}
}
setState(457);
_errHandler.sync(this);
_la = _input.LA(1);
} while ( ((((_la - 3)) & ~0x3f) == 0 && ((1L << (_la - 3)) & ((1L << (REGULAR_EXPRESSION_START - 3)) | (1L << (LBRACK - 3)) | (1L << (LPAREN - 3)) | (1L << (LCURLY - 3)) | (1L << (COLON - 3)) | (1L << (COLON2 - 3)) | (1L << (DOT2 - 3)) | (1L << (DOT3 - 3)) | (1L << (MINUSGT - 3)) | (1L << (EMARK - 3)) | (1L << (PLUS - 3)) | (1L << (MINUS - 3)) | (1L << (TILDE - 3)) | (1L << (SINGLE_QUOTED_STRING_LITERAL - 3)) | (1L << (DOUBLE_QUOTED_STRING_START - 3)) | (1L << (QUOTED_NON_EXPANDED_STRING_LITERAL_START - 3)) | (1L << (QUOTED_EXPANDED_STRING_LITERAL_START - 3)) | (1L << (QUOTED_EXPANDED_REGULAR_EXPRESSION_START - 3)))) != 0) || ((((_la - 67)) & ~0x3f) == 0 && ((1L << (_la - 67)) & ((1L << (QUOTED_EXPANDED_EXTERNAL_COMMAND_LITERAL_START - 67)) | (1L << (QUOTED_NON_EXPANDED_STRING_ARRAY_LITERAL_START - 67)) | (1L << (QUOTED_EXPANDED_STRING_ARRAY_LITERAL_START - 67)) | (1L << (HERE_DOC - 67)) | (1L << (QUOTED_NON_EXPANDED_SYMBOL_ARRAY_LITERAL_START - 67)) | (1L << (QUOTED_EXPANDED_SYMBOL_ARRAY_LITERAL_START - 67)) | (1L << (DECIMAL_INTEGER_LITERAL - 67)) | (1L << (BINARY_INTEGER_LITERAL - 67)) | (1L << (OCTAL_INTEGER_LITERAL - 67)) | (1L << (HEXADECIMAL_INTEGER_LITERAL - 67)) | (1L << (FLOAT_LITERAL_WITHOUT_EXPONENT - 67)) | (1L << (FLOAT_LITERAL_WITH_EXPONENT - 67)) | (1L << (SYMBOL_LITERAL - 67)) | (1L << (LOCAL_VARIABLE_IDENTIFIER - 67)) | (1L << (LINE__ - 67)) | (1L << (ENCODING__ - 67)) | (1L << (FILE__ - 67)) | (1L << (BEGIN - 67)) | (1L << (BREAK - 67)) | (1L << (CASE - 67)) | (1L << (CLASS - 67)) | (1L << (DEF - 67)) | (1L << (IS_DEFINED - 67)) | (1L << (FOR - 67)) | (1L << (FALSE - 67)) | (1L << (IF - 67)) | (1L << (MODULE - 67)) | (1L << (NEXT - 67)) | (1L << (NIL - 67)) | (1L << (REDO - 67)) | (1L << (RETRY - 67)) | (1L << (RETURN - 67)) | (1L << (SELF - 67)) | (1L << (SUPER - 67)) | (1L << (TRUE - 67)) | (1L << (UNLESS - 67)) | (1L << (UNTIL - 67)) | (1L << (WHILE - 67)) | (1L << (YIELD - 67)) | (1L << (GLOBAL_VARIABLE_IDENTIFIER - 67)) | (1L << (INSTANCE_VARIABLE_IDENTIFIER - 67)) | (1L << (CLASS_VARIABLE_IDENTIFIER - 67)) | (1L << (CONSTANT_IDENTIFIER - 67)))) != 0) );
setState(460);
_errHandler.sync(this);
_la = _input.LA(1);
if (_la==STAR) {
{
setState(459);
packingLeftHandSide();
}
}
setState(472);
_errHandler.sync(this);
switch ( getInterpreter().adaptivePredict(_input,35,_ctx) ) {
case 1:
{
setState(463);
_errHandler.sync(this);
_la = _input.LA(1);
if (_la==COMMA) {
{
setState(462);
match(COMMA);
}
}
setState(468);
_errHandler.sync(this);
_la = _input.LA(1);
while (_la==NL) {
{
{
setState(465);
match(NL);
}
}
setState(470);
_errHandler.sync(this);
_la = _input.LA(1);
}
setState(471);
procParameter();
}
break;
}
setState(475);
_errHandler.sync(this);
_la = _input.LA(1);
if (_la==COMMA) {
{
setState(474);
match(COMMA);
}
}
}
break;
case 3:
enterOuterAlt(_localctx, 3);
{
setState(477);
packingLeftHandSide();
}
break;
case 4:
enterOuterAlt(_localctx, 4);
{
setState(478);
groupedLeftHandSide();
}
break;
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class MultipleLeftHandSideExceptPackingContext extends ParserRuleContext {
public List multipleLeftHandSideItem() {
return getRuleContexts(MultipleLeftHandSideItemContext.class);
}
public MultipleLeftHandSideItemContext multipleLeftHandSideItem(int i) {
return getRuleContext(MultipleLeftHandSideItemContext.class,i);
}
public List COMMA() { return getTokens(RubyParser.COMMA); }
public TerminalNode COMMA(int i) {
return getToken(RubyParser.COMMA, i);
}
public PackingLeftHandSideContext packingLeftHandSide() {
return getRuleContext(PackingLeftHandSideContext.class,0);
}
public GroupedLeftHandSideContext groupedLeftHandSide() {
return getRuleContext(GroupedLeftHandSideContext.class,0);
}
public MultipleLeftHandSideExceptPackingContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_multipleLeftHandSideExceptPacking; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).enterMultipleLeftHandSideExceptPacking(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).exitMultipleLeftHandSideExceptPacking(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof RubyParserVisitor ) return ((RubyParserVisitor extends T>)visitor).visitMultipleLeftHandSideExceptPacking(this);
else return visitor.visitChildren(this);
}
}
public final MultipleLeftHandSideExceptPackingContext multipleLeftHandSideExceptPacking() throws RecognitionException {
MultipleLeftHandSideExceptPackingContext _localctx = new MultipleLeftHandSideExceptPackingContext(_ctx, getState());
enterRule(_localctx, 18, RULE_multipleLeftHandSideExceptPacking);
int _la;
try {
int _alt;
setState(502);
_errHandler.sync(this);
switch ( getInterpreter().adaptivePredict(_input,42,_ctx) ) {
case 1:
enterOuterAlt(_localctx, 1);
{
setState(484);
_errHandler.sync(this);
_alt = 1;
do {
switch (_alt) {
case 1:
{
{
setState(481);
multipleLeftHandSideItem();
setState(482);
match(COMMA);
}
}
break;
default:
throw new NoViableAltException(this);
}
setState(486);
_errHandler.sync(this);
_alt = getInterpreter().adaptivePredict(_input,38,_ctx);
} while ( _alt!=2 && _alt!=org.antlr.v4.runtime.atn.ATN.INVALID_ALT_NUMBER );
setState(489);
_errHandler.sync(this);
_la = _input.LA(1);
if (((((_la - 3)) & ~0x3f) == 0 && ((1L << (_la - 3)) & ((1L << (REGULAR_EXPRESSION_START - 3)) | (1L << (LBRACK - 3)) | (1L << (LPAREN - 3)) | (1L << (LCURLY - 3)) | (1L << (COLON - 3)) | (1L << (COLON2 - 3)) | (1L << (DOT2 - 3)) | (1L << (DOT3 - 3)) | (1L << (MINUSGT - 3)) | (1L << (EMARK - 3)) | (1L << (PLUS - 3)) | (1L << (MINUS - 3)) | (1L << (TILDE - 3)) | (1L << (SINGLE_QUOTED_STRING_LITERAL - 3)) | (1L << (DOUBLE_QUOTED_STRING_START - 3)) | (1L << (QUOTED_NON_EXPANDED_STRING_LITERAL_START - 3)) | (1L << (QUOTED_EXPANDED_STRING_LITERAL_START - 3)) | (1L << (QUOTED_EXPANDED_REGULAR_EXPRESSION_START - 3)))) != 0) || ((((_la - 67)) & ~0x3f) == 0 && ((1L << (_la - 67)) & ((1L << (QUOTED_EXPANDED_EXTERNAL_COMMAND_LITERAL_START - 67)) | (1L << (QUOTED_NON_EXPANDED_STRING_ARRAY_LITERAL_START - 67)) | (1L << (QUOTED_EXPANDED_STRING_ARRAY_LITERAL_START - 67)) | (1L << (HERE_DOC - 67)) | (1L << (QUOTED_NON_EXPANDED_SYMBOL_ARRAY_LITERAL_START - 67)) | (1L << (QUOTED_EXPANDED_SYMBOL_ARRAY_LITERAL_START - 67)) | (1L << (DECIMAL_INTEGER_LITERAL - 67)) | (1L << (BINARY_INTEGER_LITERAL - 67)) | (1L << (OCTAL_INTEGER_LITERAL - 67)) | (1L << (HEXADECIMAL_INTEGER_LITERAL - 67)) | (1L << (FLOAT_LITERAL_WITHOUT_EXPONENT - 67)) | (1L << (FLOAT_LITERAL_WITH_EXPONENT - 67)) | (1L << (SYMBOL_LITERAL - 67)) | (1L << (LOCAL_VARIABLE_IDENTIFIER - 67)) | (1L << (LINE__ - 67)) | (1L << (ENCODING__ - 67)) | (1L << (FILE__ - 67)) | (1L << (BEGIN - 67)) | (1L << (BREAK - 67)) | (1L << (CASE - 67)) | (1L << (CLASS - 67)) | (1L << (DEF - 67)) | (1L << (IS_DEFINED - 67)) | (1L << (FOR - 67)) | (1L << (FALSE - 67)) | (1L << (IF - 67)) | (1L << (MODULE - 67)) | (1L << (NEXT - 67)) | (1L << (NIL - 67)) | (1L << (REDO - 67)) | (1L << (RETRY - 67)) | (1L << (RETURN - 67)) | (1L << (SELF - 67)) | (1L << (SUPER - 67)) | (1L << (TRUE - 67)) | (1L << (UNLESS - 67)) | (1L << (UNTIL - 67)) | (1L << (WHILE - 67)) | (1L << (YIELD - 67)) | (1L << (GLOBAL_VARIABLE_IDENTIFIER - 67)) | (1L << (INSTANCE_VARIABLE_IDENTIFIER - 67)) | (1L << (CLASS_VARIABLE_IDENTIFIER - 67)) | (1L << (CONSTANT_IDENTIFIER - 67)))) != 0)) {
{
setState(488);
multipleLeftHandSideItem();
}
}
}
break;
case 2:
enterOuterAlt(_localctx, 2);
{
setState(494);
_errHandler.sync(this);
_la = _input.LA(1);
do {
{
{
setState(491);
multipleLeftHandSideItem();
setState(492);
match(COMMA);
}
}
setState(496);
_errHandler.sync(this);
_la = _input.LA(1);
} while ( ((((_la - 3)) & ~0x3f) == 0 && ((1L << (_la - 3)) & ((1L << (REGULAR_EXPRESSION_START - 3)) | (1L << (LBRACK - 3)) | (1L << (LPAREN - 3)) | (1L << (LCURLY - 3)) | (1L << (COLON - 3)) | (1L << (COLON2 - 3)) | (1L << (DOT2 - 3)) | (1L << (DOT3 - 3)) | (1L << (MINUSGT - 3)) | (1L << (EMARK - 3)) | (1L << (PLUS - 3)) | (1L << (MINUS - 3)) | (1L << (TILDE - 3)) | (1L << (SINGLE_QUOTED_STRING_LITERAL - 3)) | (1L << (DOUBLE_QUOTED_STRING_START - 3)) | (1L << (QUOTED_NON_EXPANDED_STRING_LITERAL_START - 3)) | (1L << (QUOTED_EXPANDED_STRING_LITERAL_START - 3)) | (1L << (QUOTED_EXPANDED_REGULAR_EXPRESSION_START - 3)))) != 0) || ((((_la - 67)) & ~0x3f) == 0 && ((1L << (_la - 67)) & ((1L << (QUOTED_EXPANDED_EXTERNAL_COMMAND_LITERAL_START - 67)) | (1L << (QUOTED_NON_EXPANDED_STRING_ARRAY_LITERAL_START - 67)) | (1L << (QUOTED_EXPANDED_STRING_ARRAY_LITERAL_START - 67)) | (1L << (HERE_DOC - 67)) | (1L << (QUOTED_NON_EXPANDED_SYMBOL_ARRAY_LITERAL_START - 67)) | (1L << (QUOTED_EXPANDED_SYMBOL_ARRAY_LITERAL_START - 67)) | (1L << (DECIMAL_INTEGER_LITERAL - 67)) | (1L << (BINARY_INTEGER_LITERAL - 67)) | (1L << (OCTAL_INTEGER_LITERAL - 67)) | (1L << (HEXADECIMAL_INTEGER_LITERAL - 67)) | (1L << (FLOAT_LITERAL_WITHOUT_EXPONENT - 67)) | (1L << (FLOAT_LITERAL_WITH_EXPONENT - 67)) | (1L << (SYMBOL_LITERAL - 67)) | (1L << (LOCAL_VARIABLE_IDENTIFIER - 67)) | (1L << (LINE__ - 67)) | (1L << (ENCODING__ - 67)) | (1L << (FILE__ - 67)) | (1L << (BEGIN - 67)) | (1L << (BREAK - 67)) | (1L << (CASE - 67)) | (1L << (CLASS - 67)) | (1L << (DEF - 67)) | (1L << (IS_DEFINED - 67)) | (1L << (FOR - 67)) | (1L << (FALSE - 67)) | (1L << (IF - 67)) | (1L << (MODULE - 67)) | (1L << (NEXT - 67)) | (1L << (NIL - 67)) | (1L << (REDO - 67)) | (1L << (RETRY - 67)) | (1L << (RETURN - 67)) | (1L << (SELF - 67)) | (1L << (SUPER - 67)) | (1L << (TRUE - 67)) | (1L << (UNLESS - 67)) | (1L << (UNTIL - 67)) | (1L << (WHILE - 67)) | (1L << (YIELD - 67)) | (1L << (GLOBAL_VARIABLE_IDENTIFIER - 67)) | (1L << (INSTANCE_VARIABLE_IDENTIFIER - 67)) | (1L << (CLASS_VARIABLE_IDENTIFIER - 67)) | (1L << (CONSTANT_IDENTIFIER - 67)))) != 0) );
setState(499);
_errHandler.sync(this);
_la = _input.LA(1);
if (_la==STAR) {
{
setState(498);
packingLeftHandSide();
}
}
}
break;
case 3:
enterOuterAlt(_localctx, 3);
{
setState(501);
groupedLeftHandSide();
}
break;
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class PackingLeftHandSideContext extends ParserRuleContext {
public TerminalNode STAR() { return getToken(RubyParser.STAR, 0); }
public LeftHandSideContext leftHandSide() {
return getRuleContext(LeftHandSideContext.class,0);
}
public List COMMA() { return getTokens(RubyParser.COMMA); }
public TerminalNode COMMA(int i) {
return getToken(RubyParser.COMMA, i);
}
public List multipleLeftHandSideItem() {
return getRuleContexts(MultipleLeftHandSideItemContext.class);
}
public MultipleLeftHandSideItemContext multipleLeftHandSideItem(int i) {
return getRuleContext(MultipleLeftHandSideItemContext.class,i);
}
public PackingLeftHandSideContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_packingLeftHandSide; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).enterPackingLeftHandSide(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).exitPackingLeftHandSide(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof RubyParserVisitor ) return ((RubyParserVisitor extends T>)visitor).visitPackingLeftHandSide(this);
else return visitor.visitChildren(this);
}
}
public final PackingLeftHandSideContext packingLeftHandSide() throws RecognitionException {
PackingLeftHandSideContext _localctx = new PackingLeftHandSideContext(_ctx, getState());
enterRule(_localctx, 20, RULE_packingLeftHandSide);
int _la;
try {
int _alt;
enterOuterAlt(_localctx, 1);
{
setState(504);
match(STAR);
setState(506);
_errHandler.sync(this);
_la = _input.LA(1);
if (((((_la - 3)) & ~0x3f) == 0 && ((1L << (_la - 3)) & ((1L << (REGULAR_EXPRESSION_START - 3)) | (1L << (LBRACK - 3)) | (1L << (LPAREN - 3)) | (1L << (LCURLY - 3)) | (1L << (COLON - 3)) | (1L << (COLON2 - 3)) | (1L << (DOT2 - 3)) | (1L << (DOT3 - 3)) | (1L << (MINUSGT - 3)) | (1L << (EMARK - 3)) | (1L << (PLUS - 3)) | (1L << (MINUS - 3)) | (1L << (TILDE - 3)) | (1L << (SINGLE_QUOTED_STRING_LITERAL - 3)) | (1L << (DOUBLE_QUOTED_STRING_START - 3)) | (1L << (QUOTED_NON_EXPANDED_STRING_LITERAL_START - 3)) | (1L << (QUOTED_EXPANDED_STRING_LITERAL_START - 3)) | (1L << (QUOTED_EXPANDED_REGULAR_EXPRESSION_START - 3)))) != 0) || ((((_la - 67)) & ~0x3f) == 0 && ((1L << (_la - 67)) & ((1L << (QUOTED_EXPANDED_EXTERNAL_COMMAND_LITERAL_START - 67)) | (1L << (QUOTED_NON_EXPANDED_STRING_ARRAY_LITERAL_START - 67)) | (1L << (QUOTED_EXPANDED_STRING_ARRAY_LITERAL_START - 67)) | (1L << (HERE_DOC - 67)) | (1L << (QUOTED_NON_EXPANDED_SYMBOL_ARRAY_LITERAL_START - 67)) | (1L << (QUOTED_EXPANDED_SYMBOL_ARRAY_LITERAL_START - 67)) | (1L << (DECIMAL_INTEGER_LITERAL - 67)) | (1L << (BINARY_INTEGER_LITERAL - 67)) | (1L << (OCTAL_INTEGER_LITERAL - 67)) | (1L << (HEXADECIMAL_INTEGER_LITERAL - 67)) | (1L << (FLOAT_LITERAL_WITHOUT_EXPONENT - 67)) | (1L << (FLOAT_LITERAL_WITH_EXPONENT - 67)) | (1L << (SYMBOL_LITERAL - 67)) | (1L << (LOCAL_VARIABLE_IDENTIFIER - 67)) | (1L << (LINE__ - 67)) | (1L << (ENCODING__ - 67)) | (1L << (FILE__ - 67)) | (1L << (BEGIN - 67)) | (1L << (BREAK - 67)) | (1L << (CASE - 67)) | (1L << (CLASS - 67)) | (1L << (DEF - 67)) | (1L << (IS_DEFINED - 67)) | (1L << (FOR - 67)) | (1L << (FALSE - 67)) | (1L << (IF - 67)) | (1L << (MODULE - 67)) | (1L << (NEXT - 67)) | (1L << (NIL - 67)) | (1L << (REDO - 67)) | (1L << (RETRY - 67)) | (1L << (RETURN - 67)) | (1L << (SELF - 67)) | (1L << (SUPER - 67)) | (1L << (TRUE - 67)) | (1L << (UNLESS - 67)) | (1L << (UNTIL - 67)) | (1L << (WHILE - 67)) | (1L << (YIELD - 67)) | (1L << (GLOBAL_VARIABLE_IDENTIFIER - 67)) | (1L << (INSTANCE_VARIABLE_IDENTIFIER - 67)) | (1L << (CLASS_VARIABLE_IDENTIFIER - 67)) | (1L << (CONSTANT_IDENTIFIER - 67)))) != 0)) {
{
setState(505);
leftHandSide();
}
}
setState(512);
_errHandler.sync(this);
_alt = getInterpreter().adaptivePredict(_input,44,_ctx);
while ( _alt!=2 && _alt!=org.antlr.v4.runtime.atn.ATN.INVALID_ALT_NUMBER ) {
if ( _alt==1 ) {
{
{
setState(508);
match(COMMA);
setState(509);
multipleLeftHandSideItem();
}
}
}
setState(514);
_errHandler.sync(this);
_alt = getInterpreter().adaptivePredict(_input,44,_ctx);
}
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class GroupedLeftHandSideContext extends ParserRuleContext {
public TerminalNode LPAREN() { return getToken(RubyParser.LPAREN, 0); }
public MultipleLeftHandSideContext multipleLeftHandSide() {
return getRuleContext(MultipleLeftHandSideContext.class,0);
}
public TerminalNode RPAREN() { return getToken(RubyParser.RPAREN, 0); }
public GroupedLeftHandSideContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_groupedLeftHandSide; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).enterGroupedLeftHandSide(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).exitGroupedLeftHandSide(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof RubyParserVisitor ) return ((RubyParserVisitor extends T>)visitor).visitGroupedLeftHandSide(this);
else return visitor.visitChildren(this);
}
}
public final GroupedLeftHandSideContext groupedLeftHandSide() throws RecognitionException {
GroupedLeftHandSideContext _localctx = new GroupedLeftHandSideContext(_ctx, getState());
enterRule(_localctx, 22, RULE_groupedLeftHandSide);
try {
enterOuterAlt(_localctx, 1);
{
setState(515);
match(LPAREN);
setState(516);
multipleLeftHandSide();
setState(517);
match(RPAREN);
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class MultipleLeftHandSideItemContext extends ParserRuleContext {
public LeftHandSideContext leftHandSide() {
return getRuleContext(LeftHandSideContext.class,0);
}
public GroupedLeftHandSideContext groupedLeftHandSide() {
return getRuleContext(GroupedLeftHandSideContext.class,0);
}
public MultipleLeftHandSideItemContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_multipleLeftHandSideItem; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).enterMultipleLeftHandSideItem(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).exitMultipleLeftHandSideItem(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof RubyParserVisitor ) return ((RubyParserVisitor extends T>)visitor).visitMultipleLeftHandSideItem(this);
else return visitor.visitChildren(this);
}
}
public final MultipleLeftHandSideItemContext multipleLeftHandSideItem() throws RecognitionException {
MultipleLeftHandSideItemContext _localctx = new MultipleLeftHandSideItemContext(_ctx, getState());
enterRule(_localctx, 24, RULE_multipleLeftHandSideItem);
try {
setState(521);
_errHandler.sync(this);
switch ( getInterpreter().adaptivePredict(_input,45,_ctx) ) {
case 1:
enterOuterAlt(_localctx, 1);
{
setState(519);
leftHandSide();
}
break;
case 2:
enterOuterAlt(_localctx, 2);
{
setState(520);
groupedLeftHandSide();
}
break;
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class MultipleRightHandSideContext extends ParserRuleContext {
public List operatorExpressionList() {
return getRuleContexts(OperatorExpressionListContext.class);
}
public OperatorExpressionListContext operatorExpressionList(int i) {
return getRuleContext(OperatorExpressionListContext.class,i);
}
public List splattingRightHandSide() {
return getRuleContexts(SplattingRightHandSideContext.class);
}
public SplattingRightHandSideContext splattingRightHandSide(int i) {
return getRuleContext(SplattingRightHandSideContext.class,i);
}
public List COMMA() { return getTokens(RubyParser.COMMA); }
public TerminalNode COMMA(int i) {
return getToken(RubyParser.COMMA, i);
}
public MultipleRightHandSideContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_multipleRightHandSide; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).enterMultipleRightHandSide(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).exitMultipleRightHandSide(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof RubyParserVisitor ) return ((RubyParserVisitor extends T>)visitor).visitMultipleRightHandSide(this);
else return visitor.visitChildren(this);
}
}
public final MultipleRightHandSideContext multipleRightHandSide() throws RecognitionException {
MultipleRightHandSideContext _localctx = new MultipleRightHandSideContext(_ctx, getState());
enterRule(_localctx, 26, RULE_multipleRightHandSide);
try {
int _alt;
enterOuterAlt(_localctx, 1);
{
setState(525);
_errHandler.sync(this);
switch (_input.LA(1)) {
case REGULAR_EXPRESSION_START:
case LBRACK:
case LPAREN:
case LCURLY:
case COLON:
case COLON2:
case DOT2:
case DOT3:
case MINUSGT:
case EMARK:
case PLUS:
case MINUS:
case TILDE:
case SINGLE_QUOTED_STRING_LITERAL:
case DOUBLE_QUOTED_STRING_START:
case QUOTED_NON_EXPANDED_STRING_LITERAL_START:
case QUOTED_EXPANDED_STRING_LITERAL_START:
case QUOTED_EXPANDED_REGULAR_EXPRESSION_START:
case QUOTED_EXPANDED_EXTERNAL_COMMAND_LITERAL_START:
case QUOTED_NON_EXPANDED_STRING_ARRAY_LITERAL_START:
case QUOTED_EXPANDED_STRING_ARRAY_LITERAL_START:
case HERE_DOC:
case QUOTED_NON_EXPANDED_SYMBOL_ARRAY_LITERAL_START:
case QUOTED_EXPANDED_SYMBOL_ARRAY_LITERAL_START:
case DECIMAL_INTEGER_LITERAL:
case BINARY_INTEGER_LITERAL:
case OCTAL_INTEGER_LITERAL:
case HEXADECIMAL_INTEGER_LITERAL:
case FLOAT_LITERAL_WITHOUT_EXPONENT:
case FLOAT_LITERAL_WITH_EXPONENT:
case SYMBOL_LITERAL:
case LOCAL_VARIABLE_IDENTIFIER:
case LINE__:
case ENCODING__:
case FILE__:
case BEGIN:
case BREAK:
case CASE:
case CLASS:
case DEF:
case IS_DEFINED:
case FOR:
case FALSE:
case IF:
case MODULE:
case NEXT:
case NIL:
case REDO:
case RETRY:
case RETURN:
case SELF:
case SUPER:
case TRUE:
case UNLESS:
case UNTIL:
case WHILE:
case YIELD:
case GLOBAL_VARIABLE_IDENTIFIER:
case INSTANCE_VARIABLE_IDENTIFIER:
case CLASS_VARIABLE_IDENTIFIER:
case CONSTANT_IDENTIFIER:
{
setState(523);
operatorExpressionList();
}
break;
case STAR:
case STAR2:
{
setState(524);
splattingRightHandSide();
}
break;
default:
throw new NoViableAltException(this);
}
setState(534);
_errHandler.sync(this);
_alt = getInterpreter().adaptivePredict(_input,48,_ctx);
while ( _alt!=2 && _alt!=org.antlr.v4.runtime.atn.ATN.INVALID_ALT_NUMBER ) {
if ( _alt==1 ) {
{
{
setState(527);
match(COMMA);
setState(530);
_errHandler.sync(this);
switch (_input.LA(1)) {
case REGULAR_EXPRESSION_START:
case LBRACK:
case LPAREN:
case LCURLY:
case COLON:
case COLON2:
case DOT2:
case DOT3:
case MINUSGT:
case EMARK:
case PLUS:
case MINUS:
case TILDE:
case SINGLE_QUOTED_STRING_LITERAL:
case DOUBLE_QUOTED_STRING_START:
case QUOTED_NON_EXPANDED_STRING_LITERAL_START:
case QUOTED_EXPANDED_STRING_LITERAL_START:
case QUOTED_EXPANDED_REGULAR_EXPRESSION_START:
case QUOTED_EXPANDED_EXTERNAL_COMMAND_LITERAL_START:
case QUOTED_NON_EXPANDED_STRING_ARRAY_LITERAL_START:
case QUOTED_EXPANDED_STRING_ARRAY_LITERAL_START:
case HERE_DOC:
case QUOTED_NON_EXPANDED_SYMBOL_ARRAY_LITERAL_START:
case QUOTED_EXPANDED_SYMBOL_ARRAY_LITERAL_START:
case DECIMAL_INTEGER_LITERAL:
case BINARY_INTEGER_LITERAL:
case OCTAL_INTEGER_LITERAL:
case HEXADECIMAL_INTEGER_LITERAL:
case FLOAT_LITERAL_WITHOUT_EXPONENT:
case FLOAT_LITERAL_WITH_EXPONENT:
case SYMBOL_LITERAL:
case LOCAL_VARIABLE_IDENTIFIER:
case LINE__:
case ENCODING__:
case FILE__:
case BEGIN:
case BREAK:
case CASE:
case CLASS:
case DEF:
case IS_DEFINED:
case FOR:
case FALSE:
case IF:
case MODULE:
case NEXT:
case NIL:
case REDO:
case RETRY:
case RETURN:
case SELF:
case SUPER:
case TRUE:
case UNLESS:
case UNTIL:
case WHILE:
case YIELD:
case GLOBAL_VARIABLE_IDENTIFIER:
case INSTANCE_VARIABLE_IDENTIFIER:
case CLASS_VARIABLE_IDENTIFIER:
case CONSTANT_IDENTIFIER:
{
setState(528);
operatorExpressionList();
}
break;
case STAR:
case STAR2:
{
setState(529);
splattingRightHandSide();
}
break;
default:
throw new NoViableAltException(this);
}
}
}
}
setState(536);
_errHandler.sync(this);
_alt = getInterpreter().adaptivePredict(_input,48,_ctx);
}
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class SplattingRightHandSideContext extends ParserRuleContext {
public SplattingArgumentContext splattingArgument() {
return getRuleContext(SplattingArgumentContext.class,0);
}
public SplattingRightHandSideContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_splattingRightHandSide; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).enterSplattingRightHandSide(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).exitSplattingRightHandSide(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof RubyParserVisitor ) return ((RubyParserVisitor extends T>)visitor).visitSplattingRightHandSide(this);
else return visitor.visitChildren(this);
}
}
public final SplattingRightHandSideContext splattingRightHandSide() throws RecognitionException {
SplattingRightHandSideContext _localctx = new SplattingRightHandSideContext(_ctx, getState());
enterRule(_localctx, 28, RULE_splattingRightHandSide);
try {
enterOuterAlt(_localctx, 1);
{
setState(537);
splattingArgument();
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class MethodIdentifierContext extends ParserRuleContext {
public TerminalNode LOCAL_VARIABLE_IDENTIFIER() { return getToken(RubyParser.LOCAL_VARIABLE_IDENTIFIER, 0); }
public TerminalNode CONSTANT_IDENTIFIER() { return getToken(RubyParser.CONSTANT_IDENTIFIER, 0); }
public MethodOnlyIdentifierContext methodOnlyIdentifier() {
return getRuleContext(MethodOnlyIdentifierContext.class,0);
}
public MethodIdentifierContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_methodIdentifier; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).enterMethodIdentifier(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).exitMethodIdentifier(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof RubyParserVisitor ) return ((RubyParserVisitor extends T>)visitor).visitMethodIdentifier(this);
else return visitor.visitChildren(this);
}
}
public final MethodIdentifierContext methodIdentifier() throws RecognitionException {
MethodIdentifierContext _localctx = new MethodIdentifierContext(_ctx, getState());
enterRule(_localctx, 30, RULE_methodIdentifier);
try {
setState(542);
_errHandler.sync(this);
switch ( getInterpreter().adaptivePredict(_input,49,_ctx) ) {
case 1:
enterOuterAlt(_localctx, 1);
{
setState(539);
match(LOCAL_VARIABLE_IDENTIFIER);
}
break;
case 2:
enterOuterAlt(_localctx, 2);
{
setState(540);
match(CONSTANT_IDENTIFIER);
}
break;
case 3:
enterOuterAlt(_localctx, 3);
{
setState(541);
methodOnlyIdentifier();
}
break;
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class MethodNameContext extends ParserRuleContext {
public MethodIdentifierContext methodIdentifier() {
return getRuleContext(MethodIdentifierContext.class,0);
}
public KeywordContext keyword() {
return getRuleContext(KeywordContext.class,0);
}
public PseudoVariableContext pseudoVariable() {
return getRuleContext(PseudoVariableContext.class,0);
}
public MethodNameContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_methodName; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).enterMethodName(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).exitMethodName(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof RubyParserVisitor ) return ((RubyParserVisitor extends T>)visitor).visitMethodName(this);
else return visitor.visitChildren(this);
}
}
public final MethodNameContext methodName() throws RecognitionException {
MethodNameContext _localctx = new MethodNameContext(_ctx, getState());
enterRule(_localctx, 32, RULE_methodName);
try {
setState(547);
_errHandler.sync(this);
switch ( getInterpreter().adaptivePredict(_input,50,_ctx) ) {
case 1:
enterOuterAlt(_localctx, 1);
{
setState(544);
methodIdentifier();
}
break;
case 2:
enterOuterAlt(_localctx, 2);
{
setState(545);
keyword();
}
break;
case 3:
enterOuterAlt(_localctx, 3);
{
setState(546);
pseudoVariable();
}
break;
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class MethodOnlyIdentifierContext extends ParserRuleContext {
public TerminalNode EMARK() { return getToken(RubyParser.EMARK, 0); }
public TerminalNode QMARK() { return getToken(RubyParser.QMARK, 0); }
public TerminalNode EQ() { return getToken(RubyParser.EQ, 0); }
public TerminalNode CONSTANT_IDENTIFIER() { return getToken(RubyParser.CONSTANT_IDENTIFIER, 0); }
public TerminalNode LOCAL_VARIABLE_IDENTIFIER() { return getToken(RubyParser.LOCAL_VARIABLE_IDENTIFIER, 0); }
public PseudoVariableContext pseudoVariable() {
return getRuleContext(PseudoVariableContext.class,0);
}
public MethodOnlyIdentifierContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_methodOnlyIdentifier; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).enterMethodOnlyIdentifier(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).exitMethodOnlyIdentifier(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof RubyParserVisitor ) return ((RubyParserVisitor extends T>)visitor).visitMethodOnlyIdentifier(this);
else return visitor.visitChildren(this);
}
}
public final MethodOnlyIdentifierContext methodOnlyIdentifier() throws RecognitionException {
MethodOnlyIdentifierContext _localctx = new MethodOnlyIdentifierContext(_ctx, getState());
enterRule(_localctx, 34, RULE_methodOnlyIdentifier);
int _la;
try {
enterOuterAlt(_localctx, 1);
{
setState(552);
_errHandler.sync(this);
switch (_input.LA(1)) {
case CONSTANT_IDENTIFIER:
{
setState(549);
match(CONSTANT_IDENTIFIER);
}
break;
case LOCAL_VARIABLE_IDENTIFIER:
{
setState(550);
match(LOCAL_VARIABLE_IDENTIFIER);
}
break;
case LINE__:
case ENCODING__:
case FILE__:
case FALSE:
case NIL:
case SELF:
case TRUE:
{
setState(551);
pseudoVariable();
}
break;
default:
throw new NoViableAltException(this);
}
setState(554);
_la = _input.LA(1);
if ( !((((_la) & ~0x3f) == 0 && ((1L << _la) & ((1L << QMARK) | (1L << EMARK) | (1L << EQ))) != 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 static class MethodInvocationWithoutParenthesesContext extends ParserRuleContext {
public MethodInvocationWithoutParenthesesContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_methodInvocationWithoutParentheses; }
public MethodInvocationWithoutParenthesesContext() { }
public void copyFrom(MethodInvocationWithoutParenthesesContext ctx) {
super.copyFrom(ctx);
}
}
public static class NextMethodInvocationWithoutParenthesesContext extends MethodInvocationWithoutParenthesesContext {
public TerminalNode NEXT() { return getToken(RubyParser.NEXT, 0); }
public PrimaryValueListContext primaryValueList() {
return getRuleContext(PrimaryValueListContext.class,0);
}
public NextMethodInvocationWithoutParenthesesContext(MethodInvocationWithoutParenthesesContext ctx) { copyFrom(ctx); }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).enterNextMethodInvocationWithoutParentheses(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).exitNextMethodInvocationWithoutParentheses(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof RubyParserVisitor ) return ((RubyParserVisitor extends T>)visitor).visitNextMethodInvocationWithoutParentheses(this);
else return visitor.visitChildren(this);
}
}
public static class ChainedMethodInvocationWithoutParenthesesContext extends MethodInvocationWithoutParenthesesContext {
public ChainedCommandWithDoBlockContext chainedCommandWithDoBlock() {
return getRuleContext(ChainedCommandWithDoBlockContext.class,0);
}
public MethodNameContext methodName() {
return getRuleContext(MethodNameContext.class,0);
}
public CommandArgumentListContext commandArgumentList() {
return getRuleContext(CommandArgumentListContext.class,0);
}
public TerminalNode DOT() { return getToken(RubyParser.DOT, 0); }
public TerminalNode COLON2() { return getToken(RubyParser.COLON2, 0); }
public ChainedMethodInvocationWithoutParenthesesContext(MethodInvocationWithoutParenthesesContext ctx) { copyFrom(ctx); }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).enterChainedMethodInvocationWithoutParentheses(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).exitChainedMethodInvocationWithoutParentheses(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof RubyParserVisitor ) return ((RubyParserVisitor extends T>)visitor).visitChainedMethodInvocationWithoutParentheses(this);
else return visitor.visitChildren(this);
}
}
public static class ReturnMethodInvocationWithoutParenthesesContext extends MethodInvocationWithoutParenthesesContext {
public TerminalNode RETURN() { return getToken(RubyParser.RETURN, 0); }
public PrimaryValueListWithAssociationContext primaryValueListWithAssociation() {
return getRuleContext(PrimaryValueListWithAssociationContext.class,0);
}
public ReturnMethodInvocationWithoutParenthesesContext(MethodInvocationWithoutParenthesesContext ctx) { copyFrom(ctx); }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).enterReturnMethodInvocationWithoutParentheses(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).exitReturnMethodInvocationWithoutParentheses(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof RubyParserVisitor ) return ((RubyParserVisitor extends T>)visitor).visitReturnMethodInvocationWithoutParentheses(this);
else return visitor.visitChildren(this);
}
}
public static class YieldMethodInvocationWithoutParenthesesContext extends MethodInvocationWithoutParenthesesContext {
public TerminalNode YIELD() { return getToken(RubyParser.YIELD, 0); }
public PrimaryValueListWithAssociationContext primaryValueListWithAssociation() {
return getRuleContext(PrimaryValueListWithAssociationContext.class,0);
}
public YieldMethodInvocationWithoutParenthesesContext(MethodInvocationWithoutParenthesesContext ctx) { copyFrom(ctx); }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).enterYieldMethodInvocationWithoutParentheses(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).exitYieldMethodInvocationWithoutParentheses(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof RubyParserVisitor ) return ((RubyParserVisitor extends T>)visitor).visitYieldMethodInvocationWithoutParentheses(this);
else return visitor.visitChildren(this);
}
}
public static class BreakMethodInvocationWithoutParenthesesContext extends MethodInvocationWithoutParenthesesContext {
public TerminalNode BREAK() { return getToken(RubyParser.BREAK, 0); }
public PrimaryValueListContext primaryValueList() {
return getRuleContext(PrimaryValueListContext.class,0);
}
public BreakMethodInvocationWithoutParenthesesContext(MethodInvocationWithoutParenthesesContext ctx) { copyFrom(ctx); }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).enterBreakMethodInvocationWithoutParentheses(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).exitBreakMethodInvocationWithoutParentheses(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof RubyParserVisitor ) return ((RubyParserVisitor extends T>)visitor).visitBreakMethodInvocationWithoutParentheses(this);
else return visitor.visitChildren(this);
}
}
public static class CommandMethodInvocationWithoutParenthesesContext extends MethodInvocationWithoutParenthesesContext {
public CommandContext command() {
return getRuleContext(CommandContext.class,0);
}
public CommandMethodInvocationWithoutParenthesesContext(MethodInvocationWithoutParenthesesContext ctx) { copyFrom(ctx); }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).enterCommandMethodInvocationWithoutParentheses(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).exitCommandMethodInvocationWithoutParentheses(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof RubyParserVisitor ) return ((RubyParserVisitor extends T>)visitor).visitCommandMethodInvocationWithoutParentheses(this);
else return visitor.visitChildren(this);
}
}
public final MethodInvocationWithoutParenthesesContext methodInvocationWithoutParentheses() throws RecognitionException {
MethodInvocationWithoutParenthesesContext _localctx = new MethodInvocationWithoutParenthesesContext(_ctx, getState());
enterRule(_localctx, 36, RULE_methodInvocationWithoutParentheses);
int _la;
try {
setState(572);
_errHandler.sync(this);
switch ( getInterpreter().adaptivePredict(_input,53,_ctx) ) {
case 1:
_localctx = new CommandMethodInvocationWithoutParenthesesContext(_localctx);
enterOuterAlt(_localctx, 1);
{
setState(556);
command();
}
break;
case 2:
_localctx = new ChainedMethodInvocationWithoutParenthesesContext(_localctx);
enterOuterAlt(_localctx, 2);
{
setState(557);
chainedCommandWithDoBlock();
setState(562);
_errHandler.sync(this);
switch ( getInterpreter().adaptivePredict(_input,52,_ctx) ) {
case 1:
{
setState(558);
_la = _input.LA(1);
if ( !(_la==COLON2 || _la==DOT) ) {
_errHandler.recoverInline(this);
}
else {
if ( _input.LA(1)==Token.EOF ) matchedEOF = true;
_errHandler.reportMatch(this);
consume();
}
setState(559);
methodName();
setState(560);
commandArgumentList();
}
break;
}
}
break;
case 3:
_localctx = new ReturnMethodInvocationWithoutParenthesesContext(_localctx);
enterOuterAlt(_localctx, 3);
{
setState(564);
match(RETURN);
setState(565);
primaryValueListWithAssociation();
}
break;
case 4:
_localctx = new BreakMethodInvocationWithoutParenthesesContext(_localctx);
enterOuterAlt(_localctx, 4);
{
setState(566);
match(BREAK);
setState(567);
primaryValueList();
}
break;
case 5:
_localctx = new NextMethodInvocationWithoutParenthesesContext(_localctx);
enterOuterAlt(_localctx, 5);
{
setState(568);
match(NEXT);
setState(569);
primaryValueList();
}
break;
case 6:
_localctx = new YieldMethodInvocationWithoutParenthesesContext(_localctx);
enterOuterAlt(_localctx, 6);
{
setState(570);
match(YIELD);
setState(571);
primaryValueListWithAssociation();
}
break;
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class CommandContext extends ParserRuleContext {
public CommandContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_command; }
public CommandContext() { }
public void copyFrom(CommandContext ctx) {
super.copyFrom(ctx);
}
}
public static class MemberAccessCommandContext extends CommandContext {
public PrimaryContext primary() {
return getRuleContext(PrimaryContext.class,0);
}
public MethodNameContext methodName() {
return getRuleContext(MethodNameContext.class,0);
}
public CommandArgumentContext commandArgument() {
return getRuleContext(CommandArgumentContext.class,0);
}
public TerminalNode AMPDOT() { return getToken(RubyParser.AMPDOT, 0); }
public TerminalNode DOT() { return getToken(RubyParser.DOT, 0); }
public TerminalNode COLON2() { return getToken(RubyParser.COLON2, 0); }
public TerminalNode NL() { return getToken(RubyParser.NL, 0); }
public MemberAccessCommandContext(CommandContext ctx) { copyFrom(ctx); }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).enterMemberAccessCommand(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).exitMemberAccessCommand(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof RubyParserVisitor ) return ((RubyParserVisitor extends T>)visitor).visitMemberAccessCommand(this);
else return visitor.visitChildren(this);
}
}
public static class CommandTernaryOperatorExpressionContext extends CommandContext {
public List operatorExpression() {
return getRuleContexts(OperatorExpressionContext.class);
}
public OperatorExpressionContext operatorExpression(int i) {
return getRuleContext(OperatorExpressionContext.class,i);
}
public TerminalNode QMARK() { return getToken(RubyParser.QMARK, 0); }
public TerminalNode COLON() { return getToken(RubyParser.COLON, 0); }
public List NL() { return getTokens(RubyParser.NL); }
public TerminalNode NL(int i) {
return getToken(RubyParser.NL, i);
}
public CommandTernaryOperatorExpressionContext(CommandContext ctx) { copyFrom(ctx); }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).enterCommandTernaryOperatorExpression(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).exitCommandTernaryOperatorExpression(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof RubyParserVisitor ) return ((RubyParserVisitor extends T>)visitor).visitCommandTernaryOperatorExpression(this);
else return visitor.visitChildren(this);
}
}
public static class SimpleCommandContext extends CommandContext {
public MethodIdentifierContext methodIdentifier() {
return getRuleContext(MethodIdentifierContext.class,0);
}
public CommandArgumentContext commandArgument() {
return getRuleContext(CommandArgumentContext.class,0);
}
public SimpleCommandContext(CommandContext ctx) { copyFrom(ctx); }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).enterSimpleCommand(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).exitSimpleCommand(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof RubyParserVisitor ) return ((RubyParserVisitor extends T>)visitor).visitSimpleCommand(this);
else return visitor.visitChildren(this);
}
}
public final CommandContext command() throws RecognitionException {
CommandContext _localctx = new CommandContext(_ctx, getState());
enterRule(_localctx, 38, RULE_command);
int _la;
try {
setState(609);
_errHandler.sync(this);
switch ( getInterpreter().adaptivePredict(_input,58,_ctx) ) {
case 1:
_localctx = new CommandTernaryOperatorExpressionContext(_localctx);
enterOuterAlt(_localctx, 1);
{
setState(574);
operatorExpression(0);
setState(575);
match(QMARK);
setState(579);
_errHandler.sync(this);
_la = _input.LA(1);
while (_la==NL) {
{
{
setState(576);
match(NL);
}
}
setState(581);
_errHandler.sync(this);
_la = _input.LA(1);
}
setState(582);
operatorExpression(0);
setState(586);
_errHandler.sync(this);
_la = _input.LA(1);
while (_la==NL) {
{
{
setState(583);
match(NL);
}
}
setState(588);
_errHandler.sync(this);
_la = _input.LA(1);
}
setState(589);
match(COLON);
setState(593);
_errHandler.sync(this);
_la = _input.LA(1);
while (_la==NL) {
{
{
setState(590);
match(NL);
}
}
setState(595);
_errHandler.sync(this);
_la = _input.LA(1);
}
setState(596);
operatorExpression(0);
}
break;
case 2:
_localctx = new MemberAccessCommandContext(_localctx);
enterOuterAlt(_localctx, 2);
{
setState(598);
primary();
setState(600);
_errHandler.sync(this);
_la = _input.LA(1);
if (_la==NL) {
{
setState(599);
match(NL);
}
}
setState(602);
_la = _input.LA(1);
if ( !((((_la) & ~0x3f) == 0 && ((1L << _la) & ((1L << COLON2) | (1L << DOT) | (1L << AMPDOT))) != 0)) ) {
_errHandler.recoverInline(this);
}
else {
if ( _input.LA(1)==Token.EOF ) matchedEOF = true;
_errHandler.reportMatch(this);
consume();
}
setState(603);
methodName();
setState(604);
commandArgument();
}
break;
case 3:
_localctx = new SimpleCommandContext(_localctx);
enterOuterAlt(_localctx, 3);
{
setState(606);
methodIdentifier();
setState(607);
commandArgument();
}
break;
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class CommandArgumentContext extends ParserRuleContext {
public CommandArgumentContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_commandArgument; }
public CommandArgumentContext() { }
public void copyFrom(CommandArgumentContext ctx) {
super.copyFrom(ctx);
}
}
public static class CommandCommandArgumentListContext extends CommandArgumentContext {
public CommandContext command() {
return getRuleContext(CommandContext.class,0);
}
public CommandCommandArgumentListContext(CommandArgumentContext ctx) { copyFrom(ctx); }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).enterCommandCommandArgumentList(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).exitCommandCommandArgumentList(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof RubyParserVisitor ) return ((RubyParserVisitor extends T>)visitor).visitCommandCommandArgumentList(this);
else return visitor.visitChildren(this);
}
}
public static class CommandArgumentCommandArgumentListContext extends CommandArgumentContext {
public CommandArgumentListContext commandArgumentList() {
return getRuleContext(CommandArgumentListContext.class,0);
}
public CommandArgumentCommandArgumentListContext(CommandArgumentContext ctx) { copyFrom(ctx); }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).enterCommandArgumentCommandArgumentList(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).exitCommandArgumentCommandArgumentList(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof RubyParserVisitor ) return ((RubyParserVisitor extends T>)visitor).visitCommandArgumentCommandArgumentList(this);
else return visitor.visitChildren(this);
}
}
public final CommandArgumentContext commandArgument() throws RecognitionException {
CommandArgumentContext _localctx = new CommandArgumentContext(_ctx, getState());
enterRule(_localctx, 40, RULE_commandArgument);
try {
setState(613);
_errHandler.sync(this);
switch ( getInterpreter().adaptivePredict(_input,59,_ctx) ) {
case 1:
_localctx = new CommandArgumentCommandArgumentListContext(_localctx);
enterOuterAlt(_localctx, 1);
{
setState(611);
commandArgumentList();
}
break;
case 2:
_localctx = new CommandCommandArgumentListContext(_localctx);
enterOuterAlt(_localctx, 2);
{
setState(612);
command();
}
break;
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class ChainedCommandWithDoBlockContext extends ParserRuleContext {
public CommandWithDoBlockContext commandWithDoBlock() {
return getRuleContext(CommandWithDoBlockContext.class,0);
}
public List chainedMethodInvocation() {
return getRuleContexts(ChainedMethodInvocationContext.class);
}
public ChainedMethodInvocationContext chainedMethodInvocation(int i) {
return getRuleContext(ChainedMethodInvocationContext.class,i);
}
public ChainedCommandWithDoBlockContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_chainedCommandWithDoBlock; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).enterChainedCommandWithDoBlock(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).exitChainedCommandWithDoBlock(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof RubyParserVisitor ) return ((RubyParserVisitor extends T>)visitor).visitChainedCommandWithDoBlock(this);
else return visitor.visitChildren(this);
}
}
public final ChainedCommandWithDoBlockContext chainedCommandWithDoBlock() throws RecognitionException {
ChainedCommandWithDoBlockContext _localctx = new ChainedCommandWithDoBlockContext(_ctx, getState());
enterRule(_localctx, 42, RULE_chainedCommandWithDoBlock);
try {
int _alt;
enterOuterAlt(_localctx, 1);
{
setState(615);
commandWithDoBlock();
setState(619);
_errHandler.sync(this);
_alt = getInterpreter().adaptivePredict(_input,60,_ctx);
while ( _alt!=2 && _alt!=org.antlr.v4.runtime.atn.ATN.INVALID_ALT_NUMBER ) {
if ( _alt==1 ) {
{
{
setState(616);
chainedMethodInvocation();
}
}
}
setState(621);
_errHandler.sync(this);
_alt = getInterpreter().adaptivePredict(_input,60,_ctx);
}
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class ChainedMethodInvocationContext extends ParserRuleContext {
public MethodNameContext methodName() {
return getRuleContext(MethodNameContext.class,0);
}
public TerminalNode DOT() { return getToken(RubyParser.DOT, 0); }
public TerminalNode COLON2() { return getToken(RubyParser.COLON2, 0); }
public ArgumentWithParenthesesContext argumentWithParentheses() {
return getRuleContext(ArgumentWithParenthesesContext.class,0);
}
public ChainedMethodInvocationContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_chainedMethodInvocation; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).enterChainedMethodInvocation(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).exitChainedMethodInvocation(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof RubyParserVisitor ) return ((RubyParserVisitor extends T>)visitor).visitChainedMethodInvocation(this);
else return visitor.visitChildren(this);
}
}
public final ChainedMethodInvocationContext chainedMethodInvocation() throws RecognitionException {
ChainedMethodInvocationContext _localctx = new ChainedMethodInvocationContext(_ctx, getState());
enterRule(_localctx, 44, RULE_chainedMethodInvocation);
int _la;
try {
enterOuterAlt(_localctx, 1);
{
setState(622);
_la = _input.LA(1);
if ( !(_la==COLON2 || _la==DOT) ) {
_errHandler.recoverInline(this);
}
else {
if ( _input.LA(1)==Token.EOF ) matchedEOF = true;
_errHandler.reportMatch(this);
consume();
}
setState(623);
methodName();
setState(625);
_errHandler.sync(this);
switch ( getInterpreter().adaptivePredict(_input,61,_ctx) ) {
case 1:
{
setState(624);
argumentWithParentheses();
}
break;
}
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class CommandWithDoBlockContext extends ParserRuleContext {
public TerminalNode SUPER() { return getToken(RubyParser.SUPER, 0); }
public ArgumentListContext argumentList() {
return getRuleContext(ArgumentListContext.class,0);
}
public DoBlockContext doBlock() {
return getRuleContext(DoBlockContext.class,0);
}
public MethodIdentifierContext methodIdentifier() {
return getRuleContext(MethodIdentifierContext.class,0);
}
public PrimaryContext primary() {
return getRuleContext(PrimaryContext.class,0);
}
public MethodNameContext methodName() {
return getRuleContext(MethodNameContext.class,0);
}
public TerminalNode DOT() { return getToken(RubyParser.DOT, 0); }
public TerminalNode COLON2() { return getToken(RubyParser.COLON2, 0); }
public CommandWithDoBlockContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_commandWithDoBlock; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).enterCommandWithDoBlock(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).exitCommandWithDoBlock(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof RubyParserVisitor ) return ((RubyParserVisitor extends T>)visitor).visitCommandWithDoBlock(this);
else return visitor.visitChildren(this);
}
}
public final CommandWithDoBlockContext commandWithDoBlock() throws RecognitionException {
CommandWithDoBlockContext _localctx = new CommandWithDoBlockContext(_ctx, getState());
enterRule(_localctx, 46, RULE_commandWithDoBlock);
int _la;
try {
setState(641);
_errHandler.sync(this);
switch ( getInterpreter().adaptivePredict(_input,62,_ctx) ) {
case 1:
enterOuterAlt(_localctx, 1);
{
setState(627);
match(SUPER);
setState(628);
argumentList();
setState(629);
doBlock();
}
break;
case 2:
enterOuterAlt(_localctx, 2);
{
setState(631);
methodIdentifier();
setState(632);
argumentList();
setState(633);
doBlock();
}
break;
case 3:
enterOuterAlt(_localctx, 3);
{
setState(635);
primary();
setState(636);
_la = _input.LA(1);
if ( !(_la==COLON2 || _la==DOT) ) {
_errHandler.recoverInline(this);
}
else {
if ( _input.LA(1)==Token.EOF ) matchedEOF = true;
_errHandler.reportMatch(this);
consume();
}
setState(637);
methodName();
setState(638);
argumentList();
setState(639);
doBlock();
}
break;
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class BracketedArrayElementListContext extends ParserRuleContext {
public List bracketedArrayElement() {
return getRuleContexts(BracketedArrayElementContext.class);
}
public BracketedArrayElementContext bracketedArrayElement(int i) {
return getRuleContext(BracketedArrayElementContext.class,i);
}
public List COMMA() { return getTokens(RubyParser.COMMA); }
public TerminalNode COMMA(int i) {
return getToken(RubyParser.COMMA, i);
}
public List NL() { return getTokens(RubyParser.NL); }
public TerminalNode NL(int i) {
return getToken(RubyParser.NL, i);
}
public BracketedArrayElementListContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_bracketedArrayElementList; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).enterBracketedArrayElementList(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).exitBracketedArrayElementList(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof RubyParserVisitor ) return ((RubyParserVisitor extends T>)visitor).visitBracketedArrayElementList(this);
else return visitor.visitChildren(this);
}
}
public final BracketedArrayElementListContext bracketedArrayElementList() throws RecognitionException {
BracketedArrayElementListContext _localctx = new BracketedArrayElementListContext(_ctx, getState());
enterRule(_localctx, 48, RULE_bracketedArrayElementList);
int _la;
try {
int _alt;
enterOuterAlt(_localctx, 1);
{
setState(643);
bracketedArrayElement();
setState(656);
_errHandler.sync(this);
_alt = getInterpreter().adaptivePredict(_input,65,_ctx);
while ( _alt!=2 && _alt!=org.antlr.v4.runtime.atn.ATN.INVALID_ALT_NUMBER ) {
if ( _alt==1 ) {
{
{
setState(645);
_errHandler.sync(this);
_la = _input.LA(1);
if (_la==COMMA) {
{
setState(644);
match(COMMA);
}
}
setState(650);
_errHandler.sync(this);
_la = _input.LA(1);
while (_la==NL) {
{
{
setState(647);
match(NL);
}
}
setState(652);
_errHandler.sync(this);
_la = _input.LA(1);
}
setState(653);
bracketedArrayElement();
}
}
}
setState(658);
_errHandler.sync(this);
_alt = getInterpreter().adaptivePredict(_input,65,_ctx);
}
setState(660);
_errHandler.sync(this);
_la = _input.LA(1);
if (_la==COMMA) {
{
setState(659);
match(COMMA);
}
}
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class BracketedArrayElementContext extends ParserRuleContext {
public IndexingArgumentContext indexingArgument() {
return getRuleContext(IndexingArgumentContext.class,0);
}
public CommandContext command() {
return getRuleContext(CommandContext.class,0);
}
public HashLiteralContext hashLiteral() {
return getRuleContext(HashLiteralContext.class,0);
}
public SplattingArgumentContext splattingArgument() {
return getRuleContext(SplattingArgumentContext.class,0);
}
public IndexingArgumentListContext indexingArgumentList() {
return getRuleContext(IndexingArgumentListContext.class,0);
}
public BracketedArrayElementContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_bracketedArrayElement; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).enterBracketedArrayElement(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).exitBracketedArrayElement(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof RubyParserVisitor ) return ((RubyParserVisitor extends T>)visitor).visitBracketedArrayElement(this);
else return visitor.visitChildren(this);
}
}
public final BracketedArrayElementContext bracketedArrayElement() throws RecognitionException {
BracketedArrayElementContext _localctx = new BracketedArrayElementContext(_ctx, getState());
enterRule(_localctx, 50, RULE_bracketedArrayElement);
try {
setState(667);
_errHandler.sync(this);
switch ( getInterpreter().adaptivePredict(_input,67,_ctx) ) {
case 1:
enterOuterAlt(_localctx, 1);
{
setState(662);
indexingArgument();
}
break;
case 2:
enterOuterAlt(_localctx, 2);
{
setState(663);
command();
}
break;
case 3:
enterOuterAlt(_localctx, 3);
{
setState(664);
hashLiteral();
}
break;
case 4:
enterOuterAlt(_localctx, 4);
{
setState(665);
splattingArgument();
}
break;
case 5:
enterOuterAlt(_localctx, 5);
{
setState(666);
indexingArgumentList();
}
break;
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class IndexingArgumentListContext extends ParserRuleContext {
public IndexingArgumentListContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_indexingArgumentList; }
public IndexingArgumentListContext() { }
public void copyFrom(IndexingArgumentListContext ctx) {
super.copyFrom(ctx);
}
}
public static class OperatorExpressionListWithSplattingArgumentIndexingArgumentListContext extends IndexingArgumentListContext {
public OperatorExpressionListContext operatorExpressionList() {
return getRuleContext(OperatorExpressionListContext.class,0);
}
public TerminalNode COMMA() { return getToken(RubyParser.COMMA, 0); }
public SplattingArgumentContext splattingArgument() {
return getRuleContext(SplattingArgumentContext.class,0);
}
public OperatorExpressionListWithSplattingArgumentIndexingArgumentListContext(IndexingArgumentListContext ctx) { copyFrom(ctx); }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).enterOperatorExpressionListWithSplattingArgumentIndexingArgumentList(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).exitOperatorExpressionListWithSplattingArgumentIndexingArgumentList(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof RubyParserVisitor ) return ((RubyParserVisitor extends T>)visitor).visitOperatorExpressionListWithSplattingArgumentIndexingArgumentList(this);
else return visitor.visitChildren(this);
}
}
public static class IndexingArgumentIndexingArgumentListContext extends IndexingArgumentListContext {
public List indexingArgument() {
return getRuleContexts(IndexingArgumentContext.class);
}
public IndexingArgumentContext indexingArgument(int i) {
return getRuleContext(IndexingArgumentContext.class,i);
}
public List COMMA() { return getTokens(RubyParser.COMMA); }
public TerminalNode COMMA(int i) {
return getToken(RubyParser.COMMA, i);
}
public List NL() { return getTokens(RubyParser.NL); }
public TerminalNode NL(int i) {
return getToken(RubyParser.NL, i);
}
public IndexingArgumentIndexingArgumentListContext(IndexingArgumentListContext ctx) { copyFrom(ctx); }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).enterIndexingArgumentIndexingArgumentList(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).exitIndexingArgumentIndexingArgumentList(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof RubyParserVisitor ) return ((RubyParserVisitor extends T>)visitor).visitIndexingArgumentIndexingArgumentList(this);
else return visitor.visitChildren(this);
}
}
public static class SplattingArgumentIndexingArgumentListContext extends IndexingArgumentListContext {
public List splattingArgument() {
return getRuleContexts(SplattingArgumentContext.class);
}
public SplattingArgumentContext splattingArgument(int i) {
return getRuleContext(SplattingArgumentContext.class,i);
}
public List COMMA() { return getTokens(RubyParser.COMMA); }
public TerminalNode COMMA(int i) {
return getToken(RubyParser.COMMA, i);
}
public List NL() { return getTokens(RubyParser.NL); }
public TerminalNode NL(int i) {
return getToken(RubyParser.NL, i);
}
public SplattingArgumentIndexingArgumentListContext(IndexingArgumentListContext ctx) { copyFrom(ctx); }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).enterSplattingArgumentIndexingArgumentList(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).exitSplattingArgumentIndexingArgumentList(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof RubyParserVisitor ) return ((RubyParserVisitor extends T>)visitor).visitSplattingArgumentIndexingArgumentList(this);
else return visitor.visitChildren(this);
}
}
public static class OperatorExpressionListIndexingArgumentListContext extends IndexingArgumentListContext {
public OperatorExpressionListContext operatorExpressionList() {
return getRuleContext(OperatorExpressionListContext.class,0);
}
public TerminalNode COMMA() { return getToken(RubyParser.COMMA, 0); }
public OperatorExpressionListIndexingArgumentListContext(IndexingArgumentListContext ctx) { copyFrom(ctx); }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).enterOperatorExpressionListIndexingArgumentList(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).exitOperatorExpressionListIndexingArgumentList(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof RubyParserVisitor ) return ((RubyParserVisitor extends T>)visitor).visitOperatorExpressionListIndexingArgumentList(this);
else return visitor.visitChildren(this);
}
}
public static class AssociationListIndexingArgumentListContext extends IndexingArgumentListContext {
public AssociationListContext associationList() {
return getRuleContext(AssociationListContext.class,0);
}
public TerminalNode COMMA() { return getToken(RubyParser.COMMA, 0); }
public AssociationListIndexingArgumentListContext(IndexingArgumentListContext ctx) { copyFrom(ctx); }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).enterAssociationListIndexingArgumentList(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).exitAssociationListIndexingArgumentList(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof RubyParserVisitor ) return ((RubyParserVisitor extends T>)visitor).visitAssociationListIndexingArgumentList(this);
else return visitor.visitChildren(this);
}
}
public final IndexingArgumentListContext indexingArgumentList() throws RecognitionException {
IndexingArgumentListContext _localctx = new IndexingArgumentListContext(_ctx, getState());
enterRule(_localctx, 52, RULE_indexingArgumentList);
int _la;
try {
int _alt;
setState(711);
_errHandler.sync(this);
switch ( getInterpreter().adaptivePredict(_input,75,_ctx) ) {
case 1:
_localctx = new OperatorExpressionListIndexingArgumentListContext(_localctx);
enterOuterAlt(_localctx, 1);
{
setState(669);
operatorExpressionList();
setState(671);
_errHandler.sync(this);
switch ( getInterpreter().adaptivePredict(_input,68,_ctx) ) {
case 1:
{
setState(670);
match(COMMA);
}
break;
}
}
break;
case 2:
_localctx = new OperatorExpressionListWithSplattingArgumentIndexingArgumentListContext(_localctx);
enterOuterAlt(_localctx, 2);
{
setState(673);
operatorExpressionList();
setState(674);
match(COMMA);
setState(675);
splattingArgument();
}
break;
case 3:
_localctx = new IndexingArgumentIndexingArgumentListContext(_localctx);
enterOuterAlt(_localctx, 3);
{
setState(677);
indexingArgument();
setState(690);
_errHandler.sync(this);
_alt = getInterpreter().adaptivePredict(_input,71,_ctx);
while ( _alt!=2 && _alt!=org.antlr.v4.runtime.atn.ATN.INVALID_ALT_NUMBER ) {
if ( _alt==1 ) {
{
{
setState(679);
_errHandler.sync(this);
_la = _input.LA(1);
if (_la==COMMA) {
{
setState(678);
match(COMMA);
}
}
setState(684);
_errHandler.sync(this);
_la = _input.LA(1);
while (_la==NL) {
{
{
setState(681);
match(NL);
}
}
setState(686);
_errHandler.sync(this);
_la = _input.LA(1);
}
setState(687);
indexingArgument();
}
}
}
setState(692);
_errHandler.sync(this);
_alt = getInterpreter().adaptivePredict(_input,71,_ctx);
}
}
break;
case 4:
_localctx = new AssociationListIndexingArgumentListContext(_localctx);
enterOuterAlt(_localctx, 4);
{
setState(693);
associationList();
setState(695);
_errHandler.sync(this);
switch ( getInterpreter().adaptivePredict(_input,72,_ctx) ) {
case 1:
{
setState(694);
match(COMMA);
}
break;
}
}
break;
case 5:
_localctx = new SplattingArgumentIndexingArgumentListContext(_localctx);
enterOuterAlt(_localctx, 5);
{
setState(697);
splattingArgument();
setState(708);
_errHandler.sync(this);
_alt = getInterpreter().adaptivePredict(_input,74,_ctx);
while ( _alt!=2 && _alt!=org.antlr.v4.runtime.atn.ATN.INVALID_ALT_NUMBER ) {
if ( _alt==1 ) {
{
{
setState(698);
match(COMMA);
setState(702);
_errHandler.sync(this);
_la = _input.LA(1);
while (_la==NL) {
{
{
setState(699);
match(NL);
}
}
setState(704);
_errHandler.sync(this);
_la = _input.LA(1);
}
setState(705);
splattingArgument();
}
}
}
setState(710);
_errHandler.sync(this);
_alt = getInterpreter().adaptivePredict(_input,74,_ctx);
}
}
break;
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class IndexingArgumentContext extends ParserRuleContext {
public IndexingArgumentContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_indexingArgument; }
public IndexingArgumentContext() { }
public void copyFrom(IndexingArgumentContext ctx) {
super.copyFrom(ctx);
}
}
public static class SymbolIndexingArgumentContext extends IndexingArgumentContext {
public SymbolContext symbol() {
return getRuleContext(SymbolContext.class,0);
}
public SymbolIndexingArgumentContext(IndexingArgumentContext ctx) { copyFrom(ctx); }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).enterSymbolIndexingArgument(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).exitSymbolIndexingArgument(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof RubyParserVisitor ) return ((RubyParserVisitor extends T>)visitor).visitSymbolIndexingArgument(this);
else return visitor.visitChildren(this);
}
}
public static class NumericLiteralIndexingArgumentContext extends IndexingArgumentContext {
public Token sign;
public UnsignedNumericLiteralContext unsignedNumericLiteral() {
return getRuleContext(UnsignedNumericLiteralContext.class,0);
}
public TerminalNode PLUS() { return getToken(RubyParser.PLUS, 0); }
public TerminalNode MINUS() { return getToken(RubyParser.MINUS, 0); }
public NumericLiteralIndexingArgumentContext(IndexingArgumentContext ctx) { copyFrom(ctx); }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).enterNumericLiteralIndexingArgument(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).exitNumericLiteralIndexingArgument(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof RubyParserVisitor ) return ((RubyParserVisitor extends T>)visitor).visitNumericLiteralIndexingArgument(this);
else return visitor.visitChildren(this);
}
}
public static class AssociationIndexingArgumentContext extends IndexingArgumentContext {
public AssociationContext association() {
return getRuleContext(AssociationContext.class,0);
}
public AssociationIndexingArgumentContext(IndexingArgumentContext ctx) { copyFrom(ctx); }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).enterAssociationIndexingArgument(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).exitAssociationIndexingArgument(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof RubyParserVisitor ) return ((RubyParserVisitor extends T>)visitor).visitAssociationIndexingArgument(this);
else return visitor.visitChildren(this);
}
}
public final IndexingArgumentContext indexingArgument() throws RecognitionException {
IndexingArgumentContext _localctx = new IndexingArgumentContext(_ctx, getState());
enterRule(_localctx, 54, RULE_indexingArgument);
int _la;
try {
setState(719);
_errHandler.sync(this);
switch ( getInterpreter().adaptivePredict(_input,77,_ctx) ) {
case 1:
_localctx = new SymbolIndexingArgumentContext(_localctx);
enterOuterAlt(_localctx, 1);
{
setState(713);
symbol();
}
break;
case 2:
_localctx = new AssociationIndexingArgumentContext(_localctx);
enterOuterAlt(_localctx, 2);
{
setState(714);
association();
}
break;
case 3:
_localctx = new NumericLiteralIndexingArgumentContext(_localctx);
enterOuterAlt(_localctx, 3);
{
setState(716);
_errHandler.sync(this);
_la = _input.LA(1);
if (_la==PLUS || _la==MINUS) {
{
setState(715);
((NumericLiteralIndexingArgumentContext)_localctx).sign = _input.LT(1);
_la = _input.LA(1);
if ( !(_la==PLUS || _la==MINUS) ) {
((NumericLiteralIndexingArgumentContext)_localctx).sign = (Token)_errHandler.recoverInline(this);
}
else {
if ( _input.LA(1)==Token.EOF ) matchedEOF = true;
_errHandler.reportMatch(this);
consume();
}
}
}
setState(718);
unsignedNumericLiteral();
}
break;
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class SplattingArgumentContext extends ParserRuleContext {
public TerminalNode STAR() { return getToken(RubyParser.STAR, 0); }
public OperatorExpressionContext operatorExpression() {
return getRuleContext(OperatorExpressionContext.class,0);
}
public TerminalNode STAR2() { return getToken(RubyParser.STAR2, 0); }
public SplattingArgumentContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_splattingArgument; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).enterSplattingArgument(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).exitSplattingArgument(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof RubyParserVisitor ) return ((RubyParserVisitor extends T>)visitor).visitSplattingArgument(this);
else return visitor.visitChildren(this);
}
}
public final SplattingArgumentContext splattingArgument() throws RecognitionException {
SplattingArgumentContext _localctx = new SplattingArgumentContext(_ctx, getState());
enterRule(_localctx, 56, RULE_splattingArgument);
try {
setState(725);
_errHandler.sync(this);
switch (_input.LA(1)) {
case STAR:
enterOuterAlt(_localctx, 1);
{
setState(721);
match(STAR);
setState(722);
operatorExpression(0);
}
break;
case STAR2:
enterOuterAlt(_localctx, 2);
{
setState(723);
match(STAR2);
setState(724);
operatorExpression(0);
}
break;
default:
throw new NoViableAltException(this);
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class OperatorExpressionListContext extends ParserRuleContext {
public List operatorExpression() {
return getRuleContexts(OperatorExpressionContext.class);
}
public OperatorExpressionContext operatorExpression(int i) {
return getRuleContext(OperatorExpressionContext.class,i);
}
public List COMMA() { return getTokens(RubyParser.COMMA); }
public TerminalNode COMMA(int i) {
return getToken(RubyParser.COMMA, i);
}
public List NL() { return getTokens(RubyParser.NL); }
public TerminalNode NL(int i) {
return getToken(RubyParser.NL, i);
}
public OperatorExpressionListContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_operatorExpressionList; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).enterOperatorExpressionList(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).exitOperatorExpressionList(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof RubyParserVisitor ) return ((RubyParserVisitor extends T>)visitor).visitOperatorExpressionList(this);
else return visitor.visitChildren(this);
}
}
public final OperatorExpressionListContext operatorExpressionList() throws RecognitionException {
OperatorExpressionListContext _localctx = new OperatorExpressionListContext(_ctx, getState());
enterRule(_localctx, 58, RULE_operatorExpressionList);
int _la;
try {
int _alt;
enterOuterAlt(_localctx, 1);
{
setState(727);
operatorExpression(0);
setState(738);
_errHandler.sync(this);
_alt = getInterpreter().adaptivePredict(_input,80,_ctx);
while ( _alt!=2 && _alt!=org.antlr.v4.runtime.atn.ATN.INVALID_ALT_NUMBER ) {
if ( _alt==1 ) {
{
{
setState(728);
match(COMMA);
setState(732);
_errHandler.sync(this);
_la = _input.LA(1);
while (_la==NL) {
{
{
setState(729);
match(NL);
}
}
setState(734);
_errHandler.sync(this);
_la = _input.LA(1);
}
setState(735);
operatorExpression(0);
}
}
}
setState(740);
_errHandler.sync(this);
_alt = getInterpreter().adaptivePredict(_input,80,_ctx);
}
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class OperatorExpressionList2Context extends ParserRuleContext {
public List operatorExpression() {
return getRuleContexts(OperatorExpressionContext.class);
}
public OperatorExpressionContext operatorExpression(int i) {
return getRuleContext(OperatorExpressionContext.class,i);
}
public List COMMA() { return getTokens(RubyParser.COMMA); }
public TerminalNode COMMA(int i) {
return getToken(RubyParser.COMMA, i);
}
public List NL() { return getTokens(RubyParser.NL); }
public TerminalNode NL(int i) {
return getToken(RubyParser.NL, i);
}
public OperatorExpressionList2Context(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_operatorExpressionList2; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).enterOperatorExpressionList2(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).exitOperatorExpressionList2(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof RubyParserVisitor ) return ((RubyParserVisitor extends T>)visitor).visitOperatorExpressionList2(this);
else return visitor.visitChildren(this);
}
}
public final OperatorExpressionList2Context operatorExpressionList2() throws RecognitionException {
OperatorExpressionList2Context _localctx = new OperatorExpressionList2Context(_ctx, getState());
enterRule(_localctx, 60, RULE_operatorExpressionList2);
int _la;
try {
enterOuterAlt(_localctx, 1);
{
setState(741);
operatorExpression(0);
setState(750);
_errHandler.sync(this);
_la = _input.LA(1);
do {
{
{
setState(742);
match(COMMA);
setState(746);
_errHandler.sync(this);
_la = _input.LA(1);
while (_la==NL) {
{
{
setState(743);
match(NL);
}
}
setState(748);
_errHandler.sync(this);
_la = _input.LA(1);
}
setState(749);
operatorExpression(0);
}
}
setState(752);
_errHandler.sync(this);
_la = _input.LA(1);
} while ( _la==COMMA );
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class ArgumentWithParenthesesContext extends ParserRuleContext {
public ArgumentWithParenthesesContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_argumentWithParentheses; }
public ArgumentWithParenthesesContext() { }
public void copyFrom(ArgumentWithParenthesesContext ctx) {
super.copyFrom(ctx);
}
}
public static class EmptyArgumentWithParenthesesContext extends ArgumentWithParenthesesContext {
public TerminalNode LPAREN() { return getToken(RubyParser.LPAREN, 0); }
public TerminalNode RPAREN() { return getToken(RubyParser.RPAREN, 0); }
public List NL() { return getTokens(RubyParser.NL); }
public TerminalNode NL(int i) {
return getToken(RubyParser.NL, i);
}
public TerminalNode COMMA() { return getToken(RubyParser.COMMA, 0); }
public EmptyArgumentWithParenthesesContext(ArgumentWithParenthesesContext ctx) { copyFrom(ctx); }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).enterEmptyArgumentWithParentheses(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).exitEmptyArgumentWithParentheses(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof RubyParserVisitor ) return ((RubyParserVisitor extends T>)visitor).visitEmptyArgumentWithParentheses(this);
else return visitor.visitChildren(this);
}
}
public static class OperatorExpressionsAndChainedCommandWithBlockArgumentWithParenthesesContext extends ArgumentWithParenthesesContext {
public TerminalNode LPAREN() { return getToken(RubyParser.LPAREN, 0); }
public OperatorExpressionListContext operatorExpressionList() {
return getRuleContext(OperatorExpressionListContext.class,0);
}
public List COMMA() { return getTokens(RubyParser.COMMA); }
public TerminalNode COMMA(int i) {
return getToken(RubyParser.COMMA, i);
}
public ChainedCommandWithDoBlockContext chainedCommandWithDoBlock() {
return getRuleContext(ChainedCommandWithDoBlockContext.class,0);
}
public TerminalNode RPAREN() { return getToken(RubyParser.RPAREN, 0); }
public List NL() { return getTokens(RubyParser.NL); }
public TerminalNode NL(int i) {
return getToken(RubyParser.NL, i);
}
public OperatorExpressionsAndChainedCommandWithBlockArgumentWithParenthesesContext(ArgumentWithParenthesesContext ctx) { copyFrom(ctx); }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).enterOperatorExpressionsAndChainedCommandWithBlockArgumentWithParentheses(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).exitOperatorExpressionsAndChainedCommandWithBlockArgumentWithParentheses(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof RubyParserVisitor ) return ((RubyParserVisitor extends T>)visitor).visitOperatorExpressionsAndChainedCommandWithBlockArgumentWithParentheses(this);
else return visitor.visitChildren(this);
}
}
public static class ChainedCommandWithDoBlockArgumentWithParenthesesContext extends ArgumentWithParenthesesContext {
public TerminalNode LPAREN() { return getToken(RubyParser.LPAREN, 0); }
public ChainedCommandWithDoBlockContext chainedCommandWithDoBlock() {
return getRuleContext(ChainedCommandWithDoBlockContext.class,0);
}
public TerminalNode RPAREN() { return getToken(RubyParser.RPAREN, 0); }
public List NL() { return getTokens(RubyParser.NL); }
public TerminalNode NL(int i) {
return getToken(RubyParser.NL, i);
}
public TerminalNode COMMA() { return getToken(RubyParser.COMMA, 0); }
public ChainedCommandWithDoBlockArgumentWithParenthesesContext(ArgumentWithParenthesesContext ctx) { copyFrom(ctx); }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).enterChainedCommandWithDoBlockArgumentWithParentheses(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).exitChainedCommandWithDoBlockArgumentWithParentheses(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof RubyParserVisitor ) return ((RubyParserVisitor extends T>)visitor).visitChainedCommandWithDoBlockArgumentWithParentheses(this);
else return visitor.visitChildren(this);
}
}
public static class ArgumentListArgumentWithParenthesesContext extends ArgumentWithParenthesesContext {
public TerminalNode LPAREN() { return getToken(RubyParser.LPAREN, 0); }
public ArgumentListContext argumentList() {
return getRuleContext(ArgumentListContext.class,0);
}
public TerminalNode RPAREN() { return getToken(RubyParser.RPAREN, 0); }
public List NL() { return getTokens(RubyParser.NL); }
public TerminalNode NL(int i) {
return getToken(RubyParser.NL, i);
}
public TerminalNode COMMA() { return getToken(RubyParser.COMMA, 0); }
public ArgumentListArgumentWithParenthesesContext(ArgumentWithParenthesesContext ctx) { copyFrom(ctx); }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).enterArgumentListArgumentWithParentheses(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).exitArgumentListArgumentWithParentheses(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof RubyParserVisitor ) return ((RubyParserVisitor extends T>)visitor).visitArgumentListArgumentWithParentheses(this);
else return visitor.visitChildren(this);
}
}
public final ArgumentWithParenthesesContext argumentWithParentheses() throws RecognitionException {
ArgumentWithParenthesesContext _localctx = new ArgumentWithParenthesesContext(_ctx, getState());
enterRule(_localctx, 62, RULE_argumentWithParentheses);
int _la;
try {
int _alt;
setState(836);
_errHandler.sync(this);
switch ( getInterpreter().adaptivePredict(_input,96,_ctx) ) {
case 1:
_localctx = new EmptyArgumentWithParenthesesContext(_localctx);
enterOuterAlt(_localctx, 1);
{
setState(754);
match(LPAREN);
setState(758);
_errHandler.sync(this);
_alt = getInterpreter().adaptivePredict(_input,83,_ctx);
while ( _alt!=2 && _alt!=org.antlr.v4.runtime.atn.ATN.INVALID_ALT_NUMBER ) {
if ( _alt==1 ) {
{
{
setState(755);
match(NL);
}
}
}
setState(760);
_errHandler.sync(this);
_alt = getInterpreter().adaptivePredict(_input,83,_ctx);
}
setState(762);
_errHandler.sync(this);
_la = _input.LA(1);
if (_la==COMMA) {
{
setState(761);
match(COMMA);
}
}
setState(767);
_errHandler.sync(this);
_la = _input.LA(1);
while (_la==NL) {
{
{
setState(764);
match(NL);
}
}
setState(769);
_errHandler.sync(this);
_la = _input.LA(1);
}
setState(770);
match(RPAREN);
}
break;
case 2:
_localctx = new ArgumentListArgumentWithParenthesesContext(_localctx);
enterOuterAlt(_localctx, 2);
{
setState(771);
match(LPAREN);
setState(775);
_errHandler.sync(this);
_la = _input.LA(1);
while (_la==NL) {
{
{
setState(772);
match(NL);
}
}
setState(777);
_errHandler.sync(this);
_la = _input.LA(1);
}
setState(778);
argumentList();
setState(780);
_errHandler.sync(this);
_la = _input.LA(1);
if (_la==COMMA) {
{
setState(779);
match(COMMA);
}
}
setState(785);
_errHandler.sync(this);
_la = _input.LA(1);
while (_la==NL) {
{
{
setState(782);
match(NL);
}
}
setState(787);
_errHandler.sync(this);
_la = _input.LA(1);
}
setState(788);
match(RPAREN);
}
break;
case 3:
_localctx = new OperatorExpressionsAndChainedCommandWithBlockArgumentWithParenthesesContext(_localctx);
enterOuterAlt(_localctx, 3);
{
setState(790);
match(LPAREN);
setState(794);
_errHandler.sync(this);
_la = _input.LA(1);
while (_la==NL) {
{
{
setState(791);
match(NL);
}
}
setState(796);
_errHandler.sync(this);
_la = _input.LA(1);
}
setState(797);
operatorExpressionList();
setState(798);
match(COMMA);
setState(802);
_errHandler.sync(this);
_la = _input.LA(1);
while (_la==NL) {
{
{
setState(799);
match(NL);
}
}
setState(804);
_errHandler.sync(this);
_la = _input.LA(1);
}
setState(805);
chainedCommandWithDoBlock();
setState(807);
_errHandler.sync(this);
_la = _input.LA(1);
if (_la==COMMA) {
{
setState(806);
match(COMMA);
}
}
setState(812);
_errHandler.sync(this);
_la = _input.LA(1);
while (_la==NL) {
{
{
setState(809);
match(NL);
}
}
setState(814);
_errHandler.sync(this);
_la = _input.LA(1);
}
setState(815);
match(RPAREN);
}
break;
case 4:
_localctx = new ChainedCommandWithDoBlockArgumentWithParenthesesContext(_localctx);
enterOuterAlt(_localctx, 4);
{
setState(817);
match(LPAREN);
setState(821);
_errHandler.sync(this);
_la = _input.LA(1);
while (_la==NL) {
{
{
setState(818);
match(NL);
}
}
setState(823);
_errHandler.sync(this);
_la = _input.LA(1);
}
setState(824);
chainedCommandWithDoBlock();
setState(826);
_errHandler.sync(this);
_la = _input.LA(1);
if (_la==COMMA) {
{
setState(825);
match(COMMA);
}
}
setState(831);
_errHandler.sync(this);
_la = _input.LA(1);
while (_la==NL) {
{
{
setState(828);
match(NL);
}
}
setState(833);
_errHandler.sync(this);
_la = _input.LA(1);
}
setState(834);
match(RPAREN);
}
break;
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class ArgumentListContext extends ParserRuleContext {
public ArgumentListContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_argumentList; }
public ArgumentListContext() { }
public void copyFrom(ArgumentListContext ctx) {
super.copyFrom(ctx);
}
}
public static class ArrayArgumentListContext extends ArgumentListContext {
public TerminalNode LBRACK() { return getToken(RubyParser.LBRACK, 0); }
public TerminalNode RBRACK() { return getToken(RubyParser.RBRACK, 0); }
public IndexingArgumentListContext indexingArgumentList() {
return getRuleContext(IndexingArgumentListContext.class,0);
}
public ArrayArgumentListContext(ArgumentListContext ctx) { copyFrom(ctx); }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).enterArrayArgumentList(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).exitArrayArgumentList(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof RubyParserVisitor ) return ((RubyParserVisitor extends T>)visitor).visitArrayArgumentList(this);
else return visitor.visitChildren(this);
}
}
public static class BlockArgumentArgumentListContext extends ArgumentListContext {
public BlockArgumentContext blockArgument() {
return getRuleContext(BlockArgumentContext.class,0);
}
public BlockArgumentArgumentListContext(ArgumentListContext ctx) { copyFrom(ctx); }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).enterBlockArgumentArgumentList(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).exitBlockArgumentArgumentList(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof RubyParserVisitor ) return ((RubyParserVisitor extends T>)visitor).visitBlockArgumentArgumentList(this);
else return visitor.visitChildren(this);
}
}
public static class SingleCommandArgumentListContext extends ArgumentListContext {
public CommandContext command() {
return getRuleContext(CommandContext.class,0);
}
public SingleCommandArgumentListContext(ArgumentListContext ctx) { copyFrom(ctx); }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).enterSingleCommandArgumentList(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).exitSingleCommandArgumentList(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof RubyParserVisitor ) return ((RubyParserVisitor extends T>)visitor).visitSingleCommandArgumentList(this);
else return visitor.visitChildren(this);
}
}
public static class ArgumentListItemArgumentListContext extends ArgumentListContext {
public List argumentListItem() {
return getRuleContexts(ArgumentListItemContext.class);
}
public ArgumentListItemContext argumentListItem(int i) {
return getRuleContext(ArgumentListItemContext.class,i);
}
public List COMMA() { return getTokens(RubyParser.COMMA); }
public TerminalNode COMMA(int i) {
return getToken(RubyParser.COMMA, i);
}
public List NL() { return getTokens(RubyParser.NL); }
public TerminalNode NL(int i) {
return getToken(RubyParser.NL, i);
}
public ArgumentListItemArgumentListContext(ArgumentListContext ctx) { copyFrom(ctx); }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).enterArgumentListItemArgumentList(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).exitArgumentListItemArgumentList(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof RubyParserVisitor ) return ((RubyParserVisitor extends T>)visitor).visitArgumentListItemArgumentList(this);
else return visitor.visitChildren(this);
}
}
public final ArgumentListContext argumentList() throws RecognitionException {
ArgumentListContext _localctx = new ArgumentListContext(_ctx, getState());
enterRule(_localctx, 64, RULE_argumentList);
int _la;
try {
int _alt;
setState(859);
_errHandler.sync(this);
switch ( getInterpreter().adaptivePredict(_input,100,_ctx) ) {
case 1:
_localctx = new BlockArgumentArgumentListContext(_localctx);
enterOuterAlt(_localctx, 1);
{
setState(838);
blockArgument();
}
break;
case 2:
_localctx = new ArgumentListItemArgumentListContext(_localctx);
enterOuterAlt(_localctx, 2);
{
setState(839);
argumentListItem();
setState(850);
_errHandler.sync(this);
_alt = getInterpreter().adaptivePredict(_input,98,_ctx);
while ( _alt!=2 && _alt!=org.antlr.v4.runtime.atn.ATN.INVALID_ALT_NUMBER ) {
if ( _alt==1 ) {
{
{
setState(840);
match(COMMA);
setState(844);
_errHandler.sync(this);
_la = _input.LA(1);
while (_la==NL) {
{
{
setState(841);
match(NL);
}
}
setState(846);
_errHandler.sync(this);
_la = _input.LA(1);
}
setState(847);
argumentListItem();
}
}
}
setState(852);
_errHandler.sync(this);
_alt = getInterpreter().adaptivePredict(_input,98,_ctx);
}
}
break;
case 3:
_localctx = new ArrayArgumentListContext(_localctx);
enterOuterAlt(_localctx, 3);
{
setState(853);
match(LBRACK);
setState(855);
_errHandler.sync(this);
_la = _input.LA(1);
if (((((_la - 3)) & ~0x3f) == 0 && ((1L << (_la - 3)) & ((1L << (REGULAR_EXPRESSION_START - 3)) | (1L << (LBRACK - 3)) | (1L << (LPAREN - 3)) | (1L << (LCURLY - 3)) | (1L << (COLON - 3)) | (1L << (COLON2 - 3)) | (1L << (DOT2 - 3)) | (1L << (DOT3 - 3)) | (1L << (MINUSGT - 3)) | (1L << (EMARK - 3)) | (1L << (PLUS - 3)) | (1L << (MINUS - 3)) | (1L << (STAR - 3)) | (1L << (STAR2 - 3)) | (1L << (TILDE - 3)) | (1L << (SINGLE_QUOTED_STRING_LITERAL - 3)) | (1L << (DOUBLE_QUOTED_STRING_START - 3)) | (1L << (QUOTED_NON_EXPANDED_STRING_LITERAL_START - 3)) | (1L << (QUOTED_EXPANDED_STRING_LITERAL_START - 3)) | (1L << (QUOTED_EXPANDED_REGULAR_EXPRESSION_START - 3)))) != 0) || ((((_la - 67)) & ~0x3f) == 0 && ((1L << (_la - 67)) & ((1L << (QUOTED_EXPANDED_EXTERNAL_COMMAND_LITERAL_START - 67)) | (1L << (QUOTED_NON_EXPANDED_STRING_ARRAY_LITERAL_START - 67)) | (1L << (QUOTED_EXPANDED_STRING_ARRAY_LITERAL_START - 67)) | (1L << (HERE_DOC - 67)) | (1L << (QUOTED_NON_EXPANDED_SYMBOL_ARRAY_LITERAL_START - 67)) | (1L << (QUOTED_EXPANDED_SYMBOL_ARRAY_LITERAL_START - 67)) | (1L << (DECIMAL_INTEGER_LITERAL - 67)) | (1L << (BINARY_INTEGER_LITERAL - 67)) | (1L << (OCTAL_INTEGER_LITERAL - 67)) | (1L << (HEXADECIMAL_INTEGER_LITERAL - 67)) | (1L << (FLOAT_LITERAL_WITHOUT_EXPONENT - 67)) | (1L << (FLOAT_LITERAL_WITH_EXPONENT - 67)) | (1L << (SYMBOL_LITERAL - 67)) | (1L << (LOCAL_VARIABLE_IDENTIFIER - 67)) | (1L << (LINE__ - 67)) | (1L << (ENCODING__ - 67)) | (1L << (FILE__ - 67)) | (1L << (BEGIN_ - 67)) | (1L << (END_ - 67)) | (1L << (ALIAS - 67)) | (1L << (AND - 67)) | (1L << (BEGIN - 67)) | (1L << (BREAK - 67)) | (1L << (CASE - 67)) | (1L << (CLASS - 67)) | (1L << (DEF - 67)) | (1L << (IS_DEFINED - 67)) | (1L << (DO - 67)) | (1L << (ELSE - 67)) | (1L << (ELSIF - 67)) | (1L << (END - 67)) | (1L << (ENSURE - 67)) | (1L << (FOR - 67)) | (1L << (FALSE - 67)) | (1L << (IF - 67)) | (1L << (IN - 67)) | (1L << (MODULE - 67)) | (1L << (NEXT - 67)) | (1L << (NIL - 67)) | (1L << (NOT - 67)) | (1L << (OR - 67)) | (1L << (REDO - 67)) | (1L << (RESCUE - 67)) | (1L << (RETRY - 67)) | (1L << (RETURN - 67)) | (1L << (SELF - 67)) | (1L << (SUPER - 67)) | (1L << (THEN - 67)) | (1L << (TRUE - 67)) | (1L << (UNDEF - 67)) | (1L << (UNLESS - 67)) | (1L << (UNTIL - 67)) | (1L << (WHEN - 67)) | (1L << (WHILE - 67)) | (1L << (YIELD - 67)) | (1L << (GLOBAL_VARIABLE_IDENTIFIER - 67)) | (1L << (INSTANCE_VARIABLE_IDENTIFIER - 67)) | (1L << (CLASS_VARIABLE_IDENTIFIER - 67)) | (1L << (CONSTANT_IDENTIFIER - 67)))) != 0)) {
{
setState(854);
indexingArgumentList();
}
}
setState(857);
match(RBRACK);
}
break;
case 4:
_localctx = new SingleCommandArgumentListContext(_localctx);
enterOuterAlt(_localctx, 4);
{
setState(858);
command();
}
break;
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class ArgumentListItemContext extends ParserRuleContext {
public SplattingArgumentContext splattingArgument() {
return getRuleContext(SplattingArgumentContext.class,0);
}
public OperatorExpressionListContext operatorExpressionList() {
return getRuleContext(OperatorExpressionListContext.class,0);
}
public AssociationListContext associationList() {
return getRuleContext(AssociationListContext.class,0);
}
public BlockArgumentContext blockArgument() {
return getRuleContext(BlockArgumentContext.class,0);
}
public ArgumentListItemContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_argumentListItem; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).enterArgumentListItem(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).exitArgumentListItem(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof RubyParserVisitor ) return ((RubyParserVisitor extends T>)visitor).visitArgumentListItem(this);
else return visitor.visitChildren(this);
}
}
public final ArgumentListItemContext argumentListItem() throws RecognitionException {
ArgumentListItemContext _localctx = new ArgumentListItemContext(_ctx, getState());
enterRule(_localctx, 66, RULE_argumentListItem);
try {
setState(865);
_errHandler.sync(this);
switch ( getInterpreter().adaptivePredict(_input,101,_ctx) ) {
case 1:
enterOuterAlt(_localctx, 1);
{
setState(861);
splattingArgument();
}
break;
case 2:
enterOuterAlt(_localctx, 2);
{
setState(862);
operatorExpressionList();
}
break;
case 3:
enterOuterAlt(_localctx, 3);
{
setState(863);
associationList();
}
break;
case 4:
enterOuterAlt(_localctx, 4);
{
setState(864);
blockArgument();
}
break;
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class SplatArgListContext extends ParserRuleContext {
public List splattingArgument() {
return getRuleContexts(SplattingArgumentContext.class);
}
public SplattingArgumentContext splattingArgument(int i) {
return getRuleContext(SplattingArgumentContext.class,i);
}
public List COMMA() { return getTokens(RubyParser.COMMA); }
public TerminalNode COMMA(int i) {
return getToken(RubyParser.COMMA, i);
}
public List NL() { return getTokens(RubyParser.NL); }
public TerminalNode NL(int i) {
return getToken(RubyParser.NL, i);
}
public SplatArgListContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_splatArgList; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).enterSplatArgList(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).exitSplatArgList(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof RubyParserVisitor ) return ((RubyParserVisitor extends T>)visitor).visitSplatArgList(this);
else return visitor.visitChildren(this);
}
}
public final SplatArgListContext splatArgList() throws RecognitionException {
SplatArgListContext _localctx = new SplatArgListContext(_ctx, getState());
enterRule(_localctx, 68, RULE_splatArgList);
int _la;
try {
enterOuterAlt(_localctx, 1);
{
setState(867);
splattingArgument();
setState(878);
_errHandler.sync(this);
_la = _input.LA(1);
while (_la==COMMA) {
{
{
setState(868);
match(COMMA);
setState(872);
_errHandler.sync(this);
_la = _input.LA(1);
while (_la==NL) {
{
{
setState(869);
match(NL);
}
}
setState(874);
_errHandler.sync(this);
_la = _input.LA(1);
}
setState(875);
splattingArgument();
}
}
setState(880);
_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;
}
public static class CommandArgumentListContext extends ParserRuleContext {
public AssociationListContext associationList() {
return getRuleContext(AssociationListContext.class,0);
}
public PrimaryValueListContext primaryValueList() {
return getRuleContext(PrimaryValueListContext.class,0);
}
public TerminalNode COMMA() { return getToken(RubyParser.COMMA, 0); }
public List NL() { return getTokens(RubyParser.NL); }
public TerminalNode NL(int i) {
return getToken(RubyParser.NL, i);
}
public CommandArgumentListContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_commandArgumentList; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).enterCommandArgumentList(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).exitCommandArgumentList(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof RubyParserVisitor ) return ((RubyParserVisitor extends T>)visitor).visitCommandArgumentList(this);
else return visitor.visitChildren(this);
}
}
public final CommandArgumentListContext commandArgumentList() throws RecognitionException {
CommandArgumentListContext _localctx = new CommandArgumentListContext(_ctx, getState());
enterRule(_localctx, 70, RULE_commandArgumentList);
int _la;
try {
setState(893);
_errHandler.sync(this);
switch ( getInterpreter().adaptivePredict(_input,106,_ctx) ) {
case 1:
enterOuterAlt(_localctx, 1);
{
setState(881);
associationList();
}
break;
case 2:
enterOuterAlt(_localctx, 2);
{
setState(882);
primaryValueList();
setState(891);
_errHandler.sync(this);
switch ( getInterpreter().adaptivePredict(_input,105,_ctx) ) {
case 1:
{
setState(883);
match(COMMA);
setState(887);
_errHandler.sync(this);
_la = _input.LA(1);
while (_la==NL) {
{
{
setState(884);
match(NL);
}
}
setState(889);
_errHandler.sync(this);
_la = _input.LA(1);
}
setState(890);
associationList();
}
break;
}
}
break;
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class PrimaryValueListContext extends ParserRuleContext {
public List primaryValue() {
return getRuleContexts(PrimaryValueContext.class);
}
public PrimaryValueContext primaryValue(int i) {
return getRuleContext(PrimaryValueContext.class,i);
}
public List COMMA() { return getTokens(RubyParser.COMMA); }
public TerminalNode COMMA(int i) {
return getToken(RubyParser.COMMA, i);
}
public List NL() { return getTokens(RubyParser.NL); }
public TerminalNode NL(int i) {
return getToken(RubyParser.NL, i);
}
public PrimaryValueListContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_primaryValueList; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).enterPrimaryValueList(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).exitPrimaryValueList(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof RubyParserVisitor ) return ((RubyParserVisitor extends T>)visitor).visitPrimaryValueList(this);
else return visitor.visitChildren(this);
}
}
public final PrimaryValueListContext primaryValueList() throws RecognitionException {
PrimaryValueListContext _localctx = new PrimaryValueListContext(_ctx, getState());
enterRule(_localctx, 72, RULE_primaryValueList);
int _la;
try {
int _alt;
enterOuterAlt(_localctx, 1);
{
setState(895);
primaryValue(0);
setState(906);
_errHandler.sync(this);
_alt = getInterpreter().adaptivePredict(_input,108,_ctx);
while ( _alt!=2 && _alt!=org.antlr.v4.runtime.atn.ATN.INVALID_ALT_NUMBER ) {
if ( _alt==1 ) {
{
{
setState(896);
match(COMMA);
setState(900);
_errHandler.sync(this);
_la = _input.LA(1);
while (_la==NL) {
{
{
setState(897);
match(NL);
}
}
setState(902);
_errHandler.sync(this);
_la = _input.LA(1);
}
setState(903);
primaryValue(0);
}
}
}
setState(908);
_errHandler.sync(this);
_alt = getInterpreter().adaptivePredict(_input,108,_ctx);
}
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class PrimaryValueListWithAssociationContext extends ParserRuleContext {
public List primaryValue() {
return getRuleContexts(PrimaryValueContext.class);
}
public PrimaryValueContext primaryValue(int i) {
return getRuleContext(PrimaryValueContext.class,i);
}
public List association() {
return getRuleContexts(AssociationContext.class);
}
public AssociationContext association(int i) {
return getRuleContext(AssociationContext.class,i);
}
public List COMMA() { return getTokens(RubyParser.COMMA); }
public TerminalNode COMMA(int i) {
return getToken(RubyParser.COMMA, i);
}
public List NL() { return getTokens(RubyParser.NL); }
public TerminalNode NL(int i) {
return getToken(RubyParser.NL, i);
}
public MethodInvocationWithoutParenthesesContext methodInvocationWithoutParentheses() {
return getRuleContext(MethodInvocationWithoutParenthesesContext.class,0);
}
public PrimaryValueListWithAssociationContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_primaryValueListWithAssociation; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).enterPrimaryValueListWithAssociation(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).exitPrimaryValueListWithAssociation(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof RubyParserVisitor ) return ((RubyParserVisitor extends T>)visitor).visitPrimaryValueListWithAssociation(this);
else return visitor.visitChildren(this);
}
}
public final PrimaryValueListWithAssociationContext primaryValueListWithAssociation() throws RecognitionException {
PrimaryValueListWithAssociationContext _localctx = new PrimaryValueListWithAssociationContext(_ctx, getState());
enterRule(_localctx, 74, RULE_primaryValueListWithAssociation);
int _la;
try {
int _alt;
setState(930);
_errHandler.sync(this);
switch ( getInterpreter().adaptivePredict(_input,113,_ctx) ) {
case 1:
enterOuterAlt(_localctx, 1);
{
setState(911);
_errHandler.sync(this);
switch ( getInterpreter().adaptivePredict(_input,109,_ctx) ) {
case 1:
{
setState(909);
primaryValue(0);
}
break;
case 2:
{
setState(910);
association();
}
break;
}
setState(926);
_errHandler.sync(this);
_alt = getInterpreter().adaptivePredict(_input,112,_ctx);
while ( _alt!=2 && _alt!=org.antlr.v4.runtime.atn.ATN.INVALID_ALT_NUMBER ) {
if ( _alt==1 ) {
{
{
setState(913);
match(COMMA);
setState(917);
_errHandler.sync(this);
_la = _input.LA(1);
while (_la==NL) {
{
{
setState(914);
match(NL);
}
}
setState(919);
_errHandler.sync(this);
_la = _input.LA(1);
}
setState(922);
_errHandler.sync(this);
switch ( getInterpreter().adaptivePredict(_input,111,_ctx) ) {
case 1:
{
setState(920);
primaryValue(0);
}
break;
case 2:
{
setState(921);
association();
}
break;
}
}
}
}
setState(928);
_errHandler.sync(this);
_alt = getInterpreter().adaptivePredict(_input,112,_ctx);
}
}
break;
case 2:
enterOuterAlt(_localctx, 2);
{
setState(929);
methodInvocationWithoutParentheses();
}
break;
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class BlockArgumentContext extends ParserRuleContext {
public TerminalNode AMP() { return getToken(RubyParser.AMP, 0); }
public OperatorExpressionContext operatorExpression() {
return getRuleContext(OperatorExpressionContext.class,0);
}
public BlockArgumentContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_blockArgument; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).enterBlockArgument(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).exitBlockArgument(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof RubyParserVisitor ) return ((RubyParserVisitor extends T>)visitor).visitBlockArgument(this);
else return visitor.visitChildren(this);
}
}
public final BlockArgumentContext blockArgument() throws RecognitionException {
BlockArgumentContext _localctx = new BlockArgumentContext(_ctx, getState());
enterRule(_localctx, 76, RULE_blockArgument);
try {
enterOuterAlt(_localctx, 1);
{
setState(932);
match(AMP);
setState(934);
_errHandler.sync(this);
switch ( getInterpreter().adaptivePredict(_input,114,_ctx) ) {
case 1:
{
setState(933);
operatorExpression(0);
}
break;
}
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class ExpressionOrCommandContext extends ParserRuleContext {
public ExpressionOrCommandContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_expressionOrCommand; }
public ExpressionOrCommandContext() { }
public void copyFrom(ExpressionOrCommandContext ctx) {
super.copyFrom(ctx);
}
}
public static class OperatorExpressionOrCommandContext extends ExpressionOrCommandContext {
public OperatorExpressionContext operatorExpression() {
return getRuleContext(OperatorExpressionContext.class,0);
}
public OperatorExpressionOrCommandContext(ExpressionOrCommandContext ctx) { copyFrom(ctx); }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).enterOperatorExpressionOrCommand(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).exitOperatorExpressionOrCommand(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof RubyParserVisitor ) return ((RubyParserVisitor extends T>)visitor).visitOperatorExpressionOrCommand(this);
else return visitor.visitChildren(this);
}
}
public static class NotExpressionOrCommandContext extends ExpressionOrCommandContext {
public TerminalNode NOT() { return getToken(RubyParser.NOT, 0); }
public ExpressionOrCommandContext expressionOrCommand() {
return getRuleContext(ExpressionOrCommandContext.class,0);
}
public List NL() { return getTokens(RubyParser.NL); }
public TerminalNode NL(int i) {
return getToken(RubyParser.NL, i);
}
public NotExpressionOrCommandContext(ExpressionOrCommandContext ctx) { copyFrom(ctx); }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).enterNotExpressionOrCommand(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).exitNotExpressionOrCommand(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof RubyParserVisitor ) return ((RubyParserVisitor extends T>)visitor).visitNotExpressionOrCommand(this);
else return visitor.visitChildren(this);
}
}
public static class KeywordAndOrExpressionOrCommandContext extends ExpressionOrCommandContext {
public ExpressionOrCommandContext lhs;
public Token binOp;
public ExpressionOrCommandContext rhs;
public List expressionOrCommand() {
return getRuleContexts(ExpressionOrCommandContext.class);
}
public ExpressionOrCommandContext expressionOrCommand(int i) {
return getRuleContext(ExpressionOrCommandContext.class,i);
}
public TerminalNode AND() { return getToken(RubyParser.AND, 0); }
public TerminalNode OR() { return getToken(RubyParser.OR, 0); }
public List NL() { return getTokens(RubyParser.NL); }
public TerminalNode NL(int i) {
return getToken(RubyParser.NL, i);
}
public KeywordAndOrExpressionOrCommandContext(ExpressionOrCommandContext ctx) { copyFrom(ctx); }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).enterKeywordAndOrExpressionOrCommand(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).exitKeywordAndOrExpressionOrCommand(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof RubyParserVisitor ) return ((RubyParserVisitor extends T>)visitor).visitKeywordAndOrExpressionOrCommand(this);
else return visitor.visitChildren(this);
}
}
public static class CommandExpressionOrCommandContext extends ExpressionOrCommandContext {
public MethodInvocationWithoutParenthesesContext methodInvocationWithoutParentheses() {
return getRuleContext(MethodInvocationWithoutParenthesesContext.class,0);
}
public TerminalNode EMARK() { return getToken(RubyParser.EMARK, 0); }
public CommandExpressionOrCommandContext(ExpressionOrCommandContext ctx) { copyFrom(ctx); }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).enterCommandExpressionOrCommand(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).exitCommandExpressionOrCommand(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof RubyParserVisitor ) return ((RubyParserVisitor extends T>)visitor).visitCommandExpressionOrCommand(this);
else return visitor.visitChildren(this);
}
}
public final ExpressionOrCommandContext expressionOrCommand() throws RecognitionException {
return expressionOrCommand(0);
}
private ExpressionOrCommandContext expressionOrCommand(int _p) throws RecognitionException {
ParserRuleContext _parentctx = _ctx;
int _parentState = getState();
ExpressionOrCommandContext _localctx = new ExpressionOrCommandContext(_ctx, _parentState);
ExpressionOrCommandContext _prevctx = _localctx;
int _startState = 78;
enterRecursionRule(_localctx, 78, RULE_expressionOrCommand, _p);
int _la;
try {
int _alt;
enterOuterAlt(_localctx, 1);
{
setState(950);
_errHandler.sync(this);
switch ( getInterpreter().adaptivePredict(_input,117,_ctx) ) {
case 1:
{
_localctx = new OperatorExpressionOrCommandContext(_localctx);
_ctx = _localctx;
_prevctx = _localctx;
setState(937);
operatorExpression(0);
}
break;
case 2:
{
_localctx = new CommandExpressionOrCommandContext(_localctx);
_ctx = _localctx;
_prevctx = _localctx;
setState(939);
_errHandler.sync(this);
switch ( getInterpreter().adaptivePredict(_input,115,_ctx) ) {
case 1:
{
setState(938);
match(EMARK);
}
break;
}
setState(941);
methodInvocationWithoutParentheses();
}
break;
case 3:
{
_localctx = new NotExpressionOrCommandContext(_localctx);
_ctx = _localctx;
_prevctx = _localctx;
setState(942);
match(NOT);
setState(946);
_errHandler.sync(this);
_la = _input.LA(1);
while (_la==NL) {
{
{
setState(943);
match(NL);
}
}
setState(948);
_errHandler.sync(this);
_la = _input.LA(1);
}
setState(949);
expressionOrCommand(2);
}
break;
}
_ctx.stop = _input.LT(-1);
setState(963);
_errHandler.sync(this);
_alt = getInterpreter().adaptivePredict(_input,119,_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 KeywordAndOrExpressionOrCommandContext(new ExpressionOrCommandContext(_parentctx, _parentState));
((KeywordAndOrExpressionOrCommandContext)_localctx).lhs = _prevctx;
pushNewRecursionContext(_localctx, _startState, RULE_expressionOrCommand);
setState(952);
if (!(precpred(_ctx, 1))) throw new FailedPredicateException(this, "precpred(_ctx, 1)");
setState(953);
((KeywordAndOrExpressionOrCommandContext)_localctx).binOp = _input.LT(1);
_la = _input.LA(1);
if ( !(_la==AND || _la==OR) ) {
((KeywordAndOrExpressionOrCommandContext)_localctx).binOp = (Token)_errHandler.recoverInline(this);
}
else {
if ( _input.LA(1)==Token.EOF ) matchedEOF = true;
_errHandler.reportMatch(this);
consume();
}
setState(957);
_errHandler.sync(this);
_la = _input.LA(1);
while (_la==NL) {
{
{
setState(954);
match(NL);
}
}
setState(959);
_errHandler.sync(this);
_la = _input.LA(1);
}
setState(960);
((KeywordAndOrExpressionOrCommandContext)_localctx).rhs = expressionOrCommand(2);
}
}
}
setState(965);
_errHandler.sync(this);
_alt = getInterpreter().adaptivePredict(_input,119,_ctx);
}
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
unrollRecursionContexts(_parentctx);
}
return _localctx;
}
public static class OperatorExpressionContext extends ParserRuleContext {
public OperatorExpressionContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_operatorExpression; }
public OperatorExpressionContext() { }
public void copyFrom(OperatorExpressionContext ctx) {
super.copyFrom(ctx);
}
}
public static class TernaryOperatorExpressionContext extends OperatorExpressionContext {
public List operatorExpression() {
return getRuleContexts(OperatorExpressionContext.class);
}
public OperatorExpressionContext operatorExpression(int i) {
return getRuleContext(OperatorExpressionContext.class,i);
}
public TerminalNode QMARK() { return getToken(RubyParser.QMARK, 0); }
public TerminalNode COLON() { return getToken(RubyParser.COLON, 0); }
public List NL() { return getTokens(RubyParser.NL); }
public TerminalNode NL(int i) {
return getToken(RubyParser.NL, i);
}
public TernaryOperatorExpressionContext(OperatorExpressionContext ctx) { copyFrom(ctx); }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).enterTernaryOperatorExpression(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).exitTernaryOperatorExpression(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof RubyParserVisitor ) return ((RubyParserVisitor extends T>)visitor).visitTernaryOperatorExpression(this);
else return visitor.visitChildren(this);
}
}
public static class PrimaryOperatorExpressionContext extends OperatorExpressionContext {
public PrimaryContext primary() {
return getRuleContext(PrimaryContext.class,0);
}
public PrimaryOperatorExpressionContext(OperatorExpressionContext ctx) { copyFrom(ctx); }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).enterPrimaryOperatorExpression(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).exitPrimaryOperatorExpression(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof RubyParserVisitor ) return ((RubyParserVisitor extends T>)visitor).visitPrimaryOperatorExpression(this);
else return visitor.visitChildren(this);
}
}
public final OperatorExpressionContext operatorExpression() throws RecognitionException {
return operatorExpression(0);
}
private OperatorExpressionContext operatorExpression(int _p) throws RecognitionException {
ParserRuleContext _parentctx = _ctx;
int _parentState = getState();
OperatorExpressionContext _localctx = new OperatorExpressionContext(_ctx, _parentState);
OperatorExpressionContext _prevctx = _localctx;
int _startState = 80;
enterRecursionRule(_localctx, 80, RULE_operatorExpression, _p);
int _la;
try {
int _alt;
enterOuterAlt(_localctx, 1);
{
{
_localctx = new PrimaryOperatorExpressionContext(_localctx);
_ctx = _localctx;
_prevctx = _localctx;
setState(967);
primary();
}
_ctx.stop = _input.LT(-1);
setState(995);
_errHandler.sync(this);
_alt = getInterpreter().adaptivePredict(_input,123,_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 TernaryOperatorExpressionContext(new OperatorExpressionContext(_parentctx, _parentState));
pushNewRecursionContext(_localctx, _startState, RULE_operatorExpression);
setState(969);
if (!(precpred(_ctx, 1))) throw new FailedPredicateException(this, "precpred(_ctx, 1)");
setState(970);
match(QMARK);
setState(974);
_errHandler.sync(this);
_la = _input.LA(1);
while (_la==NL) {
{
{
setState(971);
match(NL);
}
}
setState(976);
_errHandler.sync(this);
_la = _input.LA(1);
}
setState(977);
operatorExpression(0);
setState(981);
_errHandler.sync(this);
_la = _input.LA(1);
while (_la==NL) {
{
{
setState(978);
match(NL);
}
}
setState(983);
_errHandler.sync(this);
_la = _input.LA(1);
}
setState(984);
match(COLON);
setState(988);
_errHandler.sync(this);
_la = _input.LA(1);
while (_la==NL) {
{
{
setState(985);
match(NL);
}
}
setState(990);
_errHandler.sync(this);
_la = _input.LA(1);
}
setState(991);
operatorExpression(2);
}
}
}
setState(997);
_errHandler.sync(this);
_alt = getInterpreter().adaptivePredict(_input,123,_ctx);
}
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
unrollRecursionContexts(_parentctx);
}
return _localctx;
}
public static class PrimaryContext extends ParserRuleContext {
public PrimaryContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_primary; }
public PrimaryContext() { }
public void copyFrom(PrimaryContext ctx) {
super.copyFrom(ctx);
}
}
public static class PrimaryValuePrimaryContext extends PrimaryContext {
public PrimaryValueContext primaryValue() {
return getRuleContext(PrimaryValueContext.class,0);
}
public PrimaryValuePrimaryContext(PrimaryContext ctx) { copyFrom(ctx); }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).enterPrimaryValuePrimary(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).exitPrimaryValuePrimary(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof RubyParserVisitor ) return ((RubyParserVisitor extends T>)visitor).visitPrimaryValuePrimary(this);
else return visitor.visitChildren(this);
}
}
public static class ReturnWithoutArgumentsContext extends PrimaryContext {
public TerminalNode RETURN() { return getToken(RubyParser.RETURN, 0); }
public ReturnWithoutArgumentsContext(PrimaryContext ctx) { copyFrom(ctx); }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).enterReturnWithoutArguments(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).exitReturnWithoutArguments(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof RubyParserVisitor ) return ((RubyParserVisitor extends T>)visitor).visitReturnWithoutArguments(this);
else return visitor.visitChildren(this);
}
}
public static class BreakWithoutArgumentsContext extends PrimaryContext {
public TerminalNode BREAK() { return getToken(RubyParser.BREAK, 0); }
public BreakWithoutArgumentsContext(PrimaryContext ctx) { copyFrom(ctx); }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).enterBreakWithoutArguments(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).exitBreakWithoutArguments(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof RubyParserVisitor ) return ((RubyParserVisitor extends T>)visitor).visitBreakWithoutArguments(this);
else return visitor.visitChildren(this);
}
}
public static class RedoWithoutArgumentsContext extends PrimaryContext {
public TerminalNode REDO() { return getToken(RubyParser.REDO, 0); }
public RedoWithoutArgumentsContext(PrimaryContext ctx) { copyFrom(ctx); }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).enterRedoWithoutArguments(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).exitRedoWithoutArguments(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof RubyParserVisitor ) return ((RubyParserVisitor extends T>)visitor).visitRedoWithoutArguments(this);
else return visitor.visitChildren(this);
}
}
public static class NextWithoutArgumentsContext extends PrimaryContext {
public TerminalNode NEXT() { return getToken(RubyParser.NEXT, 0); }
public NextWithoutArgumentsContext(PrimaryContext ctx) { copyFrom(ctx); }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).enterNextWithoutArguments(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).exitNextWithoutArguments(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof RubyParserVisitor ) return ((RubyParserVisitor extends T>)visitor).visitNextWithoutArguments(this);
else return visitor.visitChildren(this);
}
}
public static class RetryWithoutArgumentsContext extends PrimaryContext {
public TerminalNode RETRY() { return getToken(RubyParser.RETRY, 0); }
public RetryWithoutArgumentsContext(PrimaryContext ctx) { copyFrom(ctx); }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).enterRetryWithoutArguments(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).exitRetryWithoutArguments(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof RubyParserVisitor ) return ((RubyParserVisitor extends T>)visitor).visitRetryWithoutArguments(this);
else return visitor.visitChildren(this);
}
}
public final PrimaryContext primary() throws RecognitionException {
PrimaryContext _localctx = new PrimaryContext(_ctx, getState());
enterRule(_localctx, 82, RULE_primary);
try {
setState(1004);
_errHandler.sync(this);
switch (_input.LA(1)) {
case RETURN:
_localctx = new ReturnWithoutArgumentsContext(_localctx);
enterOuterAlt(_localctx, 1);
{
setState(998);
match(RETURN);
}
break;
case BREAK:
_localctx = new BreakWithoutArgumentsContext(_localctx);
enterOuterAlt(_localctx, 2);
{
setState(999);
match(BREAK);
}
break;
case NEXT:
_localctx = new NextWithoutArgumentsContext(_localctx);
enterOuterAlt(_localctx, 3);
{
setState(1000);
match(NEXT);
}
break;
case REDO:
_localctx = new RedoWithoutArgumentsContext(_localctx);
enterOuterAlt(_localctx, 4);
{
setState(1001);
match(REDO);
}
break;
case RETRY:
_localctx = new RetryWithoutArgumentsContext(_localctx);
enterOuterAlt(_localctx, 5);
{
setState(1002);
match(RETRY);
}
break;
case REGULAR_EXPRESSION_START:
case LBRACK:
case LPAREN:
case LCURLY:
case COLON:
case COLON2:
case DOT2:
case DOT3:
case MINUSGT:
case EMARK:
case PLUS:
case MINUS:
case TILDE:
case SINGLE_QUOTED_STRING_LITERAL:
case DOUBLE_QUOTED_STRING_START:
case QUOTED_NON_EXPANDED_STRING_LITERAL_START:
case QUOTED_EXPANDED_STRING_LITERAL_START:
case QUOTED_EXPANDED_REGULAR_EXPRESSION_START:
case QUOTED_EXPANDED_EXTERNAL_COMMAND_LITERAL_START:
case QUOTED_NON_EXPANDED_STRING_ARRAY_LITERAL_START:
case QUOTED_EXPANDED_STRING_ARRAY_LITERAL_START:
case HERE_DOC:
case QUOTED_NON_EXPANDED_SYMBOL_ARRAY_LITERAL_START:
case QUOTED_EXPANDED_SYMBOL_ARRAY_LITERAL_START:
case DECIMAL_INTEGER_LITERAL:
case BINARY_INTEGER_LITERAL:
case OCTAL_INTEGER_LITERAL:
case HEXADECIMAL_INTEGER_LITERAL:
case FLOAT_LITERAL_WITHOUT_EXPONENT:
case FLOAT_LITERAL_WITH_EXPONENT:
case SYMBOL_LITERAL:
case LOCAL_VARIABLE_IDENTIFIER:
case LINE__:
case ENCODING__:
case FILE__:
case BEGIN:
case CASE:
case CLASS:
case DEF:
case IS_DEFINED:
case FOR:
case FALSE:
case IF:
case MODULE:
case NIL:
case SELF:
case SUPER:
case TRUE:
case UNLESS:
case UNTIL:
case WHILE:
case YIELD:
case GLOBAL_VARIABLE_IDENTIFIER:
case INSTANCE_VARIABLE_IDENTIFIER:
case CLASS_VARIABLE_IDENTIFIER:
case CONSTANT_IDENTIFIER:
_localctx = new PrimaryValuePrimaryContext(_localctx);
enterOuterAlt(_localctx, 6);
{
setState(1003);
primaryValue(0);
}
break;
default:
throw new NoViableAltException(this);
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class HashLiteralContext extends ParserRuleContext {
public TerminalNode LCURLY() { return getToken(RubyParser.LCURLY, 0); }
public TerminalNode RCURLY() { return getToken(RubyParser.RCURLY, 0); }
public List NL() { return getTokens(RubyParser.NL); }
public TerminalNode NL(int i) {
return getToken(RubyParser.NL, i);
}
public AssociationListContext associationList() {
return getRuleContext(AssociationListContext.class,0);
}
public TerminalNode COMMA() { return getToken(RubyParser.COMMA, 0); }
public HashLiteralContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_hashLiteral; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).enterHashLiteral(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).exitHashLiteral(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof RubyParserVisitor ) return ((RubyParserVisitor extends T>)visitor).visitHashLiteral(this);
else return visitor.visitChildren(this);
}
}
public final HashLiteralContext hashLiteral() throws RecognitionException {
HashLiteralContext _localctx = new HashLiteralContext(_ctx, getState());
enterRule(_localctx, 84, RULE_hashLiteral);
int _la;
try {
int _alt;
enterOuterAlt(_localctx, 1);
{
setState(1006);
match(LCURLY);
setState(1010);
_errHandler.sync(this);
_alt = getInterpreter().adaptivePredict(_input,125,_ctx);
while ( _alt!=2 && _alt!=org.antlr.v4.runtime.atn.ATN.INVALID_ALT_NUMBER ) {
if ( _alt==1 ) {
{
{
setState(1007);
match(NL);
}
}
}
setState(1012);
_errHandler.sync(this);
_alt = getInterpreter().adaptivePredict(_input,125,_ctx);
}
setState(1017);
_errHandler.sync(this);
_la = _input.LA(1);
if (((((_la - 3)) & ~0x3f) == 0 && ((1L << (_la - 3)) & ((1L << (REGULAR_EXPRESSION_START - 3)) | (1L << (LBRACK - 3)) | (1L << (LPAREN - 3)) | (1L << (LCURLY - 3)) | (1L << (COLON - 3)) | (1L << (COLON2 - 3)) | (1L << (DOT2 - 3)) | (1L << (DOT3 - 3)) | (1L << (MINUSGT - 3)) | (1L << (EMARK - 3)) | (1L << (PLUS - 3)) | (1L << (MINUS - 3)) | (1L << (STAR2 - 3)) | (1L << (TILDE - 3)) | (1L << (SINGLE_QUOTED_STRING_LITERAL - 3)) | (1L << (DOUBLE_QUOTED_STRING_START - 3)) | (1L << (QUOTED_NON_EXPANDED_STRING_LITERAL_START - 3)) | (1L << (QUOTED_EXPANDED_STRING_LITERAL_START - 3)) | (1L << (QUOTED_EXPANDED_REGULAR_EXPRESSION_START - 3)))) != 0) || ((((_la - 67)) & ~0x3f) == 0 && ((1L << (_la - 67)) & ((1L << (QUOTED_EXPANDED_EXTERNAL_COMMAND_LITERAL_START - 67)) | (1L << (QUOTED_NON_EXPANDED_STRING_ARRAY_LITERAL_START - 67)) | (1L << (QUOTED_EXPANDED_STRING_ARRAY_LITERAL_START - 67)) | (1L << (HERE_DOC - 67)) | (1L << (QUOTED_NON_EXPANDED_SYMBOL_ARRAY_LITERAL_START - 67)) | (1L << (QUOTED_EXPANDED_SYMBOL_ARRAY_LITERAL_START - 67)) | (1L << (DECIMAL_INTEGER_LITERAL - 67)) | (1L << (BINARY_INTEGER_LITERAL - 67)) | (1L << (OCTAL_INTEGER_LITERAL - 67)) | (1L << (HEXADECIMAL_INTEGER_LITERAL - 67)) | (1L << (FLOAT_LITERAL_WITHOUT_EXPONENT - 67)) | (1L << (FLOAT_LITERAL_WITH_EXPONENT - 67)) | (1L << (SYMBOL_LITERAL - 67)) | (1L << (LOCAL_VARIABLE_IDENTIFIER - 67)) | (1L << (LINE__ - 67)) | (1L << (ENCODING__ - 67)) | (1L << (FILE__ - 67)) | (1L << (BEGIN_ - 67)) | (1L << (END_ - 67)) | (1L << (ALIAS - 67)) | (1L << (AND - 67)) | (1L << (BEGIN - 67)) | (1L << (BREAK - 67)) | (1L << (CASE - 67)) | (1L << (CLASS - 67)) | (1L << (DEF - 67)) | (1L << (IS_DEFINED - 67)) | (1L << (DO - 67)) | (1L << (ELSE - 67)) | (1L << (ELSIF - 67)) | (1L << (END - 67)) | (1L << (ENSURE - 67)) | (1L << (FOR - 67)) | (1L << (FALSE - 67)) | (1L << (IF - 67)) | (1L << (IN - 67)) | (1L << (MODULE - 67)) | (1L << (NEXT - 67)) | (1L << (NIL - 67)) | (1L << (NOT - 67)) | (1L << (OR - 67)) | (1L << (REDO - 67)) | (1L << (RESCUE - 67)) | (1L << (RETRY - 67)) | (1L << (RETURN - 67)) | (1L << (SELF - 67)) | (1L << (SUPER - 67)) | (1L << (THEN - 67)) | (1L << (TRUE - 67)) | (1L << (UNDEF - 67)) | (1L << (UNLESS - 67)) | (1L << (UNTIL - 67)) | (1L << (WHEN - 67)) | (1L << (WHILE - 67)) | (1L << (YIELD - 67)) | (1L << (GLOBAL_VARIABLE_IDENTIFIER - 67)) | (1L << (INSTANCE_VARIABLE_IDENTIFIER - 67)) | (1L << (CLASS_VARIABLE_IDENTIFIER - 67)) | (1L << (CONSTANT_IDENTIFIER - 67)))) != 0)) {
{
setState(1013);
associationList();
setState(1015);
_errHandler.sync(this);
_la = _input.LA(1);
if (_la==COMMA) {
{
setState(1014);
match(COMMA);
}
}
}
}
setState(1022);
_errHandler.sync(this);
_la = _input.LA(1);
while (_la==NL) {
{
{
setState(1019);
match(NL);
}
}
setState(1024);
_errHandler.sync(this);
_la = _input.LA(1);
}
setState(1025);
match(RCURLY);
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class PrimaryValueContext extends ParserRuleContext {
public PrimaryValueContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_primaryValue; }
public PrimaryValueContext() { }
public void copyFrom(PrimaryValueContext ctx) {
super.copyFrom(ctx);
}
}
public static class MethodDefinitionContext extends PrimaryValueContext {
public TerminalNode DEF() { return getToken(RubyParser.DEF, 0); }
public DefinedMethodNameContext definedMethodName() {
return getRuleContext(DefinedMethodNameContext.class,0);
}
public MethodParameterPartContext methodParameterPart() {
return getRuleContext(MethodParameterPartContext.class,0);
}
public BodyStatementContext bodyStatement() {
return getRuleContext(BodyStatementContext.class,0);
}
public TerminalNode END() { return getToken(RubyParser.END, 0); }
public MethodDefinitionContext(PrimaryValueContext ctx) { copyFrom(ctx); }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).enterMethodDefinition(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).exitMethodDefinition(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof RubyParserVisitor ) return ((RubyParserVisitor extends T>)visitor).visitMethodDefinition(this);
else return visitor.visitChildren(this);
}
}
public static class BeginEndExpressionContext extends PrimaryValueContext {
public TerminalNode BEGIN() { return getToken(RubyParser.BEGIN, 0); }
public BodyStatementContext bodyStatement() {
return getRuleContext(BodyStatementContext.class,0);
}
public TerminalNode END() { return getToken(RubyParser.END, 0); }
public BeginEndExpressionContext(PrimaryValueContext ctx) { copyFrom(ctx); }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).enterBeginEndExpression(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).exitBeginEndExpression(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof RubyParserVisitor ) return ((RubyParserVisitor extends T>)visitor).visitBeginEndExpression(this);
else return visitor.visitChildren(this);
}
}
public static class IndexingAccessExpressionContext extends PrimaryValueContext {
public PrimaryValueContext primaryValue() {
return getRuleContext(PrimaryValueContext.class,0);
}
public TerminalNode LBRACK() { return getToken(RubyParser.LBRACK, 0); }
public TerminalNode RBRACK() { return getToken(RubyParser.RBRACK, 0); }
public IndexingArgumentListContext indexingArgumentList() {
return getRuleContext(IndexingArgumentListContext.class,0);
}
public IndexingAccessExpressionContext(PrimaryValueContext ctx) { copyFrom(ctx); }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).enterIndexingAccessExpression(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).exitIndexingAccessExpression(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof RubyParserVisitor ) return ((RubyParserVisitor extends T>)visitor).visitIndexingAccessExpression(this);
else return visitor.visitChildren(this);
}
}
public static class ConstantAssignmentExpressionContext extends PrimaryValueContext {
public TerminalNode COLON2() { return getToken(RubyParser.COLON2, 0); }
public TerminalNode CONSTANT_IDENTIFIER() { return getToken(RubyParser.CONSTANT_IDENTIFIER, 0); }
public AssignmentOperatorContext assignmentOperator() {
return getRuleContext(AssignmentOperatorContext.class,0);
}
public OperatorExpressionContext operatorExpression() {
return getRuleContext(OperatorExpressionContext.class,0);
}
public List NL() { return getTokens(RubyParser.NL); }
public TerminalNode NL(int i) {
return getToken(RubyParser.NL, i);
}
public ConstantAssignmentExpressionContext(PrimaryValueContext ctx) { copyFrom(ctx); }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).enterConstantAssignmentExpression(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).exitConstantAssignmentExpression(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof RubyParserVisitor ) return ((RubyParserVisitor extends T>)visitor).visitConstantAssignmentExpression(this);
else return visitor.visitChildren(this);
}
}
public static class UntilExpressionContext extends PrimaryValueContext {
public TerminalNode UNTIL() { return getToken(RubyParser.UNTIL, 0); }
public ExpressionOrCommandContext expressionOrCommand() {
return getRuleContext(ExpressionOrCommandContext.class,0);
}
public DoClauseContext doClause() {
return getRuleContext(DoClauseContext.class,0);
}
public TerminalNode END() { return getToken(RubyParser.END, 0); }
public List NL() { return getTokens(RubyParser.NL); }
public TerminalNode NL(int i) {
return getToken(RubyParser.NL, i);
}
public UntilExpressionContext(PrimaryValueContext ctx) { copyFrom(ctx); }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).enterUntilExpression(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).exitUntilExpression(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof RubyParserVisitor ) return ((RubyParserVisitor extends T>)visitor).visitUntilExpression(this);
else return visitor.visitChildren(this);
}
}
public static class BoundedRangeExpressionContext extends PrimaryValueContext {
public List primaryValue() {
return getRuleContexts(PrimaryValueContext.class);
}
public PrimaryValueContext primaryValue(int i) {
return getRuleContext(PrimaryValueContext.class,i);
}
public RangeOperatorContext rangeOperator() {
return getRuleContext(RangeOperatorContext.class,0);
}
public List NL() { return getTokens(RubyParser.NL); }
public TerminalNode NL(int i) {
return getToken(RubyParser.NL, i);
}
public BoundedRangeExpressionContext(PrimaryValueContext ctx) { copyFrom(ctx); }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).enterBoundedRangeExpression(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).exitBoundedRangeExpression(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof RubyParserVisitor ) return ((RubyParserVisitor extends T>)visitor).visitBoundedRangeExpression(this);
else return visitor.visitChildren(this);
}
}
public static class ModuleDefinitionContext extends PrimaryValueContext {
public TerminalNode MODULE() { return getToken(RubyParser.MODULE, 0); }
public ClassPathContext classPath() {
return getRuleContext(ClassPathContext.class,0);
}
public BodyStatementContext bodyStatement() {
return getRuleContext(BodyStatementContext.class,0);
}
public TerminalNode END() { return getToken(RubyParser.END, 0); }
public ModuleDefinitionContext(PrimaryValueContext ctx) { copyFrom(ctx); }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).enterModuleDefinition(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).exitModuleDefinition(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof RubyParserVisitor ) return ((RubyParserVisitor extends T>)visitor).visitModuleDefinition(this);
else return visitor.visitChildren(this);
}
}
public static class SingletonMethodDefinitionContext extends PrimaryValueContext {
public Token op;
public TerminalNode DEF() { return getToken(RubyParser.DEF, 0); }
public SingletonObjectContext singletonObject() {
return getRuleContext(SingletonObjectContext.class,0);
}
public DefinedMethodNameContext definedMethodName() {
return getRuleContext(DefinedMethodNameContext.class,0);
}
public MethodParameterPartContext methodParameterPart() {
return getRuleContext(MethodParameterPartContext.class,0);
}
public BodyStatementContext bodyStatement() {
return getRuleContext(BodyStatementContext.class,0);
}
public TerminalNode END() { return getToken(RubyParser.END, 0); }
public TerminalNode DOT() { return getToken(RubyParser.DOT, 0); }
public TerminalNode COLON2() { return getToken(RubyParser.COLON2, 0); }
public SingletonMethodDefinitionContext(PrimaryValueContext ctx) { copyFrom(ctx); }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).enterSingletonMethodDefinition(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).exitSingletonMethodDefinition(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof RubyParserVisitor ) return ((RubyParserVisitor extends T>)visitor).visitSingletonMethodDefinition(this);
else return visitor.visitChildren(this);
}
}
public static class BitwiseAndExpressionContext extends PrimaryValueContext {
public Token bitwiseAndOperator;
public List primaryValue() {
return getRuleContexts(PrimaryValueContext.class);
}
public PrimaryValueContext primaryValue(int i) {
return getRuleContext(PrimaryValueContext.class,i);
}
public TerminalNode AMP() { return getToken(RubyParser.AMP, 0); }
public List NL() { return getTokens(RubyParser.NL); }
public TerminalNode NL(int i) {
return getToken(RubyParser.NL, i);
}
public BitwiseAndExpressionContext(PrimaryValueContext ctx) { copyFrom(ctx); }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).enterBitwiseAndExpression(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).exitBitwiseAndExpression(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof RubyParserVisitor ) return ((RubyParserVisitor extends T>)visitor).visitBitwiseAndExpression(this);
else return visitor.visitChildren(this);
}
}
public static class LogicalAndExpressionContext extends PrimaryValueContext {
public Token andOperator;
public List primaryValue() {
return getRuleContexts(PrimaryValueContext.class);
}
public PrimaryValueContext primaryValue(int i) {
return getRuleContext(PrimaryValueContext.class,i);
}
public TerminalNode AMP2() { return getToken(RubyParser.AMP2, 0); }
public TerminalNode RETURN() { return getToken(RubyParser.RETURN, 0); }
public List NL() { return getTokens(RubyParser.NL); }
public TerminalNode NL(int i) {
return getToken(RubyParser.NL, i);
}
public LogicalAndExpressionContext(PrimaryValueContext ctx) { copyFrom(ctx); }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).enterLogicalAndExpression(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).exitLogicalAndExpression(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof RubyParserVisitor ) return ((RubyParserVisitor extends T>)visitor).visitLogicalAndExpression(this);
else return visitor.visitChildren(this);
}
}
public static class MemberAccessExpressionContext extends PrimaryValueContext {
public Token op;
public PrimaryValueContext primaryValue() {
return getRuleContext(PrimaryValueContext.class,0);
}
public MethodNameContext methodName() {
return getRuleContext(MethodNameContext.class,0);
}
public TerminalNode AMPDOT() { return getToken(RubyParser.AMPDOT, 0); }
public TerminalNode DOT() { return getToken(RubyParser.DOT, 0); }
public TerminalNode COLON2() { return getToken(RubyParser.COLON2, 0); }
public List NL() { return getTokens(RubyParser.NL); }
public TerminalNode NL(int i) {
return getToken(RubyParser.NL, i);
}
public ArgumentWithParenthesesContext argumentWithParentheses() {
return getRuleContext(ArgumentWithParenthesesContext.class,0);
}
public BlockContext block() {
return getRuleContext(BlockContext.class,0);
}
public MemberAccessExpressionContext(PrimaryValueContext ctx) { copyFrom(ctx); }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).enterMemberAccessExpression(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).exitMemberAccessExpression(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof RubyParserVisitor ) return ((RubyParserVisitor extends T>)visitor).visitMemberAccessExpression(this);
else return visitor.visitChildren(this);
}
}
public static class UnaryExpressionContext extends PrimaryValueContext {
public UnaryOperatorContext unaryOperator() {
return getRuleContext(UnaryOperatorContext.class,0);
}
public PrimaryValueContext primaryValue() {
return getRuleContext(PrimaryValueContext.class,0);
}
public UnaryExpressionContext(PrimaryValueContext ctx) { copyFrom(ctx); }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).enterUnaryExpression(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).exitUnaryExpression(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof RubyParserVisitor ) return ((RubyParserVisitor extends T>)visitor).visitUnaryExpression(this);
else return visitor.visitChildren(this);
}
}
public static class NumericLiteralContext extends PrimaryValueContext {
public Token sign;
public UnsignedNumericLiteralContext unsignedNumericLiteral() {
return getRuleContext(UnsignedNumericLiteralContext.class,0);
}
public TerminalNode PLUS() { return getToken(RubyParser.PLUS, 0); }
public TerminalNode MINUS() { return getToken(RubyParser.MINUS, 0); }
public NumericLiteralContext(PrimaryValueContext ctx) { copyFrom(ctx); }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).enterNumericLiteral(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).exitNumericLiteral(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof RubyParserVisitor ) return ((RubyParserVisitor extends T>)visitor).visitNumericLiteral(this);
else return visitor.visitChildren(this);
}
}
public static class ClassDefinitionContext extends PrimaryValueContext {
public TerminalNode CLASS() { return getToken(RubyParser.CLASS, 0); }
public ClassPathContext classPath() {
return getRuleContext(ClassPathContext.class,0);
}
public BodyStatementContext bodyStatement() {
return getRuleContext(BodyStatementContext.class,0);
}
public TerminalNode END() { return getToken(RubyParser.END, 0); }
public TerminalNode LT() { return getToken(RubyParser.LT, 0); }
public CommandOrPrimaryValueClassContext commandOrPrimaryValueClass() {
return getRuleContext(CommandOrPrimaryValueClassContext.class,0);
}
public TerminalNode SEMI() { return getToken(RubyParser.SEMI, 0); }
public TerminalNode NL() { return getToken(RubyParser.NL, 0); }
public ClassDefinitionContext(PrimaryValueContext ctx) { copyFrom(ctx); }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).enterClassDefinition(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).exitClassDefinition(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof RubyParserVisitor ) return ((RubyParserVisitor extends T>)visitor).visitClassDefinition(this);
else return visitor.visitChildren(this);
}
}
public static class QuotedExpandedSymbolArrayLiteralContext extends PrimaryValueContext {
public TerminalNode QUOTED_EXPANDED_SYMBOL_ARRAY_LITERAL_START() { return getToken(RubyParser.QUOTED_EXPANDED_SYMBOL_ARRAY_LITERAL_START, 0); }
public TerminalNode QUOTED_EXPANDED_SYMBOL_ARRAY_LITERAL_END() { return getToken(RubyParser.QUOTED_EXPANDED_SYMBOL_ARRAY_LITERAL_END, 0); }
public QuotedExpandedArrayElementListContext quotedExpandedArrayElementList() {
return getRuleContext(QuotedExpandedArrayElementListContext.class,0);
}
public QuotedExpandedSymbolArrayLiteralContext(PrimaryValueContext ctx) { copyFrom(ctx); }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).enterQuotedExpandedSymbolArrayLiteral(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).exitQuotedExpandedSymbolArrayLiteral(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof RubyParserVisitor ) return ((RubyParserVisitor extends T>)visitor).visitQuotedExpandedSymbolArrayLiteral(this);
else return visitor.visitChildren(this);
}
}
public static class ForExpressionContext extends PrimaryValueContext {
public TerminalNode FOR() { return getToken(RubyParser.FOR, 0); }
public ForVariableContext forVariable() {
return getRuleContext(ForVariableContext.class,0);
}
public TerminalNode IN() { return getToken(RubyParser.IN, 0); }
public CommandOrPrimaryValueContext commandOrPrimaryValue() {
return getRuleContext(CommandOrPrimaryValueContext.class,0);
}
public DoClauseContext doClause() {
return getRuleContext(DoClauseContext.class,0);
}
public TerminalNode END() { return getToken(RubyParser.END, 0); }
public List NL() { return getTokens(RubyParser.NL); }
public TerminalNode NL(int i) {
return getToken(RubyParser.NL, i);
}
public ForExpressionContext(PrimaryValueContext ctx) { copyFrom(ctx); }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).enterForExpression(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).exitForExpression(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof RubyParserVisitor ) return ((RubyParserVisitor extends T>)visitor).visitForExpression(this);
else return visitor.visitChildren(this);
}
}
public static class BracketedArrayLiteralContext extends PrimaryValueContext {
public TerminalNode LBRACK() { return getToken(RubyParser.LBRACK, 0); }
public TerminalNode RBRACK() { return getToken(RubyParser.RBRACK, 0); }
public List NL() { return getTokens(RubyParser.NL); }
public TerminalNode NL(int i) {
return getToken(RubyParser.NL, i);
}
public BracketedArrayElementListContext bracketedArrayElementList() {
return getRuleContext(BracketedArrayElementListContext.class,0);
}
public BracketedArrayLiteralContext(PrimaryValueContext ctx) { copyFrom(ctx); }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).enterBracketedArrayLiteral(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).exitBracketedArrayLiteral(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof RubyParserVisitor ) return ((RubyParserVisitor extends T>)visitor).visitBracketedArrayLiteral(this);
else return visitor.visitChildren(this);
}
}
public static class LambdaExpressionContext extends PrimaryValueContext {
public TerminalNode MINUSGT() { return getToken(RubyParser.MINUSGT, 0); }
public BlockContext block() {
return getRuleContext(BlockContext.class,0);
}
public LambdaExpressionParameterListContext lambdaExpressionParameterList() {
return getRuleContext(LambdaExpressionParameterListContext.class,0);
}
public LambdaExpressionContext(PrimaryValueContext ctx) { copyFrom(ctx); }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).enterLambdaExpression(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).exitLambdaExpression(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof RubyParserVisitor ) return ((RubyParserVisitor extends T>)visitor).visitLambdaExpression(this);
else return visitor.visitChildren(this);
}
}
public static class CaseWithoutExpressionContext extends PrimaryValueContext {
public TerminalNode CASE() { return getToken(RubyParser.CASE, 0); }
public TerminalNode END() { return getToken(RubyParser.END, 0); }
public List whenClause() {
return getRuleContexts(WhenClauseContext.class);
}
public WhenClauseContext whenClause(int i) {
return getRuleContext(WhenClauseContext.class,i);
}
public ElseClauseContext elseClause() {
return getRuleContext(ElseClauseContext.class,0);
}
public List SEMI() { return getTokens(RubyParser.SEMI); }
public TerminalNode SEMI(int i) {
return getToken(RubyParser.SEMI, i);
}
public List NL() { return getTokens(RubyParser.NL); }
public TerminalNode NL(int i) {
return getToken(RubyParser.NL, i);
}
public CaseWithoutExpressionContext(PrimaryValueContext ctx) { copyFrom(ctx); }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).enterCaseWithoutExpression(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).exitCaseWithoutExpression(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof RubyParserVisitor ) return ((RubyParserVisitor extends T>)visitor).visitCaseWithoutExpression(this);
else return visitor.visitChildren(this);
}
}
public static class QuotedNonExpandedStringLiteralContext extends PrimaryValueContext {
public TerminalNode QUOTED_NON_EXPANDED_STRING_LITERAL_START() { return getToken(RubyParser.QUOTED_NON_EXPANDED_STRING_LITERAL_START, 0); }
public TerminalNode QUOTED_NON_EXPANDED_STRING_LITERAL_END() { return getToken(RubyParser.QUOTED_NON_EXPANDED_STRING_LITERAL_END, 0); }
public TerminalNode NON_EXPANDED_LITERAL_CHARACTER_SEQUENCE() { return getToken(RubyParser.NON_EXPANDED_LITERAL_CHARACTER_SEQUENCE, 0); }
public QuotedNonExpandedStringLiteralContext(PrimaryValueContext ctx) { copyFrom(ctx); }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).enterQuotedNonExpandedStringLiteral(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).exitQuotedNonExpandedStringLiteral(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof RubyParserVisitor ) return ((RubyParserVisitor extends T>)visitor).visitQuotedNonExpandedStringLiteral(this);
else return visitor.visitChildren(this);
}
}
public static class ShiftExpressionContext extends PrimaryValueContext {
public List primaryValue() {
return getRuleContexts(PrimaryValueContext.class);
}
public PrimaryValueContext primaryValue(int i) {
return getRuleContext(PrimaryValueContext.class,i);
}
public BitwiseShiftOperatorContext bitwiseShiftOperator() {
return getRuleContext(BitwiseShiftOperatorContext.class,0);
}
public List NL() { return getTokens(RubyParser.NL); }
public TerminalNode NL(int i) {
return getToken(RubyParser.NL, i);
}
public ShiftExpressionContext(PrimaryValueContext ctx) { copyFrom(ctx); }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).enterShiftExpression(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).exitShiftExpression(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof RubyParserVisitor ) return ((RubyParserVisitor extends T>)visitor).visitShiftExpression(this);
else return visitor.visitChildren(this);
}
}
public static class EndlessMethodDefinitionContext extends PrimaryValueContext {
public TerminalNode DEF() { return getToken(RubyParser.DEF, 0); }
public DefinedMethodNameContext definedMethodName() {
return getRuleContext(DefinedMethodNameContext.class,0);
}
public TerminalNode EQ() { return getToken(RubyParser.EQ, 0); }
public StatementContext statement() {
return getRuleContext(StatementContext.class,0);
}
public TerminalNode LPAREN() { return getToken(RubyParser.LPAREN, 0); }
public TerminalNode RPAREN() { return getToken(RubyParser.RPAREN, 0); }
public List NL() { return getTokens(RubyParser.NL); }
public TerminalNode NL(int i) {
return getToken(RubyParser.NL, i);
}
public ParameterListContext parameterList() {
return getRuleContext(ParameterListContext.class,0);
}
public EndlessMethodDefinitionContext(PrimaryValueContext ctx) { copyFrom(ctx); }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).enterEndlessMethodDefinition(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).exitEndlessMethodDefinition(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof RubyParserVisitor ) return ((RubyParserVisitor extends T>)visitor).visitEndlessMethodDefinition(this);
else return visitor.visitChildren(this);
}
}
public static class QuotedExpandedExternalCommandLiteralContext extends PrimaryValueContext {
public TerminalNode QUOTED_EXPANDED_EXTERNAL_COMMAND_LITERAL_START() { return getToken(RubyParser.QUOTED_EXPANDED_EXTERNAL_COMMAND_LITERAL_START, 0); }
public TerminalNode QUOTED_EXPANDED_EXTERNAL_COMMAND_LITERAL_END() { return getToken(RubyParser.QUOTED_EXPANDED_EXTERNAL_COMMAND_LITERAL_END, 0); }
public List quotedExpandedLiteralStringContent() {
return getRuleContexts(QuotedExpandedLiteralStringContentContext.class);
}
public QuotedExpandedLiteralStringContentContext quotedExpandedLiteralStringContent(int i) {
return getRuleContext(QuotedExpandedLiteralStringContentContext.class,i);
}
public QuotedExpandedExternalCommandLiteralContext(PrimaryValueContext ctx) { copyFrom(ctx); }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).enterQuotedExpandedExternalCommandLiteral(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).exitQuotedExpandedExternalCommandLiteral(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof RubyParserVisitor ) return ((RubyParserVisitor extends T>)visitor).visitQuotedExpandedExternalCommandLiteral(this);
else return visitor.visitChildren(this);
}
}
public static class RegularExpressionLiteralContext extends PrimaryValueContext {
public TerminalNode REGULAR_EXPRESSION_START() { return getToken(RubyParser.REGULAR_EXPRESSION_START, 0); }
public TerminalNode REGULAR_EXPRESSION_END() { return getToken(RubyParser.REGULAR_EXPRESSION_END, 0); }
public List regexpLiteralContent() {
return getRuleContexts(RegexpLiteralContentContext.class);
}
public RegexpLiteralContentContext regexpLiteralContent(int i) {
return getRuleContext(RegexpLiteralContentContext.class,i);
}
public RegularExpressionLiteralContext(PrimaryValueContext ctx) { copyFrom(ctx); }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).enterRegularExpressionLiteral(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).exitRegularExpressionLiteral(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof RubyParserVisitor ) return ((RubyParserVisitor extends T>)visitor).visitRegularExpressionLiteral(this);
else return visitor.visitChildren(this);
}
}
public static class BeginlessRangeExpressionContext extends PrimaryValueContext {
public RangeOperatorContext rangeOperator() {
return getRuleContext(RangeOperatorContext.class,0);
}
public PrimaryValueContext primaryValue() {
return getRuleContext(PrimaryValueContext.class,0);
}
public BeginlessRangeExpressionContext(PrimaryValueContext ctx) { copyFrom(ctx); }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).enterBeginlessRangeExpression(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).exitBeginlessRangeExpression(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof RubyParserVisitor ) return ((RubyParserVisitor extends T>)visitor).visitBeginlessRangeExpression(this);
else return visitor.visitChildren(this);
}
}
public static class PowerExpressionContext extends PrimaryValueContext {
public Token powerOperator;
public List primaryValue() {
return getRuleContexts(PrimaryValueContext.class);
}
public PrimaryValueContext primaryValue(int i) {
return getRuleContext(PrimaryValueContext.class,i);
}
public TerminalNode STAR2() { return getToken(RubyParser.STAR2, 0); }
public List NL() { return getTokens(RubyParser.NL); }
public TerminalNode NL(int i) {
return getToken(RubyParser.NL, i);
}
public PowerExpressionContext(PrimaryValueContext ctx) { copyFrom(ctx); }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).enterPowerExpression(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).exitPowerExpression(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof RubyParserVisitor ) return ((RubyParserVisitor extends T>)visitor).visitPowerExpression(this);
else return visitor.visitChildren(this);
}
}
public static class QuotedNonExpandedSymbolArrayLiteralContext extends PrimaryValueContext {
public TerminalNode QUOTED_NON_EXPANDED_SYMBOL_ARRAY_LITERAL_START() { return getToken(RubyParser.QUOTED_NON_EXPANDED_SYMBOL_ARRAY_LITERAL_START, 0); }
public TerminalNode QUOTED_NON_EXPANDED_SYMBOL_ARRAY_LITERAL_END() { return getToken(RubyParser.QUOTED_NON_EXPANDED_SYMBOL_ARRAY_LITERAL_END, 0); }
public QuotedNonExpandedArrayElementListContext quotedNonExpandedArrayElementList() {
return getRuleContext(QuotedNonExpandedArrayElementListContext.class,0);
}
public QuotedNonExpandedSymbolArrayLiteralContext(PrimaryValueContext ctx) { copyFrom(ctx); }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).enterQuotedNonExpandedSymbolArrayLiteral(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).exitQuotedNonExpandedSymbolArrayLiteral(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof RubyParserVisitor ) return ((RubyParserVisitor extends T>)visitor).visitQuotedNonExpandedSymbolArrayLiteral(this);
else return visitor.visitChildren(this);
}
}
public static class BitwiseOrExpressionContext extends PrimaryValueContext {
public List primaryValue() {
return getRuleContexts(PrimaryValueContext.class);
}
public PrimaryValueContext primaryValue(int i) {
return getRuleContext(PrimaryValueContext.class,i);
}
public BitwiseOrOperatorContext bitwiseOrOperator() {
return getRuleContext(BitwiseOrOperatorContext.class,0);
}
public List NL() { return getTokens(RubyParser.NL); }
public TerminalNode NL(int i) {
return getToken(RubyParser.NL, i);
}
public BitwiseOrExpressionContext(PrimaryValueContext ctx) { copyFrom(ctx); }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).enterBitwiseOrExpression(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).exitBitwiseOrExpression(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof RubyParserVisitor ) return ((RubyParserVisitor extends T>)visitor).visitBitwiseOrExpression(this);
else return visitor.visitChildren(this);
}
}
public static class QuotedExpandedStringLiteralContext extends PrimaryValueContext {
public TerminalNode QUOTED_EXPANDED_STRING_LITERAL_START() { return getToken(RubyParser.QUOTED_EXPANDED_STRING_LITERAL_START, 0); }
public TerminalNode QUOTED_EXPANDED_STRING_LITERAL_END() { return getToken(RubyParser.QUOTED_EXPANDED_STRING_LITERAL_END, 0); }
public List quotedExpandedLiteralStringContent() {
return getRuleContexts(QuotedExpandedLiteralStringContentContext.class);
}
public QuotedExpandedLiteralStringContentContext quotedExpandedLiteralStringContent(int i) {
return getRuleContext(QuotedExpandedLiteralStringContentContext.class,i);
}
public QuotedExpandedStringLiteralContext(PrimaryValueContext ctx) { copyFrom(ctx); }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).enterQuotedExpandedStringLiteral(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).exitQuotedExpandedStringLiteral(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof RubyParserVisitor ) return ((RubyParserVisitor extends T>)visitor).visitQuotedExpandedStringLiteral(this);
else return visitor.visitChildren(this);
}
}
public static class AttributeAssignmentExpressionContext extends PrimaryValueContext {
public Token op;
public PrimaryValueContext primaryValue() {
return getRuleContext(PrimaryValueContext.class,0);
}
public MethodNameContext methodName() {
return getRuleContext(MethodNameContext.class,0);
}
public AssignmentOperatorContext assignmentOperator() {
return getRuleContext(AssignmentOperatorContext.class,0);
}
public OperatorExpressionContext operatorExpression() {
return getRuleContext(OperatorExpressionContext.class,0);
}
public TerminalNode DOT() { return getToken(RubyParser.DOT, 0); }
public TerminalNode COLON2() { return getToken(RubyParser.COLON2, 0); }
public List NL() { return getTokens(RubyParser.NL); }
public TerminalNode NL(int i) {
return getToken(RubyParser.NL, i);
}
public AttributeAssignmentExpressionContext(PrimaryValueContext ctx) { copyFrom(ctx); }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).enterAttributeAssignmentExpression(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).exitAttributeAssignmentExpression(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof RubyParserVisitor ) return ((RubyParserVisitor extends T>)visitor).visitAttributeAssignmentExpression(this);
else return visitor.visitChildren(this);
}
}
public static class EqualityExpressionContext extends PrimaryValueContext {
public List primaryValue() {
return getRuleContexts(PrimaryValueContext.class);
}
public PrimaryValueContext primaryValue(int i) {
return getRuleContext(PrimaryValueContext.class,i);
}
public EqualityOperatorContext equalityOperator() {
return getRuleContext(EqualityOperatorContext.class,0);
}
public List NL() { return getTokens(RubyParser.NL); }
public TerminalNode NL(int i) {
return getToken(RubyParser.NL, i);
}
public EqualityExpressionContext(PrimaryValueContext ctx) { copyFrom(ctx); }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).enterEqualityExpression(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).exitEqualityExpression(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof RubyParserVisitor ) return ((RubyParserVisitor extends T>)visitor).visitEqualityExpression(this);
else return visitor.visitChildren(this);
}
}
public static class BracketAssignmentExpressionContext extends PrimaryValueContext {
public PrimaryValueContext primaryValue() {
return getRuleContext(PrimaryValueContext.class,0);
}
public TerminalNode LBRACK() { return getToken(RubyParser.LBRACK, 0); }
public TerminalNode RBRACK() { return getToken(RubyParser.RBRACK, 0); }
public AssignmentOperatorContext assignmentOperator() {
return getRuleContext(AssignmentOperatorContext.class,0);
}
public OperatorExpressionContext operatorExpression() {
return getRuleContext(OperatorExpressionContext.class,0);
}
public IndexingArgumentListContext indexingArgumentList() {
return getRuleContext(IndexingArgumentListContext.class,0);
}
public List NL() { return getTokens(RubyParser.NL); }
public TerminalNode NL(int i) {
return getToken(RubyParser.NL, i);
}
public BracketAssignmentExpressionContext(PrimaryValueContext ctx) { copyFrom(ctx); }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).enterBracketAssignmentExpression(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).exitBracketAssignmentExpression(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof RubyParserVisitor ) return ((RubyParserVisitor extends T>)visitor).visitBracketAssignmentExpression(this);
else return visitor.visitChildren(this);
}
}
public static class EndlessRangeExpressionContext extends PrimaryValueContext {
public PrimaryValueContext primaryValue() {
return getRuleContext(PrimaryValueContext.class,0);
}
public RangeOperatorContext rangeOperator() {
return getRuleContext(RangeOperatorContext.class,0);
}
public EndlessRangeExpressionContext(PrimaryValueContext ctx) { copyFrom(ctx); }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).enterEndlessRangeExpression(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).exitEndlessRangeExpression(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof RubyParserVisitor ) return ((RubyParserVisitor extends T>)visitor).visitEndlessRangeExpression(this);
else return visitor.visitChildren(this);
}
}
public static class AdditiveExpressionContext extends PrimaryValueContext {
public List primaryValue() {
return getRuleContexts(PrimaryValueContext.class);
}
public PrimaryValueContext primaryValue(int i) {
return getRuleContext(PrimaryValueContext.class,i);
}
public AdditiveOperatorContext additiveOperator() {
return getRuleContext(AdditiveOperatorContext.class,0);
}
public List NL() { return getTokens(RubyParser.NL); }
public TerminalNode NL(int i) {
return getToken(RubyParser.NL, i);
}
public AdditiveExpressionContext(PrimaryValueContext ctx) { copyFrom(ctx); }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).enterAdditiveExpression(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).exitAdditiveExpression(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof RubyParserVisitor ) return ((RubyParserVisitor extends T>)visitor).visitAdditiveExpression(this);
else return visitor.visitChildren(this);
}
}
public static class RelationalExpressionContext extends PrimaryValueContext {
public List primaryValue() {
return getRuleContexts(PrimaryValueContext.class);
}
public PrimaryValueContext primaryValue(int i) {
return getRuleContext(PrimaryValueContext.class,i);
}
public RelationalOperatorContext relationalOperator() {
return getRuleContext(RelationalOperatorContext.class,0);
}
public List NL() { return getTokens(RubyParser.NL); }
public TerminalNode NL(int i) {
return getToken(RubyParser.NL, i);
}
public RelationalExpressionContext(PrimaryValueContext ctx) { copyFrom(ctx); }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).enterRelationalExpression(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).exitRelationalExpression(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof RubyParserVisitor ) return ((RubyParserVisitor extends T>)visitor).visitRelationalExpression(this);
else return visitor.visitChildren(this);
}
}
public static class LocalVariableAssignmentExpressionContext extends PrimaryValueContext {
public VariableContext lhs;
public OperatorExpressionContext rhs;
public AssignmentOperatorContext assignmentOperator() {
return getRuleContext(AssignmentOperatorContext.class,0);
}
public VariableContext variable() {
return getRuleContext(VariableContext.class,0);
}
public OperatorExpressionContext operatorExpression() {
return getRuleContext(OperatorExpressionContext.class,0);
}
public List NL() { return getTokens(RubyParser.NL); }
public TerminalNode NL(int i) {
return getToken(RubyParser.NL, i);
}
public LocalVariableAssignmentExpressionContext(PrimaryValueContext ctx) { copyFrom(ctx); }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).enterLocalVariableAssignmentExpression(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).exitLocalVariableAssignmentExpression(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof RubyParserVisitor ) return ((RubyParserVisitor extends T>)visitor).visitLocalVariableAssignmentExpression(this);
else return visitor.visitChildren(this);
}
}
public static class HereDocsContext extends PrimaryValueContext {
public HereDocContext hereDoc() {
return getRuleContext(HereDocContext.class,0);
}
public HereDocsContext(PrimaryValueContext ctx) { copyFrom(ctx); }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).enterHereDocs(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).exitHereDocs(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof RubyParserVisitor ) return ((RubyParserVisitor extends T>)visitor).visitHereDocs(this);
else return visitor.visitChildren(this);
}
}
public static class AssignmentWithRescueContext extends PrimaryValueContext {
public PrimaryValueContext primaryValue() {
return getRuleContext(PrimaryValueContext.class,0);
}
public AssignmentOperatorContext assignmentOperator() {
return getRuleContext(AssignmentOperatorContext.class,0);
}
public List operatorExpression() {
return getRuleContexts(OperatorExpressionContext.class);
}
public OperatorExpressionContext operatorExpression(int i) {
return getRuleContext(OperatorExpressionContext.class,i);
}
public TerminalNode RESCUE() { return getToken(RubyParser.RESCUE, 0); }
public List NL() { return getTokens(RubyParser.NL); }
public TerminalNode NL(int i) {
return getToken(RubyParser.NL, i);
}
public AssignmentWithRescueContext(PrimaryValueContext ctx) { copyFrom(ctx); }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).enterAssignmentWithRescue(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).exitAssignmentWithRescue(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof RubyParserVisitor ) return ((RubyParserVisitor extends T>)visitor).visitAssignmentWithRescue(this);
else return visitor.visitChildren(this);
}
}
public static class MethodCallWithParenthesesContext extends PrimaryValueContext {
public MethodCallsWithParenthesesContext methodCallsWithParentheses() {
return getRuleContext(MethodCallsWithParenthesesContext.class,0);
}
public MethodCallWithParenthesesContext(PrimaryValueContext ctx) { copyFrom(ctx); }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).enterMethodCallWithParentheses(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).exitMethodCallWithParentheses(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof RubyParserVisitor ) return ((RubyParserVisitor extends T>)visitor).visitMethodCallWithParentheses(this);
else return visitor.visitChildren(this);
}
}
public static class GroupingStatementContext extends PrimaryValueContext {
public TerminalNode LPAREN() { return getToken(RubyParser.LPAREN, 0); }
public CompoundStatementContext compoundStatement() {
return getRuleContext(CompoundStatementContext.class,0);
}
public TerminalNode RPAREN() { return getToken(RubyParser.RPAREN, 0); }
public GroupingStatementContext(PrimaryValueContext ctx) { copyFrom(ctx); }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).enterGroupingStatement(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).exitGroupingStatement(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof RubyParserVisitor ) return ((RubyParserVisitor extends T>)visitor).visitGroupingStatement(this);
else return visitor.visitChildren(this);
}
}
public static class IfExpressionContext extends PrimaryValueContext {
public TerminalNode IF() { return getToken(RubyParser.IF, 0); }
public ExpressionOrCommandContext expressionOrCommand() {
return getRuleContext(ExpressionOrCommandContext.class,0);
}
public ThenClauseContext thenClause() {
return getRuleContext(ThenClauseContext.class,0);
}
public TerminalNode END() { return getToken(RubyParser.END, 0); }
public List NL() { return getTokens(RubyParser.NL); }
public TerminalNode NL(int i) {
return getToken(RubyParser.NL, i);
}
public List elsifClause() {
return getRuleContexts(ElsifClauseContext.class);
}
public ElsifClauseContext elsifClause(int i) {
return getRuleContext(ElsifClauseContext.class,i);
}
public ElseClauseContext elseClause() {
return getRuleContext(ElseClauseContext.class,0);
}
public IfExpressionContext(PrimaryValueContext ctx) { copyFrom(ctx); }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).enterIfExpression(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).exitIfExpression(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof RubyParserVisitor ) return ((RubyParserVisitor extends T>)visitor).visitIfExpression(this);
else return visitor.visitChildren(this);
}
}
public static class QuotedNonExpandedStringArrayLiteralContext extends PrimaryValueContext {
public TerminalNode QUOTED_NON_EXPANDED_STRING_ARRAY_LITERAL_START() { return getToken(RubyParser.QUOTED_NON_EXPANDED_STRING_ARRAY_LITERAL_START, 0); }
public TerminalNode QUOTED_NON_EXPANDED_STRING_ARRAY_LITERAL_END() { return getToken(RubyParser.QUOTED_NON_EXPANDED_STRING_ARRAY_LITERAL_END, 0); }
public QuotedNonExpandedArrayElementListContext quotedNonExpandedArrayElementList() {
return getRuleContext(QuotedNonExpandedArrayElementListContext.class,0);
}
public QuotedNonExpandedStringArrayLiteralContext(PrimaryValueContext ctx) { copyFrom(ctx); }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).enterQuotedNonExpandedStringArrayLiteral(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).exitQuotedNonExpandedStringArrayLiteral(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof RubyParserVisitor ) return ((RubyParserVisitor extends T>)visitor).visitQuotedNonExpandedStringArrayLiteral(this);
else return visitor.visitChildren(this);
}
}
public static class UnlessExpressionContext extends PrimaryValueContext {
public TerminalNode UNLESS() { return getToken(RubyParser.UNLESS, 0); }
public ExpressionOrCommandContext expressionOrCommand() {
return getRuleContext(ExpressionOrCommandContext.class,0);
}
public ThenClauseContext thenClause() {
return getRuleContext(ThenClauseContext.class,0);
}
public TerminalNode END() { return getToken(RubyParser.END, 0); }
public List NL() { return getTokens(RubyParser.NL); }
public TerminalNode NL(int i) {
return getToken(RubyParser.NL, i);
}
public ElseClauseContext elseClause() {
return getRuleContext(ElseClauseContext.class,0);
}
public UnlessExpressionContext(PrimaryValueContext ctx) { copyFrom(ctx); }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).enterUnlessExpression(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).exitUnlessExpression(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof RubyParserVisitor ) return ((RubyParserVisitor extends T>)visitor).visitUnlessExpression(this);
else return visitor.visitChildren(this);
}
}
public static class SingletonClassDefinitionContext extends PrimaryValueContext {
public TerminalNode CLASS() { return getToken(RubyParser.CLASS, 0); }
public TerminalNode LT2() { return getToken(RubyParser.LT2, 0); }
public CommandOrPrimaryValueClassContext commandOrPrimaryValueClass() {
return getRuleContext(CommandOrPrimaryValueClassContext.class,0);
}
public BodyStatementContext bodyStatement() {
return getRuleContext(BodyStatementContext.class,0);
}
public TerminalNode END() { return getToken(RubyParser.END, 0); }
public TerminalNode SEMI() { return getToken(RubyParser.SEMI, 0); }
public TerminalNode NL() { return getToken(RubyParser.NL, 0); }
public SingletonClassDefinitionContext(PrimaryValueContext ctx) { copyFrom(ctx); }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).enterSingletonClassDefinition(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).exitSingletonClassDefinition(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof RubyParserVisitor ) return ((RubyParserVisitor extends T>)visitor).visitSingletonClassDefinition(this);
else return visitor.visitChildren(this);
}
}
public static class QuotedExpandedStringArrayLiteralContext extends PrimaryValueContext {
public TerminalNode QUOTED_EXPANDED_STRING_ARRAY_LITERAL_START() { return getToken(RubyParser.QUOTED_EXPANDED_STRING_ARRAY_LITERAL_START, 0); }
public TerminalNode QUOTED_EXPANDED_STRING_ARRAY_LITERAL_END() { return getToken(RubyParser.QUOTED_EXPANDED_STRING_ARRAY_LITERAL_END, 0); }
public QuotedExpandedArrayElementListContext quotedExpandedArrayElementList() {
return getRuleContext(QuotedExpandedArrayElementListContext.class,0);
}
public QuotedExpandedStringArrayLiteralContext(PrimaryValueContext ctx) { copyFrom(ctx); }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).enterQuotedExpandedStringArrayLiteral(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).exitQuotedExpandedStringArrayLiteral(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof RubyParserVisitor ) return ((RubyParserVisitor extends T>)visitor).visitQuotedExpandedStringArrayLiteral(this);
else return visitor.visitChildren(this);
}
}
public static class QuotedExpandedRegularExpressionLiteralContext extends PrimaryValueContext {
public TerminalNode QUOTED_EXPANDED_REGULAR_EXPRESSION_START() { return getToken(RubyParser.QUOTED_EXPANDED_REGULAR_EXPRESSION_START, 0); }
public TerminalNode QUOTED_EXPANDED_REGULAR_EXPRESSION_END() { return getToken(RubyParser.QUOTED_EXPANDED_REGULAR_EXPRESSION_END, 0); }
public List quotedExpandedLiteralStringContent() {
return getRuleContexts(QuotedExpandedLiteralStringContentContext.class);
}
public QuotedExpandedLiteralStringContentContext quotedExpandedLiteralStringContent(int i) {
return getRuleContext(QuotedExpandedLiteralStringContentContext.class,i);
}
public QuotedExpandedRegularExpressionLiteralContext(PrimaryValueContext ctx) { copyFrom(ctx); }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).enterQuotedExpandedRegularExpressionLiteral(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).exitQuotedExpandedRegularExpressionLiteral(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof RubyParserVisitor ) return ((RubyParserVisitor extends T>)visitor).visitQuotedExpandedRegularExpressionLiteral(this);
else return visitor.visitChildren(this);
}
}
public static class WhileExpressionContext extends PrimaryValueContext {
public TerminalNode WHILE() { return getToken(RubyParser.WHILE, 0); }
public ExpressionOrCommandContext expressionOrCommand() {
return getRuleContext(ExpressionOrCommandContext.class,0);
}
public DoClauseContext doClause() {
return getRuleContext(DoClauseContext.class,0);
}
public TerminalNode END() { return getToken(RubyParser.END, 0); }
public List NL() { return getTokens(RubyParser.NL); }
public TerminalNode NL(int i) {
return getToken(RubyParser.NL, i);
}
public WhileExpressionContext(PrimaryValueContext ctx) { copyFrom(ctx); }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).enterWhileExpression(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).exitWhileExpression(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof RubyParserVisitor ) return ((RubyParserVisitor extends T>)visitor).visitWhileExpression(this);
else return visitor.visitChildren(this);
}
}
public static class SingleQuotedStringExpressionContext extends PrimaryValueContext {
public SingleQuotedStringContext singleQuotedString() {
return getRuleContext(SingleQuotedStringContext.class,0);
}
public List singleOrDoubleQuotedString() {
return getRuleContexts(SingleOrDoubleQuotedStringContext.class);
}
public SingleOrDoubleQuotedStringContext singleOrDoubleQuotedString(int i) {
return getRuleContext(SingleOrDoubleQuotedStringContext.class,i);
}
public SingleQuotedStringExpressionContext(PrimaryValueContext ctx) { copyFrom(ctx); }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).enterSingleQuotedStringExpression(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).exitSingleQuotedStringExpression(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof RubyParserVisitor ) return ((RubyParserVisitor extends T>)visitor).visitSingleQuotedStringExpression(this);
else return visitor.visitChildren(this);
}
}
public static class PrimaryValueHashLiteralContext extends PrimaryValueContext {
public HashLiteralContext hashLiteral() {
return getRuleContext(HashLiteralContext.class,0);
}
public PrimaryValueHashLiteralContext(PrimaryValueContext ctx) { copyFrom(ctx); }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).enterPrimaryValueHashLiteral(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).exitPrimaryValueHashLiteral(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof RubyParserVisitor ) return ((RubyParserVisitor extends T>)visitor).visitPrimaryValueHashLiteral(this);
else return visitor.visitChildren(this);
}
}
public static class MultiplicativeExpressionContext extends PrimaryValueContext {
public List primaryValue() {
return getRuleContexts(PrimaryValueContext.class);
}
public PrimaryValueContext primaryValue(int i) {
return getRuleContext(PrimaryValueContext.class,i);
}
public MultiplicativeOperatorContext multiplicativeOperator() {
return getRuleContext(MultiplicativeOperatorContext.class,0);
}
public List NL() { return getTokens(RubyParser.NL); }
public TerminalNode NL(int i) {
return getToken(RubyParser.NL, i);
}
public MultiplicativeExpressionContext(PrimaryValueContext ctx) { copyFrom(ctx); }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).enterMultiplicativeExpression(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).exitMultiplicativeExpression(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof RubyParserVisitor ) return ((RubyParserVisitor extends T>)visitor).visitMultiplicativeExpression(this);
else return visitor.visitChildren(this);
}
}
public static class LogicalOrExpressionContext extends PrimaryValueContext {
public Token orOperator;
public List primaryValue() {
return getRuleContexts(PrimaryValueContext.class);
}
public PrimaryValueContext primaryValue(int i) {
return getRuleContext(PrimaryValueContext.class,i);
}
public TerminalNode BAR2() { return getToken(RubyParser.BAR2, 0); }
public TerminalNode RETURN() { return getToken(RubyParser.RETURN, 0); }
public List NL() { return getTokens(RubyParser.NL); }
public TerminalNode NL(int i) {
return getToken(RubyParser.NL, i);
}
public LogicalOrExpressionContext(PrimaryValueContext ctx) { copyFrom(ctx); }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).enterLogicalOrExpression(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).exitLogicalOrExpression(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof RubyParserVisitor ) return ((RubyParserVisitor extends T>)visitor).visitLogicalOrExpression(this);
else return visitor.visitChildren(this);
}
}
public static class UnaryMinusExpressionContext extends PrimaryValueContext {
public TerminalNode MINUS() { return getToken(RubyParser.MINUS, 0); }
public PrimaryValueContext primaryValue() {
return getRuleContext(PrimaryValueContext.class,0);
}
public UnaryMinusExpressionContext(PrimaryValueContext ctx) { copyFrom(ctx); }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).enterUnaryMinusExpression(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).exitUnaryMinusExpression(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof RubyParserVisitor ) return ((RubyParserVisitor extends T>)visitor).visitUnaryMinusExpression(this);
else return visitor.visitChildren(this);
}
}
public static class SymbolExpressionContext extends PrimaryValueContext {
public SymbolContext symbol() {
return getRuleContext(SymbolContext.class,0);
}
public SymbolExpressionContext(PrimaryValueContext ctx) { copyFrom(ctx); }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).enterSymbolExpression(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).exitSymbolExpression(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof RubyParserVisitor ) return ((RubyParserVisitor extends T>)visitor).visitSymbolExpression(this);
else return visitor.visitChildren(this);
}
}
public static class DoubleQuotedStringExpressionContext extends PrimaryValueContext {
public DoubleQuotedStringContext doubleQuotedString() {
return getRuleContext(DoubleQuotedStringContext.class,0);
}
public List singleOrDoubleQuotedString() {
return getRuleContexts(SingleOrDoubleQuotedStringContext.class);
}
public SingleOrDoubleQuotedStringContext singleOrDoubleQuotedString(int i) {
return getRuleContext(SingleOrDoubleQuotedStringContext.class,i);
}
public DoubleQuotedStringExpressionContext(PrimaryValueContext ctx) { copyFrom(ctx); }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).enterDoubleQuotedStringExpression(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).exitDoubleQuotedStringExpression(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof RubyParserVisitor ) return ((RubyParserVisitor extends T>)visitor).visitDoubleQuotedStringExpression(this);
else return visitor.visitChildren(this);
}
}
public static class YieldExpressionContext extends PrimaryValueContext {
public TerminalNode YIELD() { return getToken(RubyParser.YIELD, 0); }
public ArgumentWithParenthesesContext argumentWithParentheses() {
return getRuleContext(ArgumentWithParenthesesContext.class,0);
}
public YieldExpressionContext(PrimaryValueContext ctx) { copyFrom(ctx); }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).enterYieldExpression(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).exitYieldExpression(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof RubyParserVisitor ) return ((RubyParserVisitor extends T>)visitor).visitYieldExpression(this);
else return visitor.visitChildren(this);
}
}
public static class CaseWithExpressionContext extends PrimaryValueContext {
public TerminalNode CASE() { return getToken(RubyParser.CASE, 0); }
public ExpressionOrCommandContext expressionOrCommand() {
return getRuleContext(ExpressionOrCommandContext.class,0);
}
public TerminalNode END() { return getToken(RubyParser.END, 0); }
public List NL() { return getTokens(RubyParser.NL); }
public TerminalNode NL(int i) {
return getToken(RubyParser.NL, i);
}
public List whenClause() {
return getRuleContexts(WhenClauseContext.class);
}
public WhenClauseContext whenClause(int i) {
return getRuleContext(WhenClauseContext.class,i);
}
public ElseClauseContext elseClause() {
return getRuleContext(ElseClauseContext.class,0);
}
public List SEMI() { return getTokens(RubyParser.SEMI); }
public TerminalNode SEMI(int i) {
return getToken(RubyParser.SEMI, i);
}
public CaseWithExpressionContext(PrimaryValueContext ctx) { copyFrom(ctx); }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).enterCaseWithExpression(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof RubyParserListener ) ((RubyParserListener)listener).exitCaseWithExpression(this);
}
@Override
public