$ANTLR start synpred48_DRL6Expressions
515550
public final void synpred48_DRL6Expressions_fragment() throws RecognitionException {
		// src/main/resources/org/drools/compiler/lang/DRL6Expressions.g:741:7: ( GREATER GREATER )
		// src/main/resources/org/drools/compiler/lang/DRL6Expressions.g:741:8: GREATER GREATER
		{
		match(input,GREATER,FOLLOW_GREATER_in_synpred48_DRL6Expressions4697); if (state.failed) return;
		match(input,GREATER,FOLLOW_GREATER_in_synpred48_DRL6Expressions4699); if (state.failed) return;
		}

	}
749372
public final void synpred31_DRL5Expressions_fragment() throws RecognitionException {
		// src/main/resources/org/drools/compiler/lang/DRL5Expressions.g:555:15: ( NULL_SAFE_DOT ID )
		// src/main/resources/org/drools/compiler/lang/DRL5Expressions.g:555:16: NULL_SAFE_DOT ID
		{
		match(input,NULL_SAFE_DOT,FOLLOW_NULL_SAFE_DOT_in_synpred31_DRL5Expressions3048); if (state.failed) return;
		match(input,ID,FOLLOW_ID_in_synpred31_DRL5Expressions3050); if (state.failed) return;
		}

	}
968094
public final void synpred38_DRL5Expressions_fragment() throws RecognitionException {
		// src/main/resources/org/drools/compiler/lang/DRL5Expressions.g:654:9: ( DOT ID )
		// src/main/resources/org/drools/compiler/lang/DRL5Expressions.g:654:10: DOT ID
		{
		match(input,DOT,FOLLOW_DOT_in_synpred38_DRL5Expressions3848); if (state.failed) return;
		match(input,ID,FOLLOW_ID_in_synpred38_DRL5Expressions3850); if (state.failed) return;
		}

	}
911689
public final void synpred18_DRL5Expressions_fragment() throws RecognitionException {
		// src/main/resources/org/drools/compiler/lang/DRL5Expressions.g:522:8: ( LEFT_PAREN type )
		// src/main/resources/org/drools/compiler/lang/DRL5Expressions.g:522:9: LEFT_PAREN type
		{
		match(input,LEFT_PAREN,FOLLOW_LEFT_PAREN_in_synpred18_DRL5Expressions2611); if (state.failed) return;
		pushFollow(FOLLOW_type_in_synpred18_DRL5Expressions2613);
		type();
		state._fsp--;
		if (state.failed) return;
		}

	}
865610
public final void synpred11_InternalSARL_fragment() throws RecognitionException {   
        // InternalSARL.g:8562:6: ( ( '(' ( ( ruleJvmFormalParameter ) ) '=' ) )
        // InternalSARL.g:8562:7: ( '(' ( ( ruleJvmFormalParameter ) ) '=' )
        {
        // InternalSARL.g:8562:7: ( '(' ( ( ruleJvmFormalParameter ) ) '=' )
        // InternalSARL.g:8563:7: '(' ( ( ruleJvmFormalParameter ) ) '='
        {
        match(input,49,FOLLOW_75); if (state.failed) return ;
        // InternalSARL.g:8564:7: ( ( ruleJvmFormalParameter ) )
        // InternalSARL.g:8565:8: ( ruleJvmFormalParameter )
        {
        // InternalSARL.g:8565:8: ( ruleJvmFormalParameter )
        // InternalSARL.g:8566:9: ruleJvmFormalParameter
        {
        pushFollow(FOLLOW_83);
        ruleJvmFormalParameter();

        state._fsp--;
        if (state.failed) return ;

        }


        }

        match(input,47,FOLLOW_2); if (state.failed) return ;

        }


        }
    }
317538
public final void synpred244_Java_fragment() throws RecognitionException {
		// src/main/resources/org/drools/compiler/semantics/java/parser/Java.g:1211:8: ( '(' primitiveType ')' unaryExpression )
		// src/main/resources/org/drools/compiler/semantics/java/parser/Java.g:1211:8: '(' primitiveType ')' unaryExpression
		{
		match(input,36,FOLLOW_36_in_synpred244_Java5610); if (state.failed) return;
		pushFollow(FOLLOW_primitiveType_in_synpred244_Java5612);
		primitiveType();
		state._fsp--;
		if (state.failed) return;
		match(input,37,FOLLOW_37_in_synpred244_Java5614); if (state.failed) return;
		pushFollow(FOLLOW_unaryExpression_in_synpred244_Java5616);
		unaryExpression();
		state._fsp--;
		if (state.failed) return;
		}

	}
359453
public final void synpred2_DRL5Expressions_fragment() throws RecognitionException {
		// src/main/resources/org/drools/compiler/lang/DRL5Expressions.g:138:44: ( LEFT_SQUARE RIGHT_SQUARE )
		// src/main/resources/org/drools/compiler/lang/DRL5Expressions.g:138:45: LEFT_SQUARE RIGHT_SQUARE
		{
		match(input,LEFT_SQUARE,FOLLOW_LEFT_SQUARE_in_synpred2_DRL5Expressions559); if (state.failed) return;
		match(input,RIGHT_SQUARE,FOLLOW_RIGHT_SQUARE_in_synpred2_DRL5Expressions561); if (state.failed) return;
		}

	}
585790
@Override
	public void mTokens() throws RecognitionException {
		// src/main/resources/org/drools/compiler/lang/DRL5Lexer.g:1:8: ( WS | FLOAT | HEX | DECIMAL | STRING | TIME_INTERVAL | BOOL | NULL | AT | PLUS_ASSIGN | MINUS_ASSIGN | MULT_ASSIGN | DIV_ASSIGN | AND_ASSIGN | OR_ASSIGN | XOR_ASSIGN | MOD_ASSIGN | UNIFY | DECR | INCR | ARROW | SEMICOLON | COLON | EQUALS | NOT_EQUALS | GREATER_EQUALS | LESS_EQUALS | GREATER | LESS | EQUALS_ASSIGN | LEFT_PAREN | RIGHT_PAREN | LEFT_SQUARE | RIGHT_SQUARE | LEFT_CURLY | RIGHT_CURLY | COMMA | DOT | NULL_SAFE_DOT | DOUBLE_AMPER | DOUBLE_PIPE | QUESTION | NEGATION | TILDE | PIPE | AMPER | XOR | MOD | STAR | MINUS | PLUS | HASH | C_STYLE_SINGLE_LINE_COMMENT | MULTI_LINE_COMMENT | ID | DIV | MISC )
		int alt63=57;
		alt63 = dfa63.predict(input);
		switch (alt63) {
			case 1 :
				// src/main/resources/org/drools/compiler/lang/DRL5Lexer.g:1:10: WS
				{
				mWS(); if (state.failed) return;

				}
				break;
			case 2 :
				// src/main/resources/org/drools/compiler/lang/DRL5Lexer.g:1:13: FLOAT
				{
				mFLOAT(); if (state.failed) return;

				}
				break;
			case 3 :
				// src/main/resources/org/drools/compiler/lang/DRL5Lexer.g:1:19: HEX
				{
				mHEX(); if (state.failed) return;

				}
				break;
			case 4 :
				// src/main/resources/org/drools/compiler/lang/DRL5Lexer.g:1:23: DECIMAL
				{
				mDECIMAL(); if (state.failed) return;

				}
				break;
			case 5 :
				// src/main/resources/org/drools/compiler/lang/DRL5Lexer.g:1:31: STRING
				{
				mSTRING(); if (state.failed) return;

				}
				break;
			case 6 :
				// src/main/resources/org/drools/compiler/lang/DRL5Lexer.g:1:38: TIME_INTERVAL
				{
				mTIME_INTERVAL(); if (state.failed) return;

				}
				break;
			case 7 :
				// src/main/resources/org/drools/compiler/lang/DRL5Lexer.g:1:52: BOOL
				{
				mBOOL(); if (state.failed) return;

				}
				break;
			case 8 :
				// src/main/resources/org/drools/compiler/lang/DRL5Lexer.g:1:57: NULL
				{
				mNULL(); if (state.failed) return;

				}
				break;
			case 9 :
				// src/main/resources/org/drools/compiler/lang/DRL5Lexer.g:1:62: AT
				{
				mAT(); if (state.failed) return;

				}
				break;
			case 10 :
				// src/main/resources/org/drools/compiler/lang/DRL5Lexer.g:1:65: PLUS_ASSIGN
				{
				mPLUS_ASSIGN(); if (state.failed) return;

				}
				break;
			case 11 :
				// src/main/resources/org/drools/compiler/lang/DRL5Lexer.g:1:77: MINUS_ASSIGN
				{
				mMINUS_ASSIGN(); if (state.failed) return;

				}
				break;
			case 12 :
				// src/main/resources/org/drools/compiler/lang/DRL5Lexer.g:1:90: MULT_ASSIGN
				{
				mMULT_ASSIGN(); if (state.failed) return;

				}
				break;
			case 13 :
				// src/main/resources/org/drools/compiler/lang/DRL5Lexer.g:1:102: DIV_ASSIGN
				{
				mDIV_ASSIGN(); if (state.failed) return;

				}
				break;
			case 14 :
				// src/main/resources/org/drools/compiler/lang/DRL5Lexer.g:1:113: AND_ASSIGN
				{
				mAND_ASSIGN(); if (state.failed) return;

				}
				break;
			case 15 :
				// src/main/resources/org/drools/compiler/lang/DRL5Lexer.g:1:124: OR_ASSIGN
				{
				mOR_ASSIGN(); if (state.failed) return;

				}
				break;
			case 16 :
				// src/main/resources/org/drools/compiler/lang/DRL5Lexer.g:1:134: XOR_ASSIGN
				{
				mXOR_ASSIGN(); if (state.failed) return;

				}
				break;
			case 17 :
				// src/main/resources/org/drools/compiler/lang/DRL5Lexer.g:1:145: MOD_ASSIGN
				{
				mMOD_ASSIGN(); if (state.failed) return;

				}
				break;
			case 18 :
				// src/main/resources/org/drools/compiler/lang/DRL5Lexer.g:1:156: UNIFY
				{
				mUNIFY(); if (state.failed) return;

				}
				break;
			case 19 :
				// src/main/resources/org/drools/compiler/lang/DRL5Lexer.g:1:162: DECR
				{
				mDECR(); if (state.failed) return;

				}
				break;
			case 20 :
				// src/main/resources/org/drools/compiler/lang/DRL5Lexer.g:1:167: INCR
				{
				mINCR(); if (state.failed) return;

				}
				break;
			case 21 :
				// src/main/resources/org/drools/compiler/lang/DRL5Lexer.g:1:172: ARROW
				{
				mARROW(); if (state.failed) return;

				}
				break;
			case 22 :
				// src/main/resources/org/drools/compiler/lang/DRL5Lexer.g:1:178: SEMICOLON
				{
				mSEMICOLON(); if (state.failed) return;

				}
				break;
			case 23 :
				// src/main/resources/org/drools/compiler/lang/DRL5Lexer.g:1:188: COLON
				{
				mCOLON(); if (state.failed) return;

				}
				break;
			case 24 :
				// src/main/resources/org/drools/compiler/lang/DRL5Lexer.g:1:194: EQUALS
				{
				mEQUALS(); if (state.failed) return;

				}
				break;
			case 25 :
				// src/main/resources/org/drools/compiler/lang/DRL5Lexer.g:1:201: NOT_EQUALS
				{
				mNOT_EQUALS(); if (state.failed) return;

				}
				break;
			case 26 :
				// src/main/resources/org/drools/compiler/lang/DRL5Lexer.g:1:212: GREATER_EQUALS
				{
				mGREATER_EQUALS(); if (state.failed) return;

				}
				break;
			case 27 :
				// src/main/resources/org/drools/compiler/lang/DRL5Lexer.g:1:227: LESS_EQUALS
				{
				mLESS_EQUALS(); if (state.failed) return;

				}
				break;
			case 28 :
				// src/main/resources/org/drools/compiler/lang/DRL5Lexer.g:1:239: GREATER
				{
				mGREATER(); if (state.failed) return;

				}
				break;
			case 29 :
				// src/main/resources/org/drools/compiler/lang/DRL5Lexer.g:1:247: LESS
				{
				mLESS(); if (state.failed) return;

				}
				break;
			case 30 :
				// src/main/resources/org/drools/compiler/lang/DRL5Lexer.g:1:252: EQUALS_ASSIGN
				{
				mEQUALS_ASSIGN(); if (state.failed) return;

				}
				break;
			case 31 :
				// src/main/resources/org/drools/compiler/lang/DRL5Lexer.g:1:266: LEFT_PAREN
				{
				mLEFT_PAREN(); if (state.failed) return;

				}
				break;
			case 32 :
				// src/main/resources/org/drools/compiler/lang/DRL5Lexer.g:1:277: RIGHT_PAREN
				{
				mRIGHT_PAREN(); if (state.failed) return;

				}
				break;
			case 33 :
				// src/main/resources/org/drools/compiler/lang/DRL5Lexer.g:1:289: LEFT_SQUARE
				{
				mLEFT_SQUARE(); if (state.failed) return;

				}
				break;
			case 34 :
				// src/main/resources/org/drools/compiler/lang/DRL5Lexer.g:1:301: RIGHT_SQUARE
				{
				mRIGHT_SQUARE(); if (state.failed) return;

				}
				break;
			case 35 :
				// src/main/resources/org/drools/compiler/lang/DRL5Lexer.g:1:314: LEFT_CURLY
				{
				mLEFT_CURLY(); if (state.failed) return;

				}
				break;
			case 36 :
				// src/main/resources/org/drools/compiler/lang/DRL5Lexer.g:1:325: RIGHT_CURLY
				{
				mRIGHT_CURLY(); if (state.failed) return;

				}
				break;
			case 37 :
				// src/main/resources/org/drools/compiler/lang/DRL5Lexer.g:1:337: COMMA
				{
				mCOMMA(); if (state.failed) return;

				}
				break;
			case 38 :
				// src/main/resources/org/drools/compiler/lang/DRL5Lexer.g:1:343: DOT
				{
				mDOT(); if (state.failed) return;

				}
				break;
			case 39 :
				// src/main/resources/org/drools/compiler/lang/DRL5Lexer.g:1:347: NULL_SAFE_DOT
				{
				mNULL_SAFE_DOT(); if (state.failed) return;

				}
				break;
			case 40 :
				// src/main/resources/org/drools/compiler/lang/DRL5Lexer.g:1:361: DOUBLE_AMPER
				{
				mDOUBLE_AMPER(); if (state.failed) return;

				}
				break;
			case 41 :
				// src/main/resources/org/drools/compiler/lang/DRL5Lexer.g:1:374: DOUBLE_PIPE
				{
				mDOUBLE_PIPE(); if (state.failed) return;

				}
				break;
			case 42 :
				// src/main/resources/org/drools/compiler/lang/DRL5Lexer.g:1:386: QUESTION
				{
				mQUESTION(); if (state.failed) return;

				}
				break;
			case 43 :
				// src/main/resources/org/drools/compiler/lang/DRL5Lexer.g:1:395: NEGATION
				{
				mNEGATION(); if (state.failed) return;

				}
				break;
			case 44 :
				// src/main/resources/org/drools/compiler/lang/DRL5Lexer.g:1:404: TILDE
				{
				mTILDE(); if (state.failed) return;

				}
				break;
			case 45 :
				// src/main/resources/org/drools/compiler/lang/DRL5Lexer.g:1:410: PIPE
				{
				mPIPE(); if (state.failed) return;

				}
				break;
			case 46 :
				// src/main/resources/org/drools/compiler/lang/DRL5Lexer.g:1:415: AMPER
				{
				mAMPER(); if (state.failed) return;

				}
				break;
			case 47 :
				// src/main/resources/org/drools/compiler/lang/DRL5Lexer.g:1:421: XOR
				{
				mXOR(); if (state.failed) return;

				}
				break;
			case 48 :
				// src/main/resources/org/drools/compiler/lang/DRL5Lexer.g:1:425: MOD
				{
				mMOD(); if (state.failed) return;

				}
				break;
			case 49 :
				// src/main/resources/org/drools/compiler/lang/DRL5Lexer.g:1:429: STAR
				{
				mSTAR(); if (state.failed) return;

				}
				break;
			case 50 :
				// src/main/resources/org/drools/compiler/lang/DRL5Lexer.g:1:434: MINUS
				{
				mMINUS(); if (state.failed) return;

				}
				break;
			case 51 :
				// src/main/resources/org/drools/compiler/lang/DRL5Lexer.g:1:440: PLUS
				{
				mPLUS(); if (state.failed) return;

				}
				break;
			case 52 :
				// src/main/resources/org/drools/compiler/lang/DRL5Lexer.g:1:445: HASH
				{
				mHASH(); if (state.failed) return;

				}
				break;
			case 53 :
				// src/main/resources/org/drools/compiler/lang/DRL5Lexer.g:1:450: C_STYLE_SINGLE_LINE_COMMENT
				{
				mC_STYLE_SINGLE_LINE_COMMENT(); if (state.failed) return;

				}
				break;
			case 54 :
				// src/main/resources/org/drools/compiler/lang/DRL5Lexer.g:1:478: MULTI_LINE_COMMENT
				{
				mMULTI_LINE_COMMENT(); if (state.failed) return;

				}
				break;
			case 55 :
				// src/main/resources/org/drools/compiler/lang/DRL5Lexer.g:1:497: ID
				{
				mID(); if (state.failed) return;

				}
				break;
			case 56 :
				// src/main/resources/org/drools/compiler/lang/DRL5Lexer.g:1:500: DIV
				{
				mDIV(); if (state.failed) return;

				}
				break;
			case 57 :
				// src/main/resources/org/drools/compiler/lang/DRL5Lexer.g:1:504: MISC
				{
				mMISC(); if (state.failed) return;

				}
				break;

		}
	}
532186
public final void synpred28_DRL5Expressions_fragment() throws RecognitionException {
		// src/main/resources/org/drools/compiler/lang/DRL5Expressions.g:549:15: ( DOT ID )
		// src/main/resources/org/drools/compiler/lang/DRL5Expressions.g:549:16: DOT ID
		{
		match(input,DOT,FOLLOW_DOT_in_synpred28_DRL5Expressions2916); if (state.failed) return;
		match(input,ID,FOLLOW_ID_in_synpred28_DRL5Expressions2918); if (state.failed) return;
		}

	}
410018
public final void synpred258_Java_fragment() throws RecognitionException {
		// src/main/resources/org/drools/compiler/semantics/java/parser/Java.g:1224:127: ( '.' methodName )
		// src/main/resources/org/drools/compiler/semantics/java/parser/Java.g:1224:127: '.' methodName
		{
		match(input,47,FOLLOW_47_in_synpred258_Java5777); if (state.failed) return;
		pushFollow(FOLLOW_methodName_in_synpred258_Java5779);
		methodName();
		state._fsp--;
		if (state.failed) return;
		}

	}
1314582
public final void synpred11_DRL5Expressions_fragment() throws RecognitionException {
		// src/main/resources/org/drools/compiler/lang/DRL5Expressions.g:424:8: ( squareArguments shiftExpression )
		// src/main/resources/org/drools/compiler/lang/DRL5Expressions.g:424:9: squareArguments shiftExpression
		{
		pushFollow(FOLLOW_squareArguments_in_synpred11_DRL5Expressions1984);
		squareArguments();
		state._fsp--;
		if (state.failed) return;
		pushFollow(FOLLOW_shiftExpression_in_synpred11_DRL5Expressions1986);
		shiftExpression();
		state._fsp--;
		if (state.failed) return;
		}

	}
1217347
public final void synpred28_InternalSARL_fragment() throws RecognitionException {   
        // InternalSARL.g:11744:5: ( ( () '#' '[' ) )
        // InternalSARL.g:11744:6: ( () '#' '[' )
        {
        // InternalSARL.g:11744:6: ( () '#' '[' )
        // InternalSARL.g:11745:6: () '#' '['
        {
        // InternalSARL.g:11745:6: ()
        // InternalSARL.g:11746:6: 
        {
        }

        match(input,106,FOLLOW_90); if (state.failed) return ;
        match(input,55,FOLLOW_2); if (state.failed) return ;

        }


        }
    }
748993
public final void synpred12_InternalSARL_fragment() throws RecognitionException {   
        // InternalSARL.g:8629:6: ( ( ( ( ruleJvmFormalParameter ) ) '=' ) )
        // InternalSARL.g:8629:7: ( ( ( ruleJvmFormalParameter ) ) '=' )
        {
        // InternalSARL.g:8629:7: ( ( ( ruleJvmFormalParameter ) ) '=' )
        // InternalSARL.g:8630:7: ( ( ruleJvmFormalParameter ) ) '='
        {
        // InternalSARL.g:8630:7: ( ( ruleJvmFormalParameter ) )
        // InternalSARL.g:8631:8: ( ruleJvmFormalParameter )
        {
        // InternalSARL.g:8631:8: ( ruleJvmFormalParameter )
        // InternalSARL.g:8632:9: ruleJvmFormalParameter
        {
        pushFollow(FOLLOW_83);
        ruleJvmFormalParameter();

        state._fsp--;
        if (state.failed) return ;

        }


        }

        match(input,47,FOLLOW_2); if (state.failed) return ;

        }


        }
    }
1024180
def call_antlr4(arg):
    ""
    # pylint: disable=unused-argument, unused-variable
    antlr_path = os.path.join(ROOT_DIR, "java", "antlr-4.7-complete.jar")
    classpath = os.pathsep.join([".", "{:s}".format(antlr_path), "$CLASSPATH"])
    generated = os.path.join(ROOT_DIR, 'src', 'pymoca', 'generated')
    cmd = "java -Xmx500M -cp \"{classpath:s}\" org.antlr.v4.Tool {arg:s}" \
          " -o {generated:s} -visitor -Dlanguage=Python3".format(**locals())
    print(cmd)
    proc = subprocess.Popen(cmd.split(), cwd=os.path.join(ROOT_DIR, 'src', 'pymoca'))
    proc.communicate()
    with open(os.path.join(generated, '__init__.py'), 'w') as fid:
        fid.write('')
313789
public final void synpred34_DRL6Expressions_fragment() throws RecognitionException {
		// src/main/resources/org/drools/compiler/lang/DRL6Expressions.g:593:15: ( ( DOT | NULL_SAFE_DOT ) LEFT_PAREN )
		// src/main/resources/org/drools/compiler/lang/DRL6Expressions.g:593:16: ( DOT | NULL_SAFE_DOT ) LEFT_PAREN
		{
		if ( input.LA(1)==DOT||input.LA(1)==NULL_SAFE_DOT ) {
			input.consume();
			state.errorRecovery=false;
			state.failed=false;
		}
		else {
			if (state.backtracking>0) {state.failed=true; return;}
			MismatchedSetException mse = new MismatchedSetException(null,input);
			throw mse;
		}
		match(input,LEFT_PAREN,FOLLOW_LEFT_PAREN_in_synpred34_DRL6Expressions3286); if (state.failed) return;
		}

	}
723885
public final void synpred5_DRL6Expressions_fragment() throws RecognitionException {
		// src/main/resources/org/drools/compiler/lang/DRL6Expressions.g:139:92: ( LEFT_SQUARE RIGHT_SQUARE )
		// src/main/resources/org/drools/compiler/lang/DRL6Expressions.g:139:93: LEFT_SQUARE RIGHT_SQUARE
		{
		match(input,LEFT_SQUARE,FOLLOW_LEFT_SQUARE_in_synpred5_DRL6Expressions611); if (state.failed) return;
		match(input,RIGHT_SQUARE,FOLLOW_RIGHT_SQUARE_in_synpred5_DRL6Expressions613); if (state.failed) return;
		}

	}
1067194
public final void synpred29_InternalSARL_fragment() throws RecognitionException {   
        // InternalSARL.g:11886:5: ( ( () '#' '[' ) )
        // InternalSARL.g:11886:6: ( () '#' '[' )
        {
        // InternalSARL.g:11886:6: ( () '#' '[' )
        // InternalSARL.g:11887:6: () '#' '['
        {
        // InternalSARL.g:11887:6: ()
        // InternalSARL.g:11888:6: 
        {
        }

        match(input,106,FOLLOW_90); if (state.failed) return ;
        match(input,55,FOLLOW_2); if (state.failed) return ;

        }


        }
    }