public final BaseDescr unaryExpression() throws RecognitionException {
		BaseDescr result = null;


		BaseDescr ue =null;
		ParserRuleReturnScope left =null;

		try {
			// src/main/resources/org/drools/compiler/lang/DRL5Expressions.g:467:5: ( PLUS ue= unaryExpression | MINUS ue= unaryExpression | INCR primary | DECR primary |left= unaryExpressionNotPlusMinus )
			int alt49=5;
			switch ( input.LA(1) ) {
			case PLUS:
				{
				alt49=1;
				}
				break;
			case MINUS:
				{
				alt49=2;
				}
				break;
			case INCR:
				{
				alt49=3;
				}
				break;
			case DECR:
				{
				alt49=4;
				}
				break;
			case BOOL:
			case DECIMAL:
			case FLOAT:
			case HEX:
			case ID:
			case LEFT_PAREN:
			case LEFT_SQUARE:
			case LESS:
			case NEGATION:
			case NULL:
			case STAR:
			case STRING:
			case TILDE:
			case TIME_INTERVAL:
				{
				alt49=5;
				}
				break;
			default:
				if (state.backtracking>0) {state.failed=true; return result;}
				NoViableAltException nvae =
					new NoViableAltException("", 49, 0, input);
				throw nvae;
			}
			switch (alt49) {
				case 1 :
					// src/main/resources/org/drools/compiler/lang/DRL5Expressions.g:467:9: PLUS ue= unaryExpression
					{
					match(input,PLUS,FOLLOW_PLUS_in_unaryExpression2269); if (state.failed) return result;
					pushFollow(FOLLOW_unaryExpression_in_unaryExpression2273);
					ue=unaryExpression();
					state._fsp--;
					if (state.failed) return result;
					if ( state.backtracking==0 ) { if( buildDescr ) {
					            result = ue;
					            if( result instanceof AtomicExprDescr ) {
					                ((AtomicExprDescr)result).setExpression( "+" + ((AtomicExprDescr)result).getExpression() );
					            }
					        } }
					}
					break;
				case 2 :
					// src/main/resources/org/drools/compiler/lang/DRL5Expressions.g:474:7: MINUS ue= unaryExpression
					{
					match(input,MINUS,FOLLOW_MINUS_in_unaryExpression2291); if (state.failed) return result;
					pushFollow(FOLLOW_unaryExpression_in_unaryExpression2295);
					ue=unaryExpression();
					state._fsp--;
					if (state.failed) return result;
					if ( state.backtracking==0 ) { if( buildDescr ) {
					            result = ue;
					            if( result instanceof AtomicExprDescr ) {
					                ((AtomicExprDescr)result).setExpression( "-" + ((AtomicExprDescr)result).getExpression() );
					            }
					        } }
					}
					break;
				case 3 :
					// src/main/resources/org/drools/compiler/lang/DRL5Expressions.g:481:9: INCR primary
					{
					match(input,INCR,FOLLOW_INCR_in_unaryExpression2315); if (state.failed) return result;
					pushFollow(FOLLOW_primary_in_unaryExpression2317);
					primary();
					state._fsp--;
					if (state.failed) return result;
					}
					break;
				case 4 :
					// src/main/resources/org/drools/compiler/lang/DRL5Expressions.g:482:9: DECR primary
					{
					match(input,DECR,FOLLOW_DECR_in_unaryExpression2327); if (state.failed) return result;
					pushFollow(FOLLOW_primary_in_unaryExpression2329);
					primary();
					state._fsp--;
					if (state.failed) return result;
					}
					break;
				case 5 :
					// src/main/resources/org/drools/compiler/lang/DRL5Expressions.g:483:9: left= unaryExpressionNotPlusMinus
					{
					pushFollow(FOLLOW_unaryExpressionNotPlusMinus_in_unaryExpression2341);
					left=unaryExpressionNotPlusMinus();
					state._fsp--;
					if (state.failed) return result;
					if ( state.backtracking==0 ) { if( buildDescr ) { result = (left!=null?((DRL5Expressions.unaryExpressionNotPlusMinus_return)left).result:null); } }
					}
					break;

			}
		}

		catch (RecognitionException re) {
		    throw re;
		}

		finally {
			// do for sure before leaving
		}
		return result;
	}
public final BaseDescr unaryExpression ( ) throws RecognitionException { BaseDescr result = null ; BaseDescr ue = null ; ParserRuleReturnScope left = null ; try { int alt49 = 5 ; switch ( input . LA ( 1 ) ) { case PLUS : { alt49 = 1 ; } break ; case MINUS : { alt49 = 2 ; } break ; case INCR : { alt49 = 3 ; } break ; case DECR : { alt49 = 4 ; } break ; case BOOL : case DECIMAL : case FLOAT : case HEX : case ID : case LEFT_PAREN : case LEFT_SQUARE : case LESS : case NEGATION : case NULL : case STAR : case STRING : case TILDE : case TIME_INTERVAL : { alt49 = 5 ; } break ; default : if ( state . backtracking > 0 ) { state . failed = true ; return result ; } NoViableAltException nvae = new NoViableAltException ( "" , 49 , 0 , input ) ; throw nvae ; } switch ( alt49 ) { case 1 : { match ( input , PLUS , FOLLOW_PLUS_in_unaryExpression2269 ) ; if ( state . failed ) return result ; pushFollow ( FOLLOW_unaryExpression_in_unaryExpression2273 ) ; ue = unaryExpression ( ) ; state . _fsp -- ; if ( state . failed ) return result ; if ( state . backtracking == 0 ) { if ( buildDescr ) { result = ue ; if ( result instanceof AtomicExprDescr ) { ( ( AtomicExprDescr ) result ) . setExpression ( "+" + ( ( AtomicExprDescr ) result ) . getExpression ( ) ) ; } } } } break ; case 2 : { match ( input , MINUS , FOLLOW_MINUS_in_unaryExpression2291 ) ; if ( state . failed ) return result ; pushFollow ( FOLLOW_unaryExpression_in_unaryExpression2295 ) ; ue = unaryExpression ( ) ; state . _fsp -- ; if ( state . failed ) return result ; if ( state . backtracking == 0 ) { if ( buildDescr ) { result = ue ; if ( result instanceof AtomicExprDescr ) { ( ( AtomicExprDescr ) result ) . setExpression ( "-" + ( ( AtomicExprDescr ) result ) . getExpression ( ) ) ; } } } } break ; case 3 : { match ( input , INCR , FOLLOW_INCR_in_unaryExpression2315 ) ; if ( state . failed ) return result ; pushFollow ( FOLLOW_primary_in_unaryExpression2317 ) ; primary ( ) ; state . _fsp -- ; if ( state . failed ) return result ; } break ; case 4 : { match ( input , DECR , FOLLOW_DECR_in_unaryExpression2327 ) ; if ( state . failed ) return result ; pushFollow ( FOLLOW_primary_in_unaryExpression2329 ) ; primary ( ) ; state . _fsp -- ; if ( state . failed ) return result ; } break ; case 5 : { pushFollow ( FOLLOW_unaryExpressionNotPlusMinus_in_unaryExpression2341 ) ; left = unaryExpressionNotPlusMinus ( ) ; state . _fsp -- ; if ( state . failed ) return result ; if ( state . backtracking == 0 ) { if ( buildDescr ) { result = ( left != null ? ( ( DRL5Expressions . unaryExpressionNotPlusMinus_return ) left ) . result : null ) ; } } } break ; } } catch ( RecognitionException re ) { throw re ; } finally { } return result ; }
src/main/resources/org/drools/compiler/lang/DRL5Expressions.g:466:1: unaryExpression returns [BaseDescr result] : ( PLUS ue= unaryExpression | MINUS ue= unaryExpression | INCR primary | DECR primary |left= unaryExpressionNotPlusMinus );