1 // $ANTLR 3.1.2 BuildOptions\\DebugGrammar.g3 2009-09-30 13:18:13
2 
3 // The variable 'variable' is assigned but its value is never used.
4 #pragma warning disable 219
5 // Unreachable code detected.
6 #pragma warning disable 162
7 
8 
9 using System.Collections.Generic;
10 using Antlr.Runtime;
11 using Stack = System.Collections.Generic.Stack<object>;
12 using List = System.Collections.IList;
13 using ArrayList = System.Collections.Generic.List<object>;
14 
15 using Antlr.Runtime.Debug;
16 using IOException = System.IO.IOException;
17 
18 using Antlr.Runtime.Tree;
19 using RewriteRuleITokenStream = Antlr.Runtime.Tree.RewriteRuleTokenStream;
20 
21 [System.CodeDom.Compiler.GeneratedCode("ANTLR", "3.1.2")]
22 [System.CLSCompliant(false)]
23 public partial class DebugGrammarParser : DebugParser
24 {
25 	internal static readonly string[] tokenNames = new string[] {
26 		"<invalid>", "<EOR>", "<DOWN>", "<UP>", "CALL", "FUNC", "ID", "INT", "NEWLINE", "WS", "'-'", "'%'", "'('", "')'", "'*'", "'/'", "'+'", "'='"
27 	};
28 	public const int EOF=-1;
29 	public const int T__10=10;
30 	public const int T__11=11;
31 	public const int T__12=12;
32 	public const int T__13=13;
33 	public const int T__14=14;
34 	public const int T__15=15;
35 	public const int T__16=16;
36 	public const int T__17=17;
37 	public const int CALL=4;
38 	public const int FUNC=5;
39 	public const int ID=6;
40 	public const int INT=7;
41 	public const int NEWLINE=8;
42 	public const int WS=9;
43 
44 	// delegates
45 	// delegators
46 
47 	public static readonly string[] ruleNames =
48 		new string[]
49 		{
50 			"invalidRule", "atom", "expr", "formalPar", "func", "multExpr", "prog",
51 		"stat"
52 		};
53 
54 		int ruleLevel = 0;
55 		public virtual int RuleLevel { get { return ruleLevel; } }
IncRuleLevel()56 		public virtual void IncRuleLevel() { ruleLevel++; }
DecRuleLevel()57 		public virtual void DecRuleLevel() { ruleLevel--; }
DebugGrammarParser( ITokenStream input )58 		public DebugGrammarParser( ITokenStream input )
59 			: this( input, DebugEventSocketProxy.DefaultDebuggerPort, new RecognizerSharedState() )
60 		{
61 		}
DebugGrammarParser( ITokenStream input, int port, RecognizerSharedState state )62 		public DebugGrammarParser( ITokenStream input, int port, RecognizerSharedState state )
63 			: base( input, state )
64 		{
65 			InitializeTreeAdaptor();
66 			if ( TreeAdaptor == null )
67 				TreeAdaptor = new CommonTreeAdaptor();
68 			DebugEventSocketProxy proxy = new DebugEventSocketProxy( this, port, adaptor );
69 			DebugListener = proxy;
70 			TokenStream = new DebugTokenStream( input, proxy );
71 			try
72 			{
73 				proxy.Handshake();
74 			}
75 			catch ( IOException ioe )
76 			{
77 				ReportError( ioe );
78 			}
79 			ITreeAdaptor adap = new CommonTreeAdaptor();
80 			TreeAdaptor = adap;
81 			proxy.TreeAdaptor = adap;
82 		}
DebugGrammarParser( ITokenStream input, IDebugEventListener dbg )83 	public DebugGrammarParser( ITokenStream input, IDebugEventListener dbg )
84 		: base( input, dbg )
85 	{
86 		InitializeTreeAdaptor();
87 		if ( TreeAdaptor == null )
88 			TreeAdaptor = new CommonTreeAdaptor();
89 
90 		ITreeAdaptor adap = new CommonTreeAdaptor();
91 		TreeAdaptor = adap;
92 
93 	}
EvalPredicate( bool result, string predicate )94 	protected virtual bool EvalPredicate( bool result, string predicate )
95 	{
96 		dbg.SemanticPredicate( result, predicate );
97 		return result;
98 	}
99 
100 	// Implement this function in your helper file to use a custom tree adaptor
InitializeTreeAdaptor()101 	partial void InitializeTreeAdaptor();
102 	protected DebugTreeAdaptor adaptor;
103 
104 	public ITreeAdaptor TreeAdaptor
105 	{
106 		get
107 		{
108 			return adaptor;
109 		}
110 		set
111 		{
112 			this.adaptor = new DebugTreeAdaptor(dbg,adaptor);
113 
114 		}
115 	}
116 
117 
118 	public override string[] TokenNames { get { return DebugGrammarParser.tokenNames; } }
119 	public override string GrammarFileName { get { return "BuildOptions\\DebugGrammar.g3"; } }
120 
121 
122 	#region Rules
123 	public class prog_return : ParserRuleReturnScope
124 	{
125 		internal CommonTree tree;
126 		public override object Tree { get { return tree; } }
127 	}
128 
129 	// $ANTLR start "prog"
130 	// BuildOptions\\DebugGrammar.g3:50:0: prog : ( stat )* ;
prog( )131 	private DebugGrammarParser.prog_return prog(  )
132 	{
133 		DebugGrammarParser.prog_return retval = new DebugGrammarParser.prog_return();
134 		retval.start = input.LT(1);
135 
136 		CommonTree root_0 = null;
137 
138 		DebugGrammarParser.stat_return stat1 = default(DebugGrammarParser.stat_return);
139 
140 
141 		try
142 		{
143 			dbg.EnterRule( GrammarFileName, "prog" );
144 			if ( RuleLevel == 0 )
145 			{
146 				dbg.Commence();
147 			}
148 			IncRuleLevel();
149 			dbg.Location( 50, -1 );
150 
151 		try
152 		{
153 			// BuildOptions\\DebugGrammar.g3:50:7: ( ( stat )* )
154 			dbg.EnterAlt( 1 );
155 
156 			// BuildOptions\\DebugGrammar.g3:50:7: ( stat )*
157 			{
158 			root_0 = (CommonTree)adaptor.Nil();
159 
160 			dbg.Location( 50, 6 );
161 			// BuildOptions\\DebugGrammar.g3:50:7: ( stat )*
162 			try
163 			{
164 				dbg.EnterSubRule( 1 );
165 
166 			for ( ; ; )
167 			{
168 				int alt1=2;
169 				try
170 				{
171 					dbg.EnterDecision( 1 );
172 
173 				int LA1_0 = input.LA(1);
174 
175 				if ( ((LA1_0>=ID && LA1_0<=NEWLINE)||LA1_0==12) )
176 				{
177 					alt1=1;
178 				}
179 
180 
181 				}
182 				finally
183 				{
184 					dbg.ExitDecision( 1 );
185 				}
186 
187 				switch ( alt1 )
188 				{
189 				case 1:
190 					dbg.EnterAlt( 1 );
191 
192 					// BuildOptions\\DebugGrammar.g3:50:9: stat
193 					{
194 					dbg.Location( 50, 8 );
195 					PushFollow(Follow._stat_in_prog53);
196 					stat1=stat();
197 
198 					state._fsp--;
199 
200 					adaptor.AddChild(root_0, stat1.Tree);
201 
202 					}
203 					break;
204 
205 				default:
206 					goto loop1;
207 				}
208 			}
209 
210 			loop1:
211 				;
212 
213 			}
214 			finally
215 			{
216 				dbg.ExitSubRule( 1 );
217 			}
218 
219 
220 			}
221 
222 			retval.stop = input.LT(-1);
223 
224 			retval.tree = (CommonTree)adaptor.RulePostProcessing(root_0);
225 			adaptor.SetTokenBoundaries(retval.tree, retval.start, retval.stop);
226 
227 		}
228 		catch ( RecognitionException re )
229 		{
230 			ReportError(re);
231 			Recover(input,re);
232 		retval.tree = (CommonTree)adaptor.ErrorNode(input, retval.start, input.LT(-1), re);
233 
234 		}
235 		finally
236 		{
237 		}
238 		dbg.Location(51, 4);
239 
240 		}
241 		finally
242 		{
243 			dbg.ExitRule( GrammarFileName, "prog" );
244 			DecRuleLevel();
245 			if ( RuleLevel == 0 )
246 			{
247 				dbg.Terminate();
248 			}
249 		}
250 
251 		return retval;
252 	}
253 	// $ANTLR end "prog"
254 
255 	public class stat_return : ParserRuleReturnScope
256 	{
257 		internal CommonTree tree;
258 		public override object Tree { get { return tree; } }
259 	}
260 
261 	// $ANTLR start "stat"
262 	// BuildOptions\\DebugGrammar.g3:53:0: stat : ( expr NEWLINE -> expr | ID '=' expr NEWLINE -> ^( '=' ID expr ) | func NEWLINE -> func | NEWLINE ->);
stat( )263 	private DebugGrammarParser.stat_return stat(  )
264 	{
265 		DebugGrammarParser.stat_return retval = new DebugGrammarParser.stat_return();
266 		retval.start = input.LT(1);
267 
268 		CommonTree root_0 = null;
269 
270 		IToken NEWLINE3=null;
271 		IToken ID4=null;
272 		IToken char_literal5=null;
273 		IToken NEWLINE7=null;
274 		IToken NEWLINE9=null;
275 		IToken NEWLINE10=null;
276 		DebugGrammarParser.expr_return expr2 = default(DebugGrammarParser.expr_return);
277 		DebugGrammarParser.expr_return expr6 = default(DebugGrammarParser.expr_return);
278 		DebugGrammarParser.func_return func8 = default(DebugGrammarParser.func_return);
279 
280 		CommonTree NEWLINE3_tree=null;
281 		CommonTree ID4_tree=null;
282 		CommonTree char_literal5_tree=null;
283 		CommonTree NEWLINE7_tree=null;
284 		CommonTree NEWLINE9_tree=null;
285 		CommonTree NEWLINE10_tree=null;
286 		RewriteRuleITokenStream stream_NEWLINE=new RewriteRuleITokenStream(adaptor,"token NEWLINE");
287 		RewriteRuleITokenStream stream_ID=new RewriteRuleITokenStream(adaptor,"token ID");
288 		RewriteRuleITokenStream stream_17=new RewriteRuleITokenStream(adaptor,"token 17");
289 		RewriteRuleSubtreeStream stream_expr=new RewriteRuleSubtreeStream(adaptor,"rule expr");
290 		RewriteRuleSubtreeStream stream_func=new RewriteRuleSubtreeStream(adaptor,"rule func");
291 		try
292 		{
293 			dbg.EnterRule( GrammarFileName, "stat" );
294 			if ( RuleLevel == 0 )
295 			{
296 				dbg.Commence();
297 			}
298 			IncRuleLevel();
299 			dbg.Location( 53, -1 );
300 
301 		try
302 		{
303 			// BuildOptions\\DebugGrammar.g3:53:9: ( expr NEWLINE -> expr | ID '=' expr NEWLINE -> ^( '=' ID expr ) | func NEWLINE -> func | NEWLINE ->)
304 			int alt2=4;
305 			try
306 			{
307 				dbg.EnterDecision( 2 );
308 
309 			try
310 			{
311 				isCyclicDecision = true;
312 				alt2 = dfa2.Predict(input);
313 			}
314 			catch ( NoViableAltException nvae )
315 			{
316 				dbg.RecognitionException( nvae );
317 				throw nvae;
318 			}
319 			}
320 			finally
321 			{
322 				dbg.ExitDecision( 2 );
323 			}
324 
325 			switch ( alt2 )
326 			{
327 			case 1:
328 				dbg.EnterAlt( 1 );
329 
330 				// BuildOptions\\DebugGrammar.g3:53:9: expr NEWLINE
331 				{
332 				dbg.Location( 53, 8 );
333 				PushFollow(Follow._expr_in_stat70);
334 				expr2=expr();
335 
336 				state._fsp--;
337 
338 				stream_expr.Add(expr2.Tree);
339 				dbg.Location( 53, 13 );
340 				NEWLINE3=(IToken)Match(input,NEWLINE,Follow._NEWLINE_in_stat72);
341 				stream_NEWLINE.Add(NEWLINE3);
342 
343 
344 
345 				{
346 				// AST REWRITE
347 				// elements: expr
348 				// token labels:
349 				// rule labels: retval
350 				// token list labels:
351 				// rule list labels:
352 				// wildcard labels:
353 				retval.tree = root_0;
354 				RewriteRuleSubtreeStream stream_retval=new RewriteRuleSubtreeStream(adaptor,"rule retval",retval!=null?retval.tree:null);
355 
356 				root_0 = (CommonTree)adaptor.Nil();
357 				// 53:41: -> expr
358 				{
359 					dbg.Location( 53, 43 );
360 					adaptor.AddChild(root_0, stream_expr.NextTree());
361 
362 				}
363 
364 				retval.tree = root_0;
365 				}
366 
367 				}
368 				break;
369 			case 2:
370 				dbg.EnterAlt( 2 );
371 
372 				// BuildOptions\\DebugGrammar.g3:54:9: ID '=' expr NEWLINE
373 				{
374 				dbg.Location( 54, 8 );
375 				ID4=(IToken)Match(input,ID,Follow._ID_in_stat105);
376 				stream_ID.Add(ID4);
377 
378 				dbg.Location( 54, 11 );
379 				char_literal5=(IToken)Match(input,17,Follow._17_in_stat107);
380 				stream_17.Add(char_literal5);
381 
382 				dbg.Location( 54, 15 );
383 				PushFollow(Follow._expr_in_stat109);
384 				expr6=expr();
385 
386 				state._fsp--;
387 
388 				stream_expr.Add(expr6.Tree);
389 				dbg.Location( 54, 20 );
390 				NEWLINE7=(IToken)Match(input,NEWLINE,Follow._NEWLINE_in_stat111);
391 				stream_NEWLINE.Add(NEWLINE7);
392 
393 
394 
395 				{
396 				// AST REWRITE
397 				// elements: 17, ID, expr
398 				// token labels:
399 				// rule labels: retval
400 				// token list labels:
401 				// rule list labels:
402 				// wildcard labels:
403 				retval.tree = root_0;
404 				RewriteRuleSubtreeStream stream_retval=new RewriteRuleSubtreeStream(adaptor,"rule retval",retval!=null?retval.tree:null);
405 
406 				root_0 = (CommonTree)adaptor.Nil();
407 				// 54:41: -> ^( '=' ID expr )
408 				{
409 					dbg.Location( 54, 43 );
410 					// BuildOptions\\DebugGrammar.g3:54:44: ^( '=' ID expr )
411 					{
412 					CommonTree root_1 = (CommonTree)adaptor.Nil();
413 					dbg.Location( 54, 45 );
414 					root_1 = (CommonTree)adaptor.BecomeRoot(stream_17.NextNode(), root_1);
415 
416 					dbg.Location( 54, 49 );
417 					adaptor.AddChild(root_1, stream_ID.NextNode());
418 					dbg.Location( 54, 52 );
419 					adaptor.AddChild(root_1, stream_expr.NextTree());
420 
421 					adaptor.AddChild(root_0, root_1);
422 					}
423 
424 				}
425 
426 				retval.tree = root_0;
427 				}
428 
429 				}
430 				break;
431 			case 3:
432 				dbg.EnterAlt( 3 );
433 
434 				// BuildOptions\\DebugGrammar.g3:55:9: func NEWLINE
435 				{
436 				dbg.Location( 55, 8 );
437 				PushFollow(Follow._func_in_stat143);
438 				func8=func();
439 
440 				state._fsp--;
441 
442 				stream_func.Add(func8.Tree);
443 				dbg.Location( 55, 13 );
444 				NEWLINE9=(IToken)Match(input,NEWLINE,Follow._NEWLINE_in_stat145);
445 				stream_NEWLINE.Add(NEWLINE9);
446 
447 
448 
449 				{
450 				// AST REWRITE
451 				// elements: func
452 				// token labels:
453 				// rule labels: retval
454 				// token list labels:
455 				// rule list labels:
456 				// wildcard labels:
457 				retval.tree = root_0;
458 				RewriteRuleSubtreeStream stream_retval=new RewriteRuleSubtreeStream(adaptor,"rule retval",retval!=null?retval.tree:null);
459 
460 				root_0 = (CommonTree)adaptor.Nil();
461 				// 55:41: -> func
462 				{
463 					dbg.Location( 55, 43 );
464 					adaptor.AddChild(root_0, stream_func.NextTree());
465 
466 				}
467 
468 				retval.tree = root_0;
469 				}
470 
471 				}
472 				break;
473 			case 4:
474 				dbg.EnterAlt( 4 );
475 
476 				// BuildOptions\\DebugGrammar.g3:56:9: NEWLINE
477 				{
478 				dbg.Location( 56, 8 );
479 				NEWLINE10=(IToken)Match(input,NEWLINE,Follow._NEWLINE_in_stat178);
480 				stream_NEWLINE.Add(NEWLINE10);
481 
482 
483 
484 				{
485 				// AST REWRITE
486 				// elements:
487 				// token labels:
488 				// rule labels: retval
489 				// token list labels:
490 				// rule list labels:
491 				// wildcard labels:
492 				retval.tree = root_0;
493 				RewriteRuleSubtreeStream stream_retval=new RewriteRuleSubtreeStream(adaptor,"rule retval",retval!=null?retval.tree:null);
494 
495 				root_0 = (CommonTree)adaptor.Nil();
496 				// 56:41: ->
497 				{
498 					dbg.Location( 57, 4 );
499 					root_0 = null;
500 				}
501 
502 				retval.tree = root_0;
503 				}
504 
505 				}
506 				break;
507 
508 			}
509 			retval.stop = input.LT(-1);
510 
511 			retval.tree = (CommonTree)adaptor.RulePostProcessing(root_0);
512 			adaptor.SetTokenBoundaries(retval.tree, retval.start, retval.stop);
513 
514 		}
515 		catch ( RecognitionException re )
516 		{
517 			ReportError(re);
518 			Recover(input,re);
519 		retval.tree = (CommonTree)adaptor.ErrorNode(input, retval.start, input.LT(-1), re);
520 
521 		}
522 		finally
523 		{
524 		}
525 		dbg.Location(57, 4);
526 
527 		}
528 		finally
529 		{
530 			dbg.ExitRule( GrammarFileName, "stat" );
531 			DecRuleLevel();
532 			if ( RuleLevel == 0 )
533 			{
534 				dbg.Terminate();
535 			}
536 		}
537 
538 		return retval;
539 	}
540 	// $ANTLR end "stat"
541 
542 	public class func_return : ParserRuleReturnScope
543 	{
544 		internal CommonTree tree;
545 		public override object Tree { get { return tree; } }
546 	}
547 
548 	// $ANTLR start "func"
549 	// BuildOptions\\DebugGrammar.g3:59:0: func : ID '(' formalPar ')' '=' expr -> ^( FUNC ID formalPar expr ) ;
func( )550 	private DebugGrammarParser.func_return func(  )
551 	{
552 		DebugGrammarParser.func_return retval = new DebugGrammarParser.func_return();
553 		retval.start = input.LT(1);
554 
555 		CommonTree root_0 = null;
556 
557 		IToken ID11=null;
558 		IToken char_literal12=null;
559 		IToken char_literal14=null;
560 		IToken char_literal15=null;
561 		DebugGrammarParser.formalPar_return formalPar13 = default(DebugGrammarParser.formalPar_return);
562 		DebugGrammarParser.expr_return expr16 = default(DebugGrammarParser.expr_return);
563 
564 		CommonTree ID11_tree=null;
565 		CommonTree char_literal12_tree=null;
566 		CommonTree char_literal14_tree=null;
567 		CommonTree char_literal15_tree=null;
568 		RewriteRuleITokenStream stream_ID=new RewriteRuleITokenStream(adaptor,"token ID");
569 		RewriteRuleITokenStream stream_12=new RewriteRuleITokenStream(adaptor,"token 12");
570 		RewriteRuleITokenStream stream_13=new RewriteRuleITokenStream(adaptor,"token 13");
571 		RewriteRuleITokenStream stream_17=new RewriteRuleITokenStream(adaptor,"token 17");
572 		RewriteRuleSubtreeStream stream_formalPar=new RewriteRuleSubtreeStream(adaptor,"rule formalPar");
573 		RewriteRuleSubtreeStream stream_expr=new RewriteRuleSubtreeStream(adaptor,"rule expr");
574 		try
575 		{
576 			dbg.EnterRule( GrammarFileName, "func" );
577 			if ( RuleLevel == 0 )
578 			{
579 				dbg.Commence();
580 			}
581 			IncRuleLevel();
582 			dbg.Location( 59, -1 );
583 
584 		try
585 		{
586 			// BuildOptions\\DebugGrammar.g3:59:9: ( ID '(' formalPar ')' '=' expr -> ^( FUNC ID formalPar expr ) )
587 			dbg.EnterAlt( 1 );
588 
589 			// BuildOptions\\DebugGrammar.g3:59:9: ID '(' formalPar ')' '=' expr
590 			{
591 			dbg.Location( 59, 8 );
592 			ID11=(IToken)Match(input,ID,Follow._ID_in_func219);
593 			stream_ID.Add(ID11);
594 
595 			dbg.Location( 59, 12 );
596 			char_literal12=(IToken)Match(input,12,Follow._12_in_func222);
597 			stream_12.Add(char_literal12);
598 
599 			dbg.Location( 59, 16 );
600 			PushFollow(Follow._formalPar_in_func224);
601 			formalPar13=formalPar();
602 
603 			state._fsp--;
604 
605 			stream_formalPar.Add(formalPar13.Tree);
606 			dbg.Location( 59, 26 );
607 			char_literal14=(IToken)Match(input,13,Follow._13_in_func226);
608 			stream_13.Add(char_literal14);
609 
610 			dbg.Location( 59, 30 );
611 			char_literal15=(IToken)Match(input,17,Follow._17_in_func228);
612 			stream_17.Add(char_literal15);
613 
614 			dbg.Location( 59, 34 );
615 			PushFollow(Follow._expr_in_func230);
616 			expr16=expr();
617 
618 			state._fsp--;
619 
620 			stream_expr.Add(expr16.Tree);
621 
622 
623 			{
624 			// AST REWRITE
625 			// elements: ID, formalPar, expr
626 			// token labels:
627 			// rule labels: retval
628 			// token list labels:
629 			// rule list labels:
630 			// wildcard labels:
631 			retval.tree = root_0;
632 			RewriteRuleSubtreeStream stream_retval=new RewriteRuleSubtreeStream(adaptor,"rule retval",retval!=null?retval.tree:null);
633 
634 			root_0 = (CommonTree)adaptor.Nil();
635 			// 59:41: -> ^( FUNC ID formalPar expr )
636 			{
637 				dbg.Location( 59, 43 );
638 				// BuildOptions\\DebugGrammar.g3:59:44: ^( FUNC ID formalPar expr )
639 				{
640 				CommonTree root_1 = (CommonTree)adaptor.Nil();
641 				dbg.Location( 59, 45 );
642 				root_1 = (CommonTree)adaptor.BecomeRoot((CommonTree)adaptor.Create(FUNC, "FUNC"), root_1);
643 
644 				dbg.Location( 59, 50 );
645 				adaptor.AddChild(root_1, stream_ID.NextNode());
646 				dbg.Location( 59, 53 );
647 				adaptor.AddChild(root_1, stream_formalPar.NextTree());
648 				dbg.Location( 59, 63 );
649 				adaptor.AddChild(root_1, stream_expr.NextTree());
650 
651 				adaptor.AddChild(root_0, root_1);
652 				}
653 
654 			}
655 
656 			retval.tree = root_0;
657 			}
658 
659 			}
660 
661 			retval.stop = input.LT(-1);
662 
663 			retval.tree = (CommonTree)adaptor.RulePostProcessing(root_0);
664 			adaptor.SetTokenBoundaries(retval.tree, retval.start, retval.stop);
665 
666 		}
667 		catch ( RecognitionException re )
668 		{
669 			ReportError(re);
670 			Recover(input,re);
671 		retval.tree = (CommonTree)adaptor.ErrorNode(input, retval.start, input.LT(-1), re);
672 
673 		}
674 		finally
675 		{
676 
677 				  functionDefinitions.Add(((CommonTree)retval.Tree));
678 
679 		}
680 		dbg.Location(60, 4);
681 
682 		}
683 		finally
684 		{
685 			dbg.ExitRule( GrammarFileName, "func" );
686 			DecRuleLevel();
687 			if ( RuleLevel == 0 )
688 			{
689 				dbg.Terminate();
690 			}
691 		}
692 
693 		return retval;
694 	}
695 	// $ANTLR end "func"
696 
697 	public class formalPar_return : ParserRuleReturnScope
698 	{
699 		internal CommonTree tree;
700 		public override object Tree { get { return tree; } }
701 	}
702 
703 	// $ANTLR start "formalPar"
704 	// BuildOptions\\DebugGrammar.g3:65:0: formalPar : ( ID | INT );
formalPar( )705 	private DebugGrammarParser.formalPar_return formalPar(  )
706 	{
707 		DebugGrammarParser.formalPar_return retval = new DebugGrammarParser.formalPar_return();
708 		retval.start = input.LT(1);
709 
710 		CommonTree root_0 = null;
711 
712 		IToken set17=null;
713 
714 		CommonTree set17_tree=null;
715 
716 		try
717 		{
718 			dbg.EnterRule( GrammarFileName, "formalPar" );
719 			if ( RuleLevel == 0 )
720 			{
721 				dbg.Commence();
722 			}
723 			IncRuleLevel();
724 			dbg.Location( 65, -1 );
725 
726 		try
727 		{
728 			// BuildOptions\\DebugGrammar.g3:66:9: ( ID | INT )
729 			dbg.EnterAlt( 1 );
730 
731 			// BuildOptions\\DebugGrammar.g3:
732 			{
733 			root_0 = (CommonTree)adaptor.Nil();
734 
735 			dbg.Location( 66, 8 );
736 			set17=(IToken)input.LT(1);
737 			if ( (input.LA(1)>=ID && input.LA(1)<=INT) )
738 			{
739 				input.Consume();
740 				adaptor.AddChild(root_0, (CommonTree)adaptor.Create(set17));
741 				state.errorRecovery=false;
742 			}
743 			else
744 			{
745 				MismatchedSetException mse = new MismatchedSetException(null,input);
746 				dbg.RecognitionException( mse );
747 				throw mse;
748 			}
749 
750 
751 			}
752 
753 			retval.stop = input.LT(-1);
754 
755 			retval.tree = (CommonTree)adaptor.RulePostProcessing(root_0);
756 			adaptor.SetTokenBoundaries(retval.tree, retval.start, retval.stop);
757 
758 		}
759 		catch ( RecognitionException re )
760 		{
761 			ReportError(re);
762 			Recover(input,re);
763 		retval.tree = (CommonTree)adaptor.ErrorNode(input, retval.start, input.LT(-1), re);
764 
765 		}
766 		finally
767 		{
768 		}
769 		dbg.Location(68, 1);
770 
771 		}
772 		finally
773 		{
774 			dbg.ExitRule( GrammarFileName, "formalPar" );
775 			DecRuleLevel();
776 			if ( RuleLevel == 0 )
777 			{
778 				dbg.Terminate();
779 			}
780 		}
781 
782 		return retval;
783 	}
784 	// $ANTLR end "formalPar"
785 
786 	public class expr_return : ParserRuleReturnScope
787 	{
788 		internal CommonTree tree;
789 		public override object Tree { get { return tree; } }
790 	}
791 
792 	// $ANTLR start "expr"
793 	// BuildOptions\\DebugGrammar.g3:73:0: expr : multExpr ( ( '+' | '-' ) multExpr )* ;
expr( )794 	private DebugGrammarParser.expr_return expr(  )
795 	{
796 		DebugGrammarParser.expr_return retval = new DebugGrammarParser.expr_return();
797 		retval.start = input.LT(1);
798 
799 		CommonTree root_0 = null;
800 
801 		IToken char_literal19=null;
802 		IToken char_literal20=null;
803 		DebugGrammarParser.multExpr_return multExpr18 = default(DebugGrammarParser.multExpr_return);
804 		DebugGrammarParser.multExpr_return multExpr21 = default(DebugGrammarParser.multExpr_return);
805 
806 		CommonTree char_literal19_tree=null;
807 		CommonTree char_literal20_tree=null;
808 
809 		try
810 		{
811 			dbg.EnterRule( GrammarFileName, "expr" );
812 			if ( RuleLevel == 0 )
813 			{
814 				dbg.Commence();
815 			}
816 			IncRuleLevel();
817 			dbg.Location( 73, -1 );
818 
819 		try
820 		{
821 			// BuildOptions\\DebugGrammar.g3:73:9: ( multExpr ( ( '+' | '-' ) multExpr )* )
822 			dbg.EnterAlt( 1 );
823 
824 			// BuildOptions\\DebugGrammar.g3:73:9: multExpr ( ( '+' | '-' ) multExpr )*
825 			{
826 			root_0 = (CommonTree)adaptor.Nil();
827 
828 			dbg.Location( 73, 8 );
829 			PushFollow(Follow._multExpr_in_expr288);
830 			multExpr18=multExpr();
831 
832 			state._fsp--;
833 
834 			adaptor.AddChild(root_0, multExpr18.Tree);
835 			dbg.Location( 73, 17 );
836 			// BuildOptions\\DebugGrammar.g3:73:18: ( ( '+' | '-' ) multExpr )*
837 			try
838 			{
839 				dbg.EnterSubRule( 4 );
840 
841 			for ( ; ; )
842 			{
843 				int alt4=2;
844 				try
845 				{
846 					dbg.EnterDecision( 4 );
847 
848 				int LA4_0 = input.LA(1);
849 
850 				if ( (LA4_0==10||LA4_0==16) )
851 				{
852 					alt4=1;
853 				}
854 
855 
856 				}
857 				finally
858 				{
859 					dbg.ExitDecision( 4 );
860 				}
861 
862 				switch ( alt4 )
863 				{
864 				case 1:
865 					dbg.EnterAlt( 1 );
866 
867 					// BuildOptions\\DebugGrammar.g3:73:19: ( '+' | '-' ) multExpr
868 					{
869 					dbg.Location( 73, 18 );
870 					// BuildOptions\\DebugGrammar.g3:73:19: ( '+' | '-' )
871 					int alt3=2;
872 					try
873 					{
874 						dbg.EnterSubRule( 3 );
875 					try
876 					{
877 						dbg.EnterDecision( 3 );
878 
879 					int LA3_0 = input.LA(1);
880 
881 					if ( (LA3_0==16) )
882 					{
883 						alt3=1;
884 					}
885 					else if ( (LA3_0==10) )
886 					{
887 						alt3=2;
888 					}
889 					else
890 					{
891 						NoViableAltException nvae = new NoViableAltException("", 3, 0, input);
892 
893 						dbg.RecognitionException( nvae );
894 						throw nvae;
895 					}
896 					}
897 					finally
898 					{
899 						dbg.ExitDecision( 3 );
900 					}
901 
902 					switch ( alt3 )
903 					{
904 					case 1:
905 						dbg.EnterAlt( 1 );
906 
907 						// BuildOptions\\DebugGrammar.g3:73:20: '+'
908 						{
909 						dbg.Location( 73, 22 );
910 						char_literal19=(IToken)Match(input,16,Follow._16_in_expr292);
911 						char_literal19_tree = (CommonTree)adaptor.Create(char_literal19);
912 						root_0 = (CommonTree)adaptor.BecomeRoot(char_literal19_tree, root_0);
913 
914 
915 						}
916 						break;
917 					case 2:
918 						dbg.EnterAlt( 2 );
919 
920 						// BuildOptions\\DebugGrammar.g3:73:25: '-'
921 						{
922 						dbg.Location( 73, 27 );
923 						char_literal20=(IToken)Match(input,10,Follow._10_in_expr295);
924 						char_literal20_tree = (CommonTree)adaptor.Create(char_literal20);
925 						root_0 = (CommonTree)adaptor.BecomeRoot(char_literal20_tree, root_0);
926 
927 
928 						}
929 						break;
930 
931 					}
932 					}
933 					finally
934 					{
935 						dbg.ExitSubRule( 3 );
936 					}
937 
938 					dbg.Location( 73, 30 );
939 					PushFollow(Follow._multExpr_in_expr299);
940 					multExpr21=multExpr();
941 
942 					state._fsp--;
943 
944 					adaptor.AddChild(root_0, multExpr21.Tree);
945 
946 					}
947 					break;
948 
949 				default:
950 					goto loop4;
951 				}
952 			}
953 
954 			loop4:
955 				;
956 
957 			}
958 			finally
959 			{
960 				dbg.ExitSubRule( 4 );
961 			}
962 
963 
964 			}
965 
966 			retval.stop = input.LT(-1);
967 
968 			retval.tree = (CommonTree)adaptor.RulePostProcessing(root_0);
969 			adaptor.SetTokenBoundaries(retval.tree, retval.start, retval.stop);
970 
971 		}
972 		catch ( RecognitionException re )
973 		{
974 			ReportError(re);
975 			Recover(input,re);
976 		retval.tree = (CommonTree)adaptor.ErrorNode(input, retval.start, input.LT(-1), re);
977 
978 		}
979 		finally
980 		{
981 		}
982 		dbg.Location(74, 4);
983 
984 		}
985 		finally
986 		{
987 			dbg.ExitRule( GrammarFileName, "expr" );
988 			DecRuleLevel();
989 			if ( RuleLevel == 0 )
990 			{
991 				dbg.Terminate();
992 			}
993 		}
994 
995 		return retval;
996 	}
997 	// $ANTLR end "expr"
998 
999 	public class multExpr_return : ParserRuleReturnScope
1000 	{
1001 		internal CommonTree tree;
1002 		public override object Tree { get { return tree; } }
1003 	}
1004 
1005 	// $ANTLR start "multExpr"
1006 	// BuildOptions\\DebugGrammar.g3:76:0: multExpr : atom ( ( '*' | '/' | '%' ) atom )* ;
multExpr( )1007 	private DebugGrammarParser.multExpr_return multExpr(  )
1008 	{
1009 		DebugGrammarParser.multExpr_return retval = new DebugGrammarParser.multExpr_return();
1010 		retval.start = input.LT(1);
1011 
1012 		CommonTree root_0 = null;
1013 
1014 		IToken set23=null;
1015 		DebugGrammarParser.atom_return atom22 = default(DebugGrammarParser.atom_return);
1016 		DebugGrammarParser.atom_return atom24 = default(DebugGrammarParser.atom_return);
1017 
1018 		CommonTree set23_tree=null;
1019 
1020 		try
1021 		{
1022 			dbg.EnterRule( GrammarFileName, "multExpr" );
1023 			if ( RuleLevel == 0 )
1024 			{
1025 				dbg.Commence();
1026 			}
1027 			IncRuleLevel();
1028 			dbg.Location( 76, -1 );
1029 
1030 		try
1031 		{
1032 			// BuildOptions\\DebugGrammar.g3:77:9: ( atom ( ( '*' | '/' | '%' ) atom )* )
1033 			dbg.EnterAlt( 1 );
1034 
1035 			// BuildOptions\\DebugGrammar.g3:77:9: atom ( ( '*' | '/' | '%' ) atom )*
1036 			{
1037 			root_0 = (CommonTree)adaptor.Nil();
1038 
1039 			dbg.Location( 77, 8 );
1040 			PushFollow(Follow._atom_in_multExpr320);
1041 			atom22=atom();
1042 
1043 			state._fsp--;
1044 
1045 			adaptor.AddChild(root_0, atom22.Tree);
1046 			dbg.Location( 77, 13 );
1047 			// BuildOptions\\DebugGrammar.g3:77:14: ( ( '*' | '/' | '%' ) atom )*
1048 			try
1049 			{
1050 				dbg.EnterSubRule( 5 );
1051 
1052 			for ( ; ; )
1053 			{
1054 				int alt5=2;
1055 				try
1056 				{
1057 					dbg.EnterDecision( 5 );
1058 
1059 				int LA5_0 = input.LA(1);
1060 
1061 				if ( (LA5_0==11||(LA5_0>=14 && LA5_0<=15)) )
1062 				{
1063 					alt5=1;
1064 				}
1065 
1066 
1067 				}
1068 				finally
1069 				{
1070 					dbg.ExitDecision( 5 );
1071 				}
1072 
1073 				switch ( alt5 )
1074 				{
1075 				case 1:
1076 					dbg.EnterAlt( 1 );
1077 
1078 					// BuildOptions\\DebugGrammar.g3:77:15: ( '*' | '/' | '%' ) atom
1079 					{
1080 					dbg.Location( 77, 27 );
1081 					set23=(IToken)input.LT(1);
1082 					set23=(IToken)input.LT(1);
1083 					if ( input.LA(1)==11||(input.LA(1)>=14 && input.LA(1)<=15) )
1084 					{
1085 						input.Consume();
1086 						root_0 = (CommonTree)adaptor.BecomeRoot((CommonTree)adaptor.Create(set23), root_0);
1087 						state.errorRecovery=false;
1088 					}
1089 					else
1090 					{
1091 						MismatchedSetException mse = new MismatchedSetException(null,input);
1092 						dbg.RecognitionException( mse );
1093 						throw mse;
1094 					}
1095 
1096 					dbg.Location( 77, 29 );
1097 					PushFollow(Follow._atom_in_multExpr332);
1098 					atom24=atom();
1099 
1100 					state._fsp--;
1101 
1102 					adaptor.AddChild(root_0, atom24.Tree);
1103 
1104 					}
1105 					break;
1106 
1107 				default:
1108 					goto loop5;
1109 				}
1110 			}
1111 
1112 			loop5:
1113 				;
1114 
1115 			}
1116 			finally
1117 			{
1118 				dbg.ExitSubRule( 5 );
1119 			}
1120 
1121 
1122 			}
1123 
1124 			retval.stop = input.LT(-1);
1125 
1126 			retval.tree = (CommonTree)adaptor.RulePostProcessing(root_0);
1127 			adaptor.SetTokenBoundaries(retval.tree, retval.start, retval.stop);
1128 
1129 		}
1130 		catch ( RecognitionException re )
1131 		{
1132 			ReportError(re);
1133 			Recover(input,re);
1134 		retval.tree = (CommonTree)adaptor.ErrorNode(input, retval.start, input.LT(-1), re);
1135 
1136 		}
1137 		finally
1138 		{
1139 		}
1140 		dbg.Location(78, 4);
1141 
1142 		}
1143 		finally
1144 		{
1145 			dbg.ExitRule( GrammarFileName, "multExpr" );
1146 			DecRuleLevel();
1147 			if ( RuleLevel == 0 )
1148 			{
1149 				dbg.Terminate();
1150 			}
1151 		}
1152 
1153 		return retval;
1154 	}
1155 	// $ANTLR end "multExpr"
1156 
1157 	public class atom_return : ParserRuleReturnScope
1158 	{
1159 		internal CommonTree tree;
1160 		public override object Tree { get { return tree; } }
1161 	}
1162 
1163 	// $ANTLR start "atom"
1164 	// BuildOptions\\DebugGrammar.g3:80:0: atom : ( INT | ID | '(' expr ')' -> expr | ID '(' expr ')' -> ^( CALL ID expr ) );
atom( )1165 	private DebugGrammarParser.atom_return atom(  )
1166 	{
1167 		DebugGrammarParser.atom_return retval = new DebugGrammarParser.atom_return();
1168 		retval.start = input.LT(1);
1169 
1170 		CommonTree root_0 = null;
1171 
1172 		IToken INT25=null;
1173 		IToken ID26=null;
1174 		IToken char_literal27=null;
1175 		IToken char_literal29=null;
1176 		IToken ID30=null;
1177 		IToken char_literal31=null;
1178 		IToken char_literal33=null;
1179 		DebugGrammarParser.expr_return expr28 = default(DebugGrammarParser.expr_return);
1180 		DebugGrammarParser.expr_return expr32 = default(DebugGrammarParser.expr_return);
1181 
1182 		CommonTree INT25_tree=null;
1183 		CommonTree ID26_tree=null;
1184 		CommonTree char_literal27_tree=null;
1185 		CommonTree char_literal29_tree=null;
1186 		CommonTree ID30_tree=null;
1187 		CommonTree char_literal31_tree=null;
1188 		CommonTree char_literal33_tree=null;
1189 		RewriteRuleITokenStream stream_12=new RewriteRuleITokenStream(adaptor,"token 12");
1190 		RewriteRuleITokenStream stream_13=new RewriteRuleITokenStream(adaptor,"token 13");
1191 		RewriteRuleITokenStream stream_ID=new RewriteRuleITokenStream(adaptor,"token ID");
1192 		RewriteRuleSubtreeStream stream_expr=new RewriteRuleSubtreeStream(adaptor,"rule expr");
1193 		try
1194 		{
1195 			dbg.EnterRule( GrammarFileName, "atom" );
1196 			if ( RuleLevel == 0 )
1197 			{
1198 				dbg.Commence();
1199 			}
1200 			IncRuleLevel();
1201 			dbg.Location( 80, -1 );
1202 
1203 		try
1204 		{
1205 			// BuildOptions\\DebugGrammar.g3:80:9: ( INT | ID | '(' expr ')' -> expr | ID '(' expr ')' -> ^( CALL ID expr ) )
1206 			int alt6=4;
1207 			try
1208 			{
1209 				dbg.EnterDecision( 6 );
1210 
1211 			switch ( input.LA(1) )
1212 			{
1213 			case INT:
1214 				{
1215 				alt6=1;
1216 				}
1217 				break;
1218 			case ID:
1219 				{
1220 				int LA6_2 = input.LA(2);
1221 
1222 				if ( (LA6_2==12) )
1223 				{
1224 					alt6=4;
1225 				}
1226 				else if ( (LA6_2==NEWLINE||(LA6_2>=10 && LA6_2<=11)||(LA6_2>=13 && LA6_2<=16)) )
1227 				{
1228 					alt6=2;
1229 				}
1230 				else
1231 				{
1232 					NoViableAltException nvae = new NoViableAltException("", 6, 2, input);
1233 
1234 					dbg.RecognitionException( nvae );
1235 					throw nvae;
1236 				}
1237 				}
1238 				break;
1239 			case 12:
1240 				{
1241 				alt6=3;
1242 				}
1243 				break;
1244 			default:
1245 				{
1246 					NoViableAltException nvae = new NoViableAltException("", 6, 0, input);
1247 
1248 					dbg.RecognitionException( nvae );
1249 					throw nvae;
1250 				}
1251 			}
1252 
1253 			}
1254 			finally
1255 			{
1256 				dbg.ExitDecision( 6 );
1257 			}
1258 
1259 			switch ( alt6 )
1260 			{
1261 			case 1:
1262 				dbg.EnterAlt( 1 );
1263 
1264 				// BuildOptions\\DebugGrammar.g3:80:9: INT
1265 				{
1266 				root_0 = (CommonTree)adaptor.Nil();
1267 
1268 				dbg.Location( 80, 8 );
1269 				INT25=(IToken)Match(input,INT,Follow._INT_in_atom348);
1270 				INT25_tree = (CommonTree)adaptor.Create(INT25);
1271 				adaptor.AddChild(root_0, INT25_tree);
1272 
1273 
1274 				}
1275 				break;
1276 			case 2:
1277 				dbg.EnterAlt( 2 );
1278 
1279 				// BuildOptions\\DebugGrammar.g3:81:9: ID
1280 				{
1281 				root_0 = (CommonTree)adaptor.Nil();
1282 
1283 				dbg.Location( 81, 8 );
1284 				ID26=(IToken)Match(input,ID,Follow._ID_in_atom358);
1285 				ID26_tree = (CommonTree)adaptor.Create(ID26);
1286 				adaptor.AddChild(root_0, ID26_tree);
1287 
1288 
1289 				}
1290 				break;
1291 			case 3:
1292 				dbg.EnterAlt( 3 );
1293 
1294 				// BuildOptions\\DebugGrammar.g3:82:9: '(' expr ')'
1295 				{
1296 				dbg.Location( 82, 8 );
1297 				char_literal27=(IToken)Match(input,12,Follow._12_in_atom368);
1298 				stream_12.Add(char_literal27);
1299 
1300 				dbg.Location( 82, 12 );
1301 				PushFollow(Follow._expr_in_atom370);
1302 				expr28=expr();
1303 
1304 				state._fsp--;
1305 
1306 				stream_expr.Add(expr28.Tree);
1307 				dbg.Location( 82, 17 );
1308 				char_literal29=(IToken)Match(input,13,Follow._13_in_atom372);
1309 				stream_13.Add(char_literal29);
1310 
1311 
1312 
1313 				{
1314 				// AST REWRITE
1315 				// elements: expr
1316 				// token labels:
1317 				// rule labels: retval
1318 				// token list labels:
1319 				// rule list labels:
1320 				// wildcard labels:
1321 				retval.tree = root_0;
1322 				RewriteRuleSubtreeStream stream_retval=new RewriteRuleSubtreeStream(adaptor,"rule retval",retval!=null?retval.tree:null);
1323 
1324 				root_0 = (CommonTree)adaptor.Nil();
1325 				// 82:25: -> expr
1326 				{
1327 					dbg.Location( 82, 27 );
1328 					adaptor.AddChild(root_0, stream_expr.NextTree());
1329 
1330 				}
1331 
1332 				retval.tree = root_0;
1333 				}
1334 
1335 				}
1336 				break;
1337 			case 4:
1338 				dbg.EnterAlt( 4 );
1339 
1340 				// BuildOptions\\DebugGrammar.g3:83:9: ID '(' expr ')'
1341 				{
1342 				dbg.Location( 83, 8 );
1343 				ID30=(IToken)Match(input,ID,Follow._ID_in_atom389);
1344 				stream_ID.Add(ID30);
1345 
1346 				dbg.Location( 83, 11 );
1347 				char_literal31=(IToken)Match(input,12,Follow._12_in_atom391);
1348 				stream_12.Add(char_literal31);
1349 
1350 				dbg.Location( 83, 15 );
1351 				PushFollow(Follow._expr_in_atom393);
1352 				expr32=expr();
1353 
1354 				state._fsp--;
1355 
1356 				stream_expr.Add(expr32.Tree);
1357 				dbg.Location( 83, 20 );
1358 				char_literal33=(IToken)Match(input,13,Follow._13_in_atom395);
1359 				stream_13.Add(char_literal33);
1360 
1361 
1362 
1363 				{
1364 				// AST REWRITE
1365 				// elements: ID, expr
1366 				// token labels:
1367 				// rule labels: retval
1368 				// token list labels:
1369 				// rule list labels:
1370 				// wildcard labels:
1371 				retval.tree = root_0;
1372 				RewriteRuleSubtreeStream stream_retval=new RewriteRuleSubtreeStream(adaptor,"rule retval",retval!=null?retval.tree:null);
1373 
1374 				root_0 = (CommonTree)adaptor.Nil();
1375 				// 83:25: -> ^( CALL ID expr )
1376 				{
1377 					dbg.Location( 83, 27 );
1378 					// BuildOptions\\DebugGrammar.g3:83:28: ^( CALL ID expr )
1379 					{
1380 					CommonTree root_1 = (CommonTree)adaptor.Nil();
1381 					dbg.Location( 83, 29 );
1382 					root_1 = (CommonTree)adaptor.BecomeRoot((CommonTree)adaptor.Create(CALL, "CALL"), root_1);
1383 
1384 					dbg.Location( 83, 34 );
1385 					adaptor.AddChild(root_1, stream_ID.NextNode());
1386 					dbg.Location( 83, 37 );
1387 					adaptor.AddChild(root_1, stream_expr.NextTree());
1388 
1389 					adaptor.AddChild(root_0, root_1);
1390 					}
1391 
1392 				}
1393 
1394 				retval.tree = root_0;
1395 				}
1396 
1397 				}
1398 				break;
1399 
1400 			}
1401 			retval.stop = input.LT(-1);
1402 
1403 			retval.tree = (CommonTree)adaptor.RulePostProcessing(root_0);
1404 			adaptor.SetTokenBoundaries(retval.tree, retval.start, retval.stop);
1405 
1406 		}
1407 		catch ( RecognitionException re )
1408 		{
1409 			ReportError(re);
1410 			Recover(input,re);
1411 		retval.tree = (CommonTree)adaptor.ErrorNode(input, retval.start, input.LT(-1), re);
1412 
1413 		}
1414 		finally
1415 		{
1416 		}
1417 		dbg.Location(84, 4);
1418 
1419 		}
1420 		finally
1421 		{
1422 			dbg.ExitRule( GrammarFileName, "atom" );
1423 			DecRuleLevel();
1424 			if ( RuleLevel == 0 )
1425 			{
1426 				dbg.Terminate();
1427 			}
1428 		}
1429 
1430 		return retval;
1431 	}
1432 	// $ANTLR end "atom"
1433 	#endregion Rules
1434 
1435 
1436 	#region DFA
1437 	DFA2 dfa2;
1438 
InitDFAs()1439 	protected override void InitDFAs()
1440 	{
1441 		base.InitDFAs();
1442 		dfa2 = new DFA2( this );
1443 	}
1444 
1445 	class DFA2 : DFA
1446 	{
1447 
1448 		const string DFA2_eotS =
1449 			"\xA\xFFFF";
1450 		const string DFA2_eofS =
1451 			"\xA\xFFFF";
1452 		const string DFA2_minS =
1453 			"\x1\x6\x1\xFFFF\x1\x8\x1\xFFFF\x1\x6\x1\xFFFF\x2\xA\x1\x8\x1\xFFFF";
1454 		const string DFA2_maxS =
1455 			"\x1\xC\x1\xFFFF\x1\x11\x1\xFFFF\x1\xC\x1\xFFFF\x2\x10\x1\x11\x1\xFFFF";
1456 		const string DFA2_acceptS =
1457 			"\x1\xFFFF\x1\x1\x1\xFFFF\x1\x4\x1\xFFFF\x1\x2\x3\xFFFF\x1\x3";
1458 		const string DFA2_specialS =
1459 			"\xA\xFFFF}>";
1460 		static readonly string[] DFA2_transitionS =
1461 			{
1462 				"\x1\x2\x1\x1\x1\x3\x3\xFFFF\x1\x1",
1463 				"",
1464 				"\x1\x1\x1\xFFFF\x2\x1\x1\x4\x1\xFFFF\x3\x1\x1\x5",
1465 				"",
1466 				"\x1\x7\x1\x6\x4\xFFFF\x1\x1",
1467 				"",
1468 				"\x2\x1\x1\xFFFF\x1\x8\x3\x1",
1469 				"\x3\x1\x1\x8\x3\x1",
1470 				"\x1\x1\x1\xFFFF\x2\x1\x2\xFFFF\x3\x1\x1\x9",
1471 				""
1472 			};
1473 
1474 		static readonly short[] DFA2_eot = DFA.UnpackEncodedString(DFA2_eotS);
1475 		static readonly short[] DFA2_eof = DFA.UnpackEncodedString(DFA2_eofS);
1476 		static readonly char[] DFA2_min = DFA.UnpackEncodedStringToUnsignedChars(DFA2_minS);
1477 		static readonly char[] DFA2_max = DFA.UnpackEncodedStringToUnsignedChars(DFA2_maxS);
1478 		static readonly short[] DFA2_accept = DFA.UnpackEncodedString(DFA2_acceptS);
1479 		static readonly short[] DFA2_special = DFA.UnpackEncodedString(DFA2_specialS);
1480 		static readonly short[][] DFA2_transition;
1481 
DFA2()1482 		static DFA2()
1483 		{
1484 			int numStates = DFA2_transitionS.Length;
1485 			DFA2_transition = new short[numStates][];
1486 			for ( int i=0; i < numStates; i++ )
1487 			{
1488 				DFA2_transition[i] = DFA.UnpackEncodedString(DFA2_transitionS[i]);
1489 			}
1490 		}
1491 
DFA2( BaseRecognizer recognizer )1492 		public DFA2( BaseRecognizer recognizer )
1493 		{
1494 			this.recognizer = recognizer;
1495 			this.decisionNumber = 2;
1496 			this.eot = DFA2_eot;
1497 			this.eof = DFA2_eof;
1498 			this.min = DFA2_min;
1499 			this.max = DFA2_max;
1500 			this.accept = DFA2_accept;
1501 			this.special = DFA2_special;
1502 			this.transition = DFA2_transition;
1503 		}
GetDescription()1504 		public override string GetDescription()
1505 		{
1506 			return "53:0: stat : ( expr NEWLINE -> expr | ID '=' expr NEWLINE -> ^( '=' ID expr ) | func NEWLINE -> func | NEWLINE ->);";
1507 		}
Error( NoViableAltException nvae )1508 		public override void Error( NoViableAltException nvae )
1509 		{
1510 			((DebugParser)recognizer).dbg.RecognitionException( nvae );
1511 		}
1512 	}
1513 
1514 
1515 	#endregion DFA
1516 
1517 	#region Follow sets
1518 	private static class Follow
1519 	{
1520 		public static readonly BitSet _stat_in_prog53 = new BitSet(new ulong[]{0x11C2UL});
1521 		public static readonly BitSet _expr_in_stat70 = new BitSet(new ulong[]{0x100UL});
1522 		public static readonly BitSet _NEWLINE_in_stat72 = new BitSet(new ulong[]{0x2UL});
1523 		public static readonly BitSet _ID_in_stat105 = new BitSet(new ulong[]{0x20000UL});
1524 		public static readonly BitSet _17_in_stat107 = new BitSet(new ulong[]{0x10C0UL});
1525 		public static readonly BitSet _expr_in_stat109 = new BitSet(new ulong[]{0x100UL});
1526 		public static readonly BitSet _NEWLINE_in_stat111 = new BitSet(new ulong[]{0x2UL});
1527 		public static readonly BitSet _func_in_stat143 = new BitSet(new ulong[]{0x100UL});
1528 		public static readonly BitSet _NEWLINE_in_stat145 = new BitSet(new ulong[]{0x2UL});
1529 		public static readonly BitSet _NEWLINE_in_stat178 = new BitSet(new ulong[]{0x2UL});
1530 		public static readonly BitSet _ID_in_func219 = new BitSet(new ulong[]{0x1000UL});
1531 		public static readonly BitSet _12_in_func222 = new BitSet(new ulong[]{0xC0UL});
1532 		public static readonly BitSet _formalPar_in_func224 = new BitSet(new ulong[]{0x2000UL});
1533 		public static readonly BitSet _13_in_func226 = new BitSet(new ulong[]{0x20000UL});
1534 		public static readonly BitSet _17_in_func228 = new BitSet(new ulong[]{0x10C0UL});
1535 		public static readonly BitSet _expr_in_func230 = new BitSet(new ulong[]{0x2UL});
1536 		public static readonly BitSet _set_in_formalPar267 = new BitSet(new ulong[]{0x2UL});
1537 		public static readonly BitSet _multExpr_in_expr288 = new BitSet(new ulong[]{0x10402UL});
1538 		public static readonly BitSet _16_in_expr292 = new BitSet(new ulong[]{0x10C0UL});
1539 		public static readonly BitSet _10_in_expr295 = new BitSet(new ulong[]{0x10C0UL});
1540 		public static readonly BitSet _multExpr_in_expr299 = new BitSet(new ulong[]{0x10402UL});
1541 		public static readonly BitSet _atom_in_multExpr320 = new BitSet(new ulong[]{0xC802UL});
1542 		public static readonly BitSet _set_in_multExpr323 = new BitSet(new ulong[]{0x10C0UL});
1543 		public static readonly BitSet _atom_in_multExpr332 = new BitSet(new ulong[]{0xC802UL});
1544 		public static readonly BitSet _INT_in_atom348 = new BitSet(new ulong[]{0x2UL});
1545 		public static readonly BitSet _ID_in_atom358 = new BitSet(new ulong[]{0x2UL});
1546 		public static readonly BitSet _12_in_atom368 = new BitSet(new ulong[]{0x10C0UL});
1547 		public static readonly BitSet _expr_in_atom370 = new BitSet(new ulong[]{0x2000UL});
1548 		public static readonly BitSet _13_in_atom372 = new BitSet(new ulong[]{0x2UL});
1549 		public static readonly BitSet _ID_in_atom389 = new BitSet(new ulong[]{0x1000UL});
1550 		public static readonly BitSet _12_in_atom391 = new BitSet(new ulong[]{0x10C0UL});
1551 		public static readonly BitSet _expr_in_atom393 = new BitSet(new ulong[]{0x2000UL});
1552 		public static readonly BitSet _13_in_atom395 = new BitSet(new ulong[]{0x2UL});
1553 
1554 	}
1555 	#endregion Follow sets
1556 }
1557