Beispiel #1
0
        // throws RecognitionException [1]
        // $ANTLR start relationalExpression
        // C:\\Users\\sephiroth\\Documents\\Visual Studio 2005\\Projects\\CodeReformatter\\CodeReformatter\\AS.g:1351:1: relationalExpression : shiftExpression ( ( relationalOperator )=>op= relationalOperator shiftExpression )* ;
        public relationalExpression_return relationalExpression()
        {
            relationalExpression_return retval = new relationalExpression_return();
            retval.start = input.LT(1);
            int relationalExpression_StartIndex = input.Index();
            CommonTree root_0 = null;

            relationalOperator_return op = null;

            shiftExpression_return shiftExpression255 = null;

            shiftExpression_return shiftExpression256 = null;

            try
            {
            if ( (backtracking > 0) && AlreadyParsedRule(input, 100) )
            {
                return retval;
            }
            // C:\\Users\\sephiroth\\Documents\\Visual Studio 2005\\Projects\\CodeReformatter\\CodeReformatter\\AS.g:1352:4: ( shiftExpression ( ( relationalOperator )=>op= relationalOperator shiftExpression )* )
            // C:\\Users\\sephiroth\\Documents\\Visual Studio 2005\\Projects\\CodeReformatter\\CodeReformatter\\AS.g:1352:4: shiftExpression ( ( relationalOperator )=>op= relationalOperator shiftExpression )*
            {
                root_0 = (CommonTree)adaptor.GetNilNode();

                PushFollow(FOLLOW_shiftExpression_in_relationalExpression4633);
                shiftExpression255 = shiftExpression();
                followingStackPointer_--;
                if (failed) return retval;
                if ( backtracking==0 ) adaptor.AddChild(root_0, shiftExpression255.Tree);
                // C:\\Users\\sephiroth\\Documents\\Visual Studio 2005\\Projects\\CodeReformatter\\CodeReformatter\\AS.g:1353:3: ( ( relationalOperator )=>op= relationalOperator shiftExpression )*
                do
                {
                    int alt75 = 2;
                    int LA75_0 = input.LA(1);

                    if ( (LA75_0 == IS) )
                    {
                        switch ( input.LA(2) )
                        {
                        case LBRACK:
                            {
                            int LA75_78 = input.LA(3);

                            if ( (synpred130()) )
                            {
                                alt75 = 1;
                            }

                            }
                            break;
                        case LPAREN:
                            {
                            int LA75_79 = input.LA(3);

                            if ( (synpred130()) )
                            {
                                alt75 = 1;
                            }

                            }
                            break;
                        case INC:
                            {
                            int LA75_80 = input.LA(3);

                            if ( (synpred130()) )
                            {
                                alt75 = 1;
                            }

                            }
                            break;
                        case DEC:
                            {
                            int LA75_81 = input.LA(3);

                            if ( (synpred130()) )
                            {
                                alt75 = 1;
                            }

                            }
                            break;
                        case MINUS:
                            {
                            int LA75_83 = input.LA(3);

                            if ( (synpred130()) )
                            {
                                alt75 = 1;
                            }

                            }
                            break;
                        case IS:
                            {
                            int LA75_90 = input.LA(3);

                            if ( (synpred130()) )
                            {
                                alt75 = 1;
                            }

                            }
                            break;
                        case AS:
                            {
                            int LA75_91 = input.LA(3);

                            if ( (synpred130()) )
                            {
                                alt75 = 1;
                            }

                            }
                            break;
                        case LCURLY:
                            {
                            int LA75_107 = input.LA(3);

                            if ( (synpred130()) )
                            {
                                alt75 = 1;
                            }

                            }
                            break;
                        case PLUS:
                            {
                            int LA75_109 = input.LA(3);

                            if ( (synpred130()) )
                            {
                                alt75 = 1;
                            }

                            }
                            break;
                        case DELETE:
                            {
                            int LA75_110 = input.LA(3);

                            if ( (synpred130()) )
                            {
                                alt75 = 1;
                            }

                            }
                            break;
                        case VOID:
                            {
                            int LA75_111 = input.LA(3);

                            if ( (synpred130()) )
                            {
                                alt75 = 1;
                            }

                            }
                            break;
                        case TYPEOF:
                            {
                            int LA75_112 = input.LA(3);

                            if ( (synpred130()) )
                            {
                                alt75 = 1;
                            }

                            }
                            break;
                        case LNOT:
                            {
                            int LA75_113 = input.LA(3);

                            if ( (synpred130()) )
                            {
                                alt75 = 1;
                            }

                            }
                            break;
                        case BNOT:
                            {
                            int LA75_114 = input.LA(3);

                            if ( (synpred130()) )
                            {
                                alt75 = 1;
                            }

                            }
                            break;
                        case UNDEFINED:
                            {
                            int LA75_115 = input.LA(3);

                            if ( (synpred130()) )
                            {
                                alt75 = 1;
                            }

                            }
                            break;
                        case HEX_LITERAL:
                        case DECIMAL_LITERAL:
                        case OCTAL_LITERAL:
                        case FLOAT_LITERAL:
                            {
                            int LA75_116 = input.LA(3);

                            if ( (synpred130()) )
                            {
                                alt75 = 1;
                            }

                            }
                            break;
                        case STRING_LITERAL:
                            {
                            int LA75_117 = input.LA(3);

                            if ( (synpred130()) )
                            {
                                alt75 = 1;
                            }

                            }
                            break;
                        case TRUE:
                            {
                            int LA75_118 = input.LA(3);

                            if ( (synpred130()) )
                            {
                                alt75 = 1;
                            }

                            }
                            break;
                        case FALSE:
                            {
                            int LA75_119 = input.LA(3);

                            if ( (synpred130()) )
                            {
                                alt75 = 1;
                            }

                            }
                            break;
                        case NULL:
                            {
                            int LA75_120 = input.LA(3);

                            if ( (synpred130()) )
                            {
                                alt75 = 1;
                            }

                            }
                            break;
                        case FUNCTION:
                            {
                            int LA75_121 = input.LA(3);

                            if ( (synpred130()) )
                            {
                                alt75 = 1;
                            }

                            }
                            break;
                        case NEW:
                            {
                            int LA75_122 = input.LA(3);

                            if ( (synpred130()) )
                            {
                                alt75 = 1;
                            }

                            }
                            break;
                        case IDENT:
                            {
                            int LA75_123 = input.LA(3);

                            if ( (synpred130()) )
                            {
                                alt75 = 1;
                            }

                            }
                            break;
                        case USE:
                            {
                            int LA75_124 = input.LA(3);

                            if ( (synpred130()) )
                            {
                                alt75 = 1;
                            }

                            }
                            break;
                        case XML:
                            {
                            int LA75_125 = input.LA(3);

                            if ( (synpred130()) )
                            {
                                alt75 = 1;
                            }

                            }
                            break;
                        case DYNAMIC:
                            {
                            int LA75_126 = input.LA(3);

                            if ( (synpred130()) )
                            {
                                alt75 = 1;
                            }

                            }
                            break;
                        case GET:
                            {
                            int LA75_127 = input.LA(3);

                            if ( (synpred130()) )
                            {
                                alt75 = 1;
                            }

                            }
                            break;
                        case SET:
                            {
                            int LA75_128 = input.LA(3);

                            if ( (synpred130()) )
                            {
                                alt75 = 1;
                            }

                            }
                            break;

                        }

                    }
                    else if ( (LA75_0 == AS) )
                    {
                        switch ( input.LA(2) )
                        {
                        case LBRACK:
                            {
                            int LA75_143 = input.LA(3);

                            if ( (synpred130()) )
                            {
                                alt75 = 1;
                            }

                            }
                            break;
                        case LPAREN:
                            {
                            int LA75_144 = input.LA(3);

                            if ( (synpred130()) )
                            {
                                alt75 = 1;
                            }

                            }
                            break;
                        case INC:
                            {
                            int LA75_145 = input.LA(3);

                            if ( (synpred130()) )
                            {
                                alt75 = 1;
                            }

                            }
                            break;
                        case DEC:
                            {
                            int LA75_146 = input.LA(3);

                            if ( (synpred130()) )
                            {
                                alt75 = 1;
                            }

                            }
                            break;
                        case MINUS:
                            {
                            int LA75_148 = input.LA(3);

                            if ( (synpred130()) )
                            {
                                alt75 = 1;
                            }

                            }
                            break;
                        case IS:
                            {
                            int LA75_155 = input.LA(3);

                            if ( (synpred130()) )
                            {
                                alt75 = 1;
                            }

                            }
                            break;
                        case AS:
                            {
                            int LA75_156 = input.LA(3);

                            if ( (synpred130()) )
                            {
                                alt75 = 1;
                            }

                            }
                            break;
                        case LCURLY:
                            {
                            int LA75_169 = input.LA(3);

                            if ( (synpred130()) )
                            {
                                alt75 = 1;
                            }

                            }
                            break;
                        case PLUS:
                            {
                            int LA75_171 = input.LA(3);

                            if ( (synpred130()) )
                            {
                                alt75 = 1;
                            }

                            }
                            break;
                        case DELETE:
                            {
                            int LA75_172 = input.LA(3);

                            if ( (synpred130()) )
                            {
                                alt75 = 1;
                            }

                            }
                            break;
                        case VOID:
                            {
                            int LA75_173 = input.LA(3);

                            if ( (synpred130()) )
                            {
                                alt75 = 1;
                            }

                            }
                            break;
                        case TYPEOF:
                            {
                            int LA75_174 = input.LA(3);

                            if ( (synpred130()) )
                            {
                                alt75 = 1;
                            }

                            }
                            break;
                        case LNOT:
                            {
                            int LA75_175 = input.LA(3);

                            if ( (synpred130()) )
                            {
                                alt75 = 1;
                            }

                            }
                            break;
                        case BNOT:
                            {
                            int LA75_176 = input.LA(3);

                            if ( (synpred130()) )
                            {
                                alt75 = 1;
                            }

                            }
                            break;
                        case UNDEFINED:
                            {
                            int LA75_177 = input.LA(3);

                            if ( (synpred130()) )
                            {
                                alt75 = 1;
                            }

                            }
                            break;
                        case HEX_LITERAL:
                        case DECIMAL_LITERAL:
                        case OCTAL_LITERAL:
                        case FLOAT_LITERAL:
                            {
                            int LA75_178 = input.LA(3);

                            if ( (synpred130()) )
                            {
                                alt75 = 1;
                            }

                            }
                            break;
                        case STRING_LITERAL:
                            {
                            int LA75_179 = input.LA(3);

                            if ( (synpred130()) )
                            {
                                alt75 = 1;
                            }

                            }
                            break;
                        case TRUE:
                            {
                            int LA75_180 = input.LA(3);

                            if ( (synpred130()) )
                            {
                                alt75 = 1;
                            }

                            }
                            break;
                        case FALSE:
                            {
                            int LA75_181 = input.LA(3);

                            if ( (synpred130()) )
                            {
                                alt75 = 1;
                            }

                            }
                            break;
                        case NULL:
                            {
                            int LA75_182 = input.LA(3);

                            if ( (synpred130()) )
                            {
                                alt75 = 1;
                            }

                            }
                            break;
                        case FUNCTION:
                            {
                            int LA75_183 = input.LA(3);

                            if ( (synpred130()) )
                            {
                                alt75 = 1;
                            }

                            }
                            break;
                        case NEW:
                            {
                            int LA75_184 = input.LA(3);

                            if ( (synpred130()) )
                            {
                                alt75 = 1;
                            }

                            }
                            break;
                        case IDENT:
                            {
                            int LA75_185 = input.LA(3);

                            if ( (synpred130()) )
                            {
                                alt75 = 1;
                            }

                            }
                            break;
                        case USE:
                            {
                            int LA75_186 = input.LA(3);

                            if ( (synpred130()) )
                            {
                                alt75 = 1;
                            }

                            }
                            break;
                        case XML:
                            {
                            int LA75_187 = input.LA(3);

                            if ( (synpred130()) )
                            {
                                alt75 = 1;
                            }

                            }
                            break;
                        case DYNAMIC:
                            {
                            int LA75_188 = input.LA(3);

                            if ( (synpred130()) )
                            {
                                alt75 = 1;
                            }

                            }
                            break;
                        case GET:
                            {
                            int LA75_189 = input.LA(3);

                            if ( (synpred130()) )
                            {
                                alt75 = 1;
                            }

                            }
                            break;
                        case SET:
                            {
                            int LA75_190 = input.LA(3);

                            if ( (synpred130()) )
                            {
                                alt75 = 1;
                            }

                            }
                            break;

                        }

                    }
                    else if ( (LA75_0 == IN) )
                    {
                        switch ( input.LA(2) )
                        {
                        case INC:
                            {
                            int LA75_207 = input.LA(3);

                            if ( ((synpred130() && ((InOperator_scope)InOperator_stack.Peek()).allowed)) )
                            {
                                alt75 = 1;
                            }

                            }
                            break;
                        case DEC:
                            {
                            int LA75_208 = input.LA(3);

                            if ( ((synpred130() && ((InOperator_scope)InOperator_stack.Peek()).allowed)) )
                            {
                                alt75 = 1;
                            }

                            }
                            break;
                        case MINUS:
                            {
                            int LA75_209 = input.LA(3);

                            if ( ((synpred130() && ((InOperator_scope)InOperator_stack.Peek()).allowed)) )
                            {
                                alt75 = 1;
                            }

                            }
                            break;
                        case PLUS:
                            {
                            int LA75_210 = input.LA(3);

                            if ( ((synpred130() && ((InOperator_scope)InOperator_stack.Peek()).allowed)) )
                            {
                                alt75 = 1;
                            }

                            }
                            break;
                        case DELETE:
                            {
                            int LA75_211 = input.LA(3);

                            if ( ((synpred130() && ((InOperator_scope)InOperator_stack.Peek()).allowed)) )
                            {
                                alt75 = 1;
                            }

                            }
                            break;
                        case VOID:
                            {
                            int LA75_212 = input.LA(3);

                            if ( ((synpred130() && ((InOperator_scope)InOperator_stack.Peek()).allowed)) )
                            {
                                alt75 = 1;
                            }

                            }
                            break;
                        case TYPEOF:
                            {
                            int LA75_213 = input.LA(3);

                            if ( ((synpred130() && ((InOperator_scope)InOperator_stack.Peek()).allowed)) )
                            {
                                alt75 = 1;
                            }

                            }
                            break;
                        case LNOT:
                            {
                            int LA75_214 = input.LA(3);

                            if ( ((synpred130() && ((InOperator_scope)InOperator_stack.Peek()).allowed)) )
                            {
                                alt75 = 1;
                            }

                            }
                            break;
                        case BNOT:
                            {
                            int LA75_215 = input.LA(3);

                            if ( ((synpred130() && ((InOperator_scope)InOperator_stack.Peek()).allowed)) )
                            {
                                alt75 = 1;
                            }

                            }
                            break;
                        case UNDEFINED:
                            {
                            int LA75_216 = input.LA(3);

                            if ( ((synpred130() && ((InOperator_scope)InOperator_stack.Peek()).allowed)) )
                            {
                                alt75 = 1;
                            }

                            }
                            break;
                        case HEX_LITERAL:
                        case DECIMAL_LITERAL:
                        case OCTAL_LITERAL:
                        case FLOAT_LITERAL:
                            {
                            int LA75_217 = input.LA(3);

                            if ( ((synpred130() && ((InOperator_scope)InOperator_stack.Peek()).allowed)) )
                            {
                                alt75 = 1;
                            }

                            }
                            break;
                        case STRING_LITERAL:
                            {
                            int LA75_218 = input.LA(3);

                            if ( ((synpred130() && ((InOperator_scope)InOperator_stack.Peek()).allowed)) )
                            {
                                alt75 = 1;
                            }

                            }
                            break;
                        case TRUE:
                            {
                            int LA75_219 = input.LA(3);

                            if ( ((synpred130() && ((InOperator_scope)InOperator_stack.Peek()).allowed)) )
                            {
                                alt75 = 1;
                            }

                            }
                            break;
                        case FALSE:
                            {
                            int LA75_220 = input.LA(3);

                            if ( ((synpred130() && ((InOperator_scope)InOperator_stack.Peek()).allowed)) )
                            {
                                alt75 = 1;
                            }

                            }
                            break;
                        case NULL:
                            {
                            int LA75_221 = input.LA(3);

                            if ( ((synpred130() && ((InOperator_scope)InOperator_stack.Peek()).allowed)) )
                            {
                                alt75 = 1;
                            }

                            }
                            break;
                        case LBRACK:
                            {
                            int LA75_222 = input.LA(3);

                            if ( ((synpred130() && ((InOperator_scope)InOperator_stack.Peek()).allowed)) )
                            {
                                alt75 = 1;
                            }

                            }
                            break;
                        case LCURLY:
                            {
                            int LA75_223 = input.LA(3);

                            if ( ((synpred130() && ((InOperator_scope)InOperator_stack.Peek()).allowed)) )
                            {
                                alt75 = 1;
                            }

                            }
                            break;
                        case FUNCTION:
                            {
                            int LA75_224 = input.LA(3);

                            if ( ((synpred130() && ((InOperator_scope)InOperator_stack.Peek()).allowed)) )
                            {
                                alt75 = 1;
                            }

                            }
                            break;
                        case NEW:
                            {
                            int LA75_225 = input.LA(3);

                            if ( ((synpred130() && ((InOperator_scope)InOperator_stack.Peek()).allowed)) )
                            {
                                alt75 = 1;
                            }

                            }
                            break;
                        case LPAREN:
                            {
                            int LA75_226 = input.LA(3);

                            if ( ((synpred130() && ((InOperator_scope)InOperator_stack.Peek()).allowed)) )
                            {
                                alt75 = 1;
                            }

                            }
                            break;
                        case IDENT:
                            {
                            int LA75_227 = input.LA(3);

                            if ( ((synpred130() && ((InOperator_scope)InOperator_stack.Peek()).allowed)) )
                            {
                                alt75 = 1;
                            }

                            }
                            break;
                        case USE:
                            {
                            int LA75_228 = input.LA(3);

                            if ( ((synpred130() && ((InOperator_scope)InOperator_stack.Peek()).allowed)) )
                            {
                                alt75 = 1;
                            }

                            }
                            break;
                        case XML:
                            {
                            int LA75_229 = input.LA(3);

                            if ( ((synpred130() && ((InOperator_scope)InOperator_stack.Peek()).allowed)) )
                            {
                                alt75 = 1;
                            }

                            }
                            break;
                        case DYNAMIC:
                            {
                            int LA75_230 = input.LA(3);

                            if ( ((synpred130() && ((InOperator_scope)InOperator_stack.Peek()).allowed)) )
                            {
                                alt75 = 1;
                            }

                            }
                            break;
                        case IS:
                            {
                            int LA75_231 = input.LA(3);

                            if ( ((synpred130() && ((InOperator_scope)InOperator_stack.Peek()).allowed)) )
                            {
                                alt75 = 1;
                            }

                            }
                            break;
                        case AS:
                            {
                            int LA75_232 = input.LA(3);

                            if ( ((synpred130() && ((InOperator_scope)InOperator_stack.Peek()).allowed)) )
                            {
                                alt75 = 1;
                            }

                            }
                            break;
                        case GET:
                            {
                            int LA75_233 = input.LA(3);

                            if ( ((synpred130() && ((InOperator_scope)InOperator_stack.Peek()).allowed)) )
                            {
                                alt75 = 1;
                            }

                            }
                            break;
                        case SET:
                            {
                            int LA75_234 = input.LA(3);

                            if ( ((synpred130() && ((InOperator_scope)InOperator_stack.Peek()).allowed)) )
                            {
                                alt75 = 1;
                            }

                            }
                            break;

                        }

                    }
                    else if ( (LA75_0 == LT) && (synpred130()) )
                    {
                        alt75 = 1;
                    }
                    else if ( (LA75_0 == GT) && (synpred130()) )
                    {
                        alt75 = 1;
                    }
                    else if ( (LA75_0 == LE) && (synpred130()) )
                    {
                        alt75 = 1;
                    }
                    else if ( (LA75_0 == GE) && (synpred130()) )
                    {
                        alt75 = 1;
                    }
                    else if ( (LA75_0 == INSTANCEOF) && (synpred130()) )
                    {
                        alt75 = 1;
                    }

                    switch (alt75)
                    {
                        case 1 :
                            // C:\\Users\\sephiroth\\Documents\\Visual Studio 2005\\Projects\\CodeReformatter\\CodeReformatter\\AS.g:1354:4: ( relationalOperator )=>op= relationalOperator shiftExpression
                            {
                                PushFollow(FOLLOW_relationalOperator_in_relationalExpression4649);
                                op = relationalOperator();
                                followingStackPointer_--;
                                if (failed) return retval;
                                if ( backtracking==0 ) root_0 = (CommonTree)adaptor.BecomeRoot(op.Tree, root_0);
                                if ( backtracking == 0 )
                                {

                                  																buffer.Append(" ");
                                  																buffer.Append(((CommonTree)op.Tree).Text );
                                  																buffer.Append(" ");

                                }
                                PushFollow(FOLLOW_shiftExpression_in_relationalExpression4657);
                                shiftExpression256 = shiftExpression();
                                followingStackPointer_--;
                                if (failed) return retval;
                                if ( backtracking==0 ) adaptor.AddChild(root_0, shiftExpression256.Tree);

                            }
                            break;

                        default:
                            goto loop75;
                    }
                } while (true);

                loop75:
                    ;	// Stops C# compiler whinging that label 'loop75' has no statements

            }

            retval.stop = input.LT(-1);

            if ( backtracking==0 )
            {	retval.tree = (CommonTree)adaptor.RulePostProcessing(root_0);
                adaptor.SetTokenBoundaries(retval.Tree, retval.start, retval.stop);
            }
            }

            catch (NoViableAltException e)
            {
                Debug.WriteLine("NoValiable alt: token=" + e.Token + " (decision=" + e.decisionNumber + " state " + e.stateNumber + ")" + " decision=<<" + e.grammarDecisionDescription + ">>");
                throw e;
            }
            catch (MismatchedTokenException e)
            {
                Debug.WriteLine("[" + e.Line + ":" + e.Index + "]: " + e.Message + ". Unexpected " + e.UnexpectedType.ToString() +  "( expecting: "+ e.expecting + " )");
                throw e;
            }
            catch(RecognitionException e)
            {
                Debug.WriteLine("RecognitionException: " + e);
                throw e;
            }
            finally
            {
            if ( backtracking > 0 )
            {
                Memoize(input, 100, relationalExpression_StartIndex);
            }
            }
            return retval;
        }
Beispiel #2
0
    // $ANTLR start relationalExpression
    // C:\\Documents and Settings\\Sébastien Ros\\Mes documents\\Développement\\NLinq\\NLinq.g:104:1: relationalExpression returns [Expression value] : left= additiveExpression ( ( '<' | '<=' | '>' | '>=' ) right= additiveExpression )* ;
    public relationalExpression_return relationalExpression() // throws RecognitionException [1]
    {   
        relationalExpression_return retval = new relationalExpression_return();
        retval.start = input.LT(1);
        
        CommonTree root_0 = null;
    
        IToken char_literal13 = null;
        IToken string_literal14 = null;
        IToken char_literal15 = null;
        IToken string_literal16 = null;
        additiveExpression_return left = null;

        additiveExpression_return right = null;
        
        
        CommonTree char_literal13_tree=null;
        CommonTree string_literal14_tree=null;
        CommonTree char_literal15_tree=null;
        CommonTree string_literal16_tree=null;
    
        
        BinaryExpressionType type = BinaryExpressionType.Unknown;
    
        try 
    	{
            // C:\\Documents and Settings\\Sébastien Ros\\Mes documents\\Développement\\NLinq\\NLinq.g:108:2: (left= additiveExpression ( ( '<' | '<=' | '>' | '>=' ) right= additiveExpression )* )
            // C:\\Documents and Settings\\Sébastien Ros\\Mes documents\\Développement\\NLinq\\NLinq.g:108:4: left= additiveExpression ( ( '<' | '<=' | '>' | '>=' ) right= additiveExpression )*
            {
            	root_0 = (CommonTree)adaptor.GetNilNode();
            
            	PushFollow(FOLLOW_additiveExpression_in_relationalExpression321);
            	left = additiveExpression();
            	followingStackPointer_--;
            	
            	adaptor.AddChild(root_0, left.Tree);
            	 retval.value =  left.value; 
            	// C:\\Documents and Settings\\Sébastien Ros\\Mes documents\\Développement\\NLinq\\NLinq.g:108:54: ( ( '<' | '<=' | '>' | '>=' ) right= additiveExpression )*
            	do 
            	{
            	    int alt8 = 2;
            	    switch ( input.LA(1) ) 
            	    {
            	    case 23:
            	    	{
            	        alt8 = 1;
            	        }
            	        break;
            	    case 24:
            	    	{
            	        alt8 = 1;
            	        }
            	        break;
            	    case 25:
            	    	{
            	        alt8 = 1;
            	        }
            	        break;
            	    case 26:
            	    	{
            	        alt8 = 1;
            	        }
            	        break;
            	    
            	    }
            	
            	    switch (alt8) 
            		{
            			case 1 :
            			    // C:\\Documents and Settings\\Sébastien Ros\\Mes documents\\Développement\\NLinq\\NLinq.g:109:4: ( '<' | '<=' | '>' | '>=' ) right= additiveExpression
            			    {
            			    	// C:\\Documents and Settings\\Sébastien Ros\\Mes documents\\Développement\\NLinq\\NLinq.g:109:4: ( '<' | '<=' | '>' | '>=' )
            			    	int alt7 = 4;
            			    	switch ( input.LA(1) ) 
            			    	{
            			    	case 23:
            			    		{
            			    	    alt7 = 1;
            			    	    }
            			    	    break;
            			    	case 24:
            			    		{
            			    	    alt7 = 2;
            			    	    }
            			    	    break;
            			    	case 25:
            			    		{
            			    	    alt7 = 3;
            			    	    }
            			    	    break;
            			    	case 26:
            			    		{
            			    	    alt7 = 4;
            			    	    }
            			    	    break;
            			    		default:
            			    		    NoViableAltException nvae_d7s0 =
            			    		        new NoViableAltException("109:4: ( '<' | '<=' | '>' | '>=' )", 7, 0, input);
            			    	
            			    		    throw nvae_d7s0;
            			    	}
            			    	
            			    	switch (alt7) 
            			    	{
            			    	    case 1 :
            			    	        // C:\\Documents and Settings\\Sébastien Ros\\Mes documents\\Développement\\NLinq\\NLinq.g:109:6: '<'
            			    	        {
            			    	        	char_literal13 = (IToken)input.LT(1);
            			    	        	Match(input,23,FOLLOW_23_in_relationalExpression332); 
            			    	        	char_literal13_tree = (CommonTree)adaptor.Create(char_literal13);
            			    	        	adaptor.AddChild(root_0, char_literal13_tree);

            			    	        	 type = BinaryExpressionType.Lesser; 
            			    	        
            			    	        }
            			    	        break;
            			    	    case 2 :
            			    	        // C:\\Documents and Settings\\Sébastien Ros\\Mes documents\\Développement\\NLinq\\NLinq.g:110:6: '<='
            			    	        {
            			    	        	string_literal14 = (IToken)input.LT(1);
            			    	        	Match(input,24,FOLLOW_24_in_relationalExpression342); 
            			    	        	string_literal14_tree = (CommonTree)adaptor.Create(string_literal14);
            			    	        	adaptor.AddChild(root_0, string_literal14_tree);

            			    	        	 type = BinaryExpressionType.LesserOrEqual; 
            			    	        
            			    	        }
            			    	        break;
            			    	    case 3 :
            			    	        // C:\\Documents and Settings\\Sébastien Ros\\Mes documents\\Développement\\NLinq\\NLinq.g:111:6: '>'
            			    	        {
            			    	        	char_literal15 = (IToken)input.LT(1);
            			    	        	Match(input,25,FOLLOW_25_in_relationalExpression353); 
            			    	        	char_literal15_tree = (CommonTree)adaptor.Create(char_literal15);
            			    	        	adaptor.AddChild(root_0, char_literal15_tree);

            			    	        	 type = BinaryExpressionType.Greater; 
            			    	        
            			    	        }
            			    	        break;
            			    	    case 4 :
            			    	        // C:\\Documents and Settings\\Sébastien Ros\\Mes documents\\Développement\\NLinq\\NLinq.g:112:6: '>='
            			    	        {
            			    	        	string_literal16 = (IToken)input.LT(1);
            			    	        	Match(input,26,FOLLOW_26_in_relationalExpression363); 
            			    	        	string_literal16_tree = (CommonTree)adaptor.Create(string_literal16);
            			    	        	adaptor.AddChild(root_0, string_literal16_tree);

            			    	        	 type = BinaryExpressionType.GreaterOrEqual; 
            			    	        
            			    	        }
            			    	        break;
            			    	
            			    	}

            			    	PushFollow(FOLLOW_additiveExpression_in_relationalExpression375);
            			    	right = additiveExpression();
            			    	followingStackPointer_--;
            			    	
            			    	adaptor.AddChild(root_0, right.Tree);
            			    	 retval.value =  new BinaryExpression(type, retval.value, right.value); 
            			    
            			    }
            			    break;
            	
            			default:
            			    goto loop8;
            	    }
            	} while (true);
            	
            	loop8:
            		;	// Stops C# compiler whinging that label 'loop8' has no statements

            
            }
    
            retval.stop = input.LT(-1);
            
            	retval.tree = (CommonTree)adaptor.RulePostProcessing(root_0);
            	adaptor.SetTokenBoundaries(retval.Tree, retval.start, retval.stop);
    
        }
        catch (RecognitionException re) 
    	{
            ReportError(re);
            Recover(input,re);
        }
        finally 
    	{
        }
        return retval;
    }