Ejemplo n.º 1
0
		public void ReplaceInList(variant_type el, IEnumerable<variant_type> newels)
		{
			var ind = FindIndexInList(el);
			vars.RemoveAt(ind);
			vars.InsertRange(ind, newels);
		}
Ejemplo n.º 2
0
		public bool Remove(variant_type el)
		{
			return vars.Remove(el);
		}
Ejemplo n.º 3
0
		public void ReplaceInList(variant_type el, variant_type newel)
		{
			vars[FindIndexInList(el)] = newel;
		}
Ejemplo n.º 4
0
		public void visit(variant_type _variant_type)
		{
			bw.Write((Int16)94);
			write_variant_type(_variant_type);
		}
///////////////////////////////////////////////////////////////////////////////
///////////////////////////////////////////////////////////////////////////////
//CreateNonTerminalObject
///////////////////////////////////////////////////////////////////////////////
///////////////////////////////////////////////////////////////////////////////

public Object CreateNonTerminalObject(int ReductionRuleIndex)
{
switch (ReductionRuleIndex)
{
	case (int)RuleConstants.RULE_PARSE_GOAL :
	//<parse_goal> ::= <program_file>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_PARSE_GOAL2 :
	//<parse_goal> ::= <unit_file>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_PARSE_GOAL3 :
	//<parse_goal> ::= <parts>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_PARTS_TKPARSEMODEEXPRESSION :
	//<parts> ::= tkParseModeExpression <expr>
return LRParser.GetReductionSyntaxNode(1);
	case (int)RuleConstants.RULE_PARTS_TKPARSEMODESTATEMENT :
	//<parts> ::= tkParseModeStatement <stmt_or_expression>
return LRParser.GetReductionSyntaxNode(1);
	case (int)RuleConstants.RULE_STMT_OR_EXPRESSION :
	//<stmt_or_expression> ::= <expr> <empty>
         
		{
			expression_as_statement _expression_as_statement=new expression_as_statement((expression)LRParser.GetReductionSyntaxNode(0));
			 parsertools.create_source_context(_expression_as_statement,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(0));
			return _expression_as_statement;
		}

	case (int)RuleConstants.RULE_STMT_OR_EXPRESSION2 :
	//<stmt_or_expression> ::= <assignment>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_STMT_OR_EXPRESSION3 :
	//<stmt_or_expression> ::= <var_stmt>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_OPT_HEAD_COMPILER_DIRECTIVES :
	//<opt_head_compiler_directives> ::= 
	//NONTERMINAL:<opt_head_compiler_directives> ::= 
	return null;
	//ENDNONTERMINAL
	case (int)RuleConstants.RULE_OPT_HEAD_COMPILER_DIRECTIVES2 :
	//<opt_head_compiler_directives> ::= <head_compiler_directives>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_HEAD_COMPILER_DIRECTIVES :
	//<head_compiler_directives> ::= <one_compiler_directive>
return null;
	case (int)RuleConstants.RULE_HEAD_COMPILER_DIRECTIVES2 :
	//<head_compiler_directives> ::= <head_compiler_directives> <one_compiler_directive>
return null;
	case (int)RuleConstants.RULE_ONE_COMPILER_DIRECTIVE_TKDIRECTIVENAME_TKIDENTIFIER :
	//<one_compiler_directive> ::= tkDirectiveName tkIdentifier
 {
									token_info t1 = new token_info();
									t1.text=((ident)LRParser.GetReductionSyntaxNode(0)).name;
					                                t1.source_context = ((ident)LRParser.GetReductionSyntaxNode(0)).source_context;
									token_info t2 = new token_info();
									t2.text=((ident)LRParser.GetReductionSyntaxNode(1)).name;
					                                t2.source_context = ((ident)LRParser.GetReductionSyntaxNode(1)).source_context;
									compiler_directive cd=new compiler_directive(t1,t2); 
									parsertools.create_source_context(cd,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(1)); 
									CompilerDirectives.Add(cd); return null;
								}
	case (int)RuleConstants.RULE_ONE_COMPILER_DIRECTIVE_TKDIRECTIVENAME_TKSTRINGLITERAL :
	//<one_compiler_directive> ::= tkDirectiveName tkStringLiteral
 {
									token_info t1 = new token_info();
									t1.text=((ident)LRParser.GetReductionSyntaxNode(0)).name;
					                                t1.source_context = ((ident)LRParser.GetReductionSyntaxNode(0)).source_context;
									token_info t2 = new token_info();
									t2.text=((string_const)LRParser.GetReductionSyntaxNode(1)).Value;
					                                t2.source_context = ((string_const)LRParser.GetReductionSyntaxNode(1)).source_context;
									compiler_directive cd=new compiler_directive(t1,t2); 
									parsertools.create_source_context(cd,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(1)); 
									CompilerDirectives.Add(cd); return null;
								}
	case (int)RuleConstants.RULE_PROGRAM_FILE :
	//<program_file> ::= <program_heading> <opt_head_compiler_directives> <main_uses_clause> <using_clause> <program_block> <opt_tk_point>
         
		{
			program_module _program_module=new program_module(LRParser.GetReductionSyntaxNode(0) as program_name,(uses_list)LRParser.GetReductionSyntaxNode(2),(block)LRParser.GetReductionSyntaxNode(4),LRParser.GetReductionSyntaxNode(3) as using_list);
			
									 _program_module.Language = LanguageId.PascalABCNET;
									 parsertools.create_source_context(_program_module,parsertools.sc_not_null(LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(2),LRParser.GetReductionSyntaxNode(3),LRParser.GetReductionSyntaxNode(4)),LRParser.GetReductionSyntaxNode(4));
									 if (LRParser.GetReductionSyntaxNode(5) == null && LRParser.GetReductionSyntaxNode(4) != null)
									 {
										file_position fp = (LRParser.GetReductionSyntaxNode(4) as syntax_tree_node).source_context.end_position;
										syntax_tree_node err_stn = (syntax_tree_node)LRParser.GetReductionSyntaxNode(4);
										if ((LRParser.GetReductionSyntaxNode(4) is block) && (LRParser.GetReductionSyntaxNode(4) as block).program_code != null && (LRParser.GetReductionSyntaxNode(4) as block).program_code.subnodes != null && (LRParser.GetReductionSyntaxNode(4) as block).program_code.subnodes.Count > 0)
										err_stn = (LRParser.GetReductionSyntaxNode(4) as block).program_code.subnodes[(LRParser.GetReductionSyntaxNode(4) as block).program_code.subnodes.Count-1];
										errors.Add(new Errors.PABCNETUnexpectedToken(current_file_name, StringResources.Get("TKPOINT"),new SourceContext(fp.line_num, fp.column_num+1, fp.line_num, fp.column_num+1, 0, 0),err_stn));
									 }
									 
			return _program_module;
		}

	case (int)RuleConstants.RULE_OPT_TK_POINT_TKPOINT :
	//<opt_tk_point> ::= tkPoint
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_OPT_TK_POINT_TKSEMICOLON :
	//<opt_tk_point> ::= tkSemiColon
return null;
	case (int)RuleConstants.RULE_OPT_TK_POINT_TKCOLON :
	//<opt_tk_point> ::= tkColon
return null;
	case (int)RuleConstants.RULE_OPT_TK_POINT_ZKCOMMA :
	//<opt_tk_point> ::= zkComma
return null;
	case (int)RuleConstants.RULE_OPT_TK_POINT_TKDOTDOT :
	//<opt_tk_point> ::= tkDotDot
return null;
	case (int)RuleConstants.RULE_OPT_TK_POINT :
	//<opt_tk_point> ::= 
	//NONTERMINAL:<opt_tk_point> ::= 
	return null;
	//ENDNONTERMINAL
	case (int)RuleConstants.RULE_PROGRAM_HEADING :
	//<program_heading> ::= 
	//NONTERMINAL:<program_heading> ::= 
	return null;
	//ENDNONTERMINAL
	case (int)RuleConstants.RULE_PROGRAM_HEADING_TKPROGRAM :
	//<program_heading> ::= tkProgram <program_name> <program_heading_2>
         
		{
			program_name _program_name=new program_name((ident)LRParser.GetReductionSyntaxNode(1));
			 parsertools.create_source_context(_program_name,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(1));
			return _program_name;
		}

	case (int)RuleConstants.RULE_PROGRAM_HEADING_2_TKSEMICOLON :
	//<program_heading_2> ::= tkSemiColon
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_PROGRAM_HEADING_2_TKROUNDOPEN_TKROUNDCLOSE_TKSEMICOLON :
	//<program_heading_2> ::= tkRoundOpen <program_param_list> tkRoundClose tkSemiColon
return null;
	case (int)RuleConstants.RULE_PROGRAM_NAME :
	//<program_name> ::= <identifier>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_PROGRAM_PARAM_LIST :
	//<program_param_list> ::= <program_param> <empty>
return null;
	case (int)RuleConstants.RULE_PROGRAM_PARAM_LIST_TKCOMMA :
	//<program_param_list> ::= <program_param_list> tkComma <program_param>
return null;
	case (int)RuleConstants.RULE_PROGRAM_PARAM :
	//<program_param> ::= <identifier>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_PROGRAM_BLOCK :
	//<program_block> ::= <program_decl_sect_list> <compound_stmt>
         
		{
			block _block=new block(null,LRParser.GetReductionSyntaxNode(1) as statement_list);
			
							if (LRParser.GetReductionSyntaxNode(0)!=null) {
								_block.defs=LRParser.GetReductionSyntaxNode(0) as declarations;
								parsertools.create_source_context(_block,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(1));
							}else	
								parsertools.create_source_context(_block,LRParser.GetReductionSyntaxNode(1),LRParser.GetReductionSyntaxNode(1));
								//tasha 16.04.2010 
                            				add_lambda_to_program_block(_block);
							
			return _block;
		}

	case (int)RuleConstants.RULE_PROGRAM_DECL_SECT_LIST :
	//<program_decl_sect_list> ::= <impl_decl_sect_list>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_USES_CLAUSE :
	//<uses_clause> ::= <main_uses_clause>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_USING_CLAUSE :
	//<using_clause> ::= 
	//NONTERMINAL:<using_clause> ::= 
	return null;
	//ENDNONTERMINAL
	case (int)RuleConstants.RULE_USING_CLAUSE2 :
	//<using_clause> ::= <using_list>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_USING_LIST :
	//<using_list> ::= <using_one> <empty>
         
		{
			using_list _using_list=new using_list();
			
								parsertools.create_source_context(_using_list,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(0));
								_using_list.namespaces.Add((unit_or_namespace)LRParser.GetReductionSyntaxNode(0));
			return _using_list;
		}

	case (int)RuleConstants.RULE_USING_LIST2 :
	//<using_list> ::= <using_list> <using_one>
         
		{
			using_list _using_list=(using_list)LRParser.GetReductionSyntaxNode(0);
								parsertools.create_source_context(_using_list,_using_list,LRParser.GetReductionSyntaxNode(1));
								_using_list.namespaces.Add((unit_or_namespace)LRParser.GetReductionSyntaxNode(1));
			return _using_list;
		}

	case (int)RuleConstants.RULE_USING_ONE_TKUSING_TKSEMICOLON :
	//<using_one> ::= tkUsing <ident_or_keyword_pointseparator_list> tkSemiColon
         
		{
			unit_or_namespace _unit_or_namespace=new unit_or_namespace((ident_list)LRParser.GetReductionSyntaxNode(1));
			 parsertools.create_source_context(_unit_or_namespace,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(2));
			return _unit_or_namespace;
		}

	case (int)RuleConstants.RULE_IDENT_OR_KEYWORD_POINTSEPARATOR_LIST :
	//<ident_or_keyword_pointseparator_list> ::= <identifier_or_keyword> <empty>
         
		//TemplateList for ident_list (create)
		{
			ident_list _ident_list=new ident_list();
			_ident_list.source_context=((ident)LRParser.GetReductionSyntaxNode(0)).source_context;
			_ident_list.idents.Add((ident)LRParser.GetReductionSyntaxNode(0));
			return _ident_list;
		}

	case (int)RuleConstants.RULE_IDENT_OR_KEYWORD_POINTSEPARATOR_LIST_TKPOINT :
	//<ident_or_keyword_pointseparator_list> ::= <ident_or_keyword_pointseparator_list> tkPoint <identifier_or_keyword>

		//TemplateList for ident_list (add)         
		{
			ident_list _ident_list=(ident_list)LRParser.GetReductionSyntaxNode(0);
			parsertools.create_source_context(_ident_list,_ident_list,LRParser.GetReductionSyntaxNode(2));
			_ident_list.idents.Add(LRParser.GetReductionSyntaxNode(2) as ident);
			return _ident_list;
		}

	case (int)RuleConstants.RULE_MAIN_USES_CLAUSE :
	//<main_uses_clause> ::= 
	//NONTERMINAL:<main_uses_clause> ::= 
	return null;
	//ENDNONTERMINAL
	case (int)RuleConstants.RULE_MAIN_USES_CLAUSE_TKUSES_TKSEMICOLON :
	//<main_uses_clause> ::= tkUses <main_used_units_list> tkSemiColon
 parsertools.create_source_context(LRParser.GetReductionSyntaxNode(1),LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(2));return LRParser.GetReductionSyntaxNode(1);
	case (int)RuleConstants.RULE_MAIN_USED_UNITS_LIST_TKCOMMA :
	//<main_used_units_list> ::= <main_used_units_list> tkComma <main_used_unit_name>
         
		{
			uses_list _uses_list=(uses_list)LRParser.GetReductionSyntaxNode(0);
								_uses_list.units.Add((unit_or_namespace)LRParser.GetReductionSyntaxNode(2));
								
			return _uses_list;
		}

	case (int)RuleConstants.RULE_MAIN_USED_UNITS_LIST :
	//<main_used_units_list> ::= <main_used_unit_name> <empty>
         
		{
			uses_list _uses_list=new uses_list();
			
								_uses_list.units.Add((unit_or_namespace)LRParser.GetReductionSyntaxNode(0));
								
			return _uses_list;
		}

	case (int)RuleConstants.RULE_MAIN_USED_UNIT_NAME :
	//<main_used_unit_name> ::= <ident_or_keyword_pointseparator_list> <empty>
         
		{
			unit_or_namespace _unit_or_namespace=new unit_or_namespace((ident_list)LRParser.GetReductionSyntaxNode(0));
			parsertools.create_source_context(_unit_or_namespace,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(0));
			
			return _unit_or_namespace;
		}

	case (int)RuleConstants.RULE_MAIN_USED_UNIT_NAME_TKIN_TKSTRINGLITERAL :
	//<main_used_unit_name> ::= <ident_or_keyword_pointseparator_list> tkIn tkStringLiteral
         
		{
			uses_unit_in _uses_unit_in=new uses_unit_in();
			parsertools.create_source_context(_uses_unit_in,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(2));
			
								_uses_unit_in.name=(ident_list)LRParser.GetReductionSyntaxNode(0);
								_uses_unit_in.in_file=(string_const)LRParser.GetReductionSyntaxNode(2);
								
			return _uses_unit_in;
		}

	case (int)RuleConstants.RULE_LIBRARY_FILE_TKPOINT :
	//<library_file> ::= <library_heading> <main_uses_clause> <library_block> tkPoint
 {errors.Add(new nonterminal_token_return_null(current_file_name,parsertools.GetTokenSourceContext(),(syntax_tree_node)prev_node,"<library_file> ::= <library_heading> <main_uses_clause> <library_block> tkPoint"));}return null;
	case (int)RuleConstants.RULE_LIBRARY_HEADING_TKLIBRARY_TKSEMICOLON :
	//<library_heading> ::= tkLibrary <identifier> tkSemiColon
 {errors.Add(new nonterminal_token_return_null(current_file_name,parsertools.GetTokenSourceContext(),(syntax_tree_node)prev_node,"<library_heading> ::= tkLibrary <identifier> tkSemiColon"));}return null;
	case (int)RuleConstants.RULE_LIBRARY_BLOCK :
	//<library_block> ::= <library_impl_decl_sect_list> <compound_stmt>
 {errors.Add(new nonterminal_token_return_null(current_file_name,parsertools.GetTokenSourceContext(),(syntax_tree_node)prev_node,"<library_block> ::= <library_impl_decl_sect_list> <compound_stmt>"));}return null;
	case (int)RuleConstants.RULE_LIBRARY_IMPL_DECL_SECT_LIST :
	//<library_impl_decl_sect_list> ::= 
	//NONTERMINAL:<library_impl_decl_sect_list> ::= 
	return null;
	//ENDNONTERMINAL
	case (int)RuleConstants.RULE_LIBRARY_IMPL_DECL_SECT_LIST2 :
	//<library_impl_decl_sect_list> ::= <library_impl_decl_sect_list> <library_impl_decl_sect>
 {errors.Add(new nonterminal_token_return_null(current_file_name,parsertools.GetTokenSourceContext(),(syntax_tree_node)prev_node,"<library_impl_decl_sect_list> ::= <library_impl_decl_sect_list> <library_impl_decl_sect>"));}return null;
	case (int)RuleConstants.RULE_LIBRARY_IMPL_DECL_SECT :
	//<library_impl_decl_sect> ::= <label_decl_sect>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_LIBRARY_IMPL_DECL_SECT2 :
	//<library_impl_decl_sect> ::= <const_decl_sect>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_LIBRARY_IMPL_DECL_SECT3 :
	//<library_impl_decl_sect> ::= <res_str_decl_sect>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_LIBRARY_IMPL_DECL_SECT4 :
	//<library_impl_decl_sect> ::= <type_decl_sect>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_LIBRARY_IMPL_DECL_SECT5 :
	//<library_impl_decl_sect> ::= <var_decl_sect>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_LIBRARY_IMPL_DECL_SECT6 :
	//<library_impl_decl_sect> ::= <proc_decl>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_LIBRARY_IMPL_DECL_SECT7 :
	//<library_impl_decl_sect> ::= <func_decl>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_LIBRARY_IMPL_DECL_SECT8 :
	//<library_impl_decl_sect> ::= <constructor_decl>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_LIBRARY_IMPL_DECL_SECT9 :
	//<library_impl_decl_sect> ::= <destructor_decl>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_LIBRARY_IMPL_DECL_SECT10 :
	//<library_impl_decl_sect> ::= <export_clause>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_EXPORT_CLAUSE_TKEXPORTS_TKSEMICOLON :
	//<export_clause> ::= tkExports <exports_list> tkSemiColon
 {errors.Add(new nonterminal_token_return_null(current_file_name,parsertools.GetTokenSourceContext(),(syntax_tree_node)prev_node,"<export_clause> ::= tkExports <exports_list> tkSemiColon"));}return null;
	case (int)RuleConstants.RULE_EXPORTS_LIST :
	//<exports_list> ::= <exports_entry>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_EXPORTS_LIST_TKCOMMA :
	//<exports_list> ::= <exports_list> tkComma <exports_entry>
 {errors.Add(new nonterminal_token_return_null(current_file_name,parsertools.GetTokenSourceContext(),(syntax_tree_node)prev_node,"<exports_list> ::= <exports_list> tkComma <exports_entry>"));}return null;
	case (int)RuleConstants.RULE_EXPORTS_ENTRY :
	//<exports_entry> ::= <identifier> <exports_index> <exports_name> <exports_resident>
 {errors.Add(new nonterminal_token_return_null(current_file_name,parsertools.GetTokenSourceContext(),(syntax_tree_node)prev_node,"<exports_entry> ::= <identifier> <exports_index> <exports_name> <exports_resident>"));}return null;
	case (int)RuleConstants.RULE_EXPORTS_INDEX :
	//<exports_index> ::= 
	//NONTERMINAL:<exports_index> ::= 
	return null;
	//ENDNONTERMINAL
	case (int)RuleConstants.RULE_EXPORTS_INDEX_TKINDEX :
	//<exports_index> ::= tkIndex <integer_const>
 {errors.Add(new nonterminal_token_return_null(current_file_name,parsertools.GetTokenSourceContext(),(syntax_tree_node)prev_node,"<exports_index> ::= tkIndex <integer_const>"));}return null;
	case (int)RuleConstants.RULE_EXPORTS_NAME :
	//<exports_name> ::= 
	//NONTERMINAL:<exports_name> ::= 
	return null;
	//ENDNONTERMINAL
	case (int)RuleConstants.RULE_EXPORTS_NAME_TKNAME :
	//<exports_name> ::= tkName <identifier>
 {errors.Add(new nonterminal_token_return_null(current_file_name,parsertools.GetTokenSourceContext(),(syntax_tree_node)prev_node,"<exports_name> ::= tkName <identifier>"));}return null;
	case (int)RuleConstants.RULE_EXPORTS_NAME_TKNAME2 :
	//<exports_name> ::= tkName <literal>
 {errors.Add(new nonterminal_token_return_null(current_file_name,parsertools.GetTokenSourceContext(),(syntax_tree_node)prev_node,"<exports_name> ::= tkName <literal>"));}return null;
	case (int)RuleConstants.RULE_EXPORTS_RESIDENT :
	//<exports_resident> ::= 
	//NONTERMINAL:<exports_resident> ::= 
	return null;
	//ENDNONTERMINAL
	case (int)RuleConstants.RULE_EXPORTS_RESIDENT_TKRESIDENT :
	//<exports_resident> ::= tkResident
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_UNIT_FILE_TKPOINT :
	//<unit_file> ::= <unit_heading> <interface_part> <implementation_part> <initialization_part> tkPoint
         
		{
			unit_module _unit_module=new unit_module((unit_name)LRParser.GetReductionSyntaxNode(0),(interface_node)LRParser.GetReductionSyntaxNode(1),(implementation_node)LRParser.GetReductionSyntaxNode(2),((initfinal_part)LRParser.GetReductionSyntaxNode(3)).initialization_sect,((initfinal_part)LRParser.GetReductionSyntaxNode(3)).finalization_sect);
			
								_unit_module.Language = LanguageId.PascalABCNET;                               
								parsertools.create_source_context(_unit_module,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(4));
								
			return _unit_module;
		}

	case (int)RuleConstants.RULE_UNIT_FILE_TKPOINT2 :
	//<unit_file> ::= <unit_heading> <abc_interface_part> <initialization_part> tkPoint
         
		{
			unit_module _unit_module=new unit_module((unit_name)LRParser.GetReductionSyntaxNode(0),(interface_node)LRParser.GetReductionSyntaxNode(1),null,((initfinal_part)LRParser.GetReductionSyntaxNode(2)).initialization_sect,((initfinal_part)LRParser.GetReductionSyntaxNode(2)).finalization_sect);
			
								_unit_module.Language = LanguageId.PascalABCNET;
                                                                parsertools.create_source_context(_unit_module,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(3));
								
			return _unit_module;
		}

	case (int)RuleConstants.RULE_UNIT_HEADING_TKSEMICOLON :
	//<unit_heading> ::= <unit_key_word> <unit_name> tkSemiColon <opt_head_compiler_directives>
         
		{
			unit_name _unit_name=new unit_name((ident)LRParser.GetReductionSyntaxNode(1),UnitHeaderKeyword.Unit);
			 
								if(((ident)LRParser.GetReductionSyntaxNode(0)).name.ToLower()=="library")
									_unit_name.HeaderKeyword=UnitHeaderKeyword.Library;
								parsertools.create_source_context(_unit_name,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(2));
			return _unit_name;
		}

	case (int)RuleConstants.RULE_UNIT_KEY_WORD_TKUNIT :
	//<unit_key_word> ::= tkUnit
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_UNIT_KEY_WORD_TKLIBRARY :
	//<unit_key_word> ::= tkLibrary
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_UNIT_NAME :
	//<unit_name> ::= <identifier>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_INTERFACE_PART_TKINTERFACE :
	//<interface_part> ::= tkInterface <uses_clause> <using_clause> <int_decl_sect_list>
         
		{
			interface_node _interface_node=new interface_node();
			 
								_interface_node.uses_modules=LRParser.GetReductionSyntaxNode(1) as uses_list;
								_interface_node.using_namespaces=LRParser.GetReductionSyntaxNode(2) as using_list;
								_interface_node.interface_definitions=LRParser.GetReductionSyntaxNode(3) as declarations;
								parsertools.create_source_context(_interface_node,LRParser.GetReductionSyntaxNode(0),parsertools.sc_not_null(LRParser.GetReductionSyntaxNode(3),LRParser.GetReductionSyntaxNode(2),LRParser.GetReductionSyntaxNode(1),LRParser.GetReductionSyntaxNode(0)));
								
			return _interface_node;
		}

	case (int)RuleConstants.RULE_IMPLEMENTATION_PART_TKIMPLEMENTATION :
	//<implementation_part> ::= tkImplementation <uses_clause> <using_clause> <impl_decl_sect_list>
         
		{
			implementation_node _implementation_node=new implementation_node();
			
								_implementation_node.uses_modules=LRParser.GetReductionSyntaxNode(1) as uses_list;
								_implementation_node.using_namespaces=LRParser.GetReductionSyntaxNode(2) as using_list;
								_implementation_node.implementation_definitions=LRParser.GetReductionSyntaxNode(3) as declarations;
								parsertools.create_source_context(_implementation_node,LRParser.GetReductionSyntaxNode(0),parsertools.sc_not_null(LRParser.GetReductionSyntaxNode(3),LRParser.GetReductionSyntaxNode(2),LRParser.GetReductionSyntaxNode(1),LRParser.GetReductionSyntaxNode(0)));
								
			return _implementation_node;
		}

	case (int)RuleConstants.RULE_ABC_INTERFACE_PART :
	//<abc_interface_part> ::= <uses_clause> <using_clause> <impl_decl_sect_list>
         
		{
			interface_node _interface_node=new interface_node();
			
								_interface_node.uses_modules=LRParser.GetReductionSyntaxNode(0) as uses_list;
								_interface_node.using_namespaces=LRParser.GetReductionSyntaxNode(1) as using_list;
								_interface_node.interface_definitions=LRParser.GetReductionSyntaxNode(2) as declarations;
								object lt=parsertools.sc_not_null(LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(1),LRParser.GetReductionSyntaxNode(2));							
								object rt=parsertools.sc_not_null(LRParser.GetReductionSyntaxNode(2),LRParser.GetReductionSyntaxNode(1),LRParser.GetReductionSyntaxNode(0));							
								if (lt!=null)parsertools.create_source_context(_interface_node,lt,rt);
								
			return _interface_node;
		}

	case (int)RuleConstants.RULE_INITIALIZATION_PART_TKEND :
	//<initialization_part> ::= tkEnd
         
		{
			initfinal_part _initfinal_part=new initfinal_part();
			
			return _initfinal_part;
		}

	case (int)RuleConstants.RULE_INITIALIZATION_PART_TKINITIALIZATION_TKEND :
	//<initialization_part> ::= tkInitialization <stmt_list> tkEnd
         
		{
			initfinal_part _initfinal_part=new initfinal_part((statement_list)LRParser.GetReductionSyntaxNode(1),null);
			
								((statement_list)LRParser.GetReductionSyntaxNode(1)).left_logical_bracket=(syntax_tree_node)LRParser.GetReductionSyntaxNode(0);
								((statement_list)LRParser.GetReductionSyntaxNode(1)).right_logical_bracket=(syntax_tree_node)LRParser.GetReductionSyntaxNode(2);
								
			return _initfinal_part;
		}

	case (int)RuleConstants.RULE_INITIALIZATION_PART_TKINITIALIZATION_TKFINALIZATION_TKEND :
	//<initialization_part> ::= tkInitialization <stmt_list> tkFinalization <stmt_list> tkEnd
         
		{
			initfinal_part _initfinal_part=new initfinal_part((statement_list)LRParser.GetReductionSyntaxNode(1),(statement_list)LRParser.GetReductionSyntaxNode(3));
			
								((statement_list)LRParser.GetReductionSyntaxNode(1)).left_logical_bracket=(syntax_tree_node)LRParser.GetReductionSyntaxNode(0);
								((statement_list)LRParser.GetReductionSyntaxNode(3)).left_logical_bracket=(syntax_tree_node)LRParser.GetReductionSyntaxNode(2);
								((statement_list)LRParser.GetReductionSyntaxNode(3)).right_logical_bracket=(syntax_tree_node)LRParser.GetReductionSyntaxNode(4);
								
			return _initfinal_part;
		}

	case (int)RuleConstants.RULE_INITIALIZATION_PART_TKBEGIN_TKEND :
	//<initialization_part> ::= tkBegin <stmt_list> tkEnd
         
		{
			initfinal_part _initfinal_part=new initfinal_part((statement_list)LRParser.GetReductionSyntaxNode(1),null);
			
								((statement_list)LRParser.GetReductionSyntaxNode(1)).left_logical_bracket=(syntax_tree_node)LRParser.GetReductionSyntaxNode(0);
								((statement_list)LRParser.GetReductionSyntaxNode(1)).right_logical_bracket=(syntax_tree_node)LRParser.GetReductionSyntaxNode(2);
								
			return _initfinal_part;
		}

	case (int)RuleConstants.RULE_PACKAGE_FILE_TKPACKAGE_TKSEMICOLON_TKEND_TKPOINT :
	//<package_file> ::= tkPackage <package_name> tkSemiColon <requires_clause> <contains_clause> tkEnd tkPoint
 {errors.Add(new nonterminal_token_return_null(current_file_name,parsertools.GetTokenSourceContext(),(syntax_tree_node)prev_node,"<package_file> ::= tkPackage <package_name> tkSemiColon <requires_clause> <contains_clause> tkEnd tkPoint"));}return null;
	case (int)RuleConstants.RULE_PACKAGE_NAME :
	//<package_name> ::= <identifier>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_REQUIRES_CLAUSE :
	//<requires_clause> ::= 
	//NONTERMINAL:<requires_clause> ::= 
	return null;
	//ENDNONTERMINAL
	case (int)RuleConstants.RULE_REQUIRES_CLAUSE_TKREQUIRES :
	//<requires_clause> ::= tkRequires
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_REQUIRES_CLAUSE_TKREQUIRES_TKSEMICOLON :
	//<requires_clause> ::= tkRequires <main_used_units_list> tkSemiColon
 {errors.Add(new nonterminal_token_return_null(current_file_name,parsertools.GetTokenSourceContext(),(syntax_tree_node)prev_node,"<requires_clause> ::= tkRequires <main_used_units_list> tkSemiColon"));}return null;
	case (int)RuleConstants.RULE_CONTAINS_CLAUSE :
	//<contains_clause> ::= 
	//NONTERMINAL:<contains_clause> ::= 
	return null;
	//ENDNONTERMINAL
	case (int)RuleConstants.RULE_CONTAINS_CLAUSE_TKCONTAINS :
	//<contains_clause> ::= tkContains
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_CONTAINS_CLAUSE_TKCONTAINS_TKSEMICOLON :
	//<contains_clause> ::= tkContains <main_used_units_list> tkSemiColon
 {errors.Add(new nonterminal_token_return_null(current_file_name,parsertools.GetTokenSourceContext(),(syntax_tree_node)prev_node,"<contains_clause> ::= tkContains <main_used_units_list> tkSemiColon"));}return null;
	case (int)RuleConstants.RULE_INT_DECL_SECT_LIST :
	//<int_decl_sect_list> ::= <int_decl_sect_list1> <empty>
if (((declarations)LRParser.GetReductionSyntaxNode(0)).defs.Count>0) return LRParser.GetReductionSyntaxNode(0); return null;
	case (int)RuleConstants.RULE_INT_DECL_SECT_LIST1 :
	//<int_decl_sect_list1> ::= <empty> <empty>
         
		{
			declarations _declarations=new declarations();
			
			return _declarations;
		}

	case (int)RuleConstants.RULE_INT_DECL_SECT_LIST12 :
	//<int_decl_sect_list1> ::= <int_decl_sect_list1> <int_decl_sect>
         
		{
			declarations _declarations=(declarations)LRParser.GetReductionSyntaxNode(0);
							_declarations.defs.Add((declaration)LRParser.GetReductionSyntaxNode(1));
							parsertools.create_source_context(_declarations,parsertools.sc_not_null(LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(1)),LRParser.GetReductionSyntaxNode(1));
							
			return _declarations;
		}

	case (int)RuleConstants.RULE_IMPL_DECL_SECT_LIST :
	//<impl_decl_sect_list> ::= <impl_decl_sect_list1> <empty>
if (((declarations)LRParser.GetReductionSyntaxNode(0)).defs.Count>0) return LRParser.GetReductionSyntaxNode(0); return null;
	case (int)RuleConstants.RULE_IMPL_DECL_SECT_LIST1 :
	//<impl_decl_sect_list1> ::= <empty> <empty>
         
		{
			declarations _declarations=new declarations();
			
			return _declarations;
		}

	case (int)RuleConstants.RULE_IMPL_DECL_SECT_LIST12 :
	//<impl_decl_sect_list1> ::= <impl_decl_sect_list1> <impl_decl_sect>
         
		{
			declarations _declarations=(declarations)LRParser.GetReductionSyntaxNode(0);
							_declarations.defs.Add((declaration)LRParser.GetReductionSyntaxNode(1));
							parsertools.create_source_context(_declarations,parsertools.sc_not_null(LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(1)),LRParser.GetReductionSyntaxNode(1));
							
			return _declarations;
		}

	case (int)RuleConstants.RULE_ABC_DECL_SECT_LIST :
	//<abc_decl_sect_list> ::= <abc_decl_sect_list1> <empty>
if (((declarations)LRParser.GetReductionSyntaxNode(0)).defs.Count>0) return LRParser.GetReductionSyntaxNode(0); return null;
	case (int)RuleConstants.RULE_ABC_DECL_SECT_LIST1 :
	//<abc_decl_sect_list1> ::= <empty> <empty>
         
		{
			declarations _declarations=new declarations();
			
			return _declarations;
		}

	case (int)RuleConstants.RULE_ABC_DECL_SECT_LIST12 :
	//<abc_decl_sect_list1> ::= <abc_decl_sect_list1> <abc_decl_sect>
         
		{
			declarations _declarations=(declarations)LRParser.GetReductionSyntaxNode(0);
							_declarations.defs.Add((declaration)LRParser.GetReductionSyntaxNode(1));
							parsertools.create_source_context(_declarations,parsertools.sc_not_null(LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(1)),LRParser.GetReductionSyntaxNode(1));
							
			return _declarations;
		}

	case (int)RuleConstants.RULE_INT_DECL_SECT :
	//<int_decl_sect> ::= <const_decl_sect>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_INT_DECL_SECT2 :
	//<int_decl_sect> ::= <res_str_decl_sect>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_INT_DECL_SECT3 :
	//<int_decl_sect> ::= <type_decl_sect>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_INT_DECL_SECT4 :
	//<int_decl_sect> ::= <var_decl_sect>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_INT_DECL_SECT5 :
	//<int_decl_sect> ::= <int_proc_heading>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_INT_DECL_SECT6 :
	//<int_decl_sect> ::= <int_func_heading>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_IMPL_DECL_SECT :
	//<impl_decl_sect> ::= <label_decl_sect>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_IMPL_DECL_SECT2 :
	//<impl_decl_sect> ::= <const_decl_sect>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_IMPL_DECL_SECT3 :
	//<impl_decl_sect> ::= <res_str_decl_sect>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_IMPL_DECL_SECT4 :
	//<impl_decl_sect> ::= <type_decl_sect>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_IMPL_DECL_SECT5 :
	//<impl_decl_sect> ::= <var_decl_sect>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_IMPL_DECL_SECT6 :
	//<impl_decl_sect> ::= <proc_decl_with_attr>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_IMPL_DECL_SECT7 :
	//<impl_decl_sect> ::= <func_decl_with_attr>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_IMPL_DECL_SECT8 :
	//<impl_decl_sect> ::= <constructor_decl_with_attr>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_IMPL_DECL_SECT9 :
	//<impl_decl_sect> ::= <destructor_decl_with_attr>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_PROC_DECL_WITH_ATTR :
	//<proc_decl_with_attr> ::= <opt_attribute_declarations> <proc_decl>
         
		{
			procedure_definition _procedure_definition;
			 _procedure_definition=(LRParser.GetReductionSyntaxNode(1) as procedure_definition); 
				if (_procedure_definition.proc_header != null)
				_procedure_definition.proc_header.attributes = LRParser.GetReductionSyntaxNode(0) as attribute_list;
			
			return _procedure_definition;
		}

	case (int)RuleConstants.RULE_FUNC_DECL_WITH_ATTR :
	//<func_decl_with_attr> ::= <opt_attribute_declarations> <func_decl>
         
		{
			procedure_definition _procedure_definition;
			 _procedure_definition=(LRParser.GetReductionSyntaxNode(1) as procedure_definition); 
				if (_procedure_definition.proc_header != null)
				_procedure_definition.proc_header.attributes = LRParser.GetReductionSyntaxNode(0) as attribute_list;
			
			return _procedure_definition;
		}

	case (int)RuleConstants.RULE_CONSTRUCTOR_DECL_WITH_ATTR :
	//<constructor_decl_with_attr> ::= <opt_attribute_declarations> <constructor_decl>
         
		{
			procedure_definition _procedure_definition;
			 _procedure_definition=(LRParser.GetReductionSyntaxNode(1) as procedure_definition); 
				if (_procedure_definition.proc_header != null)
				_procedure_definition.proc_header.attributes = LRParser.GetReductionSyntaxNode(0) as attribute_list;
			
			return _procedure_definition;
		}

	case (int)RuleConstants.RULE_DESTRUCTOR_DECL_WITH_ATTR :
	//<destructor_decl_with_attr> ::= <opt_attribute_declarations> <destructor_decl>
         
		{
			procedure_definition _procedure_definition;
			 _procedure_definition=(LRParser.GetReductionSyntaxNode(1) as procedure_definition); 
				if (_procedure_definition.proc_header != null)
				_procedure_definition.proc_header.attributes = LRParser.GetReductionSyntaxNode(0) as attribute_list;
			
			return _procedure_definition;
		}

	case (int)RuleConstants.RULE_ABC_DECL_SECT :
	//<abc_decl_sect> ::= <label_decl_sect>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_ABC_DECL_SECT2 :
	//<abc_decl_sect> ::= <const_decl_sect>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_ABC_DECL_SECT3 :
	//<abc_decl_sect> ::= <res_str_decl_sect>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_ABC_DECL_SECT4 :
	//<abc_decl_sect> ::= <type_decl_sect>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_ABC_DECL_SECT5 :
	//<abc_decl_sect> ::= <var_decl_sect>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_INT_PROC_HEADING :
	//<int_proc_heading> ::= <opt_attribute_declarations> <proc_heading>
         
		{
			declaration _declaration;
			 _declaration=(LRParser.GetReductionSyntaxNode(1) as declaration); 
				_declaration.attributes = LRParser.GetReductionSyntaxNode(0) as attribute_list;
			
			return _declaration;
		}

	case (int)RuleConstants.RULE_INT_PROC_HEADING_TKFORWARD_TKSEMICOLON :
	//<int_proc_heading> ::= <opt_attribute_declarations> <proc_heading> tkForward tkSemiColon
         
		{
			procedure_header _procedure_header;
			 _procedure_header=(LRParser.GetReductionSyntaxNode(1) as procedure_header);
							if (_procedure_header.proc_attributes==null) _procedure_header.proc_attributes=new procedure_attributes_list();
							_procedure_header.proc_attributes.proc_attributes.Add((procedure_attribute)LRParser.GetReductionSyntaxNode(2));
							_procedure_header.attributes = LRParser.GetReductionSyntaxNode(0) as attribute_list;
							parsertools.create_source_context(_procedure_header.proc_attributes,parsertools.sc_not_null(_procedure_header.proc_attributes,LRParser.GetReductionSyntaxNode(2)),LRParser.GetReductionSyntaxNode(2));
							parsertools.create_source_context(_procedure_header,LRParser.GetReductionSyntaxNode(1),LRParser.GetReductionSyntaxNode(2));
			return _procedure_header;
		}

	case (int)RuleConstants.RULE_INT_FUNC_HEADING :
	//<int_func_heading> ::= <opt_attribute_declarations> <func_heading>
         
		{
			declaration _declaration;
			 _declaration=(LRParser.GetReductionSyntaxNode(1) as declaration); 
				_declaration.attributes = LRParser.GetReductionSyntaxNode(0) as attribute_list;
			
			return _declaration;
		}

	case (int)RuleConstants.RULE_INT_FUNC_HEADING_TKFORWARD_TKSEMICOLON :
	//<int_func_heading> ::= <opt_attribute_declarations> <func_heading> tkForward tkSemiColon
         
		{
			procedure_header _procedure_header;
			 _procedure_header=(LRParser.GetReductionSyntaxNode(1) as procedure_header);
							if (_procedure_header.proc_attributes==null) _procedure_header.proc_attributes=new procedure_attributes_list();
							_procedure_header.proc_attributes.proc_attributes.Add((procedure_attribute)LRParser.GetReductionSyntaxNode(2));
							_procedure_header.attributes = LRParser.GetReductionSyntaxNode(0) as attribute_list;
							parsertools.create_source_context(_procedure_header.proc_attributes,parsertools.sc_not_null(_procedure_header.proc_attributes,LRParser.GetReductionSyntaxNode(2)),LRParser.GetReductionSyntaxNode(2));
							parsertools.create_source_context(_procedure_header,LRParser.GetReductionSyntaxNode(1),LRParser.GetReductionSyntaxNode(2));
			return _procedure_header;
		}

	case (int)RuleConstants.RULE_LABEL_DECL_SECT_TKLABEL_TKSEMICOLON :
	//<label_decl_sect> ::= tkLabel <label_list> tkSemiColon
         
		{
			label_definitions _label_definitions=new label_definitions((ident_list)LRParser.GetReductionSyntaxNode(1));
			
							parsertools.create_source_context(_label_definitions,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(2));
			return _label_definitions;
		}

	case (int)RuleConstants.RULE_LABEL_LIST :
	//<label_list> ::= <label_name> <empty>
         
		//TemplateList for ident_list (create)
		{
			ident_list _ident_list=new ident_list();
			_ident_list.source_context=((ident)LRParser.GetReductionSyntaxNode(0)).source_context;
			_ident_list.idents.Add((ident)LRParser.GetReductionSyntaxNode(0));
			return _ident_list;
		}

	case (int)RuleConstants.RULE_LABEL_LIST_TKCOMMA :
	//<label_list> ::= <label_list> tkComma <label_name>

		//TemplateList for ident_list (add)         
		{
			ident_list _ident_list=(ident_list)LRParser.GetReductionSyntaxNode(0);
			parsertools.create_source_context(_ident_list,_ident_list,LRParser.GetReductionSyntaxNode(2));
			_ident_list.idents.Add(LRParser.GetReductionSyntaxNode(2) as ident);
			return _ident_list;
		}

	case (int)RuleConstants.RULE_LABEL_NAME_TKINTEGER :
	//<label_name> ::= tkInteger <empty>
         
		{
			ident _ident=new ident();
			
								if(LRParser.GetReductionSyntaxNode(0) is int32_const)
									_ident.name = ((int32_const)LRParser.GetReductionSyntaxNode(0)).val.ToString();
								else
								if(LRParser.GetReductionSyntaxNode(0) is int64_const)
									_ident.name = ((int64_const)LRParser.GetReductionSyntaxNode(0)).val.ToString();
								else
									_ident.name = ((uint64_const)LRParser.GetReductionSyntaxNode(0)).val.ToString();
								parsertools.assign_source_context(_ident,LRParser.GetReductionSyntaxNode(0));
			return _ident;
		}

	case (int)RuleConstants.RULE_LABEL_NAME_TKFLOAT :
	//<label_name> ::= tkFloat <empty>
         
		{
			ident _ident=new ident(((double_const)LRParser.GetReductionSyntaxNode(0)).val.ToString());
			 parsertools.assign_source_context(_ident,LRParser.GetReductionSyntaxNode(0));
			return _ident;
		}

	case (int)RuleConstants.RULE_LABEL_NAME :
	//<label_name> ::= <identifier>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_CONST_DECL_SECT_TKCONST :
	//<const_decl_sect> ::= tkConst <const_decl>
         
		{
			consts_definitions_list _consts_definitions_list=new consts_definitions_list();
			
							_consts_definitions_list.const_defs.Add((const_definition)LRParser.GetReductionSyntaxNode(1));
							parsertools.create_source_context(_consts_definitions_list,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(1));
			return _consts_definitions_list;
		}

	case (int)RuleConstants.RULE_CONST_DECL_SECT :
	//<const_decl_sect> ::= <const_decl_sect> <const_decl>
         
		{
			consts_definitions_list _consts_definitions_list=(consts_definitions_list)LRParser.GetReductionSyntaxNode(0);
							_consts_definitions_list.const_defs.Add((const_definition)LRParser.GetReductionSyntaxNode(1));
							parsertools.create_source_context(_consts_definitions_list,_consts_definitions_list,LRParser.GetReductionSyntaxNode(1));
			return _consts_definitions_list;
		}

	case (int)RuleConstants.RULE_RES_STR_DECL_SECT_TKRESOURCESTRING :
	//<res_str_decl_sect> ::= tkResourceString <const_decl>
 {errors.Add(new nonterminal_token_return_null(current_file_name,parsertools.GetTokenSourceContext(),(syntax_tree_node)prev_node,"<res_str_decl_sect> ::= tkResourceString <const_decl>"));}return null;
	case (int)RuleConstants.RULE_RES_STR_DECL_SECT :
	//<res_str_decl_sect> ::= <res_str_decl_sect> <const_decl>
 {errors.Add(new nonterminal_token_return_null(current_file_name,parsertools.GetTokenSourceContext(),(syntax_tree_node)prev_node,"<res_str_decl_sect> ::= <res_str_decl_sect> <const_decl>"));}return null;
	case (int)RuleConstants.RULE_TYPE_DECL_SECT_TKTYPE :
	//<type_decl_sect> ::= tkType <type_decl>
         
		{
			type_declarations _type_declarations=new type_declarations();
			
                                                ///////////////tasha 28.04.2010
            					pascalABC_type_declarations.Add((type_declaration)LRParser.GetReductionSyntaxNode(1));
            					///////////////////////////////
							_type_declarations.types_decl.Add((type_declaration)LRParser.GetReductionSyntaxNode(1));
							parsertools.create_source_context(_type_declarations,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(1));
			return _type_declarations;
		}

	case (int)RuleConstants.RULE_TYPE_DECL_SECT :
	//<type_decl_sect> ::= <type_decl_sect> <type_decl>
         
		{
			type_declarations _type_declarations=(type_declarations)LRParser.GetReductionSyntaxNode(0);
							_type_declarations.types_decl.Add((type_declaration)LRParser.GetReductionSyntaxNode(1));
							parsertools.create_source_context(_type_declarations,_type_declarations,LRParser.GetReductionSyntaxNode(1));
			return _type_declarations;
		}

	case (int)RuleConstants.RULE_VAR_DECL_SECT_TKVAR :
	//<var_decl_sect> ::= tkVar <var_decl>
         
		{
			variable_definitions _variable_definitions=new variable_definitions();
			
									///////////////tasha 28.04.2010
            pascalABC_var_statements.Add((var_def_statement)LRParser.GetReductionSyntaxNode(1));
            ///////////////////////////////
							_variable_definitions.var_definitions.Add((var_def_statement)LRParser.GetReductionSyntaxNode(1));
							parsertools.create_source_context(_variable_definitions,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(1));
			return _variable_definitions;
		}

	case (int)RuleConstants.RULE_VAR_DECL_SECT_TKEVENT :
	//<var_decl_sect> ::= tkEvent <var_decl>
         
		{
			variable_definitions _variable_definitions=new variable_definitions();
			
							_variable_definitions.var_definitions.Add((var_def_statement)LRParser.GetReductionSyntaxNode(1));
							(LRParser.GetReductionSyntaxNode(1) as var_def_statement).is_event = true;
							parsertools.create_source_context(_variable_definitions,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(1));
							
			return _variable_definitions;
		}

	case (int)RuleConstants.RULE_VAR_DECL_SECT :
	//<var_decl_sect> ::= <var_decl_sect> <var_decl>
         
		{
			variable_definitions _variable_definitions=(variable_definitions)LRParser.GetReductionSyntaxNode(0);
							_variable_definitions.var_definitions.Add((var_def_statement)LRParser.GetReductionSyntaxNode(1));
							parsertools.create_source_context(_variable_definitions,_variable_definitions,LRParser.GetReductionSyntaxNode(1));
			return _variable_definitions;
		}

	case (int)RuleConstants.RULE_CONST_DECL_TKSEMICOLON :
	//<const_decl> ::= <only_const_decl> tkSemiColon
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_ONLY_CONST_DECL_TKEQUAL :
	//<only_const_decl> ::= <const_name> tkEqual <init_const_expr>
         
		{
			simple_const_definition _simple_const_definition=new simple_const_definition();
			
								_simple_const_definition.const_name=(ident)LRParser.GetReductionSyntaxNode(0);
								_simple_const_definition.const_value=(expression)LRParser.GetReductionSyntaxNode(2);
								parsertools.create_source_context(_simple_const_definition,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(2));
			return _simple_const_definition;
		}

	case (int)RuleConstants.RULE_ONLY_CONST_DECL_TKCOLON_TKEQUAL :
	//<only_const_decl> ::= <const_name> tkColon <type_ref> tkEqual <typed_const>
         
		{
			typed_const_definition _typed_const_definition=new typed_const_definition();
			
								_typed_const_definition.const_name=(ident)LRParser.GetReductionSyntaxNode(0);
								_typed_const_definition.const_type=(type_definition)LRParser.GetReductionSyntaxNode(2);
								_typed_const_definition.const_value=(expression)LRParser.GetReductionSyntaxNode(4);
								parsertools.create_source_context(_typed_const_definition,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(4));
			return _typed_const_definition;
		}

	case (int)RuleConstants.RULE_INIT_CONST_EXPR :
	//<init_const_expr> ::= <const_expr>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_INIT_CONST_EXPR2 :
	//<init_const_expr> ::= <array_const>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_CONST_NAME :
	//<const_name> ::= <identifier>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_CONST_EXPR :
	//<const_expr> ::= <const_simple_expr>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_CONST_EXPR2 :
	//<const_expr> ::= <const_simple_expr> <const_relop> <const_simple_expr>
         
		{
			bin_expr _bin_expr=new bin_expr((expression)LRParser.GetReductionSyntaxNode(0),(expression)LRParser.GetReductionSyntaxNode(2),((op_type_node)LRParser.GetReductionSyntaxNode(1)).type);
			parsertools.create_source_context(_bin_expr,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(2));
			
			return _bin_expr;
		}

	case (int)RuleConstants.RULE_CONST_EXPR3 :
	//<const_expr> ::= <question_constexpr>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_QUESTION_CONSTEXPR_TKQUESTION_TKCOLON :
	//<question_constexpr> ::= <const_expr> tkQuestion <const_expr> tkColon <const_expr>
         
		{
			question_colon_expression _question_colon_expression=new question_colon_expression((expression)LRParser.GetReductionSyntaxNode(0),(expression)LRParser.GetReductionSyntaxNode(2),(expression)LRParser.GetReductionSyntaxNode(4));
			 parsertools.create_source_context(_question_colon_expression,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(4));
			return _question_colon_expression;
		}

	case (int)RuleConstants.RULE_CONST_RELOP_TKEQUAL :
	//<const_relop> ::= tkEqual
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_CONST_RELOP_TKNOTEQUAL :
	//<const_relop> ::= tkNotEqual
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_CONST_RELOP_TKLOWER :
	//<const_relop> ::= tkLower
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_CONST_RELOP_TKGREATER :
	//<const_relop> ::= tkGreater
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_CONST_RELOP_TKLOWEREQUAL :
	//<const_relop> ::= tkLowerEqual
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_CONST_RELOP_TKGREATEREQUAL :
	//<const_relop> ::= tkGreaterEqual
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_CONST_RELOP_TKIN :
	//<const_relop> ::= tkIn
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_CONST_SIMPLE_EXPR :
	//<const_simple_expr> ::= <const_term>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_CONST_SIMPLE_EXPR2 :
	//<const_simple_expr> ::= <const_simple_expr> <const_addop> <const_term>
         
		{
			bin_expr _bin_expr=new bin_expr((expression)LRParser.GetReductionSyntaxNode(0),(expression)LRParser.GetReductionSyntaxNode(2),((op_type_node)LRParser.GetReductionSyntaxNode(1)).type);
			parsertools.create_source_context(_bin_expr,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(2));
			
			return _bin_expr;
		}

	case (int)RuleConstants.RULE_CONST_ADDOP_TKPLUS :
	//<const_addop> ::= tkPlus
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_CONST_ADDOP_TKMINUS :
	//<const_addop> ::= tkMinus
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_CONST_ADDOP_TKOR :
	//<const_addop> ::= tkOr
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_CONST_ADDOP_TKXOR :
	//<const_addop> ::= tkXor
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_AS_IS_CONSTEXPR :
	//<as_is_constexpr> ::= <const_term> <typecast_op> <simple_or_template_type_reference>
         
		{
			typecast_node _typecast_node=new typecast_node((addressed_value)LRParser.GetReductionSyntaxNode(0),(type_definition)LRParser.GetReductionSyntaxNode(2),(op_typecast)LRParser.GetReductionSyntaxNode(1));
			parsertools.create_source_context(_typecast_node,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(2));
			
								if (!(LRParser.GetReductionSyntaxNode(0) is addressed_value)) 
									errors.Add(new Errors.bad_operand_type(current_file_name,((syntax_tree_node)LRParser.GetReductionSyntaxNode(0)).source_context,_typecast_node));								
			return _typecast_node;
		}

	case (int)RuleConstants.RULE_CONST_TERM :
	//<const_term> ::= <const_factor>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_CONST_TERM2 :
	//<const_term> ::= <as_is_constexpr>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_CONST_TERM3 :
	//<const_term> ::= <const_term> <const_mulop> <const_factor>
         
		{
			bin_expr _bin_expr=new bin_expr((expression)LRParser.GetReductionSyntaxNode(0),(expression)LRParser.GetReductionSyntaxNode(2),((op_type_node)LRParser.GetReductionSyntaxNode(1)).type);
			parsertools.create_source_context(_bin_expr,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(2));
			
			return _bin_expr;
		}

	case (int)RuleConstants.RULE_CONST_MULOP_TKSTAR :
	//<const_mulop> ::= tkStar
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_CONST_MULOP_TKSLASH :
	//<const_mulop> ::= tkSlash
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_CONST_MULOP_TKDIV :
	//<const_mulop> ::= tkDiv
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_CONST_MULOP_TKMOD :
	//<const_mulop> ::= tkMod
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_CONST_MULOP_TKSHL :
	//<const_mulop> ::= tkShl
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_CONST_MULOP_TKSHR :
	//<const_mulop> ::= tkShr
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_CONST_MULOP_TKAND :
	//<const_mulop> ::= tkAnd
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_CONST_FACTOR :
	//<const_factor> ::= <const_variable>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_CONST_FACTOR2 :
	//<const_factor> ::= <const_set>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_CONST_FACTOR3 :
	//<const_factor> ::= <unsigned_number>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_CONST_FACTOR4 :
	//<const_factor> ::= <literal>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_CONST_FACTOR_TKNIL :
	//<const_factor> ::= tkNil <empty>
         
		{
			nil_const _nil_const=new nil_const();
			 parsertools.create_source_context(_nil_const,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(0));
			return _nil_const;
		}

	case (int)RuleConstants.RULE_CONST_FACTOR_TKADDRESSOF :
	//<const_factor> ::= tkAddressOf <const_factor>
         
		{
			get_address _get_address=new get_address((addressed_value)LRParser.GetReductionSyntaxNode(1));
			 parsertools.create_source_context(_get_address,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(1));
			return _get_address;
		}

	case (int)RuleConstants.RULE_CONST_FACTOR_TKROUNDOPEN_TKROUNDCLOSE :
	//<const_factor> ::= tkRoundOpen <const_expr> tkRoundClose
 bracket_expr _expr = new bracket_expr((expression)LRParser.GetReductionSyntaxNode(1)); parsertools.create_source_context(_expr,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(2)); return _expr;
	case (int)RuleConstants.RULE_CONST_FACTOR_TKNOT :
	//<const_factor> ::= tkNot <const_factor>
         
		{
			un_expr _un_expr=new un_expr((expression)LRParser.GetReductionSyntaxNode(1),((op_type_node)LRParser.GetReductionSyntaxNode(0)).type);
			parsertools.create_source_context(_un_expr,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(1));
			
			return _un_expr;
		}

	case (int)RuleConstants.RULE_CONST_FACTOR5 :
	//<const_factor> ::= <sign> <const_factor>
         
		{
			un_expr _un_expr=new un_expr((expression)LRParser.GetReductionSyntaxNode(1),((op_type_node)LRParser.GetReductionSyntaxNode(0)).type);
			parsertools.create_source_context(_un_expr,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(1));
			
			return _un_expr;
		}

	case (int)RuleConstants.RULE_CONST_FACTOR_TKDEREF :
	//<const_factor> ::= tkDeref <const_factor>
         
		{
			roof_dereference _roof_dereference=new roof_dereference();
			 
								_roof_dereference.dereferencing_value=(addressed_value)LRParser.GetReductionSyntaxNode(1);
								parsertools.create_source_context(_roof_dereference,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(1));
			return _roof_dereference;
		}

	case (int)RuleConstants.RULE_CONST_SET_TKSQUAREOPEN_TKSQUARECLOSE :
	//<const_set> ::= tkSquareOpen <const_elem_list> tkSquareClose
         
		{
			pascal_set_constant _pascal_set_constant=new pascal_set_constant(LRParser.GetReductionSyntaxNode(1) as expression_list);
			
								parsertools.create_source_context(_pascal_set_constant,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(2));
			return _pascal_set_constant;
		}

	case (int)RuleConstants.RULE_SIGN_TKPLUS :
	//<sign> ::= tkPlus
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_SIGN_TKMINUS :
	//<sign> ::= tkMinus
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_CONST_VARIABLE :
	//<const_variable> ::= <identifier>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_CONST_VARIABLE2 :
	//<const_variable> ::= <sizeof_expr>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_CONST_VARIABLE3 :
	//<const_variable> ::= <typeof_expr>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_CONST_VARIABLE4 :
	//<const_variable> ::= <const_variable> <const_variable_2>
if (LRParser.GetReductionSyntaxNode(1) is dereference) {
							  ((dereference)LRParser.GetReductionSyntaxNode(1)).dereferencing_value=(addressed_value)LRParser.GetReductionSyntaxNode(0);
							  parsertools.create_source_context(LRParser.GetReductionSyntaxNode(1),LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(1));
							}
							if (LRParser.GetReductionSyntaxNode(1) is dot_node) {
							  ((dot_node)LRParser.GetReductionSyntaxNode(1)).left=(addressed_value)LRParser.GetReductionSyntaxNode(0);
							  parsertools.create_source_context(LRParser.GetReductionSyntaxNode(1),LRParser.GetReductionSyntaxNode(0),((dot_node)LRParser.GetReductionSyntaxNode(1)).right);
							}
							return LRParser.GetReductionSyntaxNode(1);
							
	case (int)RuleConstants.RULE_CONST_VARIABLE_2_TKPOINT :
	//<const_variable_2> ::= tkPoint <identifier_or_keyword>
         
		{
			dot_node _dot_node=new dot_node(null,(addressed_value)LRParser.GetReductionSyntaxNode(1));
			
			return _dot_node;
		}

	case (int)RuleConstants.RULE_CONST_VARIABLE_2_TKDEREF :
	//<const_variable_2> ::= tkDeref <empty>
         
		{
			roof_dereference _roof_dereference=new roof_dereference();
			 parsertools.assign_source_context(_roof_dereference,LRParser.GetReductionSyntaxNode(0));
			return _roof_dereference;
		}

	case (int)RuleConstants.RULE_CONST_VARIABLE_2_TKROUNDOPEN_TKROUNDCLOSE :
	//<const_variable_2> ::= tkRoundOpen <opt_const_func_expr_list> tkRoundClose
         
		{
			method_call _method_call=new method_call((expression_list)LRParser.GetReductionSyntaxNode(1));
			 parsertools.create_source_context(_method_call,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(2));
			return _method_call;
		}

	case (int)RuleConstants.RULE_CONST_VARIABLE_2_TKSQUAREOPEN_TKSQUARECLOSE :
	//<const_variable_2> ::= tkSquareOpen <const_elem_list> tkSquareClose
         
		{
			indexer _indexer=new indexer((expression_list)LRParser.GetReductionSyntaxNode(1));
			 parsertools.create_source_context(_indexer,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(2));
			return _indexer;
		}

	case (int)RuleConstants.RULE_OPT_CONST_FUNC_EXPR_LIST :
	//<opt_const_func_expr_list> ::= <const_func_expr_list>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_OPT_CONST_FUNC_EXPR_LIST2 :
	//<opt_const_func_expr_list> ::= 
	//NONTERMINAL:<opt_const_func_expr_list> ::= 
	return null;
	//ENDNONTERMINAL
	case (int)RuleConstants.RULE_CONST_FUNC_EXPR_LIST :
	//<const_func_expr_list> ::= <const_expr> <empty>
         
		//TemplateList for expression_list (create)
		{
			expression_list _expression_list=new expression_list();
			_expression_list.source_context=((expression)LRParser.GetReductionSyntaxNode(0)).source_context;
			_expression_list.expressions.Add((expression)LRParser.GetReductionSyntaxNode(0));
			return _expression_list;
		}

	case (int)RuleConstants.RULE_CONST_FUNC_EXPR_LIST_TKCOMMA :
	//<const_func_expr_list> ::= <const_func_expr_list> tkComma <const_expr>

		//TemplateList for expression_list (add)         
		{
			expression_list _expression_list=(expression_list)LRParser.GetReductionSyntaxNode(0);
			parsertools.create_source_context(_expression_list,_expression_list,LRParser.GetReductionSyntaxNode(2));
			_expression_list.expressions.Add(LRParser.GetReductionSyntaxNode(2) as expression);
			return _expression_list;
		}

	case (int)RuleConstants.RULE_CONST_ELEM_LIST :
	//<const_elem_list> ::= <const_elem_list1>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_CONST_ELEM_LIST2 :
	//<const_elem_list> ::= 
	//NONTERMINAL:<const_elem_list> ::= 
	return null;
	//ENDNONTERMINAL
	case (int)RuleConstants.RULE_CONST_ELEM_LIST1 :
	//<const_elem_list1> ::= <const_elem> <empty>
         
		//TemplateList for expression_list (create)
		{
			expression_list _expression_list=new expression_list();
			_expression_list.source_context=((expression)LRParser.GetReductionSyntaxNode(0)).source_context;
			_expression_list.expressions.Add((expression)LRParser.GetReductionSyntaxNode(0));
			return _expression_list;
		}

	case (int)RuleConstants.RULE_CONST_ELEM_LIST1_TKCOMMA :
	//<const_elem_list1> ::= <const_elem_list1> tkComma <const_elem>

		//TemplateList for expression_list (add)         
		{
			expression_list _expression_list=(expression_list)LRParser.GetReductionSyntaxNode(0);
			parsertools.create_source_context(_expression_list,_expression_list,LRParser.GetReductionSyntaxNode(2));
			_expression_list.expressions.Add(LRParser.GetReductionSyntaxNode(2) as expression);
			return _expression_list;
		}

	case (int)RuleConstants.RULE_CONST_ELEM :
	//<const_elem> ::= <const_expr>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_CONST_ELEM_TKDOTDOT :
	//<const_elem> ::= <const_expr> tkDotDot <const_expr>
         
		{
			diapason_expr _diapason_expr=new diapason_expr((expression)LRParser.GetReductionSyntaxNode(0),(expression)LRParser.GetReductionSyntaxNode(2));
			parsertools.create_source_context(_diapason_expr,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(2));
			
			return _diapason_expr;
		}

	case (int)RuleConstants.RULE_UNSIGNED_NUMBER_TKINTEGER :
	//<unsigned_number> ::= tkInteger
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_UNSIGNED_NUMBER_TKHEX :
	//<unsigned_number> ::= tkHex
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_UNSIGNED_NUMBER_TKFLOAT :
	//<unsigned_number> ::= tkFloat
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_TYPED_CONST :
	//<typed_const> ::= <const_expr>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_TYPED_CONST2 :
	//<typed_const> ::= <array_const>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_TYPED_CONST3 :
	//<typed_const> ::= <record_const>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_ARRAY_CONST_TKROUNDOPEN_TKROUNDCLOSE :
	//<array_const> ::= tkRoundOpen <typed_const_list> tkRoundClose
         
		{
			array_const _array_const=new array_const((expression_list)LRParser.GetReductionSyntaxNode(1));
			
							parsertools.create_source_context(_array_const,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(2));
			return _array_const;
		}

	case (int)RuleConstants.RULE_ARRAY_CONST_TKROUNDOPEN_TKROUNDCLOSE2 :
	//<array_const> ::= tkRoundOpen <record_const> tkRoundClose
return LRParser.GetReductionSyntaxNode(1);
	case (int)RuleConstants.RULE_ARRAY_CONST_TKROUNDOPEN_TKROUNDCLOSE3 :
	//<array_const> ::= tkRoundOpen <array_const> tkRoundClose
return LRParser.GetReductionSyntaxNode(1);
	case (int)RuleConstants.RULE_TYPED_CONST_LIST :
	//<typed_const_list> ::= 
	//NONTERMINAL:<typed_const_list> ::= 
	return null;
	//ENDNONTERMINAL
	case (int)RuleConstants.RULE_TYPED_CONST_LIST2 :
	//<typed_const_list> ::= <typed_const_or_new> <empty>
         
		{
			expression_list _expression_list=new expression_list();
			
							_expression_list.expressions.Add((expression)LRParser.GetReductionSyntaxNode(0));
							//_expression_list.expressions.Add((expression)LRParser.GetReductionSyntaxNode(2));
							//parsertools.create_source_context(_expression_list,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(2));
							
			return _expression_list;
		}

	case (int)RuleConstants.RULE_TYPED_CONST_LIST_TKCOMMA :
	//<typed_const_list> ::= <typed_const_list> tkComma <typed_const_or_new>
         
		{
			expression_list _expression_list=(expression_list)LRParser.GetReductionSyntaxNode(0);
							parsertools.create_source_context(_expression_list,_expression_list,LRParser.GetReductionSyntaxNode(2));
							if (_expression_list == null)
							{
								_expression_list = new expression_list();
								errors.Add(new Errors.PABCNETUnexpectedToken(current_file_name, StringResources.Get("TKIDENTIFIER"),((syntax_tree_node)LRParser.GetReductionSyntaxNode(1)).source_context,_expression_list));
							}
							_expression_list.expressions.Add((expression)LRParser.GetReductionSyntaxNode(2));
			return _expression_list;
		}

	case (int)RuleConstants.RULE_RECORD_CONST_TKROUNDOPEN_TKROUNDCLOSE :
	//<record_const> ::= tkRoundOpen <const_field_list> tkRoundClose
parsertools.create_source_context(LRParser.GetReductionSyntaxNode(1),LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(2));return LRParser.GetReductionSyntaxNode(1);
	case (int)RuleConstants.RULE_CONST_FIELD_LIST :
	//<const_field_list> ::= <const_field_list_1>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_CONST_FIELD_LIST_TKSEMICOLON :
	//<const_field_list> ::= <const_field_list_1> tkSemiColon
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_CONST_FIELD_LIST_1 :
	//<const_field_list_1> ::= <const_field> <empty>
         
		//TemplateList for record_const (create)
		{
			record_const _record_const=new record_const();
			_record_const.source_context=((record_const_definition)LRParser.GetReductionSyntaxNode(0)).source_context;
			_record_const.rec_consts.Add((record_const_definition)LRParser.GetReductionSyntaxNode(0));
			return _record_const;
		}

	case (int)RuleConstants.RULE_CONST_FIELD_LIST_1_TKSEMICOLON :
	//<const_field_list_1> ::= <const_field_list_1> tkSemiColon <const_field>

		//TemplateList for record_const (add)         
		{
			record_const _record_const=(record_const)LRParser.GetReductionSyntaxNode(0);
			parsertools.create_source_context(_record_const,_record_const,LRParser.GetReductionSyntaxNode(2));
			_record_const.rec_consts.Add(LRParser.GetReductionSyntaxNode(2) as record_const_definition);
			return _record_const;
		}

	case (int)RuleConstants.RULE_CONST_FIELD_TKCOLON :
	//<const_field> ::= <const_field_name> tkColon <typed_const>
         
		{
			record_const_definition _record_const_definition=new record_const_definition((ident)LRParser.GetReductionSyntaxNode(0),(expression)LRParser.GetReductionSyntaxNode(2));
			parsertools.create_source_context(_record_const_definition,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(2));
			
			return _record_const_definition;
		}

	case (int)RuleConstants.RULE_CONST_FIELD_NAME :
	//<const_field_name> ::= <identifier>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_TYPE_DECL :
	//<type_decl> ::= <opt_attribute_declarations> <simple_type_decl>
         
		{
			declaration _declaration;
			 _declaration=(LRParser.GetReductionSyntaxNode(1) as declaration); 
			_declaration.attributes = LRParser.GetReductionSyntaxNode(0) as attribute_list;
		
			return _declaration;
		}

	case (int)RuleConstants.RULE_OPT_ATTRIBUTE_DECLARATIONS :
	//<opt_attribute_declarations> ::= <attribute_declarations> <empty>
 return LRParser.GetReductionSyntaxNode(0); 
	case (int)RuleConstants.RULE_OPT_ATTRIBUTE_DECLARATIONS2 :
	//<opt_attribute_declarations> ::= <empty>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_ATTRIBUTE_DECLARATIONS :
	//<attribute_declarations> ::= <attribute_declaration> <empty>
         
		{
			attribute_list _attribute_list=new attribute_list();
			
	 _attribute_list.attributes.Add((simple_attribute_list)LRParser.GetReductionSyntaxNode(0));
	
			return _attribute_list;
		}

	case (int)RuleConstants.RULE_ATTRIBUTE_DECLARATIONS2 :
	//<attribute_declarations> ::= <attribute_declarations> <attribute_declaration>
         
		{
			attribute_list _attribute_list=(attribute_list)LRParser.GetReductionSyntaxNode(0);
							_attribute_list.attributes.Add((simple_attribute_list)LRParser.GetReductionSyntaxNode(1));
							parsertools.create_source_context(_attribute_list,_attribute_list,LRParser.GetReductionSyntaxNode(1));
			return _attribute_list;
		}

	case (int)RuleConstants.RULE_ATTRIBUTE_DECLARATION_TKSQUAREOPEN_TKSQUARECLOSE :
	//<attribute_declaration> ::= tkSquareOpen <one_or_some_attribute> tkSquareClose
return LRParser.GetReductionSyntaxNode(1);
	case (int)RuleConstants.RULE_ONE_OR_SOME_ATTRIBUTE :
	//<one_or_some_attribute> ::= <one_attribute> <empty>
         
		//TemplateList for simple_attribute_list (create)
		{
			simple_attribute_list _simple_attribute_list=new simple_attribute_list();
			_simple_attribute_list.source_context=((attribute)LRParser.GetReductionSyntaxNode(0)).source_context;
			_simple_attribute_list.attributes.Add((attribute)LRParser.GetReductionSyntaxNode(0));
			return _simple_attribute_list;
		}

	case (int)RuleConstants.RULE_ONE_OR_SOME_ATTRIBUTE_TKCOMMA :
	//<one_or_some_attribute> ::= <one_or_some_attribute> tkComma <one_attribute>

		//TemplateList for simple_attribute_list (add)         
		{
			simple_attribute_list _simple_attribute_list=(simple_attribute_list)LRParser.GetReductionSyntaxNode(0);
			parsertools.create_source_context(_simple_attribute_list,_simple_attribute_list,LRParser.GetReductionSyntaxNode(2));
			_simple_attribute_list.attributes.Add(LRParser.GetReductionSyntaxNode(2) as attribute);
			return _simple_attribute_list;
		}

	case (int)RuleConstants.RULE_ONE_ATTRIBUTE :
	//<one_attribute> ::= <attribute_variable>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_ONE_ATTRIBUTE_TKCOLON :
	//<one_attribute> ::= <identifier> tkColon <attribute_variable>
         
		{
			attribute _attribute;
			 _attribute=LRParser.GetReductionSyntaxNode(2) as attribute;
			_attribute.qualifier = LRParser.GetReductionSyntaxNode(0) as ident;
			
			return _attribute;
		}

	case (int)RuleConstants.RULE_SIMPLE_TYPE_DECL_TKEQUAL_TKSEMICOLON :
	//<simple_type_decl> ::= <type_decl_identifier> tkEqual <type_decl_type> tkSemiColon
         
		{
			type_declaration _type_declaration=new type_declaration((ident)LRParser.GetReductionSyntaxNode(0),(type_definition)LRParser.GetReductionSyntaxNode(2));
			parsertools.create_source_context(_type_declaration,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(2));
			
			return _type_declaration;
		}

	case (int)RuleConstants.RULE_SIMPLE_TYPE_DECL_TKSEMICOLON :
	//<simple_type_decl> ::= <template_identifier_with_equal> <type_decl_type> tkSemiColon
         
		{
			type_declaration _type_declaration=new type_declaration((ident)LRParser.GetReductionSyntaxNode(0),(type_definition)LRParser.GetReductionSyntaxNode(1));
			parsertools.create_source_context(_type_declaration,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(1));
			
			return _type_declaration;
		}

	case (int)RuleConstants.RULE_TYPE_DECL_IDENTIFIER :
	//<type_decl_identifier> ::= <identifier>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_TYPE_DECL_IDENTIFIER2 :
	//<type_decl_identifier> ::= <identifier> <template_arguments>
         
		{
			template_type_name _template_type_name=new template_type_name((ident_list)LRParser.GetReductionSyntaxNode(1));
			
								_template_type_name.name=((ident)LRParser.GetReductionSyntaxNode(0)).name;
								parsertools.create_source_context(_template_type_name,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(1));
								
			return _template_type_name;
		}

	case (int)RuleConstants.RULE_TEMPLATE_IDENTIFIER_WITH_EQUAL_TKLOWER_TKGREATEREQUAL :
	//<template_identifier_with_equal> ::= <identifier> tkLower <ident_list> tkGreaterEqual
         
		{
			template_type_name _template_type_name=new template_type_name((ident_list)LRParser.GetReductionSyntaxNode(2));
			
								_template_type_name.name=((ident)LRParser.GetReductionSyntaxNode(0)).name;
								parsertools.create_source_context(_template_type_name,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(3));
								
			return _template_type_name;
		}

	case (int)RuleConstants.RULE_TYPE_DECL_TYPE :
	//<type_decl_type> ::= <type_ref>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_TYPE_DECL_TYPE_TKTYPE :
	//<type_decl_type> ::= tkType <type_ref>
parsertools.create_source_context(LRParser.GetReductionSyntaxNode(1),LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(1));return LRParser.GetReductionSyntaxNode(1);
	case (int)RuleConstants.RULE_TYPE_DECL_TYPE2 :
	//<type_decl_type> ::= <object_type>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_TYPE_REF :
	//<type_ref> ::= <simple_type>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_TYPE_REF2 :
	//<type_ref> ::= <string_type>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_TYPE_REF3 :
	//<type_ref> ::= <pointer_type>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_TYPE_REF4 :
	//<type_ref> ::= <structured_type>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_TYPE_REF5 :
	//<type_ref> ::= <procedural_type>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_TYPE_REF6 :
	//<type_ref> ::= <template_type>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_TEMPLATE_TYPE :
	//<template_type> ::= <simple_type_identifier> <template_type_params>
         
		{
			template_type_reference _template_type_reference=new template_type_reference((named_type_reference)LRParser.GetReductionSyntaxNode(0),(template_param_list)LRParser.GetReductionSyntaxNode(1));
			parsertools.create_source_context(_template_type_reference,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(1));
			
			return _template_type_reference;
		}

	case (int)RuleConstants.RULE_TEMPLATE_TYPE_PARAMS_TKLOWER_TKGREATER :
	//<template_type_params> ::= tkLower <template_param_list> tkGreater
parsertools.create_source_context(LRParser.GetReductionSyntaxNode(1),LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(2));return LRParser.GetReductionSyntaxNode(1);
	case (int)RuleConstants.RULE_TEMPLATE_PARAM_LIST :
	//<template_param_list> ::= <template_param> <empty>
         
		//TemplateList for template_param_list (create)
		{
			template_param_list _template_param_list=new template_param_list();
			_template_param_list.source_context=((type_definition)LRParser.GetReductionSyntaxNode(0)).source_context;
			_template_param_list.params_list.Add((type_definition)LRParser.GetReductionSyntaxNode(0));
			return _template_param_list;
		}

	case (int)RuleConstants.RULE_TEMPLATE_PARAM_LIST_TKCOMMA :
	//<template_param_list> ::= <template_param_list> tkComma <template_param>

		//TemplateList for template_param_list (add)         
		{
			template_param_list _template_param_list=(template_param_list)LRParser.GetReductionSyntaxNode(0);
			parsertools.create_source_context(_template_param_list,_template_param_list,LRParser.GetReductionSyntaxNode(2));
			_template_param_list.params_list.Add(LRParser.GetReductionSyntaxNode(2) as type_definition);
			return _template_param_list;
		}

	case (int)RuleConstants.RULE_TEMPLATE_PARAM :
	//<template_param> ::= <simple_type_identifier>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_TEMPLATE_PARAM2 :
	//<template_param> ::= <template_type>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_SIMPLE_TYPE :
	//<simple_type> ::= <simple_type_identifier>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_SIMPLE_TYPE_TKDOTDOT :
	//<simple_type> ::= <range_expr> tkDotDot <range_expr>
         
		{
			diapason _diapason=new diapason((expression)LRParser.GetReductionSyntaxNode(0),(expression)LRParser.GetReductionSyntaxNode(2));
			parsertools.create_source_context(_diapason,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(2));
			
			return _diapason;
		}

	case (int)RuleConstants.RULE_SIMPLE_TYPE_TKROUNDOPEN_TKROUNDCLOSE :
	//<simple_type> ::= tkRoundOpen <enumeration_id_list> tkRoundClose
         
		{
			enum_type_definition _enum_type_definition=new enum_type_definition((enumerator_list)LRParser.GetReductionSyntaxNode(1));
			 parsertools.create_source_context(_enum_type_definition,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(2));
			return _enum_type_definition;
		}

	case (int)RuleConstants.RULE_RANGE_EXPR :
	//<range_expr> ::= <range_term>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_RANGE_EXPR2 :
	//<range_expr> ::= <range_expr> <const_addop> <range_term>
         
		{
			bin_expr _bin_expr=new bin_expr(LRParser.GetReductionSyntaxNode(0) as expression,LRParser.GetReductionSyntaxNode(2) as expression,((op_type_node)LRParser.GetReductionSyntaxNode(1)).type);
			parsertools.create_source_context(_bin_expr,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(2));
			
			return _bin_expr;
		}

	case (int)RuleConstants.RULE_RANGE_TERM :
	//<range_term> ::= <range_factor>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_RANGE_TERM2 :
	//<range_term> ::= <range_term> <const_mulop> <range_factor>
         
		{
			bin_expr _bin_expr=new bin_expr(LRParser.GetReductionSyntaxNode(0) as expression,LRParser.GetReductionSyntaxNode(2) as expression,((op_type_node)LRParser.GetReductionSyntaxNode(1)).type);
			parsertools.create_source_context(_bin_expr,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(2));
			
			return _bin_expr;
		}

	case (int)RuleConstants.RULE_RANGE_FACTOR :
	//<range_factor> ::= <simple_type_identifier> <empty>
 if(((named_type_reference)LRParser.GetReductionSyntaxNode(0)).names.Count>0)
								return ((named_type_reference)LRParser.GetReductionSyntaxNode(0)).names[0];
						 	   else
							        return null;
							
	case (int)RuleConstants.RULE_RANGE_FACTOR2 :
	//<range_factor> ::= <unsigned_number>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_RANGE_FACTOR3 :
	//<range_factor> ::= <sign> <range_factor>
         
		{
			un_expr _un_expr=new un_expr((expression)LRParser.GetReductionSyntaxNode(1),((op_type_node)LRParser.GetReductionSyntaxNode(0)).type);
			parsertools.create_source_context(_un_expr,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(1));
			
			return _un_expr;
		}

	case (int)RuleConstants.RULE_RANGE_FACTOR4 :
	//<range_factor> ::= <literal>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_RANGE_FACTOR_TKROUNDOPEN_TKROUNDCLOSE :
	//<range_factor> ::= <range_factor> tkRoundOpen <const_elem_list> tkRoundClose
         
		{
			method_call _method_call=new method_call((expression_list)LRParser.GetReductionSyntaxNode(2));
			
							_method_call.dereferencing_value=(addressed_value)LRParser.GetReductionSyntaxNode(0);
							parsertools.create_source_context(_method_call,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(3));
							
			return _method_call;
		}

	case (int)RuleConstants.RULE_RANGE_FACTOR_TKROUNDOPEN_TKROUNDCLOSE2 :
	//<range_factor> ::= tkRoundOpen <const_expr> tkRoundClose
 return LRParser.GetReductionSyntaxNode(1);
	case (int)RuleConstants.RULE_RANGE_METHODNAME :
	//<range_methodname> ::= <identifier>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_RANGE_METHODNAME_TKPOINT :
	//<range_methodname> ::= <identifier> tkPoint <identifier_or_keyword>
         
		{
			dot_node _dot_node=new dot_node((ident)LRParser.GetReductionSyntaxNode(0),(ident)LRParser.GetReductionSyntaxNode(2));
			parsertools.create_source_context(_dot_node,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(2));
			
			return _dot_node;
		}

	case (int)RuleConstants.RULE_SIMPLE_TYPE_IDENTIFIER :
	//<simple_type_identifier> ::= <identifier> <empty>
         
		//TemplateList for named_type_reference (create)
		{
			named_type_reference _named_type_reference=new named_type_reference();
			_named_type_reference.source_context=((ident)LRParser.GetReductionSyntaxNode(0)).source_context;
			_named_type_reference.names.Add((ident)LRParser.GetReductionSyntaxNode(0));
			return _named_type_reference;
		}

	case (int)RuleConstants.RULE_SIMPLE_TYPE_IDENTIFIER_TKPOINT :
	//<simple_type_identifier> ::= <simple_type_identifier> tkPoint <identifier_or_keyword>

		//TemplateList for named_type_reference (add)         
		{
			named_type_reference _named_type_reference=(named_type_reference)LRParser.GetReductionSyntaxNode(0);
			parsertools.create_source_context(_named_type_reference,_named_type_reference,LRParser.GetReductionSyntaxNode(2));
			_named_type_reference.names.Add(LRParser.GetReductionSyntaxNode(2) as ident);
			return _named_type_reference;
		}

	case (int)RuleConstants.RULE_ENUMERATION_ID_LIST_TKCOMMA :
	//<enumeration_id_list> ::= <enumeration_id> tkComma <enumeration_id>
         
		{
			enumerator_list _enumerator_list=new enumerator_list();
			
                                                        _enumerator_list.enumerators.Add((enumerator)LRParser.GetReductionSyntaxNode(0));
                                                        _enumerator_list.enumerators.Add((enumerator)LRParser.GetReductionSyntaxNode(2));
							parsertools.create_source_context(_enumerator_list,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(2));
							
			return _enumerator_list;
		}

	case (int)RuleConstants.RULE_ENUMERATION_ID_LIST_TKCOMMA2 :
	//<enumeration_id_list> ::= <enumeration_id_list> tkComma <enumeration_id>
         
		{
			enumerator_list _enumerator_list=(enumerator_list)LRParser.GetReductionSyntaxNode(0);
                                                        _enumerator_list.enumerators.Add((enumerator)LRParser.GetReductionSyntaxNode(2));
							parsertools.create_source_context(_enumerator_list,_enumerator_list,LRParser.GetReductionSyntaxNode(2));
							
			return _enumerator_list;
		}

	case (int)RuleConstants.RULE_ENUMERATION_ID :
	//<enumeration_id> ::= <identifier> <empty>
         
		{
			enumerator _enumerator=new enumerator(LRParser.GetReductionSyntaxNode(0) as ident,null);
			parsertools.create_source_context(_enumerator,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(0));
			
			return _enumerator;
		}

	case (int)RuleConstants.RULE_ENUMERATION_ID_TKEQUAL :
	//<enumeration_id> ::= <identifier> tkEqual <expr>
         
		{
			enumerator _enumerator=new enumerator(LRParser.GetReductionSyntaxNode(0) as ident,LRParser.GetReductionSyntaxNode(2) as expression);
			parsertools.create_source_context(_enumerator,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(2));
			
			return _enumerator;
		}

	case (int)RuleConstants.RULE_POINTER_TYPE_TKDEREF :
	//<pointer_type> ::= tkDeref <fptype>
         
		{
			ref_type _ref_type=new ref_type((type_definition)LRParser.GetReductionSyntaxNode(1));
			 parsertools.create_source_context(_ref_type,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(1));
			return _ref_type;
		}

	case (int)RuleConstants.RULE_STRUCTURED_TYPE :
	//<structured_type> ::= <unpacked_structured_type>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_STRUCTURED_TYPE_TKPACKED :
	//<structured_type> ::= tkPacked <unpacked_structured_type>
 {errors.Add(new nonterminal_token_return_null(current_file_name,parsertools.GetTokenSourceContext(),(syntax_tree_node)prev_node,"<structured_type> ::= tkPacked <unpacked_structured_type>"));}return null;
	case (int)RuleConstants.RULE_UNPACKED_STRUCTURED_TYPE :
	//<unpacked_structured_type> ::= <array_type>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_UNPACKED_STRUCTURED_TYPE2 :
	//<unpacked_structured_type> ::= <new_record_type>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_UNPACKED_STRUCTURED_TYPE3 :
	//<unpacked_structured_type> ::= <set_type>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_UNPACKED_STRUCTURED_TYPE4 :
	//<unpacked_structured_type> ::= <file_type>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_ARRAY_TYPE_TKARRAY_TKSQUAREOPEN_TKSQUARECLOSE_TKOF :
	//<array_type> ::= tkArray tkSquareOpen <simple_type_list> tkSquareClose tkOf <type_ref>
         
		{
			array_type _array_type=new array_type((indexers_types)LRParser.GetReductionSyntaxNode(2),(type_definition)LRParser.GetReductionSyntaxNode(5));
			
										parsertools.create_source_context(LRParser.GetReductionSyntaxNode(2),LRParser.GetReductionSyntaxNode(1),LRParser.GetReductionSyntaxNode(3));
										parsertools.create_source_context(_array_type,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(5));
										
			return _array_type;
		}

	case (int)RuleConstants.RULE_ARRAY_TYPE :
	//<array_type> ::= <unsized_array_type>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_UNSIZED_ARRAY_TYPE_TKARRAY_TKOF :
	//<unsized_array_type> ::= tkArray tkOf <type_ref>
         
		{
			array_type _array_type=new array_type(null,(type_definition)LRParser.GetReductionSyntaxNode(2));
			
										parsertools.create_source_context(_array_type,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(2));
										
			return _array_type;
		}

	case (int)RuleConstants.RULE_SIMPLE_TYPE_LIST :
	//<simple_type_list> ::= <simple_type_or_empty> <empty>
         
		{
			indexers_types _indexers_types=new indexers_types();
			
							_indexers_types.indexers.Add((type_definition)LRParser.GetReductionSyntaxNode(0));
							
			return _indexers_types;
		}

	case (int)RuleConstants.RULE_SIMPLE_TYPE_LIST_TKCOMMA :
	//<simple_type_list> ::= <simple_type_list> tkComma <simple_type_or_empty>
         
		{
			indexers_types _indexers_types=(indexers_types)LRParser.GetReductionSyntaxNode(0);
							_indexers_types.indexers.Add((type_definition)LRParser.GetReductionSyntaxNode(2));
							
			return _indexers_types;
		}

	case (int)RuleConstants.RULE_SIMPLE_TYPE_OR_EMPTY :
	//<simple_type_or_empty> ::= <simple_type>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_SIMPLE_TYPE_OR_EMPTY2 :
	//<simple_type_or_empty> ::= 
	//NONTERMINAL:<simple_type_or_empty> ::= 
	return null;
	//ENDNONTERMINAL
	case (int)RuleConstants.RULE_RECORD_TYPE_TKRECORD_TKEND :
	//<record_type> ::= tkRecord <field_list> tkEnd
         
		{
			record_type _record_type=new record_type((record_type_parts)LRParser.GetReductionSyntaxNode(1),null);
			 parsertools.create_source_context(_record_type,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(2));
			return _record_type;
		}

	case (int)RuleConstants.RULE_RECORD_TYPE_TKRECORD_TKEND2 :
	//<record_type> ::= tkRecord tkEnd
         
		{
			record_type _record_type=new record_type(null,null);
			 parsertools.create_source_context(_record_type,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(1));
			return _record_type;
		}

	case (int)RuleConstants.RULE_FIELD_LIST :
	//<field_list> ::= <fixed_part> <empty>
         
		{
			record_type_parts _record_type_parts=new record_type_parts((var_def_list)LRParser.GetReductionSyntaxNode(0),null);
			 parsertools.create_source_context(_record_type_parts,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(0));
			return _record_type_parts;
		}

	case (int)RuleConstants.RULE_FIELD_LIST2 :
	//<field_list> ::= <variant_part> <empty>
         
		{
			record_type_parts _record_type_parts=new record_type_parts(null,(variant_record_type)LRParser.GetReductionSyntaxNode(0));
			 parsertools.create_source_context(_record_type_parts,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(0));
			return _record_type_parts;
		}

	case (int)RuleConstants.RULE_FIELD_LIST_TKSEMICOLON :
	//<field_list> ::= <fixed_part_2> tkSemiColon <variant_part>
         
		{
			record_type_parts _record_type_parts=new record_type_parts((var_def_list)LRParser.GetReductionSyntaxNode(0),(variant_record_type)LRParser.GetReductionSyntaxNode(2));
			parsertools.create_source_context(_record_type_parts,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(2));
			
			return _record_type_parts;
		}

	case (int)RuleConstants.RULE_FIXED_PART :
	//<fixed_part> ::= <fixed_part_2>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_FIXED_PART_TKSEMICOLON :
	//<fixed_part> ::= <fixed_part_2> tkSemiColon
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_FIXED_PART_2 :
	//<fixed_part_2> ::= <record_section> <empty>
         
		//TemplateList for var_def_list (create)
		{
			var_def_list _var_def_list=new var_def_list();
			_var_def_list.source_context=((var_def_statement)LRParser.GetReductionSyntaxNode(0)).source_context;
			_var_def_list.vars.Add((var_def_statement)LRParser.GetReductionSyntaxNode(0));
			return _var_def_list;
		}

	case (int)RuleConstants.RULE_FIXED_PART_2_TKSEMICOLON :
	//<fixed_part_2> ::= <fixed_part_2> tkSemiColon <record_section>

		//TemplateList for var_def_list (add)         
		{
			var_def_list _var_def_list=(var_def_list)LRParser.GetReductionSyntaxNode(0);
			parsertools.create_source_context(_var_def_list,_var_def_list,LRParser.GetReductionSyntaxNode(2));
			_var_def_list.vars.Add(LRParser.GetReductionSyntaxNode(2) as var_def_statement);
			return _var_def_list;
		}

	case (int)RuleConstants.RULE_RECORD_SECTION_TKCOLON :
	//<record_section> ::= <record_section_id_list> tkColon <type_ref>
         
		{
			var_def_statement _var_def_statement=new var_def_statement((ident_list)LRParser.GetReductionSyntaxNode(0),(type_definition)LRParser.GetReductionSyntaxNode(2),null,definition_attribute.None,false);
			 
							parsertools.create_source_context(_var_def_statement,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(2));
							
			return _var_def_statement;
		}

	case (int)RuleConstants.RULE_RECORD_SECTION_ID_LIST :
	//<record_section_id_list> ::= <record_section_id> <empty>
         
		//TemplateList for ident_list (create)
		{
			ident_list _ident_list=new ident_list();
			_ident_list.source_context=((ident)LRParser.GetReductionSyntaxNode(0)).source_context;
			_ident_list.idents.Add((ident)LRParser.GetReductionSyntaxNode(0));
			return _ident_list;
		}

	case (int)RuleConstants.RULE_RECORD_SECTION_ID_LIST_TKCOMMA :
	//<record_section_id_list> ::= <record_section_id_list> tkComma <record_section_id>

		//TemplateList for ident_list (add)         
		{
			ident_list _ident_list=(ident_list)LRParser.GetReductionSyntaxNode(0);
			parsertools.create_source_context(_ident_list,_ident_list,LRParser.GetReductionSyntaxNode(2));
			_ident_list.idents.Add(LRParser.GetReductionSyntaxNode(2) as ident);
			return _ident_list;
		}

	case (int)RuleConstants.RULE_RECORD_SECTION_ID :
	//<record_section_id> ::= <identifier>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_VARIANT_PART_TKCASE_TKOF :
	//<variant_part> ::= tkCase <tag_field> tkOf <variant_list>
         
		{
			variant_record_type _variant_record_type;
			 _variant_record_type=(variant_record_type)LRParser.GetReductionSyntaxNode(1);
							_variant_record_type.vars=LRParser.GetReductionSyntaxNode(3) as variant_types;
							parsertools.create_source_context(_variant_record_type,LRParser.GetReductionSyntaxNode(0),parsertools.sc_not_null(LRParser.GetReductionSyntaxNode(3),LRParser.GetReductionSyntaxNode(2)));	
							
			return _variant_record_type;
		}

	case (int)RuleConstants.RULE_TAG_FIELD :
	//<tag_field> ::= <tag_field_name> <empty>
         
		{
			variant_record_type _variant_record_type=new variant_record_type((ident)LRParser.GetReductionSyntaxNode(0),null,null);
			
			return _variant_record_type;
		}

	case (int)RuleConstants.RULE_TAG_FIELD_TKCOLON :
	//<tag_field> ::= <tag_field_name> tkColon <tag_field_typename>
         
		{
			variant_record_type _variant_record_type=new variant_record_type((ident)LRParser.GetReductionSyntaxNode(0),(type_definition)LRParser.GetReductionSyntaxNode(2),null);
			
			return _variant_record_type;
		}

	case (int)RuleConstants.RULE_TAG_FIELD_NAME :
	//<tag_field_name> ::= <identifier>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_TAG_FIELD_TYPENAME :
	//<tag_field_typename> ::= <fptype>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_VARIANT_LIST :
	//<variant_list> ::= <variant_list_2>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_VARIANT_LIST_TKSEMICOLON :
	//<variant_list> ::= <variant_list_2> tkSemiColon
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_VARIANT_LIST_2 :
	//<variant_list_2> ::= <variant> <empty>
         
		//TemplateList for variant_types (create)
		{
			variant_types _variant_types=new variant_types();
			_variant_types.source_context=((variant_type)LRParser.GetReductionSyntaxNode(0)).source_context;
			_variant_types.vars.Add((variant_type)LRParser.GetReductionSyntaxNode(0));
			return _variant_types;
		}

	case (int)RuleConstants.RULE_VARIANT_LIST_2_TKSEMICOLON :
	//<variant_list_2> ::= <variant_list_2> tkSemiColon <variant>

		//TemplateList for variant_types (add)         
		{
			variant_types _variant_types=(variant_types)LRParser.GetReductionSyntaxNode(0);
			parsertools.create_source_context(_variant_types,_variant_types,LRParser.GetReductionSyntaxNode(2));
			_variant_types.vars.Add(LRParser.GetReductionSyntaxNode(2) as variant_type);
			return _variant_types;
		}

	case (int)RuleConstants.RULE_VARIANT_TKCOLON_TKROUNDOPEN_TKROUNDCLOSE :
	//<variant> ::= <case_tag_list> tkColon tkRoundOpen <variant_field_list> tkRoundClose
         
		{
			variant_type _variant_type=new variant_type((expression_list)LRParser.GetReductionSyntaxNode(0),(record_type_parts)LRParser.GetReductionSyntaxNode(3));
			
							parsertools.create_source_context(_variant_type,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(4));								
							
			return _variant_type;
		}

	case (int)RuleConstants.RULE_VARIANT_FIELD_LIST :
	//<variant_field_list> ::= 
	//NONTERMINAL:<variant_field_list> ::= 
	return null;
	//ENDNONTERMINAL
	case (int)RuleConstants.RULE_VARIANT_FIELD_LIST2 :
	//<variant_field_list> ::= <field_list>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_CASE_TAG_LIST :
	//<case_tag_list> ::= <const_expr_list>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_CONST_EXPR_LIST :
	//<const_expr_list> ::= <const_expr> <empty>
         
		//TemplateList for expression_list (create)
		{
			expression_list _expression_list=new expression_list();
			_expression_list.source_context=((expression)LRParser.GetReductionSyntaxNode(0)).source_context;
			_expression_list.expressions.Add((expression)LRParser.GetReductionSyntaxNode(0));
			return _expression_list;
		}

	case (int)RuleConstants.RULE_CONST_EXPR_LIST_TKCOMMA :
	//<const_expr_list> ::= <const_expr_list> tkComma <const_expr>

		//TemplateList for expression_list (add)         
		{
			expression_list _expression_list=(expression_list)LRParser.GetReductionSyntaxNode(0);
			parsertools.create_source_context(_expression_list,_expression_list,LRParser.GetReductionSyntaxNode(2));
			_expression_list.expressions.Add(LRParser.GetReductionSyntaxNode(2) as expression);
			return _expression_list;
		}

	case (int)RuleConstants.RULE_SET_TYPE_TKSET_TKOF :
	//<set_type> ::= tkSet tkOf <simple_type>
         
		{
			set_type_definition _set_type_definition=new set_type_definition((type_definition)LRParser.GetReductionSyntaxNode(2));
			
							parsertools.create_source_context(_set_type_definition,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(2));
			return _set_type_definition;
		}

	case (int)RuleConstants.RULE_FILE_TYPE_TKFILE_TKOF :
	//<file_type> ::= tkFile tkOf <type_ref>
         
		{
			file_type _file_type=new file_type((type_definition)LRParser.GetReductionSyntaxNode(2));
			 parsertools.create_source_context(_file_type,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(2));
			return _file_type;
		}

	case (int)RuleConstants.RULE_FILE_TYPE_TKFILE :
	//<file_type> ::= tkFile <empty>
         
		{
			file_type _file_type=new file_type();
			 parsertools.assign_source_context(_file_type,LRParser.GetReductionSyntaxNode(0));
			return _file_type;
		}

	case (int)RuleConstants.RULE_STRING_TYPE_TKIDENTIFIER_TKSQUAREOPEN_TKSQUARECLOSE :
	//<string_type> ::= tkIdentifier tkSquareOpen <const_expr> tkSquareClose
         
		{
			string_num_definition _string_num_definition=new string_num_definition((expression)LRParser.GetReductionSyntaxNode(2),(ident)LRParser.GetReductionSyntaxNode(0));
			
								parsertools.create_source_context(_string_num_definition,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(3));
			return _string_num_definition;
		}

	case (int)RuleConstants.RULE_PROCEDURAL_TYPE :
	//<procedural_type> ::= <procedural_type_kind>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_PROCEDURAL_TYPE_KIND :
	//<procedural_type_kind> ::= <procedural_type_decl>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_PROCEDURAL_TYPE_DECL_TKPROCEDURE :
	//<procedural_type_decl> ::= tkProcedure <fp_list> <maybe_error>
         
		{
			procedure_header _procedure_header=new procedure_header((formal_parameters)LRParser.GetReductionSyntaxNode(1),null,null,false,false,null,null);
			 
								object rt=LRParser.GetReductionSyntaxNode(0);
								if (LRParser.GetReductionSyntaxNode(1)!=null) rt=LRParser.GetReductionSyntaxNode(1);
								parsertools.create_source_context(_procedure_header,LRParser.GetReductionSyntaxNode(0),rt);
								if(LRParser.GetReductionSyntaxNode(2)!=null)
									(LRParser.GetReductionSyntaxNode(2) as SyntaxError).bad_node=_procedure_header;
								
			return _procedure_header;
		}

	case (int)RuleConstants.RULE_PROCEDURAL_TYPE_DECL_TKFUNCTION_TKCOLON :
	//<procedural_type_decl> ::= tkFunction <fp_list> tkColon <fptype>
         
		{
			function_header _function_header=new function_header();
			 
								if (LRParser.GetReductionSyntaxNode(1)!=null) 
		                                                  _function_header.parameters=(formal_parameters)LRParser.GetReductionSyntaxNode(1);
								if (LRParser.GetReductionSyntaxNode(3)!=null) 
								  _function_header.return_type=(type_definition)LRParser.GetReductionSyntaxNode(3);
								_function_header.of_object=false;
								_function_header.class_keyword=false;
								parsertools.create_source_context(_function_header,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(3));
								
			return _function_header;
		}

	case (int)RuleConstants.RULE_MAYBE_ERROR_TKCOLON :
	//<maybe_error> ::= tkColon <fptype>
 Errors.unexpected_return_value er=new Errors.unexpected_return_value(current_file_name,((syntax_tree_node)LRParser.GetReductionSyntaxNode(1)).source_context,null); errors.Add(er);return er;
	case (int)RuleConstants.RULE_MAYBE_ERROR :
	//<maybe_error> ::= 
	//NONTERMINAL:<maybe_error> ::= 
	return null;
	//ENDNONTERMINAL
	case (int)RuleConstants.RULE_OBJECT_TYPE :
	//<object_type> ::= <new_object_type>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_OOT_PRIVAT_LIST :
	//<oot_privat_list> ::= 
	//NONTERMINAL:<oot_privat_list> ::= 
	return null;
	//ENDNONTERMINAL
	case (int)RuleConstants.RULE_OOT_PRIVAT_LIST_TKPRIVATE :
	//<oot_privat_list> ::= tkPrivate <oot_component_list>
 {errors.Add(new nonterminal_token_return_null(current_file_name,parsertools.GetTokenSourceContext(),(syntax_tree_node)prev_node,"<oot_privat_list> ::= tkPrivate <oot_component_list>"));}return null;
	case (int)RuleConstants.RULE_OOT_COMPONENT_LIST :
	//<oot_component_list> ::= 
	//NONTERMINAL:<oot_component_list> ::= 
	return null;
	//ENDNONTERMINAL
	case (int)RuleConstants.RULE_OOT_COMPONENT_LIST2 :
	//<oot_component_list> ::= <oot_field_list>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_OOT_COMPONENT_LIST3 :
	//<oot_component_list> ::= <oot_field_list> <oot_method_list>
 {errors.Add(new nonterminal_token_return_null(current_file_name,parsertools.GetTokenSourceContext(),(syntax_tree_node)prev_node,"<oot_component_list> ::= <oot_field_list> <oot_method_list>"));}return null;
	case (int)RuleConstants.RULE_OOT_COMPONENT_LIST4 :
	//<oot_component_list> ::= <oot_method_list>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_OOT_SUCCESSOR_TKROUNDOPEN_TKROUNDCLOSE :
	//<oot_successor> ::= tkRoundOpen <oot_typeidentifier> tkRoundClose
 {errors.Add(new nonterminal_token_return_null(current_file_name,parsertools.GetTokenSourceContext(),(syntax_tree_node)prev_node,"<oot_successor> ::= tkRoundOpen <oot_typeidentifier> tkRoundClose"));}return null;
	case (int)RuleConstants.RULE_OOT_TYPEIDENTIFIER :
	//<oot_typeidentifier> ::= <identifier>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_OOT_FIELD_LIST :
	//<oot_field_list> ::= <oot_field>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_OOT_FIELD_LIST2 :
	//<oot_field_list> ::= <oot_field_list> <oot_field>
 {errors.Add(new nonterminal_token_return_null(current_file_name,parsertools.GetTokenSourceContext(),(syntax_tree_node)prev_node,"<oot_field_list> ::= <oot_field_list> <oot_field>"));}return null;
	case (int)RuleConstants.RULE_OOT_FIELD_TKCOLON_TKSEMICOLON :
	//<oot_field> ::= <oot_id_list> tkColon <type_ref> tkSemiColon
 {errors.Add(new nonterminal_token_return_null(current_file_name,parsertools.GetTokenSourceContext(),(syntax_tree_node)prev_node,"<oot_field> ::= <oot_id_list> tkColon <type_ref> tkSemiColon"));}return null;
	case (int)RuleConstants.RULE_OOT_ID_LIST :
	//<oot_id_list> ::= <oot_field_identifier>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_OOT_ID_LIST_TKCOMMA :
	//<oot_id_list> ::= <oot_id_list> tkComma <oot_field_identifier>
 {errors.Add(new nonterminal_token_return_null(current_file_name,parsertools.GetTokenSourceContext(),(syntax_tree_node)prev_node,"<oot_id_list> ::= <oot_id_list> tkComma <oot_field_identifier>"));}return null;
	case (int)RuleConstants.RULE_OOT_FIELD_IDENTIFIER :
	//<oot_field_identifier> ::= <identifier>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_OOT_METHOD_LIST :
	//<oot_method_list> ::= <oot_method>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_OOT_METHOD_LIST2 :
	//<oot_method_list> ::= <oot_method_list> <oot_method>
 {errors.Add(new nonterminal_token_return_null(current_file_name,parsertools.GetTokenSourceContext(),(syntax_tree_node)prev_node,"<oot_method_list> ::= <oot_method_list> <oot_method>"));}return null;
	case (int)RuleConstants.RULE_OOT_METHOD :
	//<oot_method> ::= <oot_method_head>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_OOT_METHOD_HEAD :
	//<oot_method_head> ::= <proc_heading>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_OOT_METHOD_HEAD2 :
	//<oot_method_head> ::= <func_heading>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_OOT_METHOD_HEAD3 :
	//<oot_method_head> ::= <oot_constructor_head>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_OOT_METHOD_HEAD4 :
	//<oot_method_head> ::= <oot_destructor_head>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_OOT_CONSTRUCTOR_HEAD_TKCONSTRUCTOR :
	//<oot_constructor_head> ::= tkConstructor <proc_name> <fp_list> <opt_meth_modificators>
 {errors.Add(new nonterminal_token_return_null(current_file_name,parsertools.GetTokenSourceContext(),(syntax_tree_node)prev_node,"<oot_constructor_head> ::= tkConstructor <proc_name> <fp_list> <opt_meth_modificators>"));}return null;
	case (int)RuleConstants.RULE_OOT_DESTRUCTOR_HEAD_TKDESTRUCTOR :
	//<oot_destructor_head> ::= tkDestructor <proc_name> <fp_list> <opt_meth_modificators>
 {errors.Add(new nonterminal_token_return_null(current_file_name,parsertools.GetTokenSourceContext(),(syntax_tree_node)prev_node,"<oot_destructor_head> ::= tkDestructor <proc_name> <fp_list> <opt_meth_modificators>"));}return null;
	case (int)RuleConstants.RULE_NEW_OBJECT_TYPE :
	//<new_object_type> ::= <not_object_type>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_NOT_OBJECT_TYPE :
	//<not_object_type> ::= <class_attributes> <class_or_interface_keyword> <opt_base_classes> <opt_where_section> <opt_not_component_list_seq_end>
         
		{
			class_definition _class_definition=new class_definition(LRParser.GetReductionSyntaxNode(2) as named_type_reference_list,LRParser.GetReductionSyntaxNode(4) as class_body,class_keyword.Class,null,LRParser.GetReductionSyntaxNode(3) as where_definition_list, class_attribute.None,false);
			 
									string kw=(LRParser.GetReductionSyntaxNode(1) as token_info).text.ToLower();
									if(LRParser.GetReductionSyntaxNode(0)!=null)
										_class_definition.attribute=(class_attribute)((LRParser.GetReductionSyntaxNode(0) as token_taginfo).tag);
									if (kw=="record") 
										_class_definition.keyword=class_keyword.Record;
									else
									if (kw=="interface") 
										_class_definition.keyword=class_keyword.Interface;
									else
									if (kw=="i<>") 
										_class_definition.keyword=class_keyword.TemplateInterface;
									else
									if (kw=="r<>") 
										_class_definition.keyword=class_keyword.TemplateRecord;
									else
									if (kw=="c<>") 
										_class_definition.keyword=class_keyword.TemplateClass;
									if (_class_definition.body!=null && _class_definition.body.class_def_blocks!=null && 
										_class_definition.body.class_def_blocks.Count>0 && _class_definition.body.class_def_blocks[0].access_mod==null)
									{
										if(_class_definition.keyword==class_keyword.Class)
		                        						_class_definition.body.class_def_blocks[0].access_mod = new access_modifer_node(access_modifer.internal_modifer);
										else
											_class_definition.body.class_def_blocks[0].access_mod = new access_modifer_node(access_modifer.none);
									}	
									parsertools.create_source_context(_class_definition,parsertools.sc_not_null(LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(1)),parsertools.sc_not_null(LRParser.GetReductionSyntaxNode(4),LRParser.GetReductionSyntaxNode(3),LRParser.GetReductionSyntaxNode(2),LRParser.GetReductionSyntaxNode(1),LRParser.GetReductionSyntaxNode(0)));
			return _class_definition;
		}

	case (int)RuleConstants.RULE_NEW_RECORD_TYPE_TKEND :
	//<new_record_type> ::= <record_keyword> <opt_base_classes> <opt_where_section> <not_component_list_seq> tkEnd
         
		{
			class_definition _class_definition=new class_definition(LRParser.GetReductionSyntaxNode(1) as named_type_reference_list,LRParser.GetReductionSyntaxNode(3) as class_body,class_keyword.Record,null,LRParser.GetReductionSyntaxNode(2) as where_definition_list, class_attribute.None,false);
			 
									if (_class_definition.body!=null && _class_definition.body.class_def_blocks!=null && 
										_class_definition.body.class_def_blocks.Count>0 && _class_definition.body.class_def_blocks[0].access_mod==null)
									{
		                        					_class_definition.body.class_def_blocks[0].access_mod = new access_modifer_node(access_modifer.public_modifer);
									}	
									parsertools.create_source_context(_class_definition,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(4));
			return _class_definition;
		}

	case (int)RuleConstants.RULE_CLASS_ATTRIBUTES_TKFINAL :
	//<class_attributes> ::= tkFinal
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_CLASS_ATTRIBUTES :
	//<class_attributes> ::= 
	//NONTERMINAL:<class_attributes> ::= 
	return null;
	//ENDNONTERMINAL
	case (int)RuleConstants.RULE_CLASS_OR_INTERFACE_KEYWORD_TKCLASS :
	//<class_or_interface_keyword> ::= tkClass
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_CLASS_OR_INTERFACE_KEYWORD_TKINTERFACE :
	//<class_or_interface_keyword> ::= tkInterface
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_CLASS_OR_INTERFACE_KEYWORD_TKTEMPLATE :
	//<class_or_interface_keyword> ::= tkTemplate
         
		{
			token_info _token_info=(token_info)LRParser.GetReductionSyntaxNode(0);_token_info.text="c<>";
			return _token_info;
		}

	case (int)RuleConstants.RULE_CLASS_OR_INTERFACE_KEYWORD_TKTEMPLATE_TKCLASS :
	//<class_or_interface_keyword> ::= tkTemplate tkClass
         
		{
			token_info _token_info=(token_info)LRParser.GetReductionSyntaxNode(0);_token_info.text="c<>";parsertools.create_source_context(_token_info,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(1));
			return _token_info;
		}

	case (int)RuleConstants.RULE_CLASS_OR_INTERFACE_KEYWORD_TKTEMPLATE_TKRECORD :
	//<class_or_interface_keyword> ::= tkTemplate tkRecord
         
		{
			token_info _token_info=(token_info)LRParser.GetReductionSyntaxNode(0);_token_info.text="r<>";parsertools.create_source_context(_token_info,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(1));
			return _token_info;
		}

	case (int)RuleConstants.RULE_CLASS_OR_INTERFACE_KEYWORD_TKTEMPLATE_TKINTERFACE :
	//<class_or_interface_keyword> ::= tkTemplate tkInterface
         
		{
			token_info _token_info=(token_info)LRParser.GetReductionSyntaxNode(0);_token_info.text="i<>";parsertools.create_source_context(_token_info,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(1));
			return _token_info;
		}

	case (int)RuleConstants.RULE_RECORD_KEYWORD_TKRECORD :
	//<record_keyword> ::= tkRecord
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_OPT_NOT_COMPONENT_LIST_SEQ_END :
	//<opt_not_component_list_seq_end> ::= 
	//NONTERMINAL:<opt_not_component_list_seq_end> ::= 
	return null;
	//ENDNONTERMINAL
	case (int)RuleConstants.RULE_OPT_NOT_COMPONENT_LIST_SEQ_END_TKEND :
	//<opt_not_component_list_seq_end> ::= <not_component_list_seq> tkEnd
parsertools.create_source_context(LRParser.GetReductionSyntaxNode(0),parsertools.sc_not_null(LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(1)),LRParser.GetReductionSyntaxNode(1));return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_OPT_BASE_CLASSES :
	//<opt_base_classes> ::= 
	//NONTERMINAL:<opt_base_classes> ::= 
	return null;
	//ENDNONTERMINAL
	case (int)RuleConstants.RULE_OPT_BASE_CLASSES_TKROUNDOPEN_TKROUNDCLOSE :
	//<opt_base_classes> ::= tkRoundOpen <base_classes_names_list> tkRoundClose
return LRParser.GetReductionSyntaxNode(1);
	case (int)RuleConstants.RULE_BASE_CLASSES_NAMES_LIST :
	//<base_classes_names_list> ::= <base_class_name> <empty>
         
		//TemplateList for named_type_reference_list (create)
		{
			named_type_reference_list _named_type_reference_list=new named_type_reference_list();
			_named_type_reference_list.source_context=((named_type_reference)LRParser.GetReductionSyntaxNode(0)).source_context;
			_named_type_reference_list.types.Add((named_type_reference)LRParser.GetReductionSyntaxNode(0));
			return _named_type_reference_list;
		}

	case (int)RuleConstants.RULE_BASE_CLASSES_NAMES_LIST_TKCOMMA :
	//<base_classes_names_list> ::= <base_classes_names_list> tkComma <base_class_name>

		//TemplateList for named_type_reference_list (add)         
		{
			named_type_reference_list _named_type_reference_list=(named_type_reference_list)LRParser.GetReductionSyntaxNode(0);
			parsertools.create_source_context(_named_type_reference_list,_named_type_reference_list,LRParser.GetReductionSyntaxNode(2));
			_named_type_reference_list.types.Add(LRParser.GetReductionSyntaxNode(2) as named_type_reference);
			return _named_type_reference_list;
		}

	case (int)RuleConstants.RULE_BASE_CLASS_NAME :
	//<base_class_name> ::= <simple_type_identifier>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_BASE_CLASS_NAME2 :
	//<base_class_name> ::= <template_type>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_OPT_TEMPLATE_ARGUMENTS :
	//<opt_template_arguments> ::= 
	//NONTERMINAL:<opt_template_arguments> ::= 
	return null;
	//ENDNONTERMINAL
	case (int)RuleConstants.RULE_OPT_TEMPLATE_ARGUMENTS2 :
	//<opt_template_arguments> ::= <template_arguments>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_TEMPLATE_ARGUMENTS_TKLOWER_TKGREATER :
	//<template_arguments> ::= tkLower <ident_list> tkGreater
parsertools.create_source_context(LRParser.GetReductionSyntaxNode(1),LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(2));return LRParser.GetReductionSyntaxNode(1);
	case (int)RuleConstants.RULE_OPT_WHERE_SECTION :
	//<opt_where_section> ::= 
	//NONTERMINAL:<opt_where_section> ::= 
	return null;
	//ENDNONTERMINAL
	case (int)RuleConstants.RULE_OPT_WHERE_SECTION2 :
	//<opt_where_section> ::= <where_part_list>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_WHERE_PART_LIST :
	//<where_part_list> ::= <where_part> <empty>
         
		{
			where_definition_list _where_definition_list=new where_definition_list();
			
				    		parsertools.create_source_context(_where_definition_list,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(0));
						_where_definition_list.defs.Add((where_definition)LRParser.GetReductionSyntaxNode(0));
			return _where_definition_list;
		}

	case (int)RuleConstants.RULE_WHERE_PART_LIST2 :
	//<where_part_list> ::= <where_part_list> <where_part>
         
		{
			where_definition_list _where_definition_list=(where_definition_list)LRParser.GetReductionSyntaxNode(0);
						parsertools.create_source_context(_where_definition_list,_where_definition_list,LRParser.GetReductionSyntaxNode(1));
						_where_definition_list.defs.Add((where_definition)LRParser.GetReductionSyntaxNode(1));
			return _where_definition_list;
		}

	case (int)RuleConstants.RULE_WHERE_PART_TKWHERE_TKCOLON_TKSEMICOLON :
	//<where_part> ::= tkWhere <ident_list> tkColon <type_ref_and_secific_list> tkSemiColon
         
		{
			where_definition _where_definition=new where_definition((ident_list)LRParser.GetReductionSyntaxNode(1),(type_definition_list)LRParser.GetReductionSyntaxNode(3));
			
											parsertools.create_source_context(_where_definition,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(4));
			return _where_definition;
		}

	case (int)RuleConstants.RULE_TYPE_REF_AND_SECIFIC_LIST :
	//<type_ref_and_secific_list> ::= <type_ref_or_secific> <empty>
         
		//TemplateList for type_definition_list (create)
		{
			type_definition_list _type_definition_list=new type_definition_list();
			_type_definition_list.source_context=((type_definition)LRParser.GetReductionSyntaxNode(0)).source_context;
			_type_definition_list.defs.Add((type_definition)LRParser.GetReductionSyntaxNode(0));
			return _type_definition_list;
		}

	case (int)RuleConstants.RULE_TYPE_REF_AND_SECIFIC_LIST_TKCOMMA :
	//<type_ref_and_secific_list> ::= <type_ref_and_secific_list> tkComma <type_ref_or_secific>

		//TemplateList for type_definition_list (add)         
		{
			type_definition_list _type_definition_list=(type_definition_list)LRParser.GetReductionSyntaxNode(0);
			parsertools.create_source_context(_type_definition_list,_type_definition_list,LRParser.GetReductionSyntaxNode(2));
			_type_definition_list.defs.Add(LRParser.GetReductionSyntaxNode(2) as type_definition);
			return _type_definition_list;
		}

	case (int)RuleConstants.RULE_TYPE_REF_OR_SECIFIC :
	//<type_ref_or_secific> ::= <type_ref>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_TYPE_REF_OR_SECIFIC_TKCLASS :
	//<type_ref_or_secific> ::= tkClass
         
		{
			declaration_specificator _declaration_specificator=new declaration_specificator(DeclarationSpecificator.WhereDefClass, (LRParser.GetReductionSyntaxNode(0) as token_info).text);
			
					parsertools.assign_source_context(_declaration_specificator,LRParser.GetReductionSyntaxNode(0));
			return _declaration_specificator;
		}

	case (int)RuleConstants.RULE_TYPE_REF_OR_SECIFIC_TKRECORD :
	//<type_ref_or_secific> ::= tkRecord
         
		{
			declaration_specificator _declaration_specificator=new declaration_specificator(DeclarationSpecificator.WhereDefValueType, (LRParser.GetReductionSyntaxNode(0) as token_info).text);
			
					parsertools.assign_source_context(_declaration_specificator,LRParser.GetReductionSyntaxNode(0));
			return _declaration_specificator;
		}

	case (int)RuleConstants.RULE_TYPE_REF_OR_SECIFIC_TKCONSTRUCTOR :
	//<type_ref_or_secific> ::= tkConstructor
         
		{
			declaration_specificator _declaration_specificator=new declaration_specificator(DeclarationSpecificator.WhereDefConstructor, (LRParser.GetReductionSyntaxNode(0) as token_info).text);
			
					parsertools.assign_source_context(_declaration_specificator,LRParser.GetReductionSyntaxNode(0));
			return _declaration_specificator;
		}

	case (int)RuleConstants.RULE_RECORD_COMPONENT_LIST :
	//<record_component_list> ::= <not_component_list> <empty>
         
		{
			class_body _class_body=new class_body();
			
					if (LRParser.GetReductionSyntaxNode(0)!=null) {
		                        access_modifer_node acn=new access_modifer_node(access_modifer.public_modifer);
					((class_members)LRParser.GetReductionSyntaxNode(0)).access_mod = acn;
					_class_body.class_def_blocks.Add((class_members)LRParser.GetReductionSyntaxNode(0));
					parsertools.assign_source_context(_class_body,LRParser.GetReductionSyntaxNode(0));							
					}
					
			return _class_body;
		}

	case (int)RuleConstants.RULE_NOT_COMPONENT_LIST_SEQ :
	//<not_component_list_seq> ::= <not_component_list> <empty>
         
		{
			class_body _class_body=new class_body();
			
					if (LRParser.GetReductionSyntaxNode(0)!=null) {
					_class_body.class_def_blocks.Add((class_members)LRParser.GetReductionSyntaxNode(0));
					parsertools.assign_source_context(_class_body,LRParser.GetReductionSyntaxNode(0));							
					}
					
			return _class_body;
		}

	case (int)RuleConstants.RULE_NOT_COMPONENT_LIST_SEQ2 :
	//<not_component_list_seq> ::= <not_component_list_seq> <ot_visibility_specifier> <not_component_list>
         
		{
			class_body _class_body=(class_body)LRParser.GetReductionSyntaxNode(0);
					class_members cl=(class_members)LRParser.GetReductionSyntaxNode(2);
					if (cl==null) 
					{	
						cl=new class_members();
						parsertools.create_source_context(cl,LRParser.GetReductionSyntaxNode(1),LRParser.GetReductionSyntaxNode(1));
					}
					cl.access_mod=(access_modifer_node)LRParser.GetReductionSyntaxNode(1);
					_class_body.class_def_blocks.Add(cl);
					parsertools.create_source_context(_class_body,parsertools.sc_not_null(LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(1)),parsertools.sc_not_null(cl,LRParser.GetReductionSyntaxNode(1)));							
					
			return _class_body;
		}

	case (int)RuleConstants.RULE_OT_VISIBILITY_SPECIFIER_TKINTERNAL :
	//<ot_visibility_specifier> ::= tkInternal
         
		{
			access_modifer_node _access_modifer_node=new access_modifer_node(access_modifer.internal_modifer);
			 parsertools.assign_source_context(_access_modifer_node,LRParser.GetReductionSyntaxNode(0));
			return _access_modifer_node;
		}

	case (int)RuleConstants.RULE_OT_VISIBILITY_SPECIFIER_TKPUBLIC :
	//<ot_visibility_specifier> ::= tkPublic
         
		{
			access_modifer_node _access_modifer_node=new access_modifer_node(access_modifer.public_modifer);
			 parsertools.assign_source_context(_access_modifer_node,LRParser.GetReductionSyntaxNode(0));
			return _access_modifer_node;
		}

	case (int)RuleConstants.RULE_OT_VISIBILITY_SPECIFIER_TKPROTECTED :
	//<ot_visibility_specifier> ::= tkProtected
         
		{
			access_modifer_node _access_modifer_node=new access_modifer_node(access_modifer.protected_modifer);
			 parsertools.assign_source_context(_access_modifer_node,LRParser.GetReductionSyntaxNode(0));
			return _access_modifer_node;
		}

	case (int)RuleConstants.RULE_OT_VISIBILITY_SPECIFIER_TKPRIVATE :
	//<ot_visibility_specifier> ::= tkPrivate
         
		{
			access_modifer_node _access_modifer_node=new access_modifer_node(access_modifer.private_modifer);
			 parsertools.assign_source_context(_access_modifer_node,LRParser.GetReductionSyntaxNode(0));
			return _access_modifer_node;
		}

	case (int)RuleConstants.RULE_NOT_OBJECT_TYPE_IDENTIFIER_LIST :
	//<not_object_type_identifier_list> ::= <simple_type_identifier> <empty>
         
		//TemplateList for named_type_reference_list (create)
		{
			named_type_reference_list _named_type_reference_list=new named_type_reference_list();
			_named_type_reference_list.source_context=((named_type_reference)LRParser.GetReductionSyntaxNode(0)).source_context;
			_named_type_reference_list.types.Add((named_type_reference)LRParser.GetReductionSyntaxNode(0));
			return _named_type_reference_list;
		}

	case (int)RuleConstants.RULE_NOT_OBJECT_TYPE_IDENTIFIER_LIST_TKCOMMA :
	//<not_object_type_identifier_list> ::= <not_object_type_identifier_list> tkComma <simple_type_identifier>

		//TemplateList for named_type_reference_list (add)         
		{
			named_type_reference_list _named_type_reference_list=(named_type_reference_list)LRParser.GetReductionSyntaxNode(0);
			parsertools.create_source_context(_named_type_reference_list,_named_type_reference_list,LRParser.GetReductionSyntaxNode(2));
			_named_type_reference_list.types.Add(LRParser.GetReductionSyntaxNode(2) as named_type_reference);
			return _named_type_reference_list;
		}

	case (int)RuleConstants.RULE_IDENT_LIST :
	//<ident_list> ::= <identifier> <empty>
         
		//TemplateList for ident_list (create)
		{
			ident_list _ident_list=new ident_list();
			_ident_list.source_context=((ident)LRParser.GetReductionSyntaxNode(0)).source_context;
			_ident_list.idents.Add((ident)LRParser.GetReductionSyntaxNode(0));
			return _ident_list;
		}

	case (int)RuleConstants.RULE_IDENT_LIST_TKCOMMA :
	//<ident_list> ::= <ident_list> tkComma <identifier>

		//TemplateList for ident_list (add)         
		{
			ident_list _ident_list=(ident_list)LRParser.GetReductionSyntaxNode(0);
			parsertools.create_source_context(_ident_list,_ident_list,LRParser.GetReductionSyntaxNode(2));
			_ident_list.idents.Add(LRParser.GetReductionSyntaxNode(2) as ident);
			return _ident_list;
		}

	case (int)RuleConstants.RULE_NOT_COMPONENT_LIST :
	//<not_component_list> ::= <not_guid>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_NOT_COMPONENT_LIST2 :
	//<not_component_list> ::= <not_guid> <not_component_list_1> <opt_semicolon>
return LRParser.GetReductionSyntaxNode(1);
	case (int)RuleConstants.RULE_NOT_COMPONENT_LIST3 :
	//<not_component_list> ::= <not_guid> <not_component_list_2>
return LRParser.GetReductionSyntaxNode(1);
	case (int)RuleConstants.RULE_NOT_COMPONENT_LIST_TKSEMICOLON :
	//<not_component_list> ::= <not_guid> <not_component_list_1> tkSemiColon <not_component_list_2>
         
		{
			class_members _class_members;
			 _class_members=(class_members)LRParser.GetReductionSyntaxNode(1);
							for (int i=0;i<((class_members)LRParser.GetReductionSyntaxNode(3)).members.Count;i++)
								_class_members.members.Add(((class_members)LRParser.GetReductionSyntaxNode(3)).members[i]);
							parsertools.create_source_context(_class_members,LRParser.GetReductionSyntaxNode(1),LRParser.GetReductionSyntaxNode(3));							
							
			return _class_members;
		}

	case (int)RuleConstants.RULE_OPT_SEMICOLON :
	//<opt_semicolon> ::= 
	//NONTERMINAL:<opt_semicolon> ::= 
	return null;
	//ENDNONTERMINAL
	case (int)RuleConstants.RULE_OPT_SEMICOLON_TKSEMICOLON :
	//<opt_semicolon> ::= tkSemiColon
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_NOT_GUID :
	//<not_guid> ::= 
	//NONTERMINAL:<not_guid> ::= 
	return null;
	//ENDNONTERMINAL
	case (int)RuleConstants.RULE_NOT_COMPONENT_LIST_1 :
	//<not_component_list_1> ::= <filed_or_const_definition> <empty>
         
		{
			class_members _class_members=new class_members();
			
							_class_members.members.Add((declaration)LRParser.GetReductionSyntaxNode(0));
							parsertools.assign_source_context(_class_members,LRParser.GetReductionSyntaxNode(0));							
							
			return _class_members;
		}

	case (int)RuleConstants.RULE_NOT_COMPONENT_LIST_1_TKSEMICOLON :
	//<not_component_list_1> ::= <not_component_list_1> tkSemiColon <filed_or_const_definition_or_am>
         
		{
			class_members _class_members=(class_members)LRParser.GetReductionSyntaxNode(0);
							if(LRParser.GetReductionSyntaxNode(2) is declaration)
								_class_members.members.Add((declaration)LRParser.GetReductionSyntaxNode(2));
							else
								(_class_members.members[_class_members.members.Count-1] as var_def_statement).var_attr=definition_attribute.Static;
							parsertools.create_source_context(_class_members,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(2));							
							
			return _class_members;
		}

	case (int)RuleConstants.RULE_NOT_COMPONENT_LIST_2 :
	//<not_component_list_2> ::= <not_method_definition> <empty>
         
		{
			class_members _class_members=new class_members();
			
							_class_members.members.Add((declaration)LRParser.GetReductionSyntaxNode(0));
							parsertools.assign_source_context(_class_members,LRParser.GetReductionSyntaxNode(0));							
							
			return _class_members;
		}

	case (int)RuleConstants.RULE_NOT_COMPONENT_LIST_22 :
	//<not_component_list_2> ::= <not_property_definition> <empty>
         
		{
			class_members _class_members=new class_members();
			
							_class_members.members.Add((declaration)LRParser.GetReductionSyntaxNode(0));
							parsertools.assign_source_context(_class_members,LRParser.GetReductionSyntaxNode(0));							
							
			return _class_members;
		}

	case (int)RuleConstants.RULE_NOT_COMPONENT_LIST_23 :
	//<not_component_list_2> ::= <not_component_list_2> <not_method_definition>
         
		{
			class_members _class_members=(class_members)LRParser.GetReductionSyntaxNode(0);
							_class_members.members.Add((declaration)LRParser.GetReductionSyntaxNode(1));
							parsertools.create_source_context(_class_members,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(1));							
							
			return _class_members;
		}

	case (int)RuleConstants.RULE_NOT_COMPONENT_LIST_24 :
	//<not_component_list_2> ::= <not_component_list_2> <not_property_definition>
         
		{
			class_members _class_members=(class_members)LRParser.GetReductionSyntaxNode(0);
							_class_members.members.Add((declaration)LRParser.GetReductionSyntaxNode(1));
							parsertools.create_source_context(_class_members,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(1));							
							
			return _class_members;
		}

	case (int)RuleConstants.RULE_FILED_OR_CONST_DEFINITION :
	//<filed_or_const_definition> ::= <opt_attribute_declarations> <simple_filed_or_const_definition>
         
		{
			declaration _declaration;
			 _declaration=LRParser.GetReductionSyntaxNode(1) as declaration;
			_declaration.attributes = LRParser.GetReductionSyntaxNode(0) as attribute_list;
		
			return _declaration;
		}

	case (int)RuleConstants.RULE_SIMPLE_FILED_OR_CONST_DEFINITION_TKCONST :
	//<simple_filed_or_const_definition> ::= tkConst <only_const_decl>
 parsertools.create_source_context(LRParser.GetReductionSyntaxNode(1),LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(1)); return LRParser.GetReductionSyntaxNode(1);
	case (int)RuleConstants.RULE_SIMPLE_FILED_OR_CONST_DEFINITION :
	//<simple_filed_or_const_definition> ::= <not_field_definition>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_SIMPLE_FILED_OR_CONST_DEFINITION_TKCLASS :
	//<simple_filed_or_const_definition> ::= tkClass <not_field_definition>
         
		{
			var_def_statement _var_def_statement=(var_def_statement)LRParser.GetReductionSyntaxNode(1);
							_var_def_statement.var_attr = definition_attribute.Static;
							parsertools.create_source_context(_var_def_statement,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(1));
							
			return _var_def_statement;
		}

	case (int)RuleConstants.RULE_FILED_OR_CONST_DEFINITION_OR_AM :
	//<filed_or_const_definition_or_am> ::= <filed_or_const_definition>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_FILED_OR_CONST_DEFINITION_OR_AM2 :
	//<filed_or_const_definition_or_am> ::= <field_access_modifier>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_NOT_FIELD_DEFINITION :
	//<not_field_definition> ::= <var_decl_part>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_NOT_FIELD_DEFINITION_TKEVENT_TKCOLON :
	//<not_field_definition> ::= tkEvent <var_name_list> tkColon <type_ref>
         
		{
			var_def_statement _var_def_statement=new var_def_statement((ident_list)LRParser.GetReductionSyntaxNode(1),(type_definition)LRParser.GetReductionSyntaxNode(3),null,definition_attribute.None,true);
			
							parsertools.create_source_context(_var_def_statement,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(3));
							
			return _var_def_statement;
		}

	case (int)RuleConstants.RULE_FIELD_ACCESS_MODIFIER_TKSTATIC :
	//<field_access_modifier> ::= tkStatic
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_NOT_METHOD_DEFINITION :
	//<not_method_definition> ::= <opt_attribute_declarations> <not_method_heading>
         
		{
			declaration _declaration;
			 _declaration=(LRParser.GetReductionSyntaxNode(1) as declaration);
			if (_declaration != null)
			_declaration.attributes = LRParser.GetReductionSyntaxNode(0) as attribute_list; 
		
			return _declaration;
		}

	case (int)RuleConstants.RULE_NOT_METHOD_DEFINITION2 :
	//<not_method_definition> ::= <opt_attribute_declarations> <abc_method_decl>
         
		{
			procedure_definition _procedure_definition;
			 _procedure_definition=(LRParser.GetReductionSyntaxNode(1) as procedure_definition);
			if (_procedure_definition != null && _procedure_definition.proc_header != null)
			_procedure_definition.proc_header.attributes = LRParser.GetReductionSyntaxNode(0) as attribute_list; 
	 
			return _procedure_definition;
		}

	case (int)RuleConstants.RULE_ABC_METHOD_DECL :
	//<abc_method_decl> ::= <abc_proc_decl>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_ABC_METHOD_DECL2 :
	//<abc_method_decl> ::= <abc_func_decl>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_ABC_METHOD_DECL3 :
	//<abc_method_decl> ::= <abc_constructor_decl>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_ABC_METHOD_DECL4 :
	//<abc_method_decl> ::= <abc_destructor_decl>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_NOT_METHOD_HEADING_TKCLASS :
	//<not_method_heading> ::= tkClass <not_procfunc_heading>
 ((procedure_header)LRParser.GetReductionSyntaxNode(1)).class_keyword=true;return LRParser.GetReductionSyntaxNode(1);
	case (int)RuleConstants.RULE_NOT_METHOD_HEADING :
	//<not_method_heading> ::= <not_procfunc_heading>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_NOT_METHOD_HEADING2 :
	//<not_method_heading> ::= <not_constructor_heading>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_NOT_METHOD_HEADING3 :
	//<not_method_heading> ::= <not_destructor_heading>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_NOT_PROCFUNC_HEADING :
	//<not_procfunc_heading> ::= <not_procfunc_heading_variants> <empty>
 ((procedure_header)LRParser.GetReductionSyntaxNode(0)).name.explicit_interface_name=((procedure_header)LRParser.GetReductionSyntaxNode(0)).name.class_name; 
							((procedure_header)LRParser.GetReductionSyntaxNode(0)).name.class_name=null;
							return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_NOT_PROCFUNC_HEADING_VARIANTS :
	//<not_procfunc_heading_variants> ::= <proc_heading>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_NOT_PROCFUNC_HEADING_VARIANTS2 :
	//<not_procfunc_heading_variants> ::= <func_heading>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_OPTIONAL_QUALIFIED_IDENTIFIER :
	//<optional_qualified_identifier> ::= <qualified_identifier>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_OPTIONAL_QUALIFIED_IDENTIFIER2 :
	//<optional_qualified_identifier> ::= 
	//NONTERMINAL:<optional_qualified_identifier> ::= 
	return null;
	//ENDNONTERMINAL
	case (int)RuleConstants.RULE_NOT_CONSTRUCTOR_HEADING :
	//<not_constructor_heading> ::= <not_constructor_heading_object>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_NOT_CONSTRUCTOR_HEADING_TKCLASS :
	//<not_constructor_heading> ::= tkClass <not_constructor_heading_object>
 ((procedure_header)LRParser.GetReductionSyntaxNode(1)).class_keyword=true;return LRParser.GetReductionSyntaxNode(1);
	case (int)RuleConstants.RULE_OPT_PROC_NAME :
	//<opt_proc_name> ::= <proc_name>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_OPT_PROC_NAME2 :
	//<opt_proc_name> ::= 
	//NONTERMINAL:<opt_proc_name> ::= 
	return null;
	//ENDNONTERMINAL
	case (int)RuleConstants.RULE_NOT_CONSTRUCTOR_HEADING_OBJECT_TKCONSTRUCTOR :
	//<not_constructor_heading_object> ::= tkConstructor <opt_proc_name> <fp_list> <opt_meth_modificators>
         
		{
			constructor _constructor=new constructor();
			 
								object rt=LRParser.GetReductionSyntaxNode(1);
								_constructor.name=LRParser.GetReductionSyntaxNode(1) as method_name;
								if (LRParser.GetReductionSyntaxNode(2)!=null) {
								  rt=LRParser.GetReductionSyntaxNode(2);
		                                                  _constructor.parameters=(formal_parameters)LRParser.GetReductionSyntaxNode(2);
								}
								if (LRParser.GetReductionSyntaxNode(3)!=null) {
								  rt=LRParser.GetReductionSyntaxNode(3);
								  if (((procedure_attributes_list)LRParser.GetReductionSyntaxNode(3)).proc_attributes.Count>0) 
									_constructor.proc_attributes=(procedure_attributes_list)LRParser.GetReductionSyntaxNode(3);
								}
								parsertools.create_source_context(_constructor,LRParser.GetReductionSyntaxNode(0),rt);
								
			return _constructor;
		}

	case (int)RuleConstants.RULE_NOT_DESTRUCTOR_HEADING_TKDESTRUCTOR :
	//<not_destructor_heading> ::= tkDestructor <opt_proc_name> <fp_list> <opt_meth_modificators>
         
		{
			destructor _destructor=new destructor();
			 
								object rt=LRParser.GetReductionSyntaxNode(1);
								_destructor.name=LRParser.GetReductionSyntaxNode(1) as method_name;
								if (LRParser.GetReductionSyntaxNode(2)!=null) {
								  rt=LRParser.GetReductionSyntaxNode(2);
		                                                  _destructor.parameters=(formal_parameters)LRParser.GetReductionSyntaxNode(2);
								}
								if (LRParser.GetReductionSyntaxNode(3)!=null) {
								  rt=LRParser.GetReductionSyntaxNode(3);
								  if (((procedure_attributes_list)LRParser.GetReductionSyntaxNode(3)).proc_attributes.Count>0) 
									_destructor.proc_attributes=(procedure_attributes_list)LRParser.GetReductionSyntaxNode(3);
								}
								parsertools.create_source_context(_destructor,LRParser.GetReductionSyntaxNode(0),rt);
								
			return _destructor;
		}

	case (int)RuleConstants.RULE_QUALIFIED_IDENTIFIER :
	//<qualified_identifier> ::= <identifier> <empty>
         
		{
			method_name _method_name=new method_name(null,null,(ident)LRParser.GetReductionSyntaxNode(0),null);
			parsertools.create_source_context(_method_name,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(0));
			
			return _method_name;
		}

	case (int)RuleConstants.RULE_QUALIFIED_IDENTIFIER2 :
	//<qualified_identifier> ::= <visibility_specifier> <empty>
         
		{
			method_name _method_name=new method_name(null,null,(ident)LRParser.GetReductionSyntaxNode(0),null);
			parsertools.create_source_context(_method_name,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(0));
			
			return _method_name;
		}

	case (int)RuleConstants.RULE_QUALIFIED_IDENTIFIER_TKPOINT :
	//<qualified_identifier> ::= <qualified_identifier> tkPoint <identifier>
{
								method_name mn=(method_name)LRParser.GetReductionSyntaxNode(0);
								mn.class_name=mn.meth_name;
								mn.meth_name=(ident)LRParser.GetReductionSyntaxNode(2);
								parsertools.create_source_context(LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(2));
								return LRParser.GetReductionSyntaxNode(0);
								}
	case (int)RuleConstants.RULE_QUALIFIED_IDENTIFIER_TKPOINT2 :
	//<qualified_identifier> ::= <qualified_identifier> tkPoint <visibility_specifier>
{
								method_name mn=(method_name)LRParser.GetReductionSyntaxNode(0);
								mn.class_name=mn.meth_name;
								mn.meth_name=(ident)LRParser.GetReductionSyntaxNode(2);
								parsertools.create_source_context(LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(2));
								return LRParser.GetReductionSyntaxNode(0);
								}
	case (int)RuleConstants.RULE_NOT_PROPERTY_DEFINITION :
	//<not_property_definition> ::= <opt_attribute_declarations> <simple_not_property_definition>
         
		{
			declaration _declaration;
			 _declaration=LRParser.GetReductionSyntaxNode(1) as declaration;
			_declaration.attributes = LRParser.GetReductionSyntaxNode(0) as attribute_list;
		
			return _declaration;
		}

	case (int)RuleConstants.RULE_SIMPLE_NOT_PROPERTY_DEFINITION :
	//<simple_not_property_definition> ::= <not_simple_property_definition>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_SIMPLE_NOT_PROPERTY_DEFINITION_TKCLASS :
	//<simple_not_property_definition> ::= tkClass <not_simple_property_definition>
         
		{
			simple_property _simple_property=(simple_property)LRParser.GetReductionSyntaxNode(1); 
							_simple_property.attr=definition_attribute.Static;
						     	parsertools.create_source_context(_simple_property,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(1));
							
			return _simple_property;
		}

	case (int)RuleConstants.RULE_NOT_SIMPLE_PROPERTY_DEFINITION_TKPROPERTY_TKSEMICOLON :
	//<not_simple_property_definition> ::= tkProperty <qualified_identifier> <not_property_interface> <not_property_specifiers> tkSemiColon <not_array_defaultproperty>
         
		{
			simple_property _simple_property=new simple_property();
			
								_simple_property.property_name=((method_name)LRParser.GetReductionSyntaxNode(1)).meth_name;
								if (LRParser.GetReductionSyntaxNode(2)!=null){
									_simple_property.parameter_list=((property_interface)LRParser.GetReductionSyntaxNode(2)).parameter_list;
									_simple_property.property_type=((property_interface)LRParser.GetReductionSyntaxNode(2)).property_type;
									_simple_property.index_expression=((property_interface)LRParser.GetReductionSyntaxNode(2)).index_expression;
								}
								if (LRParser.GetReductionSyntaxNode(3)!=null) _simple_property.accessors=(property_accessors)LRParser.GetReductionSyntaxNode(3);
								if (LRParser.GetReductionSyntaxNode(5)!=null) _simple_property.array_default=(property_array_default)LRParser.GetReductionSyntaxNode(5);
								parsertools.create_source_context(_simple_property,LRParser.GetReductionSyntaxNode(0),parsertools.sc_not_null(LRParser.GetReductionSyntaxNode(5),LRParser.GetReductionSyntaxNode(4),LRParser.GetReductionSyntaxNode(3),LRParser.GetReductionSyntaxNode(2),LRParser.GetReductionSyntaxNode(1),LRParser.GetReductionSyntaxNode(0)));
								
			return _simple_property;
		}

	case (int)RuleConstants.RULE_NOT_ARRAY_DEFAULTPROPERTY :
	//<not_array_defaultproperty> ::= 
	//NONTERMINAL:<not_array_defaultproperty> ::= 
	return null;
	//ENDNONTERMINAL
	case (int)RuleConstants.RULE_NOT_ARRAY_DEFAULTPROPERTY_TKDEFAULT_TKSEMICOLON :
	//<not_array_defaultproperty> ::= tkDefault tkSemiColon
         
		{
			property_array_default _property_array_default=new property_array_default();
			 parsertools.create_source_context(_property_array_default,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(1));
			return _property_array_default;
		}

	case (int)RuleConstants.RULE_NOT_PROPERTY_INTERFACE :
	//<not_property_interface> ::= 
	//NONTERMINAL:<not_property_interface> ::= 
	return null;
	//ENDNONTERMINAL
	case (int)RuleConstants.RULE_NOT_PROPERTY_INTERFACE_TKCOLON :
	//<not_property_interface> ::= <not_property_parameter_list> tkColon <fptype> <not_property_interface_index>
         
		{
			property_interface _property_interface=new property_interface();
			
								_property_interface.parameter_list=(property_parameter_list)LRParser.GetReductionSyntaxNode(0);
								_property_interface.property_type=(type_definition)LRParser.GetReductionSyntaxNode(2);
								_property_interface.index_expression=(expression)LRParser.GetReductionSyntaxNode(3);
								parsertools.create_source_context(_property_interface,parsertools.sc_not_null(LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(1),LRParser.GetReductionSyntaxNode(2),LRParser.GetReductionSyntaxNode(3)),parsertools.sc_not_null(LRParser.GetReductionSyntaxNode(3),LRParser.GetReductionSyntaxNode(2),LRParser.GetReductionSyntaxNode(1),LRParser.GetReductionSyntaxNode(0)));
								
			return _property_interface;
		}

	case (int)RuleConstants.RULE_NOT_PROPERTY_INTERFACE_INDEX :
	//<not_property_interface_index> ::= 
	//NONTERMINAL:<not_property_interface_index> ::= 
	return null;
	//ENDNONTERMINAL
	case (int)RuleConstants.RULE_NOT_PROPERTY_INTERFACE_INDEX_TKINDEX :
	//<not_property_interface_index> ::= tkIndex <expr>
return LRParser.GetReductionSyntaxNode(1);
	case (int)RuleConstants.RULE_NOT_PROPERTY_PARAMETER_LIST :
	//<not_property_parameter_list> ::= 
	//NONTERMINAL:<not_property_parameter_list> ::= 
	return null;
	//ENDNONTERMINAL
	case (int)RuleConstants.RULE_NOT_PROPERTY_PARAMETER_LIST_TKSQUAREOPEN_TKSQUARECLOSE :
	//<not_property_parameter_list> ::= tkSquareOpen <not_parameter_decl_list> tkSquareClose
return LRParser.GetReductionSyntaxNode(1);
	case (int)RuleConstants.RULE_NOT_PARAMETER_DECL_LIST :
	//<not_parameter_decl_list> ::= <not_parameter_decl> <empty>
         
		//TemplateList for property_parameter_list (create)
		{
			property_parameter_list _property_parameter_list=new property_parameter_list();
			_property_parameter_list.source_context=((property_parameter)LRParser.GetReductionSyntaxNode(0)).source_context;
			_property_parameter_list.parameters.Add((property_parameter)LRParser.GetReductionSyntaxNode(0));
			return _property_parameter_list;
		}

	case (int)RuleConstants.RULE_NOT_PARAMETER_DECL_LIST_TKSEMICOLON :
	//<not_parameter_decl_list> ::= <not_parameter_decl_list> tkSemiColon <not_parameter_decl>

		//TemplateList for property_parameter_list (add)         
		{
			property_parameter_list _property_parameter_list=(property_parameter_list)LRParser.GetReductionSyntaxNode(0);
			parsertools.create_source_context(_property_parameter_list,_property_parameter_list,LRParser.GetReductionSyntaxNode(2));
			_property_parameter_list.parameters.Add(LRParser.GetReductionSyntaxNode(2) as property_parameter);
			return _property_parameter_list;
		}

	case (int)RuleConstants.RULE_NOT_PARAMETER_DECL_TKCOLON :
	//<not_parameter_decl> ::= <not_parameter_name_list> tkColon <fptype>
         
		{
			property_parameter _property_parameter=new property_parameter((ident_list)LRParser.GetReductionSyntaxNode(0),(type_definition)LRParser.GetReductionSyntaxNode(2));
			parsertools.create_source_context(_property_parameter,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(2));
			
			return _property_parameter;
		}

	case (int)RuleConstants.RULE_NOT_PARAMETER_DECL_TKCONST_TKCOLON :
	//<not_parameter_decl> ::= tkConst <not_parameter_name_list> tkColon <fptype>
 {errors.Add(new nonterminal_token_return_null(current_file_name,parsertools.GetTokenSourceContext(),(syntax_tree_node)prev_node,"<not_parameter_decl> ::= tkConst <not_parameter_name_list> tkColon <fptype>"));}return null;
	case (int)RuleConstants.RULE_NOT_PARAMETER_DECL_TKVAR_TKCOLON :
	//<not_parameter_decl> ::= tkVar <not_parameter_name_list> tkColon <fptype>
 {errors.Add(new nonterminal_token_return_null(current_file_name,parsertools.GetTokenSourceContext(),(syntax_tree_node)prev_node,"<not_parameter_decl> ::= tkVar <not_parameter_name_list> tkColon <fptype>"));}return null;
	case (int)RuleConstants.RULE_NOT_PARAMETER_DECL_TKOUT_TKCOLON :
	//<not_parameter_decl> ::= tkOut <not_parameter_name_list> tkColon <fptype>
 {errors.Add(new nonterminal_token_return_null(current_file_name,parsertools.GetTokenSourceContext(),(syntax_tree_node)prev_node,"<not_parameter_decl> ::= tkOut <not_parameter_name_list> tkColon <fptype>"));}return null;
	case (int)RuleConstants.RULE_NOT_PARAMETER_NAME_LIST :
	//<not_parameter_name_list> ::= <ident_list>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_OPT_IDENTIFIER :
	//<opt_identifier> ::= <identifier>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_OPT_IDENTIFIER2 :
	//<opt_identifier> ::= 
	//NONTERMINAL:<opt_identifier> ::= 
	return null;
	//ENDNONTERMINAL
	case (int)RuleConstants.RULE_NOT_PROPERTY_SPECIFIERS :
	//<not_property_specifiers> ::= 
	//NONTERMINAL:<not_property_specifiers> ::= 
	return null;
	//ENDNONTERMINAL
	case (int)RuleConstants.RULE_NOT_PROPERTY_SPECIFIERS_TKREADONLY :
	//<not_property_specifiers> ::= tkReadOnly <not_property_specifiers>
 {errors.Add(new nonterminal_token_return_null(current_file_name,parsertools.GetTokenSourceContext(),(syntax_tree_node)prev_node,"<not_property_specifiers> ::= tkReadOnly <not_property_specifiers>"));}return null;
	case (int)RuleConstants.RULE_NOT_PROPERTY_SPECIFIERS_TKWRITEONLY :
	//<not_property_specifiers> ::= tkWriteOnly <not_property_specifiers>
 {errors.Add(new nonterminal_token_return_null(current_file_name,parsertools.GetTokenSourceContext(),(syntax_tree_node)prev_node,"<not_property_specifiers> ::= tkWriteOnly <not_property_specifiers>"));}return null;
	case (int)RuleConstants.RULE_NOT_PROPERTY_SPECIFIERS_TKDEFAULT :
	//<not_property_specifiers> ::= tkDefault <const_expr> <not_property_specifiers>
 {errors.Add(new nonterminal_token_return_null(current_file_name,parsertools.GetTokenSourceContext(),(syntax_tree_node)prev_node,"<not_property_specifiers> ::= tkDefault <const_expr> <not_property_specifiers>"));}return null;
	case (int)RuleConstants.RULE_NOT_PROPERTY_SPECIFIERS_TKREAD :
	//<not_property_specifiers> ::= tkRead <opt_identifier> <not_property_specifiers>
         
		{
			property_accessors _property_accessors;
			 
								property_accessors _pa=LRParser.GetReductionSyntaxNode(2) as property_accessors;
							        if (_pa==null) {
								_pa=new property_accessors();parsertools.create_source_context(_pa,LRParser.GetReductionSyntaxNode(0),parsertools.sc_not_null(LRParser.GetReductionSyntaxNode(1),LRParser.GetReductionSyntaxNode(0)));
								}
								_property_accessors=_pa;
								if(LRParser.GetReductionSyntaxNode(1)!=null && ((ident)LRParser.GetReductionSyntaxNode(1)).name.ToLower()=="write")
								{
								_property_accessors.read_accessor=new read_accessor_name(null);
								_property_accessors.write_accessor=new write_accessor_name(null);
								parsertools.create_source_context(_property_accessors.read_accessor,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(0));
								parsertools.create_source_context(_property_accessors.write_accessor,LRParser.GetReductionSyntaxNode(1),LRParser.GetReductionSyntaxNode(1));
								parsertools.create_source_context(_property_accessors,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(1));
								}
								else
								{
								_property_accessors.read_accessor=new read_accessor_name((ident)LRParser.GetReductionSyntaxNode(1));								
								parsertools.create_source_context(_property_accessors.read_accessor,LRParser.GetReductionSyntaxNode(0),parsertools.sc_not_null(LRParser.GetReductionSyntaxNode(1),LRParser.GetReductionSyntaxNode(0)));
								parsertools.create_source_context(_property_accessors,LRParser.GetReductionSyntaxNode(0),parsertools.sc_not_null(LRParser.GetReductionSyntaxNode(2),LRParser.GetReductionSyntaxNode(1),LRParser.GetReductionSyntaxNode(0)));
								}
								
			return _property_accessors;
		}

	case (int)RuleConstants.RULE_NOT_PROPERTY_SPECIFIERS_TKWRITE :
	//<not_property_specifiers> ::= tkWrite <opt_identifier> <not_property_specifiers>
         
		{
			property_accessors _property_accessors;
			 
								property_accessors _pa=LRParser.GetReductionSyntaxNode(2) as property_accessors;
							        if (_pa==null) {
								_pa=new property_accessors();parsertools.create_source_context(_pa,LRParser.GetReductionSyntaxNode(0),parsertools.sc_not_null(LRParser.GetReductionSyntaxNode(1),LRParser.GetReductionSyntaxNode(0)));
								}
								_property_accessors=_pa;
								_property_accessors.write_accessor=new write_accessor_name((ident)LRParser.GetReductionSyntaxNode(1));
								parsertools.create_source_context(_property_accessors.write_accessor,LRParser.GetReductionSyntaxNode(0),parsertools.sc_not_null(LRParser.GetReductionSyntaxNode(1),LRParser.GetReductionSyntaxNode(0)));
								parsertools.create_source_context(_property_accessors,LRParser.GetReductionSyntaxNode(0),_pa);
								
			return _property_accessors;
		}

	case (int)RuleConstants.RULE_VAR_DECL_TKSEMICOLON :
	//<var_decl> ::= <var_decl_part> tkSemiColon
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_VAR_DECL_PART :
	//<var_decl_part> ::= <var_decl_part_normal>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_VAR_DECL_PART2 :
	//<var_decl_part> ::= <var_decl_part_assign>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_VAR_DECL_PART_TKCOLON_TKASSIGN :
	//<var_decl_part> ::= <var_name_list> tkColon <type_ref> tkAssign <var_init_value_typed>
         
		{
			var_def_statement _var_def_statement=new var_def_statement((ident_list)LRParser.GetReductionSyntaxNode(0),(type_definition)LRParser.GetReductionSyntaxNode(2),(expression)LRParser.GetReductionSyntaxNode(4),definition_attribute.None,false);
			parsertools.create_source_context(_var_def_statement,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(4));
			
			return _var_def_statement;
		}

	case (int)RuleConstants.RULE_VAR_DECL_PART_IN_STMT :
	//<var_decl_part_in_stmt> ::= <var_decl_part>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_VAR_DECL_PART_ASSIGN_TKASSIGN :
	//<var_decl_part_assign> ::= <var_name_list> tkAssign <var_init_value>
         
		{
			var_def_statement _var_def_statement=new var_def_statement((ident_list)LRParser.GetReductionSyntaxNode(0),null,(expression)LRParser.GetReductionSyntaxNode(2),definition_attribute.None,false);
			parsertools.create_source_context(_var_def_statement,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(2));
			
			return _var_def_statement;
		}

	case (int)RuleConstants.RULE_VAR_DECL_PART_NORMAL_TKCOLON :
	//<var_decl_part_normal> ::= <var_name_list> tkColon <type_ref>
         
		{
			var_def_statement _var_def_statement=new var_def_statement((ident_list)LRParser.GetReductionSyntaxNode(0),(type_definition)LRParser.GetReductionSyntaxNode(2),null,definition_attribute.None,false);
			parsertools.create_source_context(_var_def_statement,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(2));
			
			return _var_def_statement;
		}

	case (int)RuleConstants.RULE_VAR_INIT_VALUE :
	//<var_init_value> ::= <expr>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_VAR_INIT_VALUE_TYPED :
	//<var_init_value_typed> ::= <typed_const_or_new>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_TYPED_CONST_OR_NEW :
	//<typed_const_or_new> ::= <typed_const>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_TYPED_CONST_OR_NEW2 :
	//<typed_const_or_new> ::= <new_expr>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_TYPED_CONST_OR_NEW3 :
	//<typed_const_or_new> ::= <default_expr>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_VAR_NAME_LIST :
	//<var_name_list> ::= <var_name> <empty>
         
		{
			ident_list _ident_list=new ident_list();
			parsertools.create_source_context(_ident_list,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(0));
			
								_ident_list.idents.Add((ident)LRParser.GetReductionSyntaxNode(0));
			return _ident_list;
		}

	case (int)RuleConstants.RULE_VAR_NAME_LIST_TKCOMMA :
	//<var_name_list> ::= <var_name_list> tkComma <var_name>
         
		{
			ident_list _ident_list=(ident_list)LRParser.GetReductionSyntaxNode(0);
								_ident_list.idents.Add((ident)LRParser.GetReductionSyntaxNode(2));
								parsertools.create_source_context(_ident_list,_ident_list,LRParser.GetReductionSyntaxNode(2));
			return _ident_list;
		}

	case (int)RuleConstants.RULE_VAR_NAME :
	//<var_name> ::= <identifier>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_DECLARED_VAR_NAME :
	//<declared_var_name> ::= <identifier>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_CONSTRUCTOR_DECL :
	//<constructor_decl> ::= <not_constructor_heading> <not_constructor_block_decl>

                //procedure_definition create
		{
			procedure_definition _procedure_definition=new procedure_definition((procedure_header)LRParser.GetReductionSyntaxNode(0),null);
			object rt=LRParser.GetReductionSyntaxNode(0);
			if(LRParser.GetReductionSyntaxNode(1)!=null) {
				rt=LRParser.GetReductionSyntaxNode(1);
				if(LRParser.GetReductionSyntaxNode(1) is proc_block) _procedure_definition.proc_body=(proc_block)LRParser.GetReductionSyntaxNode(1);
				if(LRParser.GetReductionSyntaxNode(1) is procedure_attribute) {
					procedure_header ph=_procedure_definition.proc_header;
					if(ph.proc_attributes==null) {
						ph.proc_attributes=new procedure_attributes_list();
						parsertools.assign_source_context(ph.proc_attributes,LRParser.GetReductionSyntaxNode(1));
					}
					ph.proc_attributes.proc_attributes.Add((procedure_attribute)LRParser.GetReductionSyntaxNode(1));
					parsertools.create_source_context(ph.proc_attributes,ph.proc_attributes,LRParser.GetReductionSyntaxNode(1));
				}
			}	
			parsertools.create_source_context(_procedure_definition,LRParser.GetReductionSyntaxNode(0),rt);
			
			return _procedure_definition;
		}

	case (int)RuleConstants.RULE_ABC_CONSTRUCTOR_DECL :
	//<abc_constructor_decl> ::= <not_constructor_heading> <abc_block>

                //procedure_definition create
		{
			procedure_definition _procedure_definition=new procedure_definition((procedure_header)LRParser.GetReductionSyntaxNode(0),null);
			object rt=LRParser.GetReductionSyntaxNode(0);
			if(LRParser.GetReductionSyntaxNode(1)!=null) {
				rt=LRParser.GetReductionSyntaxNode(1);
				if(LRParser.GetReductionSyntaxNode(1) is proc_block) _procedure_definition.proc_body=(proc_block)LRParser.GetReductionSyntaxNode(1);
				if(LRParser.GetReductionSyntaxNode(1) is procedure_attribute) {
					procedure_header ph=_procedure_definition.proc_header;
					if(ph.proc_attributes==null) {
						ph.proc_attributes=new procedure_attributes_list();
						parsertools.assign_source_context(ph.proc_attributes,LRParser.GetReductionSyntaxNode(1));
					}
					ph.proc_attributes.proc_attributes.Add((procedure_attribute)LRParser.GetReductionSyntaxNode(1));
					parsertools.create_source_context(ph.proc_attributes,ph.proc_attributes,LRParser.GetReductionSyntaxNode(1));
				}
			}	
			parsertools.create_source_context(_procedure_definition,LRParser.GetReductionSyntaxNode(0),rt);
			
			return _procedure_definition;
		}

	case (int)RuleConstants.RULE_DESTRUCTOR_DECL :
	//<destructor_decl> ::= <not_destructor_heading> <not_constructor_block_decl>

                //procedure_definition create
		{
			procedure_definition _procedure_definition=new procedure_definition((procedure_header)LRParser.GetReductionSyntaxNode(0),null);
			object rt=LRParser.GetReductionSyntaxNode(0);
			if(LRParser.GetReductionSyntaxNode(1)!=null) {
				rt=LRParser.GetReductionSyntaxNode(1);
				if(LRParser.GetReductionSyntaxNode(1) is proc_block) _procedure_definition.proc_body=(proc_block)LRParser.GetReductionSyntaxNode(1);
				if(LRParser.GetReductionSyntaxNode(1) is procedure_attribute) {
					procedure_header ph=_procedure_definition.proc_header;
					if(ph.proc_attributes==null) {
						ph.proc_attributes=new procedure_attributes_list();
						parsertools.assign_source_context(ph.proc_attributes,LRParser.GetReductionSyntaxNode(1));
					}
					ph.proc_attributes.proc_attributes.Add((procedure_attribute)LRParser.GetReductionSyntaxNode(1));
					parsertools.create_source_context(ph.proc_attributes,ph.proc_attributes,LRParser.GetReductionSyntaxNode(1));
				}
			}	
			parsertools.create_source_context(_procedure_definition,LRParser.GetReductionSyntaxNode(0),rt);
			
			return _procedure_definition;
		}

	case (int)RuleConstants.RULE_ABC_DESTRUCTOR_DECL :
	//<abc_destructor_decl> ::= <not_destructor_heading> <abc_block>

                //procedure_definition create
		{
			procedure_definition _procedure_definition=new procedure_definition((procedure_header)LRParser.GetReductionSyntaxNode(0),null);
			object rt=LRParser.GetReductionSyntaxNode(0);
			if(LRParser.GetReductionSyntaxNode(1)!=null) {
				rt=LRParser.GetReductionSyntaxNode(1);
				if(LRParser.GetReductionSyntaxNode(1) is proc_block) _procedure_definition.proc_body=(proc_block)LRParser.GetReductionSyntaxNode(1);
				if(LRParser.GetReductionSyntaxNode(1) is procedure_attribute) {
					procedure_header ph=_procedure_definition.proc_header;
					if(ph.proc_attributes==null) {
						ph.proc_attributes=new procedure_attributes_list();
						parsertools.assign_source_context(ph.proc_attributes,LRParser.GetReductionSyntaxNode(1));
					}
					ph.proc_attributes.proc_attributes.Add((procedure_attribute)LRParser.GetReductionSyntaxNode(1));
					parsertools.create_source_context(ph.proc_attributes,ph.proc_attributes,LRParser.GetReductionSyntaxNode(1));
				}
			}	
			parsertools.create_source_context(_procedure_definition,LRParser.GetReductionSyntaxNode(0),rt);
			
			return _procedure_definition;
		}

	case (int)RuleConstants.RULE_NOT_CONSTRUCTOR_BLOCK_DECL :
	//<not_constructor_block_decl> ::= <block>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_NOT_CONSTRUCTOR_BLOCK_DECL2 :
	//<not_constructor_block_decl> ::= <external_directr>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_NOT_CONSTRUCTOR_BLOCK_DECL3 :
	//<not_constructor_block_decl> ::= <asm_block>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_PROC_DECL :
	//<proc_decl> ::= <proc_decl_noclass>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_PROC_DECL_TKCLASS :
	//<proc_decl> ::= tkClass <proc_decl_noclass>
 ((LRParser.GetReductionSyntaxNode(1) as procedure_definition).proc_header as procedure_header).class_keyword=true;return LRParser.GetReductionSyntaxNode(1);
	case (int)RuleConstants.RULE_PROC_DECL_NOCLASS :
	//<proc_decl_noclass> ::= <proc_heading> <proc_block>
{
			procedure_definition _procedure_definition=new procedure_definition((procedure_header)LRParser.GetReductionSyntaxNode(0),null);
			object rt=LRParser.GetReductionSyntaxNode(0);
			if(LRParser.GetReductionSyntaxNode(1)!=null) {
				rt=LRParser.GetReductionSyntaxNode(1);
                if (LRParser.GetReductionSyntaxNode(1) is proc_block)
                {
                    add_lambda(LRParser.GetReductionSyntaxNode(1), _procedure_definition);//tasha 16.04.2010
                }
				if(LRParser.GetReductionSyntaxNode(1) is procedure_attribute) {
					procedure_header ph=_procedure_definition.proc_header;
					if(ph.proc_attributes==null) {
						ph.proc_attributes=new procedure_attributes_list();
						parsertools.assign_source_context(ph.proc_attributes,LRParser.GetReductionSyntaxNode(1));
					}
					ph.proc_attributes.proc_attributes.Add((procedure_attribute)LRParser.GetReductionSyntaxNode(1));
					parsertools.create_source_context(ph.proc_attributes,ph.proc_attributes,LRParser.GetReductionSyntaxNode(1));
				}
			}	
			parsertools.create_source_context(_procedure_definition,LRParser.GetReductionSyntaxNode(0),rt);
			
			return _procedure_definition;
		}
	case (int)RuleConstants.RULE_ABC_PROC_DECL :
	//<abc_proc_decl> ::= <abc_proc_decl_noclass>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_ABC_PROC_DECL_TKCLASS :
	//<abc_proc_decl> ::= tkClass <abc_proc_decl_noclass>
 ((LRParser.GetReductionSyntaxNode(1) as procedure_definition).proc_header as procedure_header).class_keyword=true;return LRParser.GetReductionSyntaxNode(1);
	case (int)RuleConstants.RULE_ABC_PROC_DECL_NOCLASS :
	//<abc_proc_decl_noclass> ::= <proc_heading> <abc_proc_block>
{procedure_definition _procedure_definition=new procedure_definition((procedure_header)LRParser.GetReductionSyntaxNode(0),null);
			object rt=LRParser.GetReductionSyntaxNode(0);
			if(LRParser.GetReductionSyntaxNode(1)!=null) {
				rt=LRParser.GetReductionSyntaxNode(1);
                if (LRParser.GetReductionSyntaxNode(1) is proc_block)
                {
                    add_lambda(LRParser.GetReductionSyntaxNode(1), _procedure_definition);//tasha 16.04.2010
                }
				if(LRParser.GetReductionSyntaxNode(1) is procedure_attribute) {
					procedure_header ph=_procedure_definition.proc_header;
					if(ph.proc_attributes==null) {
						ph.proc_attributes=new procedure_attributes_list();
						parsertools.assign_source_context(ph.proc_attributes,LRParser.GetReductionSyntaxNode(1));
					}
					ph.proc_attributes.proc_attributes.Add((procedure_attribute)LRParser.GetReductionSyntaxNode(1));
					parsertools.create_source_context(ph.proc_attributes,ph.proc_attributes,LRParser.GetReductionSyntaxNode(1));
				}
			}	
			parsertools.create_source_context(_procedure_definition,LRParser.GetReductionSyntaxNode(0),rt);
			
			return _procedure_definition;}
	case (int)RuleConstants.RULE_FUNC_DECL :
	//<func_decl> ::= <func_decl_noclass>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_FUNC_DECL_TKCLASS :
	//<func_decl> ::= tkClass <func_decl_noclass>
 ((LRParser.GetReductionSyntaxNode(1) as procedure_definition).proc_header as procedure_header).class_keyword=true;return LRParser.GetReductionSyntaxNode(1);
	case (int)RuleConstants.RULE_FUNC_DECL_NOCLASS :
	//<func_decl_noclass> ::= <func_heading> <func_block>
{
			procedure_definition _procedure_definition=new procedure_definition((function_header)LRParser.GetReductionSyntaxNode(0),null);
			object rt=LRParser.GetReductionSyntaxNode(0);
			if(LRParser.GetReductionSyntaxNode(1)!=null) {
				rt=LRParser.GetReductionSyntaxNode(1);
                if (LRParser.GetReductionSyntaxNode(1) is proc_block)
                {
                    add_lambda(LRParser.GetReductionSyntaxNode(1), _procedure_definition);//tasha 16.04.2010
                }
				if(LRParser.GetReductionSyntaxNode(1) is procedure_attribute) {
					procedure_header ph=_procedure_definition.proc_header;
					if(ph.proc_attributes==null) {
						ph.proc_attributes=new procedure_attributes_list();
						parsertools.assign_source_context(ph.proc_attributes,LRParser.GetReductionSyntaxNode(1));
					}
					ph.proc_attributes.proc_attributes.Add((procedure_attribute)LRParser.GetReductionSyntaxNode(1));
					parsertools.create_source_context(ph.proc_attributes,ph.proc_attributes,LRParser.GetReductionSyntaxNode(1));
				}
			}	
			parsertools.create_source_context(_procedure_definition,LRParser.GetReductionSyntaxNode(0),rt);
			
			return _procedure_definition;}
	case (int)RuleConstants.RULE_ABC_FUNC_DECL :
	//<abc_func_decl> ::= <abc_func_decl_noclass>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_ABC_FUNC_DECL_TKCLASS :
	//<abc_func_decl> ::= tkClass <abc_func_decl_noclass>
 ((LRParser.GetReductionSyntaxNode(1) as procedure_definition).proc_header as procedure_header).class_keyword=true;return LRParser.GetReductionSyntaxNode(1);
	case (int)RuleConstants.RULE_ABC_FUNC_DECL_NOCLASS :
	//<abc_func_decl_noclass> ::= <func_heading> <abc_proc_block>
{
			procedure_definition _procedure_definition=new procedure_definition((function_header)LRParser.GetReductionSyntaxNode(0),null);
			object rt=LRParser.GetReductionSyntaxNode(0);
			if(LRParser.GetReductionSyntaxNode(1)!=null) {
				rt=LRParser.GetReductionSyntaxNode(1);
                if (LRParser.GetReductionSyntaxNode(1) is proc_block)
                {
                    add_lambda(LRParser.GetReductionSyntaxNode(1), _procedure_definition);//tasha 16.04.2010
                }
				if(LRParser.GetReductionSyntaxNode(1) is procedure_attribute) {
					procedure_header ph=_procedure_definition.proc_header;
					if(ph.proc_attributes==null) {
						ph.proc_attributes=new procedure_attributes_list();
						parsertools.assign_source_context(ph.proc_attributes,LRParser.GetReductionSyntaxNode(1));
					}
					ph.proc_attributes.proc_attributes.Add((procedure_attribute)LRParser.GetReductionSyntaxNode(1));
					parsertools.create_source_context(ph.proc_attributes,ph.proc_attributes,LRParser.GetReductionSyntaxNode(1));
				}
			}	
			parsertools.create_source_context(_procedure_definition,LRParser.GetReductionSyntaxNode(0),rt);
			
			return _procedure_definition;
		}
	case (int)RuleConstants.RULE_PROC_HEADING_TKPROCEDURE :
	//<proc_heading> ::= tkProcedure <proc_name> <fp_list> <maybe_error> <opt_meth_modificators> <opt_where_section>
         
		{
			procedure_header _procedure_header=new procedure_header(null,null,(method_name)LRParser.GetReductionSyntaxNode(1),false,false,null,null);
			 
								object rt=LRParser.GetReductionSyntaxNode(1);
								if(_procedure_header.name.meth_name is template_type_name)
								{
									_procedure_header.template_args=(_procedure_header.name.meth_name as template_type_name).template_args;
									ident id = new ident(_procedure_header.name.meth_name.name);
									parsertools.create_source_context(id,_procedure_header.name.meth_name,_procedure_header.name.meth_name);
									_procedure_header.name.meth_name=id;
								}
								if (LRParser.GetReductionSyntaxNode(2)!=null) {
								  rt=LRParser.GetReductionSyntaxNode(2);
		                                                  _procedure_header.parameters=(formal_parameters)LRParser.GetReductionSyntaxNode(2);
								}
								if(LRParser.GetReductionSyntaxNode(3)!=null)
									(LRParser.GetReductionSyntaxNode(3) as SyntaxError).bad_node=_procedure_header;
								if (LRParser.GetReductionSyntaxNode(4)!=null) {
								  rt=LRParser.GetReductionSyntaxNode(4);
								  if (((procedure_attributes_list)LRParser.GetReductionSyntaxNode(4)).proc_attributes.Count>0) 
									_procedure_header.proc_attributes=(procedure_attributes_list)LRParser.GetReductionSyntaxNode(4);
								}
								if (LRParser.GetReductionSyntaxNode(5)!=null) {
								  rt=LRParser.GetReductionSyntaxNode(5);
								  _procedure_header.where_defs = (where_definition_list)LRParser.GetReductionSyntaxNode(5);
								}
								parsertools.create_source_context(_procedure_header,LRParser.GetReductionSyntaxNode(0),rt);
								
			return _procedure_header;
		}

	case (int)RuleConstants.RULE_PROC_NAME :
	//<proc_name> ::= <func_name>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_FUNC_NAME :
	//<func_name> ::= <func_meth_name_ident> <empty>
         
		{
			method_name _method_name=new method_name(null,null,(ident)LRParser.GetReductionSyntaxNode(0),null);
			parsertools.create_source_context(_method_name,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(0));
			
			return _method_name;
		}

	case (int)RuleConstants.RULE_FUNC_NAME_TKPOINT :
	//<func_name> ::= <func_class_name_ident> tkPoint <func_meth_name_ident>
         
		{
			method_name _method_name=new method_name(null,(ident)LRParser.GetReductionSyntaxNode(0),(ident)LRParser.GetReductionSyntaxNode(2),null);
			parsertools.create_source_context(_method_name,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(2));
			
			return _method_name;
		}

	case (int)RuleConstants.RULE_FUNC_NAME_TKPOINT_TKPOINT :
	//<func_name> ::= <func_class_name_ident> tkPoint <func_class_name_ident> tkPoint <func_meth_name_ident>
         
		{
			method_name _method_name=new method_name(null,(ident)LRParser.GetReductionSyntaxNode(0),(ident)LRParser.GetReductionSyntaxNode(4),(ident)LRParser.GetReductionSyntaxNode(2));
			parsertools.create_source_context(_method_name,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(4));
			
			return _method_name;
		}

	case (int)RuleConstants.RULE_FUNC_CLASS_NAME_IDENT :
	//<func_class_name_ident> ::= <func_name_with_template_args>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_FUNC_METH_NAME_IDENT :
	//<func_meth_name_ident> ::= <func_name_with_template_args>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_FUNC_METH_NAME_IDENT2 :
	//<func_meth_name_ident> ::= <operator_name_ident>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_FUNC_NAME_WITH_TEMPLATE_ARGS :
	//<func_name_with_template_args> ::= <func_name_ident>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_FUNC_NAME_WITH_TEMPLATE_ARGS2 :
	//<func_name_with_template_args> ::= <func_name_ident> <template_arguments>
         
		{
			template_type_name _template_type_name=new template_type_name((ident_list)LRParser.GetReductionSyntaxNode(1));
			
								_template_type_name.name=((ident)LRParser.GetReductionSyntaxNode(0)).name;
								parsertools.create_source_context(_template_type_name,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(1));
							
			return _template_type_name;
		}

	case (int)RuleConstants.RULE_FUNC_NAME_IDENT :
	//<func_name_ident> ::= <identifier>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_FUNC_NAME_IDENT2 :
	//<func_name_ident> ::= <visibility_specifier>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_FUNC_HEADING_TKFUNCTION_TKCOLON :
	//<func_heading> ::= tkFunction <func_name> <fp_list> tkColon <fptype> <opt_meth_modificators> <opt_where_section>
         
		{
			function_header _function_header=new function_header();
			 
								object rt=LRParser.GetReductionSyntaxNode(1);
								_function_header.name=(method_name)LRParser.GetReductionSyntaxNode(1);
								if(_function_header.name.meth_name is template_type_name)
								{
									_function_header.template_args=(_function_header.name.meth_name as template_type_name).template_args;
									ident id = new ident(_function_header.name.meth_name.name);
									parsertools.create_source_context(id,_function_header.name.meth_name,_function_header.name.meth_name);
									_function_header.name.meth_name=id;
								}
								//_function_header.template_args=(ident_list)LRParser.GetReductionSyntaxNode(2);
								if (LRParser.GetReductionSyntaxNode(2)!=null) {
								  rt=LRParser.GetReductionSyntaxNode(2);
		                                                  _function_header.parameters=(formal_parameters)LRParser.GetReductionSyntaxNode(2);
								}
								if (LRParser.GetReductionSyntaxNode(4)!=null) {
								  rt=LRParser.GetReductionSyntaxNode(4);
								  _function_header.return_type=(type_definition)LRParser.GetReductionSyntaxNode(4);
								}
								if (LRParser.GetReductionSyntaxNode(5)!=null) {
								  rt=LRParser.GetReductionSyntaxNode(5);
								  if (((procedure_attributes_list)LRParser.GetReductionSyntaxNode(5)).proc_attributes.Count>0) 
									_function_header.proc_attributes=(procedure_attributes_list)LRParser.GetReductionSyntaxNode(5);
								}
								if (LRParser.GetReductionSyntaxNode(6)!=null) {
								  rt=LRParser.GetReductionSyntaxNode(6);
								  _function_header.where_defs = (where_definition_list)LRParser.GetReductionSyntaxNode(6);
								}
								_function_header.of_object=false;
 								_function_header.class_keyword=false;
								parsertools.create_source_context(_function_header,LRParser.GetReductionSyntaxNode(0),rt);
								
			return _function_header;
		}

	case (int)RuleConstants.RULE_FUNC_HEADING_TKFUNCTION :
	//<func_heading> ::= tkFunction <func_name> <opt_meth_modificators>
         
		{
			function_header _function_header=new function_header();
			 
								object rt=LRParser.GetReductionSyntaxNode(1);
								_function_header.name=(method_name)LRParser.GetReductionSyntaxNode(1);
								if (LRParser.GetReductionSyntaxNode(2)!=null) {
								  rt=LRParser.GetReductionSyntaxNode(2);
								  if (((procedure_attributes_list)LRParser.GetReductionSyntaxNode(2)).proc_attributes.Count>0) 
									_function_header.proc_attributes=(procedure_attributes_list)LRParser.GetReductionSyntaxNode(2);
								}
								_function_header.of_object=false;
 								_function_header.class_keyword=false;
								parsertools.create_source_context(_function_header,LRParser.GetReductionSyntaxNode(0),rt);
								
			return _function_header;
		}

	case (int)RuleConstants.RULE_PROC_BLOCK :
	//<proc_block> ::= <proc_block_decl>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_FUNC_BLOCK :
	//<func_block> ::= <proc_block_decl>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_PROC_BLOCK_DECL :
	//<proc_block_decl> ::= <block>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_PROC_BLOCK_DECL2 :
	//<proc_block_decl> ::= <external_directr>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_PROC_BLOCK_DECL3 :
	//<proc_block_decl> ::= <asm_block>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_PROC_BLOCK_DECL_TKFORWARD_TKSEMICOLON :
	//<proc_block_decl> ::= tkForward tkSemiColon
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_ABC_PROC_BLOCK :
	//<abc_proc_block> ::= <abc_block>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_ABC_PROC_BLOCK2 :
	//<abc_proc_block> ::= <external_directr>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_EXTERNAL_DIRECTR :
	//<external_directr> ::= <abc_external_directr>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_EXTERNAL_DIRECTR_TKSEMICOLON :
	//<external_directr> ::= <abc_external_directr> tkSemiColon
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_EXTERNAL_DIRECTR_TKEXTERNAL_TKSEMICOLON :
	//<external_directr> ::= tkExternal tkSemiColon
         
		{
			external_directive _external_directive=new external_directive(null,null);
			
		 parsertools.create_source_context(_external_directive,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(0)); 
			return _external_directive;
		}

	case (int)RuleConstants.RULE_EXTERNAL_DIRECTR_IDENT :
	//<external_directr_ident> ::= <identifier>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_EXTERNAL_DIRECTR_IDENT2 :
	//<external_directr_ident> ::= <literal>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_ABC_EXTERNAL_DIRECTR_TKEXTERNAL_TKNAME :
	//<abc_external_directr> ::= tkExternal <external_directr_ident> tkName <external_directr_ident>
         
		{
			external_directive _external_directive=new external_directive((expression)LRParser.GetReductionSyntaxNode(1),(expression)LRParser.GetReductionSyntaxNode(3));
			 
										parsertools.create_source_context(_external_directive,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(3));
			return _external_directive;
		}

	case (int)RuleConstants.RULE_ABC_EXTERNAL_DIRECTR_TKEXTERNAL :
	//<abc_external_directr> ::= tkExternal <external_directr_ident>
         
		{
			external_directive _external_directive=new external_directive((expression)LRParser.GetReductionSyntaxNode(1),null);
			
										parsertools.create_source_context(_external_directive,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(1));
			return _external_directive;
		}

	case (int)RuleConstants.RULE_ASM_BLOCK_TKASMBODY_TKSEMICOLON :
	//<asm_block> ::= <impl_decl_sect_list> tkAsmBody tkSemiColon
 {errors.Add(new nonterminal_token_return_null(current_file_name,parsertools.GetTokenSourceContext(),(syntax_tree_node)prev_node,"<asm_block> ::= <impl_decl_sect_list> tkAsmBody tkSemiColon"));}return null;
	case (int)RuleConstants.RULE_BLOCK_TKSEMICOLON :
	//<block> ::= <impl_decl_sect_list> <compound_stmt> tkSemiColon
         
		{
			block _block=new block((declarations)LRParser.GetReductionSyntaxNode(0),(statement_list)LRParser.GetReductionSyntaxNode(1));
			
								parsertools.create_source_context(_block,parsertools.sc_not_null(LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(1)),LRParser.GetReductionSyntaxNode(2));
			return _block;
		}

	case (int)RuleConstants.RULE_ABC_BLOCK_TKSEMICOLON :
	//<abc_block> ::= <abc_decl_sect_list> <compound_stmt> tkSemiColon
         
		{
			block _block=new block((declarations)LRParser.GetReductionSyntaxNode(0),(statement_list)LRParser.GetReductionSyntaxNode(1));
			
								parsertools.create_source_context(_block,parsertools.sc_not_null(LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(1)),LRParser.GetReductionSyntaxNode(2));
			return _block;
		}

	case (int)RuleConstants.RULE_FP_LIST :
	//<fp_list> ::= 
	//NONTERMINAL:<fp_list> ::= 
	return null;
	//ENDNONTERMINAL
	case (int)RuleConstants.RULE_FP_LIST_TKROUNDOPEN_TKROUNDCLOSE :
	//<fp_list> ::= tkRoundOpen <fp_sect_list> tkRoundClose
 if(LRParser.GetReductionSyntaxNode(1)!=null) parsertools.create_source_context(LRParser.GetReductionSyntaxNode(1),LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(2));
								return LRParser.GetReductionSyntaxNode(1);
	case (int)RuleConstants.RULE_FP_SECT_LIST :
	//<fp_sect_list> ::= 
	//NONTERMINAL:<fp_sect_list> ::= 
	return null;
	//ENDNONTERMINAL
	case (int)RuleConstants.RULE_FP_SECT_LIST2 :
	//<fp_sect_list> ::= <fp_sect> <empty>
         
		{
			formal_parameters _formal_parameters=new formal_parameters();
			
								_formal_parameters.params_list.Add((typed_parameters)LRParser.GetReductionSyntaxNode(0));
								
			return _formal_parameters;
		}

	case (int)RuleConstants.RULE_FP_SECT_LIST_TKSEMICOLON :
	//<fp_sect_list> ::= <fp_sect_list> tkSemiColon <fp_sect>
         
		{
			formal_parameters _formal_parameters=(formal_parameters)LRParser.GetReductionSyntaxNode(0);
								_formal_parameters.params_list.Add((typed_parameters)LRParser.GetReductionSyntaxNode(2));	
								
			return _formal_parameters;
		}

	case (int)RuleConstants.RULE_FP_SECT :
	//<fp_sect> ::= <opt_attribute_declarations> <simple_fp_sect>
         
		{
			declaration _declaration;
			 _declaration=LRParser.GetReductionSyntaxNode(1) as declaration;
			_declaration.attributes = LRParser.GetReductionSyntaxNode(0) as attribute_list;
		
			return _declaration;
		}

	case (int)RuleConstants.RULE_SIMPLE_FP_SECT_TKCOLON :
	//<simple_fp_sect> ::= <param_name_list> tkColon <fptype_new>
         
		{
			typed_parameters _typed_parameters=new typed_parameters((ident_list)LRParser.GetReductionSyntaxNode(0),(type_definition)LRParser.GetReductionSyntaxNode(2),parametr_kind.none,null);
			parsertools.create_source_context(_typed_parameters,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(2));
			
			return _typed_parameters;
		}

	case (int)RuleConstants.RULE_SIMPLE_FP_SECT_TKVAR_TKCOLON :
	//<simple_fp_sect> ::= tkVar <param_name_list> tkColon <fptype_new>
         
		{
			typed_parameters _typed_parameters=new typed_parameters((ident_list)LRParser.GetReductionSyntaxNode(1),(type_definition)LRParser.GetReductionSyntaxNode(3),parametr_kind.var_parametr,null);
			 parsertools.create_source_context(_typed_parameters,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(3));
			return _typed_parameters;
		}

	case (int)RuleConstants.RULE_SIMPLE_FP_SECT_TKOUT_TKCOLON :
	//<simple_fp_sect> ::= tkOut <param_name_list> tkColon <fptype_new>
         
		{
			typed_parameters _typed_parameters=new typed_parameters((ident_list)LRParser.GetReductionSyntaxNode(1),(type_definition)LRParser.GetReductionSyntaxNode(3),parametr_kind.out_parametr,null);
			 parsertools.create_source_context(_typed_parameters,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(3));
			return _typed_parameters;
		}

	case (int)RuleConstants.RULE_SIMPLE_FP_SECT_TKCONST_TKCOLON :
	//<simple_fp_sect> ::= tkConst <param_name_list> tkColon <fptype_new>
         
		{
			typed_parameters _typed_parameters=new typed_parameters((ident_list)LRParser.GetReductionSyntaxNode(1),(type_definition)LRParser.GetReductionSyntaxNode(3),parametr_kind.const_parametr,null);
			 parsertools.create_source_context(_typed_parameters,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(3));
			return _typed_parameters;
		}

	case (int)RuleConstants.RULE_SIMPLE_FP_SECT_TKPARAMS_TKCOLON :
	//<simple_fp_sect> ::= tkParams <param_name_list> tkColon <fptype_new>
         
		{
			typed_parameters _typed_parameters=new typed_parameters((ident_list)LRParser.GetReductionSyntaxNode(1),(type_definition)LRParser.GetReductionSyntaxNode(3),parametr_kind.params_parametr,null);
			 parsertools.create_source_context(_typed_parameters,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(3));
			return _typed_parameters;
		}

	case (int)RuleConstants.RULE_SIMPLE_FP_SECT_TKCOLON_TKASSIGN :
	//<simple_fp_sect> ::= <param_name_list> tkColon <fptype> tkAssign <const_expr>
         
		{
			typed_parameters _typed_parameters=new typed_parameters((ident_list)LRParser.GetReductionSyntaxNode(0),(type_definition)LRParser.GetReductionSyntaxNode(2),parametr_kind.none,(expression)LRParser.GetReductionSyntaxNode(4));
			parsertools.create_source_context(_typed_parameters,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(4));
			
			return _typed_parameters;
		}

	case (int)RuleConstants.RULE_SIMPLE_FP_SECT_TKVAR_TKCOLON_TKASSIGN :
	//<simple_fp_sect> ::= tkVar <param_name_list> tkColon <fptype> tkAssign <const_expr>
         
		{
			typed_parameters _typed_parameters=new typed_parameters((ident_list)LRParser.GetReductionSyntaxNode(1),(type_definition)LRParser.GetReductionSyntaxNode(3),parametr_kind.var_parametr,(expression)LRParser.GetReductionSyntaxNode(5));
			 parsertools.create_source_context(_typed_parameters,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(5));
			return _typed_parameters;
		}

	case (int)RuleConstants.RULE_SIMPLE_FP_SECT_TKOUT_TKCOLON_TKASSIGN :
	//<simple_fp_sect> ::= tkOut <param_name_list> tkColon <fptype> tkAssign <const_expr>
         
		{
			typed_parameters _typed_parameters=new typed_parameters((ident_list)LRParser.GetReductionSyntaxNode(1),(type_definition)LRParser.GetReductionSyntaxNode(3),parametr_kind.out_parametr,(expression)LRParser.GetReductionSyntaxNode(5));
			 parsertools.create_source_context(_typed_parameters,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(5));
			return _typed_parameters;
		}

	case (int)RuleConstants.RULE_SIMPLE_FP_SECT_TKCONST_TKCOLON_TKASSIGN :
	//<simple_fp_sect> ::= tkConst <param_name_list> tkColon <fptype> tkAssign <const_expr>
         
		{
			typed_parameters _typed_parameters=new typed_parameters((ident_list)LRParser.GetReductionSyntaxNode(1),(type_definition)LRParser.GetReductionSyntaxNode(3),parametr_kind.const_parametr,(expression)LRParser.GetReductionSyntaxNode(5));
			 parsertools.create_source_context(_typed_parameters,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(5));
			return _typed_parameters;
		}

	case (int)RuleConstants.RULE_PARAM_NAME_LIST :
	//<param_name_list> ::= <param_name> <empty>
         
		//TemplateList for ident_list (create)
		{
			ident_list _ident_list=new ident_list();
			_ident_list.source_context=((ident)LRParser.GetReductionSyntaxNode(0)).source_context;
			_ident_list.idents.Add((ident)LRParser.GetReductionSyntaxNode(0));
			return _ident_list;
		}

	case (int)RuleConstants.RULE_PARAM_NAME_LIST_TKCOMMA :
	//<param_name_list> ::= <param_name_list> tkComma <param_name>

		//TemplateList for ident_list (add)         
		{
			ident_list _ident_list=(ident_list)LRParser.GetReductionSyntaxNode(0);
			parsertools.create_source_context(_ident_list,_ident_list,LRParser.GetReductionSyntaxNode(2));
			_ident_list.idents.Add(LRParser.GetReductionSyntaxNode(2) as ident);
			return _ident_list;
		}

	case (int)RuleConstants.RULE_PARAM_NAME :
	//<param_name> ::= <identifier>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_FPTYPE :
	//<fptype> ::= <type_ref>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_FPTYPE_NEW :
	//<fptype_new> ::= <type_ref>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_FPTYPE_NEW_TKARRAY_TKOF_TKCONST :
	//<fptype_new> ::= tkArray tkOf tkConst
         
		{
			array_of_const_type_definition _array_of_const_type_definition=new array_of_const_type_definition();
			 parsertools.create_source_context(_array_of_const_type_definition,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(2));
			return _array_of_const_type_definition;
		}

	case (int)RuleConstants.RULE_STMT :
	//<stmt> ::= <unlabelled_stmt>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_STMT_TKCOLON :
	//<stmt> ::= <label_name> tkColon <stmt>
         
		{
			labeled_statement _labeled_statement=new labeled_statement((ident)LRParser.GetReductionSyntaxNode(0),(statement)LRParser.GetReductionSyntaxNode(2));
			 parsertools.create_source_context(_labeled_statement,LRParser.GetReductionSyntaxNode(0),parsertools.sc_not_null(LRParser.GetReductionSyntaxNode(2),LRParser.GetReductionSyntaxNode(1)));
			return _labeled_statement;
		}

	case (int)RuleConstants.RULE_UNLABELLED_STMT :
	//<unlabelled_stmt> ::= <empty> <empty>
         
		{
			empty_statement _empty_statement=new empty_statement();
			
			return _empty_statement;
		}

	case (int)RuleConstants.RULE_UNLABELLED_STMT2 :
	//<unlabelled_stmt> ::= <assignment>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_UNLABELLED_STMT3 :
	//<unlabelled_stmt> ::= <proc_call>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_UNLABELLED_STMT4 :
	//<unlabelled_stmt> ::= <goto_stmt>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_UNLABELLED_STMT5 :
	//<unlabelled_stmt> ::= <compound_stmt>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_UNLABELLED_STMT6 :
	//<unlabelled_stmt> ::= <if_stmt>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_UNLABELLED_STMT7 :
	//<unlabelled_stmt> ::= <case_stmt>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_UNLABELLED_STMT8 :
	//<unlabelled_stmt> ::= <repeat_stmt>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_UNLABELLED_STMT9 :
	//<unlabelled_stmt> ::= <while_stmt>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_UNLABELLED_STMT10 :
	//<unlabelled_stmt> ::= <for_stmt>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_UNLABELLED_STMT11 :
	//<unlabelled_stmt> ::= <with_stmt>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_UNLABELLED_STMT12 :
	//<unlabelled_stmt> ::= <asm_stmt>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_UNLABELLED_STMT13 :
	//<unlabelled_stmt> ::= <inherited_message>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_UNLABELLED_STMT14 :
	//<unlabelled_stmt> ::= <try_stmt>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_UNLABELLED_STMT15 :
	//<unlabelled_stmt> ::= <raise_stmt>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_UNLABELLED_STMT16 :
	//<unlabelled_stmt> ::= <foreach_stmt>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_UNLABELLED_STMT17 :
	//<unlabelled_stmt> ::= <var_stmt>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_UNLABELLED_STMT18 :
	//<unlabelled_stmt> ::= <expr_as_stmt>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_UNLABELLED_STMT19 :
	//<unlabelled_stmt> ::= <lock_stmt>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_VAR_STMT_TKVAR :
	//<var_stmt> ::= tkVar <var_decl_part_in_stmt>
         
		{
			var_statement _var_statement=new var_statement(LRParser.GetReductionSyntaxNode(1) as var_def_statement);
			 
                                                       ///////////////tasha 28.04.2010
            pascalABC_var_statements.Add((var_def_statement)LRParser.GetReductionSyntaxNode(1));
            ///////////////////////////////
                                                       parsertools.create_source_context(_var_statement,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(1));
			return _var_statement;
		}

	case (int)RuleConstants.RULE_ASSIGNMENT :
	//<assignment> ::= <var_reference> <assign_operator> <expr>
{
                                                        ///////////////tasha 28.04.2010
                                                        for_assignment(LRParser.GetReductionSyntaxNode(0), LRParser.GetReductionSyntaxNode(2));
                                                        ///////////////////////////////

			                                      assign _assign=new assign(LRParser.GetReductionSyntaxNode(0) as addressed_value,LRParser.GetReductionSyntaxNode(2) as expression,((op_type_node)LRParser.GetReductionSyntaxNode(1)).type);
			                                      parsertools.create_source_context(_assign,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(2));
			
			                                      return _assign;
		                                            }
	case (int)RuleConstants.RULE_PROC_CALL :
	//<proc_call> ::= <var_reference> <empty>
         
		{
			procedure_call _procedure_call=new procedure_call(LRParser.GetReductionSyntaxNode(0) as addressed_value);
			parsertools.create_source_context(_procedure_call,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(0));
			
			return _procedure_call;
		}

	case (int)RuleConstants.RULE_GOTO_STMT_TKGOTO :
	//<goto_stmt> ::= tkGoto <label_name>
         
		{
			goto_statement _goto_statement=new goto_statement((ident)LRParser.GetReductionSyntaxNode(1));
			parsertools.create_source_context(_goto_statement,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(1));
			 
												   parsertools.create_source_context(_goto_statement,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(1));
			return _goto_statement;
		}

	case (int)RuleConstants.RULE_COMPOUND_STMT_TKBEGIN_TKEND :
	//<compound_stmt> ::= tkBegin <stmt_list> tkEnd

	 							parsertools.create_source_context(LRParser.GetReductionSyntaxNode(1),LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(2));
								((statement_list)LRParser.GetReductionSyntaxNode(1)).left_logical_bracket=(syntax_tree_node)LRParser.GetReductionSyntaxNode(0);
								((statement_list)LRParser.GetReductionSyntaxNode(1)).right_logical_bracket=(syntax_tree_node)LRParser.GetReductionSyntaxNode(2);
								return LRParser.GetReductionSyntaxNode(1);
								
	case (int)RuleConstants.RULE_STMT_LIST :
	//<stmt_list> ::= <stmt> <empty>
         
		{
			statement_list _statement_list=new statement_list();
			
								_statement_list.subnodes.Add((statement)LRParser.GetReductionSyntaxNode(0));
								parsertools.assign_source_context(_statement_list,LRParser.GetReductionSyntaxNode(0)); 
								
			return _statement_list;
		}

	case (int)RuleConstants.RULE_STMT_LIST_TKSEMICOLON :
	//<stmt_list> ::= <stmt_list> tkSemiColon <stmt>
         
		{
			statement_list _statement_list;
			 _statement_list=(statement_list)LRParser.GetReductionSyntaxNode(0);
								if(_statement_list!=LRParser.GetReductionSyntaxNode(2)){
								_statement_list.subnodes.Add((statement)LRParser.GetReductionSyntaxNode(2));
								parsertools.create_source_context(_statement_list,_statement_list,parsertools.sc_not_null(LRParser.GetReductionSyntaxNode(2),LRParser.GetReductionSyntaxNode(1))); 
								}
								
			return _statement_list;
		}

	case (int)RuleConstants.RULE_IF_STMT_TKIF :
	//<if_stmt> ::= tkIf <expr> <if_then_else_branch>
((if_node)LRParser.GetReductionSyntaxNode(2)).condition=(expression)LRParser.GetReductionSyntaxNode(1);
								parsertools.create_source_context(LRParser.GetReductionSyntaxNode(2),LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(2));
								return LRParser.GetReductionSyntaxNode(2);
								
	case (int)RuleConstants.RULE_IF_THEN_ELSE_BRANCH_TKTHEN :
	//<if_then_else_branch> ::= tkThen <then_branch>
         
		{
			if_node _if_node=new if_node(null,(statement)LRParser.GetReductionSyntaxNode(1),null);
			
								parsertools.create_source_context(_if_node,LRParser.GetReductionSyntaxNode(0),parsertools.sc_not_null(LRParser.GetReductionSyntaxNode(1),LRParser.GetReductionSyntaxNode(0)));	
								
			return _if_node;
		}

	case (int)RuleConstants.RULE_IF_THEN_ELSE_BRANCH_TKTHEN_TKELSE :
	//<if_then_else_branch> ::= tkThen <then_branch> tkElse <else_branch>
         
		{
			if_node _if_node=new if_node(null,(statement)LRParser.GetReductionSyntaxNode(1),(statement)LRParser.GetReductionSyntaxNode(3));
			
								parsertools.create_source_context(_if_node,LRParser.GetReductionSyntaxNode(2),parsertools.sc_not_null(LRParser.GetReductionSyntaxNode(3),LRParser.GetReductionSyntaxNode(2)));	
								
			return _if_node;
		}

	case (int)RuleConstants.RULE_THEN_BRANCH :
	//<then_branch> ::= <stmt>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_ELSE_BRANCH :
	//<else_branch> ::= <stmt>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_CASE_STMT_TKCASE_TKOF_TKEND :
	//<case_stmt> ::= tkCase <expr> tkOf <case_list> <else_case> tkEnd
         
		{
			case_node _case_node=new case_node((expression)LRParser.GetReductionSyntaxNode(1),LRParser.GetReductionSyntaxNode(3) as case_variants,LRParser.GetReductionSyntaxNode(4) as statement);
			
								parsertools.create_source_context(_case_node,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(5));
			return _case_node;
		}

	case (int)RuleConstants.RULE_CASE_LIST :
	//<case_list> ::= <case_item> <empty>
         
		{
			case_variants _case_variants=new case_variants();
			 
								if (LRParser.GetReductionSyntaxNode(0) is case_variant)
								{
									_case_variants.variants.Add((case_variant)LRParser.GetReductionSyntaxNode(0));
									parsertools.create_source_context(_case_variants,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(0));
								}
			return _case_variants;
		}

	case (int)RuleConstants.RULE_CASE_LIST_TKSEMICOLON :
	//<case_list> ::= <case_list> tkSemiColon <case_item>
         
		{
			case_variants _case_variants=(case_variants)LRParser.GetReductionSyntaxNode(0);
								parsertools.create_source_context(_case_variants,parsertools.sc_not_null(LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(1)),parsertools.sc_not_null(LRParser.GetReductionSyntaxNode(2),LRParser.GetReductionSyntaxNode(1))); 							
								if (LRParser.GetReductionSyntaxNode(2) is case_variant) _case_variants.variants.Add((case_variant)LRParser.GetReductionSyntaxNode(2));
			return _case_variants;
		}

	case (int)RuleConstants.RULE_CASE_ITEM :
	//<case_item> ::= <empty> <empty>
         
		{
			empty_statement _empty_statement=new empty_statement();
			
			return _empty_statement;
		}

	case (int)RuleConstants.RULE_CASE_ITEM_TKCOLON :
	//<case_item> ::= <case_label_list> tkColon <stmt>
         
		{
			case_variant _case_variant=new case_variant((expression_list)LRParser.GetReductionSyntaxNode(0),(statement)LRParser.GetReductionSyntaxNode(2));
			 
								parsertools.create_source_context(_case_variant,LRParser.GetReductionSyntaxNode(0),parsertools.sc_not_null(LRParser.GetReductionSyntaxNode(2),LRParser.GetReductionSyntaxNode(1)));
			return _case_variant;
		}

	case (int)RuleConstants.RULE_CASE_LABEL_LIST :
	//<case_label_list> ::= <case_label> <empty>
         
		//TemplateList for expression_list (create)
		{
			expression_list _expression_list=new expression_list();
			_expression_list.source_context=((expression)LRParser.GetReductionSyntaxNode(0)).source_context;
			_expression_list.expressions.Add((expression)LRParser.GetReductionSyntaxNode(0));
			return _expression_list;
		}

	case (int)RuleConstants.RULE_CASE_LABEL_LIST_TKCOMMA :
	//<case_label_list> ::= <case_label_list> tkComma <case_label>

		//TemplateList for expression_list (add)         
		{
			expression_list _expression_list=(expression_list)LRParser.GetReductionSyntaxNode(0);
			parsertools.create_source_context(_expression_list,_expression_list,LRParser.GetReductionSyntaxNode(2));
			_expression_list.expressions.Add(LRParser.GetReductionSyntaxNode(2) as expression);
			return _expression_list;
		}

	case (int)RuleConstants.RULE_CASE_LABEL :
	//<case_label> ::= <const_elem>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_ELSE_CASE :
	//<else_case> ::= 
	//NONTERMINAL:<else_case> ::= 
	return null;
	//ENDNONTERMINAL
	case (int)RuleConstants.RULE_ELSE_CASE_TKELSE :
	//<else_case> ::= tkElse <stmt_list>
return LRParser.GetReductionSyntaxNode(1);
	case (int)RuleConstants.RULE_REPEAT_STMT_TKREPEAT_TKUNTIL :
	//<repeat_stmt> ::= tkRepeat <stmt_list> tkUntil <expr>
         
		{
			repeat_node _repeat_node=new repeat_node((statement)LRParser.GetReductionSyntaxNode(1),(expression)LRParser.GetReductionSyntaxNode(3));
			
								((statement_list)LRParser.GetReductionSyntaxNode(1)).left_logical_bracket=(syntax_tree_node)LRParser.GetReductionSyntaxNode(0);
								((statement_list)LRParser.GetReductionSyntaxNode(1)).right_logical_bracket=(syntax_tree_node)LRParser.GetReductionSyntaxNode(2);
                                                                parsertools.create_source_context(LRParser.GetReductionSyntaxNode(1),LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(2));
								parsertools.create_source_context(_repeat_node,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(3));	
								
			return _repeat_node;
		}

	case (int)RuleConstants.RULE_WHILE_STMT_TKWHILE :
	//<while_stmt> ::= tkWhile <expr> <opt_tk_do> <stmt>
         
		{
			while_node _while_node=new while_node((expression)LRParser.GetReductionSyntaxNode(1),(statement)LRParser.GetReductionSyntaxNode(3),WhileCycleType.While);
			
								if (LRParser.GetReductionSyntaxNode(2) == null)
								{
									file_position fp = (LRParser.GetReductionSyntaxNode(1) as syntax_tree_node).source_context.end_position;
									syntax_tree_node err_stn = (syntax_tree_node)LRParser.GetReductionSyntaxNode(3);
									if (err_stn == null)
										err_stn = (syntax_tree_node)LRParser.GetReductionSyntaxNode(1);
									errors.Add(new Errors.PABCNETUnexpectedToken(current_file_name, StringResources.Get("TKDO"),new SourceContext(fp.line_num, fp.column_num+1, fp.line_num, fp.column_num+1, 0, 0),err_stn));
									parsertools.create_source_context(_while_node,LRParser.GetReductionSyntaxNode(0),parsertools.sc_not_null(LRParser.GetReductionSyntaxNode(1),LRParser.GetReductionSyntaxNode(3)));
								}
								else
								parsertools.create_source_context(_while_node,LRParser.GetReductionSyntaxNode(0),parsertools.sc_not_null(LRParser.GetReductionSyntaxNode(3),LRParser.GetReductionSyntaxNode(2)));	
								
			return _while_node;
		}

	case (int)RuleConstants.RULE_OPT_TK_DO_TKDO :
	//<opt_tk_do> ::= tkDo
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_OPT_TK_DO :
	//<opt_tk_do> ::= 
	//NONTERMINAL:<opt_tk_do> ::= 
	return null;
	//ENDNONTERMINAL
	case (int)RuleConstants.RULE_LOCK_STMT_TKLOCK_TKDO :
	//<lock_stmt> ::= tkLock <expr> tkDo <stmt>
         
		{
			lock_stmt _lock_stmt=new lock_stmt((expression)LRParser.GetReductionSyntaxNode(1),(statement)LRParser.GetReductionSyntaxNode(3));
			
								parsertools.create_source_context(_lock_stmt,LRParser.GetReductionSyntaxNode(0),parsertools.sc_not_null(LRParser.GetReductionSyntaxNode(3),LRParser.GetReductionSyntaxNode(2)));	
								
			return _lock_stmt;
		}

	case (int)RuleConstants.RULE_FOREACH_STMT_TKFOREACH_TKIN_TKDO :
	//<foreach_stmt> ::= tkForeach <identifier> <foreach_stmt_ident_dype_opt> tkIn <expr> tkDo <stmt>
         
		{
			foreach_stmt _foreach_stmt=new foreach_stmt((ident)LRParser.GetReductionSyntaxNode(1),(type_definition)LRParser.GetReductionSyntaxNode(2),(expression)LRParser.GetReductionSyntaxNode(4),(statement)LRParser.GetReductionSyntaxNode(6));
			
								parsertools.create_source_context(_foreach_stmt,LRParser.GetReductionSyntaxNode(0),parsertools.sc_not_null(LRParser.GetReductionSyntaxNode(6),LRParser.GetReductionSyntaxNode(5)));	
								
			return _foreach_stmt;
		}

	case (int)RuleConstants.RULE_FOREACH_STMT_TKFOREACH_TKVAR_TKCOLON_TKIN_TKDO :
	//<foreach_stmt> ::= tkForeach tkVar <identifier> tkColon <type_ref> tkIn <expr> tkDo <stmt>
         
		{
			foreach_stmt _foreach_stmt=new foreach_stmt((ident)LRParser.GetReductionSyntaxNode(2),(type_definition)LRParser.GetReductionSyntaxNode(4),(expression)LRParser.GetReductionSyntaxNode(6),(statement)LRParser.GetReductionSyntaxNode(8));
			
								parsertools.create_source_context(_foreach_stmt,LRParser.GetReductionSyntaxNode(0),parsertools.sc_not_null(LRParser.GetReductionSyntaxNode(8),LRParser.GetReductionSyntaxNode(7)));	
								
			return _foreach_stmt;
		}

	case (int)RuleConstants.RULE_FOREACH_STMT_IDENT_DYPE_OPT_TKCOLON :
	//<foreach_stmt_ident_dype_opt> ::= tkColon <type_ref>
 return LRParser.GetReductionSyntaxNode(1); 
	case (int)RuleConstants.RULE_FOREACH_STMT_IDENT_DYPE_OPT :
	//<foreach_stmt_ident_dype_opt> ::= 
	//NONTERMINAL:<foreach_stmt_ident_dype_opt> ::= 
	return null;
	//ENDNONTERMINAL
	case (int)RuleConstants.RULE_FOR_STMT_TKFOR :
	//<for_stmt> ::= tkFor <opt_var> <identifier> <for_stmt_decl_or_assign> <expr> <for_cycle_type> <expr> <opt_tk_do> <stmt>
         
		{
			for_node _for_node=new for_node((ident)LRParser.GetReductionSyntaxNode(2),(expression)LRParser.GetReductionSyntaxNode(4),(expression)LRParser.GetReductionSyntaxNode(6),(statement)LRParser.GetReductionSyntaxNode(8),(for_cycle_type)LRParser.GetReductionSyntaxNode(5),null,LRParser.GetReductionSyntaxNode(3) as type_definition, LRParser.GetReductionSyntaxNode(1)!=null);
			
								if (LRParser.GetReductionSyntaxNode(7) == null)
								{
									file_position fp = (LRParser.GetReductionSyntaxNode(6) as syntax_tree_node).source_context.end_position;
									syntax_tree_node err_stn = (syntax_tree_node)LRParser.GetReductionSyntaxNode(8);
									if (err_stn == null)
										err_stn = (syntax_tree_node)LRParser.GetReductionSyntaxNode(6);
									errors.Add(new Errors.PABCNETUnexpectedToken(current_file_name, StringResources.Get("TKDO"),new SourceContext(fp.line_num, fp.column_num+1, fp.line_num, fp.column_num+1, 0, 0),err_stn));
									parsertools.create_source_context(_for_node,LRParser.GetReductionSyntaxNode(0),parsertools.sc_not_null(LRParser.GetReductionSyntaxNode(8),LRParser.GetReductionSyntaxNode(6)));
								}
								else
								parsertools.create_source_context(_for_node,LRParser.GetReductionSyntaxNode(0),parsertools.sc_not_null(LRParser.GetReductionSyntaxNode(8),LRParser.GetReductionSyntaxNode(7)));	
								
			return _for_node;
		}

	case (int)RuleConstants.RULE_OPT_VAR_TKVAR :
	//<opt_var> ::= tkVar
return true;
	case (int)RuleConstants.RULE_OPT_VAR :
	//<opt_var> ::= 
	//NONTERMINAL:<opt_var> ::= 
	return null;
	//ENDNONTERMINAL
	case (int)RuleConstants.RULE_FOR_STMT_DECL_OR_ASSIGN_TKASSIGN :
	//<for_stmt_decl_or_assign> ::= tkAssign
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_FOR_STMT_DECL_OR_ASSIGN_TKCOLON_TKASSIGN :
	//<for_stmt_decl_or_assign> ::= tkColon <simple_type_identifier> tkAssign
return LRParser.GetReductionSyntaxNode(1);
	case (int)RuleConstants.RULE_FOR_CYCLE_TYPE_TKTO :
	//<for_cycle_type> ::= tkTo
 return for_cycle_type.to; 
	case (int)RuleConstants.RULE_FOR_CYCLE_TYPE_TKDOWNTO :
	//<for_cycle_type> ::= tkDownto
 return for_cycle_type.downto; 
	case (int)RuleConstants.RULE_WITH_STMT_TKWITH_TKDO :
	//<with_stmt> ::= tkWith <expr_list> tkDo <stmt>
         
		{
			with_statement _with_statement=new with_statement((statement)LRParser.GetReductionSyntaxNode(3),(expression_list)LRParser.GetReductionSyntaxNode(1));
			
								parsertools.create_source_context(_with_statement,LRParser.GetReductionSyntaxNode(0),parsertools.sc_not_null(LRParser.GetReductionSyntaxNode(3),LRParser.GetReductionSyntaxNode(2)));
			return _with_statement;
		}

	case (int)RuleConstants.RULE_INHERITED_MESSAGE_TKINHERITED :
	//<inherited_message> ::= tkInherited <empty>
         
		{
			inherited_message _inherited_message=new inherited_message();
			 parsertools.assign_source_context(_inherited_message,LRParser.GetReductionSyntaxNode(0));
			return _inherited_message;
		}

	case (int)RuleConstants.RULE_TRY_STMT_TKTRY :
	//<try_stmt> ::= tkTry <stmt_list> <try_handler>
         
		{
			try_stmt _try_stmt=new try_stmt(((statement_list)LRParser.GetReductionSyntaxNode(1)),(try_handler)LRParser.GetReductionSyntaxNode(2));
			 
							((statement_list)LRParser.GetReductionSyntaxNode(1)).left_logical_bracket=(syntax_tree_node)LRParser.GetReductionSyntaxNode(0);
							parsertools.create_source_context(LRParser.GetReductionSyntaxNode(1),LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(1));
							parsertools.create_source_context(_try_stmt,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(2));
							
			return _try_stmt;
		}

	case (int)RuleConstants.RULE_TRY_HANDLER_TKFINALLY_TKEND :
	//<try_handler> ::= tkFinally <stmt_list> tkEnd
         
		{
			try_handler_finally _try_handler_finally=new try_handler_finally((statement_list)LRParser.GetReductionSyntaxNode(1));
			 
							((statement_list)LRParser.GetReductionSyntaxNode(1)).left_logical_bracket=(syntax_tree_node)LRParser.GetReductionSyntaxNode(0);
							((statement_list)LRParser.GetReductionSyntaxNode(1)).right_logical_bracket=(syntax_tree_node)LRParser.GetReductionSyntaxNode(2);
							parsertools.create_source_context(_try_handler_finally,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(2));
			return _try_handler_finally;
		}

	case (int)RuleConstants.RULE_TRY_HANDLER_TKEXCEPT_TKEND :
	//<try_handler> ::= tkExcept <exception_block> tkEnd
         
		{
			try_handler_except _try_handler_except=new try_handler_except((exception_block)LRParser.GetReductionSyntaxNode(1));
			 parsertools.create_source_context(_try_handler_except,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(2));
			return _try_handler_except;
		}

	case (int)RuleConstants.RULE_EXCEPTION_BLOCK :
	//<exception_block> ::= <exception_handler_list> <exception_block_else_branch>
         
		{
			exception_block _exception_block=new exception_block(null,(exception_handler_list)LRParser.GetReductionSyntaxNode(0),(statement_list)LRParser.GetReductionSyntaxNode(1));
			
										parsertools.create_source_context(_exception_block,LRParser.GetReductionSyntaxNode(0),parsertools.sc_not_null(LRParser.GetReductionSyntaxNode(1),LRParser.GetReductionSyntaxNode(0)));
			return _exception_block;
		}

	case (int)RuleConstants.RULE_EXCEPTION_BLOCK_TKSEMICOLON :
	//<exception_block> ::= <exception_handler_list> tkSemiColon <exception_block_else_branch>
         
		{
			exception_block _exception_block=new exception_block(null,(exception_handler_list)LRParser.GetReductionSyntaxNode(0),(statement_list)LRParser.GetReductionSyntaxNode(2));
			
										parsertools.create_source_context(_exception_block,LRParser.GetReductionSyntaxNode(0),parsertools.sc_not_null(LRParser.GetReductionSyntaxNode(2),LRParser.GetReductionSyntaxNode(1)));
			return _exception_block;
		}

	case (int)RuleConstants.RULE_EXCEPTION_BLOCK2 :
	//<exception_block> ::= <stmt_list> <empty>
         
		{
			exception_block _exception_block=new exception_block((statement_list)LRParser.GetReductionSyntaxNode(0),null,null);
			
										if (((syntax_tree_node)LRParser.GetReductionSyntaxNode(0)).source_context!=null) parsertools.assign_source_context(_exception_block,LRParser.GetReductionSyntaxNode(0));
			return _exception_block;
		}

	case (int)RuleConstants.RULE_EXCEPTION_HANDLER_LIST :
	//<exception_handler_list> ::= <exception_handler> <empty>
         
		//TemplateList for exception_handler_list (create)
		{
			exception_handler_list _exception_handler_list=new exception_handler_list();
			_exception_handler_list.source_context=((exception_handler)LRParser.GetReductionSyntaxNode(0)).source_context;
			_exception_handler_list.handlers.Add((exception_handler)LRParser.GetReductionSyntaxNode(0));
			return _exception_handler_list;
		}

	case (int)RuleConstants.RULE_EXCEPTION_HANDLER_LIST_TKSEMICOLON :
	//<exception_handler_list> ::= <exception_handler_list> tkSemiColon <exception_handler>

		//TemplateList for exception_handler_list (add)         
		{
			exception_handler_list _exception_handler_list=(exception_handler_list)LRParser.GetReductionSyntaxNode(0);
			parsertools.create_source_context(_exception_handler_list,_exception_handler_list,LRParser.GetReductionSyntaxNode(2));
			_exception_handler_list.handlers.Add(LRParser.GetReductionSyntaxNode(2) as exception_handler);
			return _exception_handler_list;
		}

	case (int)RuleConstants.RULE_EXCEPTION_BLOCK_ELSE_BRANCH :
	//<exception_block_else_branch> ::= 
	//NONTERMINAL:<exception_block_else_branch> ::= 
	return null;
	//ENDNONTERMINAL
	case (int)RuleConstants.RULE_EXCEPTION_BLOCK_ELSE_BRANCH_TKELSE :
	//<exception_block_else_branch> ::= tkElse <stmt_list>
return LRParser.GetReductionSyntaxNode(1);
	case (int)RuleConstants.RULE_EXCEPTION_HANDLER_TKON_TKDO :
	//<exception_handler> ::= tkOn <exception_identifier> tkDo <stmt>
         
		{
			exception_handler _exception_handler=new exception_handler(((exception_ident)LRParser.GetReductionSyntaxNode(1)).variable,((exception_ident)LRParser.GetReductionSyntaxNode(1)).type_name,(statement)LRParser.GetReductionSyntaxNode(3));
			
								parsertools.create_source_context(_exception_handler,LRParser.GetReductionSyntaxNode(0),parsertools.sc_not_null(LRParser.GetReductionSyntaxNode(3),LRParser.GetReductionSyntaxNode(2)));
			return _exception_handler;
		}

	case (int)RuleConstants.RULE_EXCEPTION_IDENTIFIER :
	//<exception_identifier> ::= <exception_class_type_identifier> <empty>
         
		{
			exception_ident _exception_ident=new exception_ident(null,(named_type_reference)LRParser.GetReductionSyntaxNode(0));
			parsertools.create_source_context(_exception_ident,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(0));
			
			return _exception_ident;
		}

	case (int)RuleConstants.RULE_EXCEPTION_IDENTIFIER_TKCOLON :
	//<exception_identifier> ::= <exception_variable> tkColon <exception_class_type_identifier>
         
		{
			exception_ident _exception_ident=new exception_ident((ident)LRParser.GetReductionSyntaxNode(0),(named_type_reference)LRParser.GetReductionSyntaxNode(2));
			parsertools.create_source_context(_exception_ident,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(2));
			
			return _exception_ident;
		}

	case (int)RuleConstants.RULE_EXCEPTION_CLASS_TYPE_IDENTIFIER :
	//<exception_class_type_identifier> ::= <simple_type_identifier>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_EXCEPTION_VARIABLE :
	//<exception_variable> ::= <identifier>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_RAISE_STMT_TKRAISE :
	//<raise_stmt> ::= tkRaise <empty>
         
		{
			raise_stmt _raise_stmt=new raise_stmt();
			 parsertools.assign_source_context(_raise_stmt,LRParser.GetReductionSyntaxNode(0));
			return _raise_stmt;
		}

	case (int)RuleConstants.RULE_RAISE_STMT_TKRAISE2 :
	//<raise_stmt> ::= tkRaise <expr>
         
		{
			raise_stmt _raise_stmt=new raise_stmt((expression)LRParser.GetReductionSyntaxNode(1),null);
			 parsertools.create_source_context(_raise_stmt,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(1));
			return _raise_stmt;
		}

	case (int)RuleConstants.RULE_RAISE_STMT_TKRAISE_TKAT :
	//<raise_stmt> ::= tkRaise <expr> tkAt <expr>
         
		{
			raise_stmt _raise_stmt=new raise_stmt((expression)LRParser.GetReductionSyntaxNode(1),(expression)LRParser.GetReductionSyntaxNode(3));
			 parsertools.create_source_context(_raise_stmt,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(3));
			return _raise_stmt;
		}

	case (int)RuleConstants.RULE_ASM_STMT_TKASMBODY :
	//<asm_stmt> ::= tkAsmBody
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_EXPR_LIST :
	//<expr_list> ::= <expr> <empty>
         
		//TemplateList for expression_list (create)
		{
			expression_list _expression_list=new expression_list();
			_expression_list.source_context=((expression)LRParser.GetReductionSyntaxNode(0)).source_context;
			_expression_list.expressions.Add((expression)LRParser.GetReductionSyntaxNode(0));
			return _expression_list;
		}

	case (int)RuleConstants.RULE_EXPR_LIST_TKCOMMA :
	//<expr_list> ::= <expr_list> tkComma <expr>

		//TemplateList for expression_list (add)         
		{
			expression_list _expression_list=(expression_list)LRParser.GetReductionSyntaxNode(0);
			parsertools.create_source_context(_expression_list,_expression_list,LRParser.GetReductionSyntaxNode(2));
			_expression_list.expressions.Add(LRParser.GetReductionSyntaxNode(2) as expression);
			return _expression_list;
		}

	case (int)RuleConstants.RULE_ATTR_EXPR_LIST :
	//<attr_expr_list> ::= <expr_list>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_EXPR_AS_STMT :
	//<expr_as_stmt> ::= <allowable_expr_as_stmt> <empty>
         
		{
			expression_as_statement _expression_as_statement=new expression_as_statement((expression)LRParser.GetReductionSyntaxNode(0));
			 parsertools.create_source_context(_expression_as_statement,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(0));
			return _expression_as_statement;
		}

	case (int)RuleConstants.RULE_ALLOWABLE_EXPR_AS_STMT :
	//<allowable_expr_as_stmt> ::= <new_expr>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_EXPR :
	//<expr> ::= <expr_l1>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_EXPR2 :
	//<expr> ::= <format_expr>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_EXPR3 :
	//<expr> ::= <func_decl_lambda>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_EXPR_L1 :
	//<expr_l1> ::= <relop_expr>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_EXPR_L12 :
	//<expr_l1> ::= <question_expr>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_SIZEOF_EXPR_TKSIZEOF_TKROUNDOPEN_TKROUNDCLOSE :
	//<sizeof_expr> ::= tkSizeOf tkRoundOpen <simple_or_template_type_reference> tkRoundClose
         
		{
			sizeof_operator _sizeof_operator=new sizeof_operator((named_type_reference)LRParser.GetReductionSyntaxNode(2),null);
			 parsertools.create_source_context(_sizeof_operator,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(3));
			return _sizeof_operator;
		}

	case (int)RuleConstants.RULE_TYPEOF_EXPR_TKTYPEOF_TKROUNDOPEN_TKROUNDCLOSE :
	//<typeof_expr> ::= tkTypeOf tkRoundOpen <simple_or_template_type_reference> tkRoundClose
         
		{
			typeof_operator _typeof_operator=new typeof_operator((named_type_reference)LRParser.GetReductionSyntaxNode(2));
			 parsertools.create_source_context(_typeof_operator,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(3));
			return _typeof_operator;
		}

	case (int)RuleConstants.RULE_QUESTION_EXPR_TKQUESTION_TKCOLON :
	//<question_expr> ::= <expr_l1> tkQuestion <expr_l1> tkColon <expr_l1>
         
		{
			question_colon_expression _question_colon_expression=new question_colon_expression((expression)LRParser.GetReductionSyntaxNode(0),(expression)LRParser.GetReductionSyntaxNode(2),(expression)LRParser.GetReductionSyntaxNode(4));
			 parsertools.create_source_context(_question_colon_expression,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(4));
			return _question_colon_expression;
		}

	case (int)RuleConstants.RULE_OPT_AMPERSEND :
	//<opt_ampersend> ::= 
	//NONTERMINAL:<opt_ampersend> ::= 
	return null;
	//ENDNONTERMINAL
	case (int)RuleConstants.RULE_OPT_AMPERSEND_TKAMPERSEND :
	//<opt_ampersend> ::= tkAmpersend
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_SIMPLE_OR_TEMPLATE_TYPE_REFERENCE :
	//<simple_or_template_type_reference> ::= <simple_type_identifier>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_SIMPLE_OR_TEMPLATE_TYPE_REFERENCE2 :
	//<simple_or_template_type_reference> ::= <simple_type_identifier> <template_type_params>
         
		{
			template_type_reference _template_type_reference=new template_type_reference((named_type_reference)LRParser.GetReductionSyntaxNode(0),(template_param_list)LRParser.GetReductionSyntaxNode(1));
			
							    parsertools.create_source_context(_template_type_reference,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(1));
							    
			return _template_type_reference;
		}

	case (int)RuleConstants.RULE_SIMPLE_OR_TEMPLATE_TYPE_REFERENCE_TKAMPERSEND :
	//<simple_or_template_type_reference> ::= <simple_type_identifier> tkAmpersend <template_type_params>
         
		{
			template_type_reference _template_type_reference=new template_type_reference((named_type_reference)LRParser.GetReductionSyntaxNode(0),(template_param_list)LRParser.GetReductionSyntaxNode(2));
			
							    parsertools.create_source_context(_template_type_reference,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(2));
							    
			return _template_type_reference;
		}

	case (int)RuleConstants.RULE_OPT_ARRAY_INITIALIZER_TKROUNDOPEN_TKROUNDCLOSE :
	//<opt_array_initializer> ::= tkRoundOpen <typed_const_list> tkRoundClose
         
		{
			array_const _array_const=new array_const((expression_list)LRParser.GetReductionSyntaxNode(1));
			
							parsertools.create_source_context(_array_const,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(2));
			return _array_const;
		}

	case (int)RuleConstants.RULE_OPT_ARRAY_INITIALIZER :
	//<opt_array_initializer> ::= 
	//NONTERMINAL:<opt_array_initializer> ::= 
	return null;
	//ENDNONTERMINAL
	case (int)RuleConstants.RULE_NEW_EXPR :
	//<new_expr> ::= <identifier> <simple_or_template_type_reference> <opt_expr_list_with_bracket>

							{
							named_type_reference ntr=(named_type_reference)LRParser.GetReductionSyntaxNode(1);
							new_expr newexpr=new new_expr(ntr,LRParser.GetReductionSyntaxNode(2) as expression_list,false,null);
							parsertools.create_source_context(newexpr,LRParser.GetReductionSyntaxNode(0),parsertools.sc_not_null(LRParser.GetReductionSyntaxNode(2),LRParser.GetReductionSyntaxNode(1)));
							if ((LRParser.GetReductionSyntaxNode(0) as ident).name.ToLower()!="new")
								errors.Add(new Errors.PABCNETUnexpectedToken(current_file_name,";",((syntax_tree_node)LRParser.GetReductionSyntaxNode(0)).source_context,newexpr));
							return newexpr;
							}
							
	case (int)RuleConstants.RULE_NEW_EXPR_TKSQUAREOPEN_TKSQUARECLOSE :
	//<new_expr> ::= <identifier> <array_name_for_new_expr> tkSquareOpen <expr_list> tkSquareClose <opt_array_initializer>

							{
							new_expr newexpr=new new_expr((type_definition)LRParser.GetReductionSyntaxNode(1),LRParser.GetReductionSyntaxNode(3) as expression_list,true,LRParser.GetReductionSyntaxNode(5) as array_const);
							if (LRParser.GetReductionSyntaxNode(5) != null)
								parsertools.create_source_context(newexpr,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(5));
							else
								parsertools.create_source_context(newexpr,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(4));
							if ((LRParser.GetReductionSyntaxNode(0) as ident).name.ToLower()!="new")
								errors.Add(new Errors.PABCNETUnexpectedToken(current_file_name,";",((syntax_tree_node)LRParser.GetReductionSyntaxNode(0)).source_context,newexpr));
							return newexpr;
							}
							
	case (int)RuleConstants.RULE_ARRAY_NAME_FOR_NEW_EXPR :
	//<array_name_for_new_expr> ::= <simple_type_identifier>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_ARRAY_NAME_FOR_NEW_EXPR2 :
	//<array_name_for_new_expr> ::= <unsized_array_type>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_OPT_TEMPLATE_TYPE_PARAMS :
	//<opt_template_type_params> ::= 
	//NONTERMINAL:<opt_template_type_params> ::= 
	return null;
	//ENDNONTERMINAL
	case (int)RuleConstants.RULE_OPT_TEMPLATE_TYPE_PARAMS2 :
	//<opt_template_type_params> ::= <template_type_params>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_OPT_EXPR_LIST_WITH_BRACKET :
	//<opt_expr_list_with_bracket> ::= 
	//NONTERMINAL:<opt_expr_list_with_bracket> ::= 
	return null;
	//ENDNONTERMINAL
	case (int)RuleConstants.RULE_OPT_EXPR_LIST_WITH_BRACKET_TKROUNDOPEN_TKROUNDCLOSE :
	//<opt_expr_list_with_bracket> ::= tkRoundOpen <opt_expr_list> tkRoundClose
return LRParser.GetReductionSyntaxNode(1);
	case (int)RuleConstants.RULE_RELOP_EXPR :
	//<relop_expr> ::= <simple_expr>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_RELOP_EXPR2 :
	//<relop_expr> ::= <simple_expr> <relop> <relop_expr>
         
		{
			bin_expr _bin_expr=new bin_expr((expression)LRParser.GetReductionSyntaxNode(0),(expression)LRParser.GetReductionSyntaxNode(2),((op_type_node)LRParser.GetReductionSyntaxNode(1)).type);
			parsertools.create_source_context(_bin_expr,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(2));
			
			return _bin_expr;
		}

	case (int)RuleConstants.RULE_FORMAT_EXPR_TKCOLON :
	//<format_expr> ::= <simple_expr> tkColon <simple_expr>
         
		{
			format_expr _format_expr=new format_expr((expression)LRParser.GetReductionSyntaxNode(0),(expression)LRParser.GetReductionSyntaxNode(2),null);
			parsertools.create_source_context(_format_expr,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(2));
			
			return _format_expr;
		}

	case (int)RuleConstants.RULE_FORMAT_EXPR_TKCOLON_TKCOLON :
	//<format_expr> ::= <simple_expr> tkColon <simple_expr> tkColon <simple_expr>
         
		{
			format_expr _format_expr=new format_expr((expression)LRParser.GetReductionSyntaxNode(0),(expression)LRParser.GetReductionSyntaxNode(2),(expression)LRParser.GetReductionSyntaxNode(4));
			parsertools.create_source_context(_format_expr,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(4));
			
			return _format_expr;
		}

	case (int)RuleConstants.RULE_RELOP_TKEQUAL :
	//<relop> ::= tkEqual
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_RELOP_TKNOTEQUAL :
	//<relop> ::= tkNotEqual
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_RELOP_TKLOWER :
	//<relop> ::= tkLower
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_RELOP_TKGREATER :
	//<relop> ::= tkGreater
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_RELOP_TKLOWEREQUAL :
	//<relop> ::= tkLowerEqual
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_RELOP_TKGREATEREQUAL :
	//<relop> ::= tkGreaterEqual
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_RELOP_TKIN :
	//<relop> ::= tkIn
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_SIMPLE_EXPR :
	//<simple_expr> ::= <term>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_SIMPLE_EXPR2 :
	//<simple_expr> ::= <simple_expr> <addop> <term>
         
		{
			bin_expr _bin_expr=new bin_expr(LRParser.GetReductionSyntaxNode(0) as expression,LRParser.GetReductionSyntaxNode(2) as expression,((op_type_node)LRParser.GetReductionSyntaxNode(1)).type);
			parsertools.create_source_context(_bin_expr,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(2));
			
			return _bin_expr;
		}

	case (int)RuleConstants.RULE_ADDOP_TKPLUS :
	//<addop> ::= tkPlus
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_ADDOP_TKMINUS :
	//<addop> ::= tkMinus
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_ADDOP_TKOR :
	//<addop> ::= tkOr
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_ADDOP_TKXOR :
	//<addop> ::= tkXor
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_ADDOP_TKCSHARPSTYLEOR :
	//<addop> ::= tkCSharpStyleOr
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_TYPECAST_OP_TKAS :
	//<typecast_op> ::= tkAs <empty>
 return op_typecast.as_op; 
	case (int)RuleConstants.RULE_TYPECAST_OP_TKIS :
	//<typecast_op> ::= tkIs <empty>
 return op_typecast.is_op; 
	case (int)RuleConstants.RULE_AS_IS_EXPR :
	//<as_is_expr> ::= <term> <typecast_op> <simple_or_template_type_reference>
         
		{
			typecast_node _typecast_node=new typecast_node((addressed_value)LRParser.GetReductionSyntaxNode(0),(type_definition)LRParser.GetReductionSyntaxNode(2),(op_typecast)LRParser.GetReductionSyntaxNode(1));
			parsertools.create_source_context(_typecast_node,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(2));
			
								if (!(LRParser.GetReductionSyntaxNode(0) is addressed_value)) 
									errors.Add(new Errors.bad_operand_type(current_file_name,((syntax_tree_node)LRParser.GetReductionSyntaxNode(0)).source_context,_typecast_node));
								
			return _typecast_node;
		}

	case (int)RuleConstants.RULE_TERM :
	//<term> ::= <factor>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_TERM2 :
	//<term> ::= <new_expr>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_TERM3 :
	//<term> ::= <term> <mulop> <factor>
         
		{
			bin_expr _bin_expr=new bin_expr(LRParser.GetReductionSyntaxNode(0) as expression,LRParser.GetReductionSyntaxNode(2) as expression,((op_type_node)LRParser.GetReductionSyntaxNode(1)).type);
			parsertools.create_source_context(_bin_expr,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(2));
			
			return _bin_expr;
		}

	case (int)RuleConstants.RULE_TERM4 :
	//<term> ::= <as_is_expr>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_MULOP_TKSTAR :
	//<mulop> ::= tkStar
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_MULOP_TKSLASH :
	//<mulop> ::= tkSlash
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_MULOP_TKDIV :
	//<mulop> ::= tkDiv
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_MULOP_TKMOD :
	//<mulop> ::= tkMod
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_MULOP_TKSHL :
	//<mulop> ::= tkShl
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_MULOP_TKSHR :
	//<mulop> ::= tkShr
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_MULOP_TKAND :
	//<mulop> ::= tkAnd
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_DEFAULT_EXPR_TKDEFAULT_TKROUNDOPEN_TKROUNDCLOSE :
	//<default_expr> ::= tkDefault tkRoundOpen <simple_or_template_type_reference> tkRoundClose
         
		{
			default_operator _default_operator=new default_operator(LRParser.GetReductionSyntaxNode(2) as named_type_reference);
			 parsertools.create_source_context(_default_operator,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(3));
			return _default_operator;
		}

	case (int)RuleConstants.RULE_FACTOR_TKNIL :
	//<factor> ::= tkNil <empty>
         
		{
			nil_const _nil_const=new nil_const();
			 parsertools.create_source_context(_nil_const,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(0));
			return _nil_const;
		}

	case (int)RuleConstants.RULE_FACTOR :
	//<factor> ::= <literal_or_number>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_FACTOR2 :
	//<factor> ::= <default_expr>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_FACTOR_TKSQUAREOPEN_TKSQUARECLOSE :
	//<factor> ::= tkSquareOpen <elem_list> tkSquareClose
         
		{
			pascal_set_constant _pascal_set_constant=new pascal_set_constant(LRParser.GetReductionSyntaxNode(1) as expression_list);
			 parsertools.create_source_context(_pascal_set_constant,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(2));
			return _pascal_set_constant;
		}

	case (int)RuleConstants.RULE_FACTOR_TKNOT :
	//<factor> ::= tkNot <factor>
         
		{
			un_expr _un_expr=new un_expr(LRParser.GetReductionSyntaxNode(1) as expression,((op_type_node)LRParser.GetReductionSyntaxNode(0)).type);
			parsertools.create_source_context(_un_expr,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(1));
			
			return _un_expr;
		}

	case (int)RuleConstants.RULE_FACTOR3 :
	//<factor> ::= <sign> <factor>
         
		{
			un_expr _un_expr=new un_expr(LRParser.GetReductionSyntaxNode(1) as expression,((op_type_node)LRParser.GetReductionSyntaxNode(0)).type);
			parsertools.create_source_context(_un_expr,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(1));
			
			return _un_expr;
		}

	case (int)RuleConstants.RULE_FACTOR_TKDEREF :
	//<factor> ::= tkDeref <factor>
         
		{
			roof_dereference _roof_dereference=new roof_dereference();
			 
							_roof_dereference.dereferencing_value=(addressed_value)LRParser.GetReductionSyntaxNode(1);
							parsertools.create_source_context(_roof_dereference,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(1));
			return _roof_dereference;
		}

	case (int)RuleConstants.RULE_FACTOR4 :
	//<factor> ::= <var_reference>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_FACTOR_TKROUNDOPEN_TKROUNDCLOSE_TKROUNDOPEN_TKROUNDCLOSE :
	//<factor> ::= tkRoundOpen <func_decl_lambda> tkRoundClose tkRoundOpen <expr_list> tkRoundClose
{ function_lambda_definition fld = find_pascalABC_lambda_name(((ident)LRParser.GetReductionSyntaxNode(1)).name);
    														expression_list _expression_list = (expression_list)LRParser.GetReductionSyntaxNode(4);
    														function_lambda_definition _lambda_definition = fld;
    														function_lambda_call _lambda_call = new function_lambda_call(_lambda_definition, _expression_list);
    														_lambda_call.source_context = ((ident)LRParser.GetReductionSyntaxNode(1)).source_context;
    														return _lambda_call;}
	case (int)RuleConstants.RULE_LITERAL_OR_NUMBER :
	//<literal_or_number> ::= <literal>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_LITERAL_OR_NUMBER2 :
	//<literal_or_number> ::= <unsigned_number>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_VAR_REFERENCE :
	//<var_reference> ::= <var_address> <variable>
((get_address)LRParser.GetReductionSyntaxNode(0)).address_of=(addressed_value)LRParser.GetReductionSyntaxNode(1);parsertools.create_source_context(NodesStack.Peek(),NodesStack.Peek(),LRParser.GetReductionSyntaxNode(1));return NodesStack.Pop();
	case (int)RuleConstants.RULE_VAR_REFERENCE2 :
	//<var_reference> ::= <variable>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_VAR_ADDRESS_TKADDRESSOF :
	//<var_address> ::= tkAddressOf <empty>
         
		{
			get_address _get_address=new get_address();
			 parsertools.assign_source_context(_get_address,LRParser.GetReductionSyntaxNode(0)); NodesStack.Push(_get_address);
			return _get_address;
		}

	case (int)RuleConstants.RULE_VAR_ADDRESS_TKADDRESSOF2 :
	//<var_address> ::= <var_address> tkAddressOf
         
		{
			get_address _get_address=new get_address();
			 ((get_address)LRParser.GetReductionSyntaxNode(0)).address_of=(addressed_value)_get_address;parsertools.create_source_context(_get_address,LRParser.GetReductionSyntaxNode(1),LRParser.GetReductionSyntaxNode(1));
			return _get_address;
		}

	case (int)RuleConstants.RULE_ATTRIBUTE_VARIABLE :
	//<attribute_variable> ::= <simple_type_identifier> <opt_expr_list_with_bracket>
         
		{
			attribute _attribute=new attribute(null,(named_type_reference)LRParser.GetReductionSyntaxNode(0),(expression_list)LRParser.GetReductionSyntaxNode(1));
			parsertools.create_source_context(_attribute,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(1));
			
		if (LRParser.GetReductionSyntaxNode(1) == null)
			parsertools.create_source_context(_attribute,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(0));
	
			return _attribute;
		}

	case (int)RuleConstants.RULE_VARIABLE :
	//<variable> ::= <identifier>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_VARIABLE2 :
	//<variable> ::= <operator_name_ident>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_VARIABLE_TKINHERITED :
	//<variable> ::= tkInherited <identifier>
         
		{
			inherited_ident _inherited_ident=new inherited_ident();
			 _inherited_ident.name=((ident)LRParser.GetReductionSyntaxNode(1)).name; parsertools.create_source_context(_inherited_ident,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(1));
			return _inherited_ident;
		}

	case (int)RuleConstants.RULE_VARIABLE_TKROUNDOPEN_TKROUNDCLOSE :
	//<variable> ::= tkRoundOpen <expr> tkRoundClose
if (!build_tree_for_brackets) { parsertools.create_source_context(LRParser.GetReductionSyntaxNode(1),LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(2));return LRParser.GetReductionSyntaxNode(1);} else 
														{
															expression br_exp = new bracket_expr(LRParser.GetReductionSyntaxNode(1) as expression);
															parsertools.create_source_context(br_exp,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(2));
															return br_exp;
														}
													
	case (int)RuleConstants.RULE_VARIABLE3 :
	//<variable> ::= <sizeof_expr>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_VARIABLE4 :
	//<variable> ::= <typeof_expr>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_VARIABLE_TKROUNDOPEN_TKROUNDCLOSE2 :
	//<variable> ::= tkRoundOpen tkRoundClose
 {errors.Add(new nonterminal_token_return_null(current_file_name,parsertools.GetTokenSourceContext(),(syntax_tree_node)prev_node,"<variable> ::= tkRoundOpen tkRoundClose"));}return null;
	case (int)RuleConstants.RULE_VARIABLE_TKPOINT :
	//<variable> ::= <literal_or_number> tkPoint <identifier_or_keyword>
         
		{
			dot_node _dot_node=new dot_node((addressed_value)LRParser.GetReductionSyntaxNode(0),(addressed_value)LRParser.GetReductionSyntaxNode(2));
			parsertools.create_source_context(_dot_node,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(2));
			
			return _dot_node;
		}

	case (int)RuleConstants.RULE_VARIABLE5 :
	//<variable> ::= <variable> <var_specifiers>

							if (LRParser.GetReductionSyntaxNode(1) is dot_node) 
							{
							  ((dot_node)LRParser.GetReductionSyntaxNode(1)).left=(addressed_value)LRParser.GetReductionSyntaxNode(0);
							  parsertools.create_source_context(LRParser.GetReductionSyntaxNode(1),LRParser.GetReductionSyntaxNode(0),((dot_node)LRParser.GetReductionSyntaxNode(1)).right);
							}
							else
							if (LRParser.GetReductionSyntaxNode(1) is template_param_list) 
							{
							  ((dot_node)(((template_param_list)LRParser.GetReductionSyntaxNode(1)).dereferencing_value)).left=(addressed_value)LRParser.GetReductionSyntaxNode(0);
                                                          parsertools.create_source_context(LRParser.GetReductionSyntaxNode(1),LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(1));
							  parsertools.create_source_context(((template_param_list)LRParser.GetReductionSyntaxNode(1)).dereferencing_value,LRParser.GetReductionSyntaxNode(0),((template_param_list)LRParser.GetReductionSyntaxNode(1)).dereferencing_value);
							}
							else
							if (LRParser.GetReductionSyntaxNode(1) is dereference) 
							{
							  ((dereference)LRParser.GetReductionSyntaxNode(1)).dereferencing_value=(addressed_value)LRParser.GetReductionSyntaxNode(0);
							  parsertools.create_source_context(LRParser.GetReductionSyntaxNode(1),LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(1));
							}
							else
							if (LRParser.GetReductionSyntaxNode(1) is ident_with_templateparams) 
							{
								((ident_with_templateparams)LRParser.GetReductionSyntaxNode(1)).name=(addressed_value_funcname)LRParser.GetReductionSyntaxNode(0);
								parsertools.create_source_context(LRParser.GetReductionSyntaxNode(1),LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(1));
							}
							return LRParser.GetReductionSyntaxNode(1);
							
	case (int)RuleConstants.RULE_OPT_EXPR_LIST :
	//<opt_expr_list> ::= <expr_list>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_OPT_EXPR_LIST2 :
	//<opt_expr_list> ::= 
	//NONTERMINAL:<opt_expr_list> ::= 
	return null;
	//ENDNONTERMINAL
	case (int)RuleConstants.RULE_OPT_ATTR_EXPR_LIST :
	//<opt_attr_expr_list> ::= <attr_expr_list>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_OPT_ATTR_EXPR_LIST2 :
	//<opt_attr_expr_list> ::= 
	//NONTERMINAL:<opt_attr_expr_list> ::= 
	return null;
	//ENDNONTERMINAL
	case (int)RuleConstants.RULE_ATTRIBUTE_VAR_SPECIFIERS_TKROUNDOPEN_TKROUNDCLOSE :
	//<attribute_var_specifiers> ::= tkRoundOpen <opt_attr_expr_list> tkRoundClose
         
		{
			method_call _method_call=new method_call(LRParser.GetReductionSyntaxNode(1) as expression_list);
			 parsertools.create_source_context(_method_call,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(2));
			return _method_call;
		}

	case (int)RuleConstants.RULE_ATTRIBUTE_VAR_SPECIFIERS_TKPOINT :
	//<attribute_var_specifiers> ::= tkPoint <identifier_keyword_operatorname>
         
		{
			dot_node _dot_node=new dot_node(null,(addressed_value)LRParser.GetReductionSyntaxNode(1));
			 parsertools.create_source_context(_dot_node,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(1));
			return _dot_node;
		}

	case (int)RuleConstants.RULE_VAR_SPECIFIERS_TKSQUAREOPEN_TKSQUARECLOSE :
	//<var_specifiers> ::= tkSquareOpen <expr_list> tkSquareClose
         
		{
			indexer _indexer=new indexer((expression_list)LRParser.GetReductionSyntaxNode(1));
			 parsertools.create_source_context(_indexer,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(2));
			return _indexer;
		}

	case (int)RuleConstants.RULE_VAR_SPECIFIERS_TKSQUAREOPEN_TKSQUARECLOSE2 :
	//<var_specifiers> ::= tkSquareOpen tkSquareClose
 {errors.Add(new nonterminal_token_return_null(current_file_name,parsertools.GetTokenSourceContext(),(syntax_tree_node)prev_node,"<var_specifiers> ::= tkSquareOpen tkSquareClose"));}return null;
	case (int)RuleConstants.RULE_VAR_SPECIFIERS_TKROUNDOPEN_TKROUNDCLOSE :
	//<var_specifiers> ::= tkRoundOpen <opt_expr_list> tkRoundClose
         
		{
			method_call _method_call=new method_call(LRParser.GetReductionSyntaxNode(1) as expression_list);
			 parsertools.create_source_context(_method_call,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(2));
			return _method_call;
		}

	case (int)RuleConstants.RULE_VAR_SPECIFIERS_TKPOINT :
	//<var_specifiers> ::= tkPoint <identifier_keyword_operatorname>
         
		{
			dot_node _dot_node=new dot_node(null,(addressed_value)LRParser.GetReductionSyntaxNode(1));
			 parsertools.create_source_context(_dot_node,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(1));
			return _dot_node;
		}

	case (int)RuleConstants.RULE_VAR_SPECIFIERS_TKDEREF :
	//<var_specifiers> ::= tkDeref <empty>
         
		{
			roof_dereference _roof_dereference=new roof_dereference();
			 parsertools.assign_source_context(_roof_dereference,LRParser.GetReductionSyntaxNode(0));
			return _roof_dereference;
		}

	case (int)RuleConstants.RULE_VAR_SPECIFIERS_TKAMPERSEND :
	//<var_specifiers> ::= tkAmpersend <template_type_params>
         
		{
			ident_with_templateparams _ident_with_templateparams=new ident_with_templateparams(null,(template_param_list)LRParser.GetReductionSyntaxNode(1));
			 parsertools.create_source_context(_ident_with_templateparams,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(1));
			return _ident_with_templateparams;
		}

	case (int)RuleConstants.RULE_TEMPLATE_TYPE_BACK_VARSPECIFIERS_TKROUNDOPEN_TKROUNDCLOSE :
	//<template_type_back_varspecifiers> ::= tkRoundOpen <expr_list> tkRoundClose
         
		{
			method_call _method_call=new method_call((expression_list)LRParser.GetReductionSyntaxNode(1));
			 parsertools.create_source_context(_method_call,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(2));
			return _method_call;
		}

	case (int)RuleConstants.RULE_TEMPLATE_TYPE_BACK_VARSPECIFIERS_TKROUNDOPEN_TKROUNDCLOSE2 :
	//<template_type_back_varspecifiers> ::= tkRoundOpen tkRoundClose
         
		{
			method_call _method_call=new method_call();
			 parsertools.create_source_context(_method_call,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(1));
			return _method_call;
		}

	case (int)RuleConstants.RULE_ELEM_LIST :
	//<elem_list> ::= <elem_list1>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_ELEM_LIST2 :
	//<elem_list> ::= 
	//NONTERMINAL:<elem_list> ::= 
	return null;
	//ENDNONTERMINAL
	case (int)RuleConstants.RULE_ELEM_LIST1 :
	//<elem_list1> ::= <elem> <empty>
         
		//TemplateList for expression_list (create)
		{
			expression_list _expression_list=new expression_list();
			_expression_list.source_context=((expression)LRParser.GetReductionSyntaxNode(0)).source_context;
			_expression_list.expressions.Add((expression)LRParser.GetReductionSyntaxNode(0));
			return _expression_list;
		}

	case (int)RuleConstants.RULE_ELEM_LIST1_TKCOMMA :
	//<elem_list1> ::= <elem_list1> tkComma <elem>

		//TemplateList for expression_list (add)         
		{
			expression_list _expression_list=(expression_list)LRParser.GetReductionSyntaxNode(0);
			parsertools.create_source_context(_expression_list,_expression_list,LRParser.GetReductionSyntaxNode(2));
			_expression_list.expressions.Add(LRParser.GetReductionSyntaxNode(2) as expression);
			return _expression_list;
		}

	case (int)RuleConstants.RULE_ELEM :
	//<elem> ::= <expr>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_ELEM_TKDOTDOT :
	//<elem> ::= <expr> tkDotDot <expr>
         
		{
			diapason_expr _diapason_expr=new diapason_expr((expression)LRParser.GetReductionSyntaxNode(0),(expression)LRParser.GetReductionSyntaxNode(2));
			parsertools.create_source_context(_diapason_expr,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(2));
			
			return _diapason_expr;
		}

	case (int)RuleConstants.RULE_ONE_LITERAL_TKSTRINGLITERAL :
	//<one_literal> ::= tkStringLiteral
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_ONE_LITERAL_TKASCIICHAR :
	//<one_literal> ::= tkAsciiChar
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_LITERAL :
	//<literal> ::= <literal_list> <empty>
 literal_const_line lcl=(literal_const_line)LRParser.GetReductionSyntaxNode(0);
	                                        if (lcl.literals.Count==1) return lcl.literals[0];
						return lcl;
						
	case (int)RuleConstants.RULE_LITERAL_LIST :
	//<literal_list> ::= <one_literal> <empty>
         
		{
			literal_const_line _literal_const_line=new literal_const_line();
			parsertools.create_source_context(_literal_const_line,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(0));
			
						_literal_const_line.literals.Add((literal)LRParser.GetReductionSyntaxNode(0));
						
			return _literal_const_line;
		}

	case (int)RuleConstants.RULE_LITERAL_LIST2 :
	//<literal_list> ::= <literal_list> <one_literal>
         
		{
			literal_const_line _literal_const_line=(literal_const_line)LRParser.GetReductionSyntaxNode(0);
						_literal_const_line.literals.Add((literal)LRParser.GetReductionSyntaxNode(1));
						parsertools.create_source_context(_literal_const_line,_literal_const_line,LRParser.GetReductionSyntaxNode(1));
						
			return _literal_const_line;
		}

	case (int)RuleConstants.RULE_OPERATOR_NAME_IDENT_TKOPERATOR :
	//<operator_name_ident> ::= tkOperator <overload_operator>
         
		{
			operator_name_ident _operator_name_ident=new operator_name_ident(((op_type_node)LRParser.GetReductionSyntaxNode(1)).type);
			
								_operator_name_ident.name=((op_type_node)LRParser.GetReductionSyntaxNode(1)).text;
								parsertools.create_source_context(_operator_name_ident,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(1));
			return _operator_name_ident;
		}

	case (int)RuleConstants.RULE_OPT_METH_MODIFICATORS_TKSEMICOLON :
	//<opt_meth_modificators> ::= tkSemiColon
         
		{
			procedure_attributes_list _procedure_attributes_list=new procedure_attributes_list();
			 parsertools.AddModifier(_procedure_attributes_list,proc_attribute.attr_overload);  parsertools.create_source_context(_procedure_attributes_list,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(0)); 
			return _procedure_attributes_list;
		}

	case (int)RuleConstants.RULE_OPT_METH_MODIFICATORS_TKSEMICOLON_TKSEMICOLON :
	//<opt_meth_modificators> ::= tkSemiColon <meth_modificators> tkSemiColon
 parsertools.AddModifier((procedure_attributes_list)LRParser.GetReductionSyntaxNode(1),proc_attribute.attr_overload); return LRParser.GetReductionSyntaxNode(1); 
	case (int)RuleConstants.RULE_METH_MODIFICATORS :
	//<meth_modificators> ::= <meth_modificator> <empty>
         
		//TemplateList for procedure_attributes_list (create)
		{
			procedure_attributes_list _procedure_attributes_list=new procedure_attributes_list();
			_procedure_attributes_list.source_context=((procedure_attribute)LRParser.GetReductionSyntaxNode(0)).source_context;
			_procedure_attributes_list.proc_attributes.Add((procedure_attribute)LRParser.GetReductionSyntaxNode(0));
			return _procedure_attributes_list;
		}

	case (int)RuleConstants.RULE_METH_MODIFICATORS_TKSEMICOLON :
	//<meth_modificators> ::= <meth_modificators> tkSemiColon <meth_modificator>

		//TemplateList for procedure_attributes_list (add)         
		{
			procedure_attributes_list _procedure_attributes_list=(procedure_attributes_list)LRParser.GetReductionSyntaxNode(0);
			parsertools.create_source_context(_procedure_attributes_list,_procedure_attributes_list,LRParser.GetReductionSyntaxNode(2));
			_procedure_attributes_list.proc_attributes.Add(LRParser.GetReductionSyntaxNode(2) as procedure_attribute);
			return _procedure_attributes_list;
		}

	case (int)RuleConstants.RULE_INTEGER_CONST_TKINTEGER :
	//<integer_const> ::= <sign> tkInteger
 {errors.Add(new nonterminal_token_return_null(current_file_name,parsertools.GetTokenSourceContext(),(syntax_tree_node)prev_node,"<integer_const> ::= <sign> tkInteger"));}return null;
	case (int)RuleConstants.RULE_INTEGER_CONST_TKINTEGER2 :
	//<integer_const> ::= tkInteger
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_INTEGER_CONST_TKHEX :
	//<integer_const> ::= <sign> tkHex
 {errors.Add(new nonterminal_token_return_null(current_file_name,parsertools.GetTokenSourceContext(),(syntax_tree_node)prev_node,"<integer_const> ::= <sign> tkHex"));}return null;
	case (int)RuleConstants.RULE_INTEGER_CONST_TKHEX2 :
	//<integer_const> ::= tkHex
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_INTEGER_CONST :
	//<integer_const> ::= <identifier>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_INTEGER_CONST2 :
	//<integer_const> ::= <sign> <identifier>
 {errors.Add(new nonterminal_token_return_null(current_file_name,parsertools.GetTokenSourceContext(),(syntax_tree_node)prev_node,"<integer_const> ::= <sign> <identifier>"));}return null;
	case (int)RuleConstants.RULE_IDENTIFIER_TKIDENTIFIER :
	//<identifier> ::= tkIdentifier
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_IDENTIFIER :
	//<identifier> ::= <real_type_name>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_IDENTIFIER2 :
	//<identifier> ::= <ord_type_name>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_IDENTIFIER3 :
	//<identifier> ::= <variant_type_name>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_IDENTIFIER4 :
	//<identifier> ::= <meth_modificator>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_IDENTIFIER5 :
	//<identifier> ::= <property_specifier_directives>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_IDENTIFIER6 :
	//<identifier> ::= <non_reserved>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_IDENTIFIER7 :
	//<identifier> ::= <other>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_IDENTIFIER_OR_KEYWORD :
	//<identifier_or_keyword> ::= <identifier>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_IDENTIFIER_OR_KEYWORD2 :
	//<identifier_or_keyword> ::= <keyword> <empty>
         
		{
			ident _ident=new ident((LRParser.GetReductionSyntaxNode(0) as token_info).text);
			 parsertools.create_source_context(_ident,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(0));
			return _ident;
		}

	case (int)RuleConstants.RULE_IDENTIFIER_OR_KEYWORD3 :
	//<identifier_or_keyword> ::= <reserved_keyword> <empty>
         
		{
			ident _ident=new ident((LRParser.GetReductionSyntaxNode(0) as token_info).text);
			 parsertools.create_source_context(_ident,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(0));
			return _ident;
		}

	case (int)RuleConstants.RULE_IDENTIFIER_KEYWORD_OPERATORNAME :
	//<identifier_keyword_operatorname> ::= <identifier>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_IDENTIFIER_KEYWORD_OPERATORNAME2 :
	//<identifier_keyword_operatorname> ::= <keyword> <empty>
         
		{
			ident _ident=new ident((LRParser.GetReductionSyntaxNode(0) as token_info).text);
			 parsertools.create_source_context(_ident,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(0));
			return _ident;
		}

	case (int)RuleConstants.RULE_IDENTIFIER_KEYWORD_OPERATORNAME3 :
	//<identifier_keyword_operatorname> ::= <operator_name_ident>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_REAL_TYPE_NAME_TKREAL :
	//<real_type_name> ::= tkReal
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_REAL_TYPE_NAME_TKSINGLE :
	//<real_type_name> ::= tkSingle
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_REAL_TYPE_NAME_TKDOUBLE :
	//<real_type_name> ::= tkDouble
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_REAL_TYPE_NAME_TKEXTENDED :
	//<real_type_name> ::= tkExtended
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_REAL_TYPE_NAME_TKCOMP :
	//<real_type_name> ::= tkComp
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_ORD_TYPE_NAME_TKSHORTINT :
	//<ord_type_name> ::= tkShortInt
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_ORD_TYPE_NAME_TKSMALLINT :
	//<ord_type_name> ::= tkSmallInt
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_ORD_TYPE_NAME_TKORDINTEGER :
	//<ord_type_name> ::= tkOrdInteger
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_ORD_TYPE_NAME_TKBYTE :
	//<ord_type_name> ::= tkByte
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_ORD_TYPE_NAME_TKLONGINT :
	//<ord_type_name> ::= tkLongInt
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_ORD_TYPE_NAME_TKINT64 :
	//<ord_type_name> ::= tkInt64
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_ORD_TYPE_NAME_TKWORD :
	//<ord_type_name> ::= tkWord
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_ORD_TYPE_NAME_TKBOOLEAN :
	//<ord_type_name> ::= tkBoolean
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_ORD_TYPE_NAME_TKCHAR :
	//<ord_type_name> ::= tkChar
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_ORD_TYPE_NAME_TKWIDECHAR :
	//<ord_type_name> ::= tkWideChar
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_ORD_TYPE_NAME_TKLONGWORD :
	//<ord_type_name> ::= tkLongWord
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_ORD_TYPE_NAME_TKPCHAR :
	//<ord_type_name> ::= tkPChar
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_ORD_TYPE_NAME_TKCARDINAL :
	//<ord_type_name> ::= tkCardinal
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_VARIANT_TYPE_NAME_TKVARIANT :
	//<variant_type_name> ::= tkVariant
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_VARIANT_TYPE_NAME_TKOLEVARIANT :
	//<variant_type_name> ::= tkOleVariant
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_METH_MODIFICATOR_TKABSTRACT :
	//<meth_modificator> ::= tkAbstract
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_METH_MODIFICATOR_TKOVERLOAD :
	//<meth_modificator> ::= tkOverload
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_METH_MODIFICATOR_TKREINTRODUCE :
	//<meth_modificator> ::= tkReintroduce
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_METH_MODIFICATOR_TKOVERRIDE :
	//<meth_modificator> ::= tkOverride
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_METH_MODIFICATOR_TKVIRTUAL :
	//<meth_modificator> ::= tkVirtual
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_METH_MODIFICATOR_TKSTATIC :
	//<meth_modificator> ::= tkStatic
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_PROPERTY_SPECIFIER_DIRECTIVES_TKREAD :
	//<property_specifier_directives> ::= tkRead
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_PROPERTY_SPECIFIER_DIRECTIVES_TKWRITE :
	//<property_specifier_directives> ::= tkWrite
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_PROPERTY_SPECIFIER_DIRECTIVES_TKSTORED :
	//<property_specifier_directives> ::= tkStored
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_PROPERTY_SPECIFIER_DIRECTIVES_TKNODEFAULT :
	//<property_specifier_directives> ::= tkNodefault
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_PROPERTY_SPECIFIER_DIRECTIVES_TKIMPLEMENTS :
	//<property_specifier_directives> ::= tkImplements
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_PROPERTY_SPECIFIER_DIRECTIVES_TKWRITEONLY :
	//<property_specifier_directives> ::= tkWriteOnly
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_PROPERTY_SPECIFIER_DIRECTIVES_TKREADONLY :
	//<property_specifier_directives> ::= tkReadOnly
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_PROPERTY_SPECIFIER_DIRECTIVES_TKDISPID :
	//<property_specifier_directives> ::= tkDispid
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_NON_RESERVED_TKAT :
	//<non_reserved> ::= tkAt
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_NON_RESERVED_TKABSOLUTE :
	//<non_reserved> ::= tkAbsolute
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_NON_RESERVED_TKON :
	//<non_reserved> ::= tkOn
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_NON_RESERVED_TKNAME :
	//<non_reserved> ::= tkName
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_NON_RESERVED_TKINDEX :
	//<non_reserved> ::= tkIndex
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_NON_RESERVED_TKMESSAGE :
	//<non_reserved> ::= tkMessage
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_NON_RESERVED_TKCONTAINS :
	//<non_reserved> ::= tkContains
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_NON_RESERVED_TKREQUIRES :
	//<non_reserved> ::= tkRequires
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_NON_RESERVED_TKFORWARD :
	//<non_reserved> ::= tkForward
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_NON_RESERVED_TKOUT :
	//<non_reserved> ::= tkOut
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_VISIBILITY_SPECIFIER_TKINTERNAL :
	//<visibility_specifier> ::= tkInternal
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_VISIBILITY_SPECIFIER_TKPUBLIC :
	//<visibility_specifier> ::= tkPublic
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_VISIBILITY_SPECIFIER_TKPROTECTED :
	//<visibility_specifier> ::= tkProtected
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_VISIBILITY_SPECIFIER_TKPRIVATE :
	//<visibility_specifier> ::= tkPrivate
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_OTHER_TKPACKAGE :
	//<other> ::= tkPackage
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_OTHER_TKUNIT :
	//<other> ::= tkUnit
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_OTHER_TKLIBRARY :
	//<other> ::= tkLibrary
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_OTHER_TKEXTERNAL :
	//<other> ::= tkExternal
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_OTHER_TKPARAMS :
	//<other> ::= tkParams
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_KEYWORD :
	//<keyword> ::= <visibility_specifier> <empty>
         
		{
			token_info _token_info=new token_info((LRParser.GetReductionSyntaxNode(0) as ident).name);
			 parsertools.create_source_context(_token_info,LRParser.GetReductionSyntaxNode(0),LRParser.GetReductionSyntaxNode(0));
			return _token_info;
		}

	case (int)RuleConstants.RULE_KEYWORD_TKFINAL :
	//<keyword> ::= tkFinal
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_KEYWORD_TKTEMPLATE :
	//<keyword> ::= tkTemplate
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_KEYWORD_TKOR :
	//<keyword> ::= tkOr
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_KEYWORD_TKTYPEOF :
	//<keyword> ::= tkTypeOf
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_KEYWORD_TKSIZEOF :
	//<keyword> ::= tkSizeOf
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_KEYWORD_TKDEFAULT :
	//<keyword> ::= tkDefault
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_KEYWORD_TKWHERE :
	//<keyword> ::= tkWhere
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_KEYWORD_TKXOR :
	//<keyword> ::= tkXor
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_KEYWORD_TKAND :
	//<keyword> ::= tkAnd
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_KEYWORD_TKDIV :
	//<keyword> ::= tkDiv
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_KEYWORD_TKMOD :
	//<keyword> ::= tkMod
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_KEYWORD_TKSHL :
	//<keyword> ::= tkShl
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_KEYWORD_TKSHR :
	//<keyword> ::= tkShr
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_KEYWORD_TKNOT :
	//<keyword> ::= tkNot
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_KEYWORD_TKAS :
	//<keyword> ::= tkAs
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_KEYWORD_TKIN :
	//<keyword> ::= tkIn
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_KEYWORD_TKIS :
	//<keyword> ::= tkIs
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_KEYWORD_TKARRAY :
	//<keyword> ::= tkArray
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_KEYWORD_TKBEGIN :
	//<keyword> ::= tkBegin
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_KEYWORD_TKCASE :
	//<keyword> ::= tkCase
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_KEYWORD_TKCLASS :
	//<keyword> ::= tkClass
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_KEYWORD_TKCONST :
	//<keyword> ::= tkConst
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_KEYWORD_TKCONSTRUCTOR :
	//<keyword> ::= tkConstructor
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_KEYWORD_TKDESTRUCTOR :
	//<keyword> ::= tkDestructor
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_KEYWORD_TKDOWNTO :
	//<keyword> ::= tkDownto
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_KEYWORD_TKDO :
	//<keyword> ::= tkDo
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_KEYWORD_TKELSE :
	//<keyword> ::= tkElse
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_KEYWORD_TKEXCEPT :
	//<keyword> ::= tkExcept
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_KEYWORD_TKFILE :
	//<keyword> ::= tkFile
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_KEYWORD_TKFINALIZATION :
	//<keyword> ::= tkFinalization
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_KEYWORD_TKFINALLY :
	//<keyword> ::= tkFinally
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_KEYWORD_TKFOR :
	//<keyword> ::= tkFor
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_KEYWORD_TKFOREACH :
	//<keyword> ::= tkForeach
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_KEYWORD_TKFUNCTION :
	//<keyword> ::= tkFunction
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_KEYWORD_TKIF :
	//<keyword> ::= tkIf
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_KEYWORD_TKIMPLEMENTATION :
	//<keyword> ::= tkImplementation
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_KEYWORD_TKINHERITED :
	//<keyword> ::= tkInherited
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_KEYWORD_TKINITIALIZATION :
	//<keyword> ::= tkInitialization
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_KEYWORD_TKINTERFACE :
	//<keyword> ::= tkInterface
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_KEYWORD_TKPROCEDURE :
	//<keyword> ::= tkProcedure
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_KEYWORD_TKPROPERTY :
	//<keyword> ::= tkProperty
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_KEYWORD_TKRAISE :
	//<keyword> ::= tkRaise
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_KEYWORD_TKRECORD :
	//<keyword> ::= tkRecord
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_KEYWORD_TKREPEAT :
	//<keyword> ::= tkRepeat
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_KEYWORD_TKSET :
	//<keyword> ::= tkSet
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_KEYWORD_TKTRY :
	//<keyword> ::= tkTry
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_KEYWORD_TKTYPE :
	//<keyword> ::= tkType
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_KEYWORD_TKTHEN :
	//<keyword> ::= tkThen
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_KEYWORD_TKTO :
	//<keyword> ::= tkTo
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_KEYWORD_TKUNTIL :
	//<keyword> ::= tkUntil
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_KEYWORD_TKUSES :
	//<keyword> ::= tkUses
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_KEYWORD_TKUSING :
	//<keyword> ::= tkUsing
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_KEYWORD_TKVAR :
	//<keyword> ::= tkVar
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_KEYWORD_TKWHILE :
	//<keyword> ::= tkWhile
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_KEYWORD_TKWITH :
	//<keyword> ::= tkWith
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_KEYWORD_TKNIL :
	//<keyword> ::= tkNil
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_KEYWORD_TKGOTO :
	//<keyword> ::= tkGoto
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_KEYWORD_TKOF :
	//<keyword> ::= tkOf
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_KEYWORD_TKLABEL :
	//<keyword> ::= tkLabel
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_KEYWORD_TKPROGRAM :
	//<keyword> ::= tkProgram
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_RESERVED_KEYWORD_TKOPERATOR :
	//<reserved_keyword> ::= tkOperator
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_RESERVED_KEYWORD_TKEND :
	//<reserved_keyword> ::= tkEnd
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_OVERLOAD_OPERATOR_TKMINUS :
	//<overload_operator> ::= tkMinus
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_OVERLOAD_OPERATOR_TKPLUS :
	//<overload_operator> ::= tkPlus
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_OVERLOAD_OPERATOR_TKSQUAREOPEN_TKSQUARECLOSE :
	//<overload_operator> ::= tkSquareOpen tkSquareClose
 {errors.Add(new nonterminal_token_return_null(current_file_name,parsertools.GetTokenSourceContext(),(syntax_tree_node)prev_node,"<overload_operator> ::= tkSquareOpen tkSquareClose"));}return null;
	case (int)RuleConstants.RULE_OVERLOAD_OPERATOR_TKROUNDOPEN_TKROUNDCLOSE :
	//<overload_operator> ::= tkRoundOpen tkRoundClose
 {errors.Add(new nonterminal_token_return_null(current_file_name,parsertools.GetTokenSourceContext(),(syntax_tree_node)prev_node,"<overload_operator> ::= tkRoundOpen tkRoundClose"));}return null;
	case (int)RuleConstants.RULE_OVERLOAD_OPERATOR_TKSLASH :
	//<overload_operator> ::= tkSlash
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_OVERLOAD_OPERATOR_TKSTAR :
	//<overload_operator> ::= tkStar
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_OVERLOAD_OPERATOR_TKEQUAL :
	//<overload_operator> ::= tkEqual
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_OVERLOAD_OPERATOR_TKGREATER :
	//<overload_operator> ::= tkGreater
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_OVERLOAD_OPERATOR_TKGREATEREQUAL :
	//<overload_operator> ::= tkGreaterEqual
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_OVERLOAD_OPERATOR_TKLOWER :
	//<overload_operator> ::= tkLower
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_OVERLOAD_OPERATOR_TKLOWEREQUAL :
	//<overload_operator> ::= tkLowerEqual
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_OVERLOAD_OPERATOR_TKNOTEQUAL :
	//<overload_operator> ::= tkNotEqual
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_OVERLOAD_OPERATOR_TKOR :
	//<overload_operator> ::= tkOr
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_OVERLOAD_OPERATOR_TKXOR :
	//<overload_operator> ::= tkXor
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_OVERLOAD_OPERATOR_TKAND :
	//<overload_operator> ::= tkAnd
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_OVERLOAD_OPERATOR_TKDIV :
	//<overload_operator> ::= tkDiv
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_OVERLOAD_OPERATOR_TKMOD :
	//<overload_operator> ::= tkMod
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_OVERLOAD_OPERATOR_TKSHL :
	//<overload_operator> ::= tkShl
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_OVERLOAD_OPERATOR_TKSHR :
	//<overload_operator> ::= tkShr
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_OVERLOAD_OPERATOR_TKNOT :
	//<overload_operator> ::= tkNot
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_OVERLOAD_OPERATOR_TKIN :
	//<overload_operator> ::= tkIn
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_OVERLOAD_OPERATOR_TKADDRESSOF :
	//<overload_operator> ::= tkAddressOf
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_OVERLOAD_OPERATOR_TKDEREF :
	//<overload_operator> ::= tkDeref
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_OVERLOAD_OPERATOR_TKIMPLICIT :
	//<overload_operator> ::= tkImplicit
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_OVERLOAD_OPERATOR_TKEXPLICIT :
	//<overload_operator> ::= tkExplicit
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_OVERLOAD_OPERATOR :
	//<overload_operator> ::= <assign_operator>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_ASSIGN_OPERATOR_TKASSIGN :
	//<assign_operator> ::= tkAssign
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_ASSIGN_OPERATOR_TKPLUSEQUAL :
	//<assign_operator> ::= tkPlusEqual
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_ASSIGN_OPERATOR_TKMINUSEQUAL :
	//<assign_operator> ::= tkMinusEqual
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_ASSIGN_OPERATOR_TKMULTEQUAL :
	//<assign_operator> ::= tkMultEqual
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_ASSIGN_OPERATOR_TKDIVEQUAL :
	//<assign_operator> ::= tkDivEqual
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_EMPTY :
	//<empty> ::= 
	//NONTERMINAL:<empty> ::= 
	return null;
	//ENDNONTERMINAL
	case (int)RuleConstants.RULE_ERROR_TKERROR :
	//<error> ::= tkError
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_FUNC_DECL_LAMBDA_TKARROW :
	//<func_decl_lambda> ::= <ident_list1> tkArrow <lambda_body>
{return func_decl_lambda(LRParser.GetReductionSyntaxNode(0), LRParser.GetReductionSyntaxNode(2));}
	case (int)RuleConstants.RULE_FUNC_DECL_LAMBDA_TKARROW2 :
	//<func_decl_lambda> ::= tkArrow <lambda_body>
{return func_decl_lambda(null, LRParser.GetReductionSyntaxNode(1));}
	case (int)RuleConstants.RULE_FUNC_DECL_LAMBDA_TKROUNDOPEN_TKROUNDCLOSE_TKARROW :
	//<func_decl_lambda> ::= tkRoundOpen tkRoundClose tkArrow <lambda_body>
{return func_decl_lambda(null, LRParser.GetReductionSyntaxNode(3));}
	case (int)RuleConstants.RULE_IDENT_LIST1_TKROUNDOPEN_TKCOMMA_TKROUNDCLOSE :
	//<ident_list1> ::= tkRoundOpen <identifier> tkComma <ident_list2> tkRoundClose
{return ident_list11(LRParser.GetReductionSyntaxNode(1), LRParser.GetReductionSyntaxNode(3));}
	case (int)RuleConstants.RULE_IDENT_LIST1 :
	//<ident_list1> ::= <identifier> <empty>
{return ident_list12(LRParser.GetReductionSyntaxNode(0));}
	case (int)RuleConstants.RULE_IDENT_LIST1_TKROUNDOPEN_TKCOLON_TKCOMMA_TKROUNDCLOSE :
	//<ident_list1> ::= tkRoundOpen <identifier> tkColon <fptype> tkComma <ident_list2> tkRoundClose
{return ident_list13(LRParser.GetReductionSyntaxNode(1), LRParser.GetReductionSyntaxNode(3), LRParser.GetReductionSyntaxNode(5));}
	case (int)RuleConstants.RULE_IDENT_LIST1_TKROUNDOPEN_TKCOLON_TKROUNDCLOSE :
	//<ident_list1> ::= tkRoundOpen <identifier> tkColon <fptype> tkRoundClose
{return ident_list14(LRParser.GetReductionSyntaxNode(1), LRParser.GetReductionSyntaxNode(3));}
	case (int)RuleConstants.RULE_IDENT_LIST2_TKCOMMA :
	//<ident_list2> ::= <ident_list2> tkComma <var_or_identifier>
{return ident_list21(LRParser.GetReductionSyntaxNode(0), LRParser.GetReductionSyntaxNode(2));}
	case (int)RuleConstants.RULE_IDENT_LIST2 :
	//<ident_list2> ::= <var_or_identifier> <empty>
{return ident_list12(LRParser.GetReductionSyntaxNode(0));}
	case (int)RuleConstants.RULE_VAR_OR_IDENTIFIER :
	//<var_or_identifier> ::= <identifier>
return LRParser.GetReductionSyntaxNode(0);
	case (int)RuleConstants.RULE_VAR_OR_IDENTIFIER_TKCOLON :
	//<var_or_identifier> ::= <identifier> tkColon <fptype>
{
            named_type_reference n_t_r = (named_type_reference)LRParser.GetReductionSyntaxNode(2);
            var_def_statement vds = new var_def_statement();
            vds.vars = new ident_list();
            vds.vars.idents.Add((ident)LRParser.GetReductionSyntaxNode(0));
            vds.vars_type = n_t_r;
            return vds;
        }
	case (int)RuleConstants.RULE_LAMBDA_BODY :
	//<lambda_body> ::= <expr_l1> <empty>
{
statement_list _statement_list = new statement_list();
    ident id = new ident("result");
    op_type_node _op_type_node = new op_type_node(Operators.Assignment);
    _op_type_node.source_context = parsertools.GetTokenSourceContext();
    assign _assign = new assign((addressed_value)id, LRParser.GetReductionSyntaxNode(0) as expression, _op_type_node.type);
    parsertools.create_source_context(_assign, id, LRParser.GetReductionSyntaxNode(0));
    _statement_list.subnodes.Add((statement)_assign);
    parsertools.assign_source_context(_statement_list, _assign);
    parsertools.create_source_context(_statement_list, null, null);
    //block _block = new block(null, _statement_list);
   return _statement_list;
}

	case (int)RuleConstants.RULE_LAMBDA_BODY2 :
	//<lambda_body> ::= <compound_stmt> <empty>
return LRParser.GetReductionSyntaxNode(0);
}
throw new RuleException("Unknown rule");
}  
		public void read_variant_type(variant_type _variant_type)
		{
			read_syntax_tree_node(_variant_type);
			_variant_type.case_exprs = _read_node() as expression_list;
			_variant_type.parts = _read_node() as record_type_parts;
		}
Ejemplo n.º 7
0
 public override void visit(variant_type _variant_type)
 {
     //throw new Exception("The method or operation is not implemented.");
 }
Ejemplo n.º 8
0
		public void AddFirst(variant_type el)
		{
			vars.Insert(0, el);
		}
Ejemplo n.º 9
0
		private int FindIndexInList(variant_type el)
		{
			var ind = vars.FindIndex(x => x == el);
			if (ind == -1)
				throw new Exception(string.Format("У списка {0} не найден элемент {1} среди дочерних\n", this, el));
			return ind;
		}
Ejemplo n.º 10
0
		// Конструкторы списка
		public variant_types(variant_type elem, SourceContext sc = null)
		{
			Add(elem, sc);
		}
Ejemplo n.º 11
0
		// Методы списка
		public variant_types Add(variant_type elem, SourceContext sc = null)
		{
			vars.Add(elem);
			if (sc != null)
				source_context = sc;
			return this;
		}
Ejemplo n.º 12
0
		public variant_types Add(variant_type _variant_type, SourceContext sc)
		{
		    vars.Add(_variant_type);
		    source_context = sc;
		    return this;
		}
Ejemplo n.º 13
0
		public variant_types Add(variant_type _variant_type)
		{
		    vars.Add(_variant_type);
		    return this;
		}
Ejemplo n.º 14
0
		public variant_types(variant_type _variant_type, SourceContext sc)
		{
		    Add(_variant_type,sc);
		}
Ejemplo n.º 15
0
		public override void visit(variant_type _variant_type)
		{
			prepare_node(_variant_type.case_exprs,"case exprs");
			prepare_node(_variant_type.parts,"parts");
		}
Ejemplo n.º 16
0
		public void InsertAfter(variant_type el, variant_type newel)
		{
			vars.Insert(FindIndex(el) + 1, newel);
		}
Ejemplo n.º 17
0
		public void visit(variant_type _variant_type)
		{
			read_variant_type(_variant_type);
		}
Ejemplo n.º 18
0
		public void InsertAfter(variant_type el, IEnumerable<variant_type> newels)
		{
			vars.InsertRange(FindIndex(el) + 1, newels);
		}
Ejemplo n.º 19
0
		public override void visit(variant_type _variant_type)
		{
			throw new NotImplementedException();
		}
Ejemplo n.º 20
0
		public void InsertBefore(variant_type el, variant_type newel)
		{
			vars.Insert(FindIndex(el), newel);
		}
Ejemplo n.º 21
0
        public override void visit(variant_type _variant_type)
        {

        }
Ejemplo n.º 22
0
		public void InsertBefore(variant_type el, IEnumerable<variant_type> newels)
		{
			vars.InsertRange(FindIndex(el), newels);
		}
Ejemplo n.º 23
0
		public void write_variant_type(variant_type _variant_type)
		{
			write_syntax_tree_node(_variant_type);
			if (_variant_type.case_exprs == null)
			{
				bw.Write((byte)0);
			}
			else
			{
				bw.Write((byte)1);
				_variant_type.case_exprs.visit(this);
			}
			if (_variant_type.parts == null)
			{
				bw.Write((byte)0);
			}
			else
			{
				bw.Write((byte)1);
				_variant_type.parts.visit(this);
			}
		}
		public void Replace(variant_type el, variant_type newel)
		{
			vars[FindIndex(el)] = newel;
		}