/** \brief Lexer rule generated by ANTLR3
 *
 * $ANTLR start DIGIT
 *
 * Looks to match the characters the constitute the token DIGIT
 * from the attached input stream.
 *
 *
 * \remark
 *  - lexer->error == ANTLR3_TRUE if an exception was thrown.
 */
static ANTLR3_INLINE
void mDIGIT(pbelle_sdpLexer ctx)
{
	ANTLR3_UINT32	_type;

    _type	    = DIGIT;
       
    
    // /Users/huyheo/Documents/Linphone/linphone-iphone/submodules/build/..//belle-sip/src/belle_sdp.g:315:6: ( ZERO | POS_DIGIT )
    // /Users/huyheo/Documents/Linphone/linphone-iphone/submodules/build/..//belle-sip/src/belle_sdp.g:
    {
        if ( ((LA(1) >= '0') && (LA(1) <= '9')) )
        {
            CONSUME();

        }
        else 
        {
            CONSTRUCTEX();
            EXCEPTION->type         = ANTLR3_MISMATCHED_SET_EXCEPTION;
            EXCEPTION->name         = (void *)ANTLR3_MISMATCHED_SET_NAME;

            LRECOVER();    goto ruleDIGITEx;
        }


    }

	LEXSTATE->type = _type;

    // This is where rules clean up and exit
    //
    goto ruleDIGITEx; /* Prevent compiler warnings */
    ruleDIGITEx: ;

}
/** \brief Lexer rule generated by ANTLR3
 *
 * $ANTLR start HEX_CHAR
 *
 * Looks to match the characters the constitute the token HEX_CHAR
 * from the attached input stream.
 *
 *
 * \remark
 *  - lexer->error == ANTLR3_TRUE if an exception was thrown.
 */
static ANTLR3_INLINE
void mHEX_CHAR(pbelle_sdpLexer ctx)
{
	ANTLR3_UINT32	_type;

    _type	    = HEX_CHAR;
       
    
    // /Users/huyheo/Documents/Linphone/linphone-iphone/submodules/build/..//belle-sip/src/belle_sdp.g:321:9: ( 'a' .. 'f' | 'A' .. 'F' )
    // /Users/huyheo/Documents/Linphone/linphone-iphone/submodules/build/..//belle-sip/src/belle_sdp.g:
    {
        if ( ((LA(1) >= 'A') && (LA(1) <= 'F')) || ((LA(1) >= 'a') && (LA(1) <= 'f')) )
        {
            CONSUME();

        }
        else 
        {
            CONSTRUCTEX();
            EXCEPTION->type         = ANTLR3_MISMATCHED_SET_EXCEPTION;
            EXCEPTION->name         = (void *)ANTLR3_MISMATCHED_SET_NAME;

            LRECOVER();    goto ruleHEX_CHAREx;
        }


    }

	LEXSTATE->type = _type;

    // This is where rules clean up and exit
    //
    goto ruleHEX_CHAREx; /* Prevent compiler warnings */
    ruleHEX_CHAREx: ;

}
/** \brief Lexer rule generated by ANTLR3
 *
 * $ANTLR start ANY_EXCEPT_CR_LF
 *
 * Looks to match the characters the constitute the token ANY_EXCEPT_CR_LF
 * from the attached input stream.
 *
 *
 * \remark
 *  - lexer->error == ANTLR3_TRUE if an exception was thrown.
 */
static ANTLR3_INLINE
void mANY_EXCEPT_CR_LF(pbelle_sdpLexer ctx)
{
	ANTLR3_UINT32	_type;

    _type	    = ANY_EXCEPT_CR_LF;
       
    
    // /Users/huyheo/Documents/Linphone/linphone-iphone/submodules/build/..//belle-sip/src/belle_sdp.g:335:17: (~ ( CR | LF ) )
    // /Users/huyheo/Documents/Linphone/linphone-iphone/submodules/build/..//belle-sip/src/belle_sdp.g:335:19: ~ ( CR | LF )
    {
        if ( ((LA(1) >= 0x0000) && (LA(1) <= '\t')) || ((LA(1) >= 0x000B) && (LA(1) <= '\f')) || ((LA(1) >= 0x000E) && (LA(1) <= 0xFFFF)) )
        {
            CONSUME();

        }
        else 
        {
            CONSTRUCTEX();
            EXCEPTION->type         = ANTLR3_MISMATCHED_SET_EXCEPTION;
            EXCEPTION->name         = (void *)ANTLR3_MISMATCHED_SET_NAME;

            LRECOVER();    goto ruleANY_EXCEPT_CR_LFEx;
        }


    }

	LEXSTATE->type = _type;

    // This is where rules clean up and exit
    //
    goto ruleANY_EXCEPT_CR_LFEx; /* Prevent compiler warnings */
    ruleANY_EXCEPT_CR_LFEx: ;

}
/** \brief Lexer rule generated by ANTLR3
 *
 * $ANTLR start WS
 *
 * Looks to match the characters the constitute the token WS
 * from the attached input stream.
 *
 *
 * \remark
 *  - lexer->error == ANTLR3_TRUE if an exception was thrown.
 */
static ANTLR3_INLINE
void mWS(pExprCppTreeLexer ctx)
{
	ANTLR3_UINT32	_type;

    _type	    = WS;
       
    
    // D:\\message\\ExprCppTree.g:45:4: ( ( ' ' | '\\t' )+ )
    // D:\\message\\ExprCppTree.g:45:6: ( ' ' | '\\t' )+
    {
        // D:\\message\\ExprCppTree.g:45:6: ( ' ' | '\\t' )+
        {
            int cnt5=0;

            for (;;)
            {
                int alt5=2;
        	switch ( LA(1) ) 
        	{
        	case '\t':
        	case ' ':
        		{
        			alt5=1;
        		}
        	    break;

        	}

        	switch (alt5) 
        	{
        	    case 1:
        	        // D:\\message\\ExprCppTree.g:
        	        {
        	            if ( LA(1) == '\t' || LA(1) == ' ' )
        	            {
        	                CONSUME();

        	            }
        	            else 
        	            {
        	                CONSTRUCTEX();
        	                EXCEPTION->type         = ANTLR3_MISMATCHED_SET_EXCEPTION;
        	                EXCEPTION->name         = (void *)ANTLR3_MISMATCHED_SET_NAME;

        	                LRECOVER();    goto ruleWSEx;
        	            }


        	        }
        	        break;

        	    default:
        	    
        		if ( cnt5 >= 1 )
        		{
        		    goto loop5;
        		}
        		/* mismatchedSetEx()
        		 */
        		CONSTRUCTEX();
        		EXCEPTION->type = ANTLR3_EARLY_EXIT_EXCEPTION;
        		EXCEPTION->name = (void *)ANTLR3_EARLY_EXIT_NAME;


        		goto ruleWSEx;
        	}
        	cnt5++;
            }
            loop5: ;	/* Jump to here if this rule does not match */
        }
        {
            LEXSTATE->channel = HIDDEN;
        }

    }

	LEXSTATE->type = _type;

    // This is where rules clean up and exit
    //
    goto ruleWSEx; /* Prevent compiler warnings */
    ruleWSEx: ;

}
/** \brief Lexer rule generated by ANTLR3
 *
 * $ANTLR start ID
 *
 * Looks to match the characters the constitute the token ID
 * from the attached input stream.
 *
 *
 * \remark
 *  - lexer->error == ANTLR3_TRUE if an exception was thrown.
 */
static ANTLR3_INLINE
void mID(pExprCppTreeLexer ctx)
{
	ANTLR3_UINT32	_type;

    _type	    = ID;
       
    
    // D:\\message\\ExprCppTree.g:42:3: ( ( 'a' .. 'z' | 'A' .. 'Z' )+ )
    // D:\\message\\ExprCppTree.g:42:5: ( 'a' .. 'z' | 'A' .. 'Z' )+
    {
        // D:\\message\\ExprCppTree.g:42:5: ( 'a' .. 'z' | 'A' .. 'Z' )+
        {
            int cnt1=0;

            for (;;)
            {
                int alt1=2;
        	switch ( LA(1) ) 
        	{
        	case 'A':
        	case 'B':
        	case 'C':
        	case 'D':
        	case 'E':
        	case 'F':
        	case 'G':
        	case 'H':
        	case 'I':
        	case 'J':
        	case 'K':
        	case 'L':
        	case 'M':
        	case 'N':
        	case 'O':
        	case 'P':
        	case 'Q':
        	case 'R':
        	case 'S':
        	case 'T':
        	case 'U':
        	case 'V':
        	case 'W':
        	case 'X':
        	case 'Y':
        	case 'Z':
        	case 'a':
        	case 'b':
        	case 'c':
        	case 'd':
        	case 'e':
        	case 'f':
        	case 'g':
        	case 'h':
        	case 'i':
        	case 'j':
        	case 'k':
        	case 'l':
        	case 'm':
        	case 'n':
        	case 'o':
        	case 'p':
        	case 'q':
        	case 'r':
        	case 's':
        	case 't':
        	case 'u':
        	case 'v':
        	case 'w':
        	case 'x':
        	case 'y':
        	case 'z':
        		{
        			alt1=1;
        		}
        	    break;

        	}

        	switch (alt1) 
        	{
        	    case 1:
        	        // D:\\message\\ExprCppTree.g:
        	        {
        	            if ( ((LA(1) >= 'A') && (LA(1) <= 'Z')) || ((LA(1) >= 'a') && (LA(1) <= 'z')) )
        	            {
        	                CONSUME();

        	            }
        	            else 
        	            {
        	                CONSTRUCTEX();
        	                EXCEPTION->type         = ANTLR3_MISMATCHED_SET_EXCEPTION;
        	                EXCEPTION->name         = (void *)ANTLR3_MISMATCHED_SET_NAME;

        	                LRECOVER();    goto ruleIDEx;
        	            }


        	        }
        	        break;

        	    default:
        	    
        		if ( cnt1 >= 1 )
        		{
        		    goto loop1;
        		}
        		/* mismatchedSetEx()
        		 */
        		CONSTRUCTEX();
        		EXCEPTION->type = ANTLR3_EARLY_EXIT_EXCEPTION;
        		EXCEPTION->name = (void *)ANTLR3_EARLY_EXIT_NAME;


        		goto ruleIDEx;
        	}
        	cnt1++;
            }
            loop1: ;	/* Jump to here if this rule does not match */
        }

    }

	LEXSTATE->type = _type;

    // This is where rules clean up and exit
    //
    goto ruleIDEx; /* Prevent compiler warnings */
    ruleIDEx: ;

}
Exemple #6
0
/** \brief Lexer rule generated by ANTLR3
 *
 * $ANTLR start TEXT
 *
 * Looks to match the characters the constitute the token TEXT
 * from the attached input stream.
 *
 *
 * \remark
 *  - lexer->error == ANTLR3_TRUE if an exception was thrown.
 */
static ANTLR3_INLINE
void mTEXT(pMudLexer ctx)
{
	ANTLR3_UINT32	_type;

    _type	    = TEXT;


    // c_src/Mud.g:129:5: ( ( 'a' .. 'z' | 'A' .. 'Z' | '1' .. '0' | '!' | '@' | '#' | '$' | '%' | '^' | '&' | '*' | '(' | ')' )+ )
    // c_src/Mud.g:129:7: ( 'a' .. 'z' | 'A' .. 'Z' | '1' .. '0' | '!' | '@' | '#' | '$' | '%' | '^' | '&' | '*' | '(' | ')' )+
    {
        // c_src/Mud.g:129:7: ( 'a' .. 'z' | 'A' .. 'Z' | '1' .. '0' | '!' | '@' | '#' | '$' | '%' | '^' | '&' | '*' | '(' | ')' )+
        {
            int cnt2=0;

            for (;;)
            {
                int alt2=2;
        	switch ( LA(1) )
        	{
        	case '!':
        	case '#':
        	case '$':
        	case '%':
        	case '&':
        	case '(':
        	case ')':
        	case '*':
        	case '@':
        	case 'A':
        	case 'B':
        	case 'C':
        	case 'D':
        	case 'E':
        	case 'F':
        	case 'G':
        	case 'H':
        	case 'I':
        	case 'J':
        	case 'K':
        	case 'L':
        	case 'M':
        	case 'N':
        	case 'O':
        	case 'P':
        	case 'Q':
        	case 'R':
        	case 'S':
        	case 'T':
        	case 'U':
        	case 'V':
        	case 'W':
        	case 'X':
        	case 'Y':
        	case 'Z':
        	case '^':
        	case 'a':
        	case 'b':
        	case 'c':
        	case 'd':
        	case 'e':
        	case 'f':
        	case 'g':
        	case 'h':
        	case 'i':
        	case 'j':
        	case 'k':
        	case 'l':
        	case 'm':
        	case 'n':
        	case 'o':
        	case 'p':
        	case 'q':
        	case 'r':
        	case 's':
        	case 't':
        	case 'u':
        	case 'v':
        	case 'w':
        	case 'x':
        	case 'y':
        	case 'z':
        		{
        			alt2=1;
        		}
        	    break;

        	}

        	switch (alt2)
        	{
        	    case 1:
        	        // c_src/Mud.g:
        	        {
        	            if ( LA(1) == '!' || ((LA(1) >= '#') && (LA(1) <= '&')) || ((LA(1) >= '(') && (LA(1) <= '*')) || ((LA(1) >= '@') && (LA(1) <= 'Z')) || LA(1) == '^' || ((LA(1) >= 'a') && (LA(1) <= 'z')) )
        	            {
        	                CONSUME();
        	            }
        	            else
        	            {
        	                CONSTRUCTEX();
        	                EXCEPTION->type         = ANTLR3_MISMATCHED_SET_EXCEPTION;
        	                EXCEPTION->name         = (void *)ANTLR3_MISMATCHED_SET_NAME;

        	                LRECOVER();
        	                goto ruleTEXTEx;
        	            }


        	        }
        	        break;

        	    default:

        		if ( cnt2 >= 1 )
        		{
        		    goto loop2;
        		}
        		/* mismatchedSetEx()
        		 */
        		CONSTRUCTEX();
        		EXCEPTION->type = ANTLR3_EARLY_EXIT_EXCEPTION;
        		EXCEPTION->name = (void *)ANTLR3_EARLY_EXIT_NAME;


        		goto ruleTEXTEx;
        	}
        	cnt2++;
            }
            loop2: ;	/* Jump to here if this rule does not match */
        }

    }

	LEXSTATE->type = _type;
    // This is where rules clean up and exit
    //
    goto ruleTEXTEx; /* Prevent compiler warnings */
    ruleTEXTEx: ;

}
Exemple #7
0
/** \brief Lexer rule generated by ANTLR3
 *
 * $ANTLR start WS
 *
 * Looks to match the characters the constitute the token WS
 * from the attached input stream.
 *
 *
 * \remark
 *  - lexer->error == ANTLR3_TRUE if an exception was thrown.
 */
static ANTLR3_INLINE
void mWS(pMudLexer ctx)
{
	ANTLR3_UINT32	_type;

    _type	    = WS;


    // c_src/Mud.g:127:3: ( ( ' ' | '\\t' )+ )
    // c_src/Mud.g:127:5: ( ' ' | '\\t' )+
    {
        // c_src/Mud.g:127:5: ( ' ' | '\\t' )+
        {
            int cnt1=0;

            for (;;)
            {
                int alt1=2;
        	switch ( LA(1) )
        	{
        	case '\t':
        	case ' ':
        		{
        			alt1=1;
        		}
        	    break;

        	}

        	switch (alt1)
        	{
        	    case 1:
        	        // c_src/Mud.g:
        	        {
        	            if ( LA(1) == '\t' || LA(1) == ' ' )
        	            {
        	                CONSUME();
        	            }
        	            else
        	            {
        	                CONSTRUCTEX();
        	                EXCEPTION->type         = ANTLR3_MISMATCHED_SET_EXCEPTION;
        	                EXCEPTION->name         = (void *)ANTLR3_MISMATCHED_SET_NAME;

        	                LRECOVER();
        	                goto ruleWSEx;
        	            }


        	        }
        	        break;

        	    default:

        		if ( cnt1 >= 1 )
        		{
        		    goto loop1;
        		}
        		/* mismatchedSetEx()
        		 */
        		CONSTRUCTEX();
        		EXCEPTION->type = ANTLR3_EARLY_EXIT_EXCEPTION;
        		EXCEPTION->name = (void *)ANTLR3_EARLY_EXIT_NAME;


        		goto ruleWSEx;
        	}
        	cnt1++;
            }
            loop1: ;	/* Jump to here if this rule does not match */
        }

    }

	LEXSTATE->type = _type;
    // This is where rules clean up and exit
    //
    goto ruleWSEx; /* Prevent compiler warnings */
    ruleWSEx: ;

}