diff --git a/CodeExamples/TypeclassExample.pas b/CodeExamples/TypeclassExample.pas index 465cba325..e10d5b5f3 100644 --- a/CodeExamples/TypeclassExample.pas +++ b/CodeExamples/TypeclassExample.pas @@ -18,7 +18,7 @@ end; begin var v1, v2, v3, res: integer; - res := Sum3&(v1, v2, v3); + res := Sum3&[integer](v1, v2, v3); Write(res); end. \ No newline at end of file diff --git a/Parsers/PascalABCParserNewSaushkin/ABCPascal.cs b/Parsers/PascalABCParserNewSaushkin/ABCPascal.cs index 20b10858f..f77034002 100644 --- a/Parsers/PascalABCParserNewSaushkin/ABCPascal.cs +++ b/Parsers/PascalABCParserNewSaushkin/ABCPascal.cs @@ -2,7 +2,7 @@ // This CSharp output file generated by Gardens Point LEX // Version: 1.1.3.301 // Machine: OBERON -// DateTime: 4/10/2018 5:44:39 PM +// DateTime: 4/18/2018 6:59:00 PM // UserName: voganesyan // GPLEX input file // GPLEX frame file diff --git a/Parsers/PascalABCParserNewSaushkin/ABCPascal.y b/Parsers/PascalABCParserNewSaushkin/ABCPascal.y index 86041fdb2..4244e67a0 100644 --- a/Parsers/PascalABCParserNewSaushkin/ABCPascal.y +++ b/Parsers/PascalABCParserNewSaushkin/ABCPascal.y @@ -154,7 +154,8 @@ %type class_or_interface_keyword optional_tk_do keyword reserved_keyword %type typeof_expr %type simple_fp_sect -%type template_param_list template_type_params +%type template_param_list template_type_params +%type template_type_or_typeclass_params typeclass_params %type template_type %type try_stmt %type uses_clause used_units_list @@ -859,7 +860,7 @@ const_variable { $$ = NewConstVariable($1, $2, @$); } - | const_variable tkAmpersend template_type_params + | const_variable tkAmpersend template_type_or_typeclass_params { $$ = new ident_with_templateparams($1 as addressed_value, $3 as template_param_list, @$); } @@ -1084,12 +1085,29 @@ simple_type_decl ; typeclass_restriction - : simple_type_identifier tkSquareOpen template_param_list tkSquareClose + : simple_type_identifier typeclass_params { - $$ = new typeclass_restriction(($1 as named_type_reference).ToString(), $3 as template_param_list, @$); + $$ = new typeclass_restriction(($1 as named_type_reference).ToString(), $2 as template_param_list, @$); } ; +typeclass_params + : tkSquareOpen template_param_list tkSquareClose + { + $$ = new typeclass_param_list($2 as template_param_list); + } + ; + +template_type_or_typeclass_params + : template_type_params + { + $$ = $1; + } + | typeclass_params + { + $$ = $1; + } + ; type_decl_identifier : identifier { $$ = $1; } @@ -2863,7 +2881,7 @@ simple_or_template_type_reference { $$ = new template_type_reference((named_type_reference)$1, (template_param_list)$2, @$); } - | simple_type_identifier tkAmpersend template_type_params + | simple_type_identifier tkAmpersend template_type_or_typeclass_params { $$ = new template_type_reference((named_type_reference)$1, (template_param_list)$3, @$); } @@ -3294,7 +3312,7 @@ variable { $$ = new roof_dereference($1 as addressed_value,@$); } - | variable tkAmpersend template_type_params + | variable tkAmpersend template_type_or_typeclass_params { $$ = new ident_with_templateparams($1 as addressed_value, $3 as template_param_list, @$); } diff --git a/Parsers/PascalABCParserNewSaushkin/ABCPascalYacc.cs b/Parsers/PascalABCParserNewSaushkin/ABCPascalYacc.cs index 60f2c588d..3a7203fec 100644 --- a/Parsers/PascalABCParserNewSaushkin/ABCPascalYacc.cs +++ b/Parsers/PascalABCParserNewSaushkin/ABCPascalYacc.cs @@ -2,7 +2,7 @@ // GPPG version 1.3.6 // Machine: OBERON -// DateTime: 4/10/2018 5:44:39 PM +// DateTime: 4/18/2018 6:59:00 PM // UserName: voganesyan // Input file @@ -74,8 +74,8 @@ public partial class GPPGParser: ShiftReduceParser aliasses; #pragma warning restore 649 - private static Rule[] rules = new Rule[855]; - private static State[] states = new State[1394]; + private static Rule[] rules = new Rule[858]; + private static State[] states = new State[1397]; private static string[] nonTerms = new string[] { "parse_goal", "unit_key_word", "assignment", "optional_array_initializer", "attribute_declarations", "ot_visibility_specifier", "one_attribute", "attribute_variable", @@ -144,25 +144,25 @@ public partial class GPPGParser: ShiftReduceParser const_variable, tkAmpersend, template_type_params + case 161: // const_variable -> const_variable, tkAmpersend, + // template_type_or_typeclass_params { CurrentSemanticValue.ex = new ident_with_templateparams(ValueStack[ValueStack.Depth-3].ex as addressed_value, ValueStack[ValueStack.Depth-1].stn as template_param_list, CurrentLocationSpan); } @@ -3280,36 +3287,50 @@ public partial class GPPGParser: ShiftReduceParser simple_type_identifier, tkSquareOpen, - // template_param_list, tkSquareClose + case 209: // typeclass_restriction -> simple_type_identifier, typeclass_params { - CurrentSemanticValue.id = new typeclass_restriction((ValueStack[ValueStack.Depth-4].td as named_type_reference).ToString(), ValueStack[ValueStack.Depth-2].stn as template_param_list, CurrentLocationSpan); + CurrentSemanticValue.id = new typeclass_restriction((ValueStack[ValueStack.Depth-2].td as named_type_reference).ToString(), ValueStack[ValueStack.Depth-1].stn as template_param_list, CurrentLocationSpan); } break; - case 210: // type_decl_identifier -> identifier + case 210: // typeclass_params -> tkSquareOpen, template_param_list, tkSquareClose +{ + CurrentSemanticValue.stn = new typeclass_param_list(ValueStack[ValueStack.Depth-2].stn as template_param_list); + } + break; + case 211: // template_type_or_typeclass_params -> template_type_params +{ + CurrentSemanticValue.stn = ValueStack[ValueStack.Depth-1].stn; + } + break; + case 212: // template_type_or_typeclass_params -> typeclass_params +{ + CurrentSemanticValue.stn = ValueStack[ValueStack.Depth-1].stn; + } + break; + case 213: // type_decl_identifier -> identifier { CurrentSemanticValue.id = ValueStack[ValueStack.Depth-1].id; } break; - case 211: // type_decl_identifier -> identifier, template_arguments + case 214: // type_decl_identifier -> identifier, template_arguments { CurrentSemanticValue.id = new template_type_name(ValueStack[ValueStack.Depth-2].id.name, ValueStack[ValueStack.Depth-1].stn as ident_list, CurrentLocationSpan); } break; - case 212: // template_identifier_with_equal -> identifier, tkLower, ident_list, + case 215: // template_identifier_with_equal -> identifier, tkLower, ident_list, // tkGreaterEqual { CurrentSemanticValue.id = new template_type_name(ValueStack[ValueStack.Depth-4].id.name, ValueStack[ValueStack.Depth-2].stn as ident_list, CurrentLocationSpan); } break; - case 213: // type_decl_type -> type_ref + case 216: // type_decl_type -> type_ref { CurrentSemanticValue.td = ValueStack[ValueStack.Depth-1].td; } break; - case 214: // type_decl_type -> object_type + case 217: // type_decl_type -> object_type { CurrentSemanticValue.td = ValueStack[ValueStack.Depth-1].td; } break; - case 215: // type_ref -> simple_type + case 218: // type_ref -> simple_type { CurrentSemanticValue.td = ValueStack[ValueStack.Depth-1].td; } break; - case 216: // type_ref -> simple_type, tkQuestion + case 219: // type_ref -> simple_type, tkQuestion { if (parsertools.build_tree_for_formatter) { @@ -3324,46 +3345,46 @@ public partial class GPPGParser: ShiftReduceParser string_type + case 220: // type_ref -> string_type { CurrentSemanticValue.td = ValueStack[ValueStack.Depth-1].td; } break; - case 218: // type_ref -> pointer_type + case 221: // type_ref -> pointer_type { CurrentSemanticValue.td = ValueStack[ValueStack.Depth-1].td; } break; - case 219: // type_ref -> structured_type + case 222: // type_ref -> structured_type { CurrentSemanticValue.td = ValueStack[ValueStack.Depth-1].td; } break; - case 220: // type_ref -> procedural_type + case 223: // type_ref -> procedural_type { CurrentSemanticValue.td = ValueStack[ValueStack.Depth-1].td; } break; - case 221: // type_ref -> template_type + case 224: // type_ref -> template_type { CurrentSemanticValue.td = ValueStack[ValueStack.Depth-1].td; } break; - case 222: // template_type -> simple_type_identifier, template_type_params + case 225: // template_type -> simple_type_identifier, template_type_params { CurrentSemanticValue.td = new template_type_reference(ValueStack[ValueStack.Depth-2].td as named_type_reference, ValueStack[ValueStack.Depth-1].stn as template_param_list, CurrentLocationSpan); } break; - case 223: // template_type_params -> tkLower, template_param_list, tkGreater + case 226: // template_type_params -> tkLower, template_param_list, tkGreater { CurrentSemanticValue.stn = ValueStack[ValueStack.Depth-2].stn; CurrentSemanticValue.stn.source_context = CurrentLocationSpan; } break; - case 224: // template_param_list -> template_param + case 227: // template_param_list -> template_param { CurrentSemanticValue.stn = new template_param_list(ValueStack[ValueStack.Depth-1].td, CurrentLocationSpan); } break; - case 225: // template_param_list -> template_param_list, tkComma, template_param + case 228: // template_param_list -> template_param_list, tkComma, template_param { CurrentSemanticValue.stn = (ValueStack[ValueStack.Depth-3].stn as template_param_list).Add(ValueStack[ValueStack.Depth-1].td, CurrentLocationSpan); } break; - case 226: // template_param -> simple_type + case 229: // template_param -> simple_type { CurrentSemanticValue.td = ValueStack[ValueStack.Depth-1].td; } break; - case 227: // template_param -> simple_type, tkQuestion + case 230: // template_param -> simple_type, tkQuestion { if (parsertools.build_tree_for_formatter) { @@ -3378,412 +3399,412 @@ public partial class GPPGParser: ShiftReduceParser structured_type + case 231: // template_param -> structured_type { CurrentSemanticValue.td = ValueStack[ValueStack.Depth-1].td; } break; - case 229: // template_param -> procedural_type + case 232: // template_param -> procedural_type { CurrentSemanticValue.td = ValueStack[ValueStack.Depth-1].td; } break; - case 230: // template_param -> template_type + case 233: // template_param -> template_type { CurrentSemanticValue.td = ValueStack[ValueStack.Depth-1].td; } break; - case 231: // simple_type -> range_expr + case 234: // simple_type -> range_expr { CurrentSemanticValue.td = parsertools.ConvertDotNodeOrIdentToNamedTypeReference(ValueStack[ValueStack.Depth-1].ex); } break; - case 232: // simple_type -> range_expr, tkDotDot, range_expr + case 235: // simple_type -> range_expr, tkDotDot, range_expr { CurrentSemanticValue.td = new diapason(ValueStack[ValueStack.Depth-3].ex, ValueStack[ValueStack.Depth-1].ex, CurrentLocationSpan); } break; - case 233: // simple_type -> tkRoundOpen, enumeration_id_list, tkRoundClose + case 236: // simple_type -> tkRoundOpen, enumeration_id_list, tkRoundClose { CurrentSemanticValue.td = new enum_type_definition(ValueStack[ValueStack.Depth-2].stn as enumerator_list, CurrentLocationSpan); } break; - case 234: // range_expr -> range_term + case 237: // range_expr -> range_term { CurrentSemanticValue.ex = ValueStack[ValueStack.Depth-1].ex; } break; - case 235: // range_expr -> range_expr, const_addop, range_term + case 238: // range_expr -> range_expr, const_addop, range_term { CurrentSemanticValue.ex = new bin_expr(ValueStack[ValueStack.Depth-3].ex, ValueStack[ValueStack.Depth-1].ex, ValueStack[ValueStack.Depth-2].op.type, CurrentLocationSpan); } break; - case 236: // range_term -> range_factor + case 239: // range_term -> range_factor { CurrentSemanticValue.ex = ValueStack[ValueStack.Depth-1].ex; } break; - case 237: // range_term -> range_term, const_mulop, range_factor + case 240: // range_term -> range_term, const_mulop, range_factor { CurrentSemanticValue.ex = new bin_expr(ValueStack[ValueStack.Depth-3].ex, ValueStack[ValueStack.Depth-1].ex, ValueStack[ValueStack.Depth-2].op.type, CurrentLocationSpan); } break; - case 238: // range_factor -> simple_type_identifier + case 241: // range_factor -> simple_type_identifier { CurrentSemanticValue.ex = parsertools.ConvertNamedTypeReferenceToDotNodeOrIdent(ValueStack[ValueStack.Depth-1].td as named_type_reference); } break; - case 239: // range_factor -> unsigned_number + case 242: // range_factor -> unsigned_number { CurrentSemanticValue.ex = ValueStack[ValueStack.Depth-1].ex; } break; - case 240: // range_factor -> sign, range_factor + case 243: // range_factor -> sign, range_factor { CurrentSemanticValue.ex = new un_expr(ValueStack[ValueStack.Depth-1].ex, ValueStack[ValueStack.Depth-2].op.type, CurrentLocationSpan); } break; - case 241: // range_factor -> literal + case 244: // range_factor -> literal { CurrentSemanticValue.ex = ValueStack[ValueStack.Depth-1].ex; } break; - case 242: // range_factor -> range_factor, tkRoundOpen, const_elem_list, tkRoundClose + case 245: // range_factor -> range_factor, tkRoundOpen, const_elem_list, tkRoundClose { CurrentSemanticValue.ex = new method_call(ValueStack[ValueStack.Depth-4].ex as addressed_value, ValueStack[ValueStack.Depth-2].stn as expression_list, CurrentLocationSpan); } break; - case 243: // simple_type_identifier -> identifier + case 246: // simple_type_identifier -> identifier { CurrentSemanticValue.td = new named_type_reference(ValueStack[ValueStack.Depth-1].id, CurrentLocationSpan); } break; - case 244: // simple_type_identifier -> simple_type_identifier, tkPoint, + case 247: // simple_type_identifier -> simple_type_identifier, tkPoint, // identifier_or_keyword { CurrentSemanticValue.td = (ValueStack[ValueStack.Depth-3].td as named_type_reference).Add(ValueStack[ValueStack.Depth-1].id, CurrentLocationSpan); } break; - case 245: // enumeration_id_list -> enumeration_id, tkComma, enumeration_id + case 248: // enumeration_id_list -> enumeration_id, tkComma, enumeration_id { CurrentSemanticValue.stn = new enumerator_list(ValueStack[ValueStack.Depth-3].stn as enumerator, CurrentLocationSpan); (CurrentSemanticValue.stn as enumerator_list).Add(ValueStack[ValueStack.Depth-1].stn as enumerator, CurrentLocationSpan); } break; - case 246: // enumeration_id_list -> enumeration_id_list, tkComma, enumeration_id + case 249: // enumeration_id_list -> enumeration_id_list, tkComma, enumeration_id { CurrentSemanticValue.stn = (ValueStack[ValueStack.Depth-3].stn as enumerator_list).Add(ValueStack[ValueStack.Depth-1].stn as enumerator, CurrentLocationSpan); } break; - case 247: // enumeration_id -> type_ref + case 250: // enumeration_id -> type_ref { CurrentSemanticValue.stn = new enumerator(ValueStack[ValueStack.Depth-1].td, null, CurrentLocationSpan); } break; - case 248: // enumeration_id -> type_ref, tkEqual, expr + case 251: // enumeration_id -> type_ref, tkEqual, expr { CurrentSemanticValue.stn = new enumerator(ValueStack[ValueStack.Depth-3].td, ValueStack[ValueStack.Depth-1].ex, CurrentLocationSpan); } break; - case 249: // pointer_type -> tkDeref, fptype + case 252: // pointer_type -> tkDeref, fptype { CurrentSemanticValue.td = new ref_type(ValueStack[ValueStack.Depth-1].td,CurrentLocationSpan); } break; - case 250: // structured_type -> unpacked_structured_type + case 253: // structured_type -> unpacked_structured_type { CurrentSemanticValue.td = ValueStack[ValueStack.Depth-1].td; } break; - case 251: // structured_type -> tkPacked, unpacked_structured_type + case 254: // structured_type -> tkPacked, unpacked_structured_type { CurrentSemanticValue.td = ValueStack[ValueStack.Depth-1].td; } break; - case 252: // unpacked_structured_type -> array_type + case 255: // unpacked_structured_type -> array_type { CurrentSemanticValue.td = ValueStack[ValueStack.Depth-1].td; } break; - case 253: // unpacked_structured_type -> record_type + case 256: // unpacked_structured_type -> record_type { CurrentSemanticValue.td = ValueStack[ValueStack.Depth-1].td; } break; - case 254: // unpacked_structured_type -> set_type + case 257: // unpacked_structured_type -> set_type { CurrentSemanticValue.td = ValueStack[ValueStack.Depth-1].td; } break; - case 255: // unpacked_structured_type -> file_type + case 258: // unpacked_structured_type -> file_type { CurrentSemanticValue.td = ValueStack[ValueStack.Depth-1].td; } break; - case 256: // unpacked_structured_type -> sequence_type + case 259: // unpacked_structured_type -> sequence_type { CurrentSemanticValue.td = ValueStack[ValueStack.Depth-1].td; } break; - case 257: // sequence_type -> tkSequence, tkOf, type_ref + case 260: // sequence_type -> tkSequence, tkOf, type_ref { CurrentSemanticValue.td = new sequence_type(ValueStack[ValueStack.Depth-1].td,CurrentLocationSpan); } break; - case 258: // array_type -> tkArray, tkSquareOpen, simple_type_list, tkSquareClose, tkOf, + case 261: // array_type -> tkArray, tkSquareOpen, simple_type_list, tkSquareClose, tkOf, // type_ref { CurrentSemanticValue.td = new array_type(ValueStack[ValueStack.Depth-4].stn as indexers_types, ValueStack[ValueStack.Depth-1].td, CurrentLocationSpan); } break; - case 259: // array_type -> unsized_array_type + case 262: // array_type -> unsized_array_type { CurrentSemanticValue.td = ValueStack[ValueStack.Depth-1].td; } break; - case 260: // unsized_array_type -> tkArray, tkOf, type_ref + case 263: // unsized_array_type -> tkArray, tkOf, type_ref { CurrentSemanticValue.td = new array_type(null, ValueStack[ValueStack.Depth-1].td, CurrentLocationSpan); } break; - case 261: // simple_type_list -> simple_type_or_ + case 264: // simple_type_list -> simple_type_or_ { CurrentSemanticValue.stn = new indexers_types(ValueStack[ValueStack.Depth-1].td, CurrentLocationSpan); } break; - case 262: // simple_type_list -> simple_type_list, tkComma, simple_type_or_ + case 265: // simple_type_list -> simple_type_list, tkComma, simple_type_or_ { CurrentSemanticValue.stn = (ValueStack[ValueStack.Depth-3].stn as indexers_types).Add(ValueStack[ValueStack.Depth-1].td, CurrentLocationSpan); } break; - case 263: // simple_type_or_ -> simple_type + case 266: // simple_type_or_ -> simple_type { CurrentSemanticValue.td = ValueStack[ValueStack.Depth-1].td; } break; - case 264: // simple_type_or_ -> /* empty */ + case 267: // simple_type_or_ -> /* empty */ { CurrentSemanticValue.td = null; } break; - case 265: // set_type -> tkSet, tkOf, simple_type + case 268: // set_type -> tkSet, tkOf, simple_type { CurrentSemanticValue.td = new set_type_definition(ValueStack[ValueStack.Depth-1].td, CurrentLocationSpan); } break; - case 266: // file_type -> tkFile, tkOf, type_ref + case 269: // file_type -> tkFile, tkOf, type_ref { CurrentSemanticValue.td = new file_type(ValueStack[ValueStack.Depth-1].td, CurrentLocationSpan); } break; - case 267: // file_type -> tkFile + case 270: // file_type -> tkFile { CurrentSemanticValue.td = new file_type(); CurrentSemanticValue.td.source_context = CurrentLocationSpan; } break; - case 268: // string_type -> tkIdentifier, tkSquareOpen, const_expr, tkSquareClose + case 271: // string_type -> tkIdentifier, tkSquareOpen, const_expr, tkSquareClose { CurrentSemanticValue.td = new string_num_definition(ValueStack[ValueStack.Depth-2].ex, ValueStack[ValueStack.Depth-4].id, CurrentLocationSpan); } break; - case 269: // procedural_type -> procedural_type_kind + case 272: // procedural_type -> procedural_type_kind { CurrentSemanticValue.td = ValueStack[ValueStack.Depth-1].td; } break; - case 270: // procedural_type_kind -> proc_type_decl + case 273: // procedural_type_kind -> proc_type_decl { CurrentSemanticValue.td = ValueStack[ValueStack.Depth-1].td; } break; - case 271: // proc_type_decl -> tkProcedure, fp_list + case 274: // proc_type_decl -> tkProcedure, fp_list { CurrentSemanticValue.td = new procedure_header(ValueStack[ValueStack.Depth-1].stn as formal_parameters,null,null,false,false,null,null,CurrentLocationSpan); } break; - case 272: // proc_type_decl -> tkFunction, fp_list + case 275: // proc_type_decl -> tkFunction, fp_list { CurrentSemanticValue.td = new function_header(ValueStack[ValueStack.Depth-1].stn as formal_parameters, null, null, null, null, CurrentLocationSpan); } break; - case 273: // proc_type_decl -> tkFunction, fp_list, tkColon, fptype + case 276: // proc_type_decl -> tkFunction, fp_list, tkColon, fptype { CurrentSemanticValue.td = new function_header(ValueStack[ValueStack.Depth-3].stn as formal_parameters, null, null, null, ValueStack[ValueStack.Depth-1].td as type_definition, CurrentLocationSpan); } break; - case 274: // proc_type_decl -> simple_type_identifier, tkArrow, template_param + case 277: // proc_type_decl -> simple_type_identifier, tkArrow, template_param { CurrentSemanticValue.td = new modern_proc_type(ValueStack[ValueStack.Depth-3].td,null,ValueStack[ValueStack.Depth-1].td,CurrentLocationSpan); } break; - case 275: // proc_type_decl -> template_type, tkArrow, template_param + case 278: // proc_type_decl -> template_type, tkArrow, template_param { CurrentSemanticValue.td = new modern_proc_type(ValueStack[ValueStack.Depth-3].td,null,ValueStack[ValueStack.Depth-1].td,CurrentLocationSpan); } break; - case 276: // proc_type_decl -> tkRoundOpen, tkRoundClose, tkArrow, template_param + case 279: // proc_type_decl -> tkRoundOpen, tkRoundClose, tkArrow, template_param { CurrentSemanticValue.td = new modern_proc_type(null,null,ValueStack[ValueStack.Depth-1].td,CurrentLocationSpan); } break; - case 277: // proc_type_decl -> tkRoundOpen, enumeration_id_list, tkRoundClose, tkArrow, + case 280: // proc_type_decl -> tkRoundOpen, enumeration_id_list, tkRoundClose, tkArrow, // template_param { CurrentSemanticValue.td = new modern_proc_type(null,ValueStack[ValueStack.Depth-4].stn as enumerator_list,ValueStack[ValueStack.Depth-1].td,CurrentLocationSpan); } break; - case 278: // proc_type_decl -> simple_type_identifier, tkArrow, tkRoundOpen, tkRoundClose + case 281: // proc_type_decl -> simple_type_identifier, tkArrow, tkRoundOpen, tkRoundClose { CurrentSemanticValue.td = new modern_proc_type(ValueStack[ValueStack.Depth-4].td,null,null,CurrentLocationSpan); } break; - case 279: // proc_type_decl -> template_type, tkArrow, tkRoundOpen, tkRoundClose + case 282: // proc_type_decl -> template_type, tkArrow, tkRoundOpen, tkRoundClose { CurrentSemanticValue.td = new modern_proc_type(ValueStack[ValueStack.Depth-4].td,null,null,CurrentLocationSpan); } break; - case 280: // proc_type_decl -> tkRoundOpen, tkRoundClose, tkArrow, tkRoundOpen, tkRoundClose + case 283: // proc_type_decl -> tkRoundOpen, tkRoundClose, tkArrow, tkRoundOpen, tkRoundClose { CurrentSemanticValue.td = new modern_proc_type(null,null,null,CurrentLocationSpan); } break; - case 281: // proc_type_decl -> tkRoundOpen, enumeration_id_list, tkRoundClose, tkArrow, + case 284: // proc_type_decl -> tkRoundOpen, enumeration_id_list, tkRoundClose, tkArrow, // tkRoundOpen, tkRoundClose { CurrentSemanticValue.td = new modern_proc_type(null,ValueStack[ValueStack.Depth-5].stn as enumerator_list,null,CurrentLocationSpan); } break; - case 282: // object_type -> class_attributes, class_or_interface_keyword, + case 285: // object_type -> class_attributes, class_or_interface_keyword, // optional_base_classes, optional_where_section, // optional_component_list_seq_end { CurrentSemanticValue.td = NewObjectType((class_attribute)ValueStack[ValueStack.Depth-5].ob, ValueStack[ValueStack.Depth-4].ti, ValueStack[ValueStack.Depth-3].stn as named_type_reference_list, ValueStack[ValueStack.Depth-2].stn as where_definition_list, ValueStack[ValueStack.Depth-1].stn as class_body_list, CurrentLocationSpan); } break; - case 283: // record_type -> tkRecord, optional_base_classes, optional_where_section, + case 286: // record_type -> tkRecord, optional_base_classes, optional_where_section, // member_list_section, tkEnd { CurrentSemanticValue.td = NewRecordType(ValueStack[ValueStack.Depth-4].stn as named_type_reference_list, ValueStack[ValueStack.Depth-3].stn as where_definition_list, ValueStack[ValueStack.Depth-2].stn as class_body_list, CurrentLocationSpan); } break; - case 284: // class_attribute -> tkSealed + case 287: // class_attribute -> tkSealed { CurrentSemanticValue.ob = class_attribute.Sealed; } break; - case 285: // class_attribute -> tkPartial + case 288: // class_attribute -> tkPartial { CurrentSemanticValue.ob = class_attribute.Partial; } break; - case 286: // class_attribute -> tkAbstract + case 289: // class_attribute -> tkAbstract { CurrentSemanticValue.ob = class_attribute.Abstract; } break; - case 287: // class_attribute -> tkAuto + case 290: // class_attribute -> tkAuto { CurrentSemanticValue.ob = class_attribute.Auto; } break; - case 288: // class_attributes -> /* empty */ + case 291: // class_attributes -> /* empty */ { CurrentSemanticValue.ob = class_attribute.None; } break; - case 289: // class_attributes -> class_attributes1 + case 292: // class_attributes -> class_attributes1 { CurrentSemanticValue.ob = ValueStack[ValueStack.Depth-1].ob; } break; - case 290: // class_attributes1 -> class_attribute + case 293: // class_attributes1 -> class_attribute { CurrentSemanticValue.ob = ValueStack[ValueStack.Depth-1].ob; } break; - case 291: // class_attributes1 -> class_attributes1, class_attribute + case 294: // class_attributes1 -> class_attributes1, class_attribute { ValueStack[ValueStack.Depth-2].ob = ((class_attribute)ValueStack[ValueStack.Depth-2].ob) | ((class_attribute)ValueStack[ValueStack.Depth-1].ob); CurrentSemanticValue.ob = ValueStack[ValueStack.Depth-2].ob; } break; - case 292: // class_or_interface_keyword -> tkClass + case 295: // class_or_interface_keyword -> tkClass { CurrentSemanticValue.ti = ValueStack[ValueStack.Depth-1].ti; } break; - case 293: // class_or_interface_keyword -> tkInterface + case 296: // class_or_interface_keyword -> tkInterface { CurrentSemanticValue.ti = ValueStack[ValueStack.Depth-1].ti; } break; - case 294: // class_or_interface_keyword -> tkTemplate + case 297: // class_or_interface_keyword -> tkTemplate { CurrentSemanticValue.ti = NewClassOrInterfaceKeyword(ValueStack[ValueStack.Depth-1].ti); } break; - case 295: // class_or_interface_keyword -> tkTemplate, tkClass + case 298: // class_or_interface_keyword -> tkTemplate, tkClass { CurrentSemanticValue.ti = NewClassOrInterfaceKeyword(ValueStack[ValueStack.Depth-2].ti, "c", CurrentLocationSpan); } break; - case 296: // class_or_interface_keyword -> tkTemplate, tkRecord + case 299: // class_or_interface_keyword -> tkTemplate, tkRecord { CurrentSemanticValue.ti = NewClassOrInterfaceKeyword(ValueStack[ValueStack.Depth-2].ti, "r", CurrentLocationSpan); } break; - case 297: // class_or_interface_keyword -> tkTemplate, tkInterface + case 300: // class_or_interface_keyword -> tkTemplate, tkInterface { CurrentSemanticValue.ti = NewClassOrInterfaceKeyword(ValueStack[ValueStack.Depth-2].ti, "i", CurrentLocationSpan); } break; - case 298: // optional_component_list_seq_end -> /* empty */ + case 301: // optional_component_list_seq_end -> /* empty */ { CurrentSemanticValue.stn = null; } break; - case 299: // optional_component_list_seq_end -> member_list_section, tkEnd + case 302: // optional_component_list_seq_end -> member_list_section, tkEnd { CurrentSemanticValue.stn = ValueStack[ValueStack.Depth-2].stn; CurrentSemanticValue.stn.source_context = CurrentLocationSpan; } break; - case 301: // optional_base_classes -> tkRoundOpen, base_classes_names_list, tkRoundClose + case 304: // optional_base_classes -> tkRoundOpen, base_classes_names_list, tkRoundClose { CurrentSemanticValue.stn = ValueStack[ValueStack.Depth-2].stn; } break; - case 302: // base_classes_names_list -> base_class_name + case 305: // base_classes_names_list -> base_class_name { CurrentSemanticValue.stn = new named_type_reference_list(ValueStack[ValueStack.Depth-1].stn as named_type_reference, CurrentLocationSpan); } break; - case 303: // base_classes_names_list -> base_classes_names_list, tkComma, base_class_name + case 306: // base_classes_names_list -> base_classes_names_list, tkComma, base_class_name { CurrentSemanticValue.stn = (ValueStack[ValueStack.Depth-3].stn as named_type_reference_list).Add(ValueStack[ValueStack.Depth-1].stn as named_type_reference, CurrentLocationSpan); } break; - case 304: // base_class_name -> simple_type_identifier + case 307: // base_class_name -> simple_type_identifier { CurrentSemanticValue.stn = ValueStack[ValueStack.Depth-1].td; } break; - case 305: // base_class_name -> template_type + case 308: // base_class_name -> template_type { CurrentSemanticValue.stn = ValueStack[ValueStack.Depth-1].td; } break; - case 306: // template_arguments -> tkLower, ident_list, tkGreater + case 309: // template_arguments -> tkLower, ident_list, tkGreater { CurrentSemanticValue.stn = ValueStack[ValueStack.Depth-2].stn; CurrentSemanticValue.stn.source_context = CurrentLocationSpan; } break; - case 307: // optional_where_section -> /* empty */ + case 310: // optional_where_section -> /* empty */ { CurrentSemanticValue.stn = null; } break; - case 308: // optional_where_section -> where_part_list + case 311: // optional_where_section -> where_part_list { CurrentSemanticValue.stn = ValueStack[ValueStack.Depth-1].stn; } break; - case 309: // where_part_list -> where_part + case 312: // where_part_list -> where_part { CurrentSemanticValue.stn = new where_definition_list(ValueStack[ValueStack.Depth-1].stn as where_definition, CurrentLocationSpan); } break; - case 310: // where_part_list -> where_part_list, where_part + case 313: // where_part_list -> where_part_list, where_part { CurrentSemanticValue.stn = (ValueStack[ValueStack.Depth-2].stn as where_definition_list).Add(ValueStack[ValueStack.Depth-1].stn as where_definition, CurrentLocationSpan); } break; - case 311: // where_part -> tkWhere, ident_list, tkColon, type_ref_and_secific_list, + case 314: // where_part -> tkWhere, ident_list, tkColon, type_ref_and_secific_list, // tkSemiColon { CurrentSemanticValue.stn = new where_definition(ValueStack[ValueStack.Depth-4].stn as ident_list, ValueStack[ValueStack.Depth-2].stn as where_type_specificator_list, CurrentLocationSpan); } break; - case 312: // where_part -> tkWhere, typeclass_restriction, tkSemiColon + case 315: // where_part -> tkWhere, typeclass_restriction, tkSemiColon { CurrentSemanticValue.stn = new where_typeclass_constraint(ValueStack[ValueStack.Depth-2].id as typeclass_restriction); } break; - case 313: // type_ref_and_secific_list -> type_ref_or_secific + case 316: // type_ref_and_secific_list -> type_ref_or_secific { CurrentSemanticValue.stn = new where_type_specificator_list(ValueStack[ValueStack.Depth-1].td, CurrentLocationSpan); } break; - case 314: // type_ref_and_secific_list -> type_ref_and_secific_list, tkComma, + case 317: // type_ref_and_secific_list -> type_ref_and_secific_list, tkComma, // type_ref_or_secific { CurrentSemanticValue.stn = (ValueStack[ValueStack.Depth-3].stn as where_type_specificator_list).Add(ValueStack[ValueStack.Depth-1].td, CurrentLocationSpan); } break; - case 315: // type_ref_or_secific -> type_ref + case 318: // type_ref_or_secific -> type_ref { CurrentSemanticValue.td = ValueStack[ValueStack.Depth-1].td; } break; - case 316: // type_ref_or_secific -> tkClass + case 319: // type_ref_or_secific -> tkClass { CurrentSemanticValue.td = new declaration_specificator(DeclarationSpecificator.WhereDefClass, ValueStack[ValueStack.Depth-1].ti.text, CurrentLocationSpan); } break; - case 317: // type_ref_or_secific -> tkRecord + case 320: // type_ref_or_secific -> tkRecord { CurrentSemanticValue.td = new declaration_specificator(DeclarationSpecificator.WhereDefValueType, ValueStack[ValueStack.Depth-1].ti.text, CurrentLocationSpan); } break; - case 318: // type_ref_or_secific -> tkConstructor + case 321: // type_ref_or_secific -> tkConstructor { CurrentSemanticValue.td = new declaration_specificator(DeclarationSpecificator.WhereDefConstructor, ValueStack[ValueStack.Depth-1].ti.text, CurrentLocationSpan); } break; - case 319: // member_list_section -> member_list + case 322: // member_list_section -> member_list { CurrentSemanticValue.stn = new class_body_list(ValueStack[ValueStack.Depth-1].stn as class_members, CurrentLocationSpan); } break; - case 320: // member_list_section -> member_list_section, ot_visibility_specifier, + case 323: // member_list_section -> member_list_section, ot_visibility_specifier, // member_list { (ValueStack[ValueStack.Depth-1].stn as class_members).access_mod = ValueStack[ValueStack.Depth-2].stn as access_modifer_node; @@ -3795,210 +3816,210 @@ public partial class GPPGParser: ShiftReduceParser tkInternal + case 324: // ot_visibility_specifier -> tkInternal { CurrentSemanticValue.stn = new access_modifer_node(access_modifer.internal_modifer, CurrentLocationSpan); } break; - case 322: // ot_visibility_specifier -> tkPublic + case 325: // ot_visibility_specifier -> tkPublic { CurrentSemanticValue.stn = new access_modifer_node(access_modifer.public_modifer, CurrentLocationSpan); } break; - case 323: // ot_visibility_specifier -> tkProtected + case 326: // ot_visibility_specifier -> tkProtected { CurrentSemanticValue.stn = new access_modifer_node(access_modifer.protected_modifer, CurrentLocationSpan); } break; - case 324: // ot_visibility_specifier -> tkPrivate + case 327: // ot_visibility_specifier -> tkPrivate { CurrentSemanticValue.stn = new access_modifer_node(access_modifer.private_modifer, CurrentLocationSpan); } break; - case 325: // member_list -> /* empty */ + case 328: // member_list -> /* empty */ { CurrentSemanticValue.stn = new class_members(); } break; - case 326: // member_list -> field_or_const_definition_list, optional_semicolon + case 329: // member_list -> field_or_const_definition_list, optional_semicolon { CurrentSemanticValue.stn = ValueStack[ValueStack.Depth-2].stn; } break; - case 327: // member_list -> method_decl_list + case 330: // member_list -> method_decl_list { CurrentSemanticValue.stn = ValueStack[ValueStack.Depth-1].stn; } break; - case 328: // member_list -> field_or_const_definition_list, tkSemiColon, method_decl_list + case 331: // member_list -> field_or_const_definition_list, tkSemiColon, method_decl_list { (ValueStack[ValueStack.Depth-3].stn as class_members).members.AddRange((ValueStack[ValueStack.Depth-1].stn as class_members).members); (ValueStack[ValueStack.Depth-3].stn as class_members).source_context = CurrentLocationSpan; CurrentSemanticValue.stn = ValueStack[ValueStack.Depth-3].stn; } break; - case 329: // ident_list -> identifier + case 332: // ident_list -> identifier { CurrentSemanticValue.stn = new ident_list(ValueStack[ValueStack.Depth-1].id, CurrentLocationSpan); } break; - case 330: // ident_list -> ident_list, tkComma, identifier + case 333: // ident_list -> ident_list, tkComma, identifier { CurrentSemanticValue.stn = (ValueStack[ValueStack.Depth-3].stn as ident_list).Add(ValueStack[ValueStack.Depth-1].id, CurrentLocationSpan); } break; - case 331: // optional_semicolon -> /* empty */ + case 334: // optional_semicolon -> /* empty */ { CurrentSemanticValue.ob = null; } break; - case 332: // optional_semicolon -> tkSemiColon + case 335: // optional_semicolon -> tkSemiColon { CurrentSemanticValue.ob = ValueStack[ValueStack.Depth-1].ti; } break; - case 333: // field_or_const_definition_list -> field_or_const_definition + case 336: // field_or_const_definition_list -> field_or_const_definition { CurrentSemanticValue.stn = new class_members(ValueStack[ValueStack.Depth-1].stn as declaration, CurrentLocationSpan); } break; - case 334: // field_or_const_definition_list -> field_or_const_definition_list, tkSemiColon, + case 337: // field_or_const_definition_list -> field_or_const_definition_list, tkSemiColon, // field_or_const_definition { CurrentSemanticValue.stn = (ValueStack[ValueStack.Depth-3].stn as class_members).Add(ValueStack[ValueStack.Depth-1].stn as declaration, CurrentLocationSpan); } break; - case 335: // field_or_const_definition -> attribute_declarations, + case 338: // field_or_const_definition -> attribute_declarations, // simple_field_or_const_definition { (ValueStack[ValueStack.Depth-1].stn as declaration).attributes = ValueStack[ValueStack.Depth-2].stn as attribute_list; CurrentSemanticValue.stn = ValueStack[ValueStack.Depth-1].stn; } break; - case 336: // method_decl_list -> method_or_property_decl + case 339: // method_decl_list -> method_or_property_decl { CurrentSemanticValue.stn = new class_members(ValueStack[ValueStack.Depth-1].stn as declaration, CurrentLocationSpan); } break; - case 337: // method_decl_list -> method_decl_list, method_or_property_decl + case 340: // method_decl_list -> method_decl_list, method_or_property_decl { CurrentSemanticValue.stn = (ValueStack[ValueStack.Depth-2].stn as class_members).Add(ValueStack[ValueStack.Depth-1].stn as declaration, CurrentLocationSpan); } break; - case 338: // method_or_property_decl -> method_decl_withattr + case 341: // method_or_property_decl -> method_decl_withattr { CurrentSemanticValue.stn = ValueStack[ValueStack.Depth-1].stn; } break; - case 339: // method_or_property_decl -> property_definition + case 342: // method_or_property_decl -> property_definition { CurrentSemanticValue.stn = ValueStack[ValueStack.Depth-1].stn; } break; - case 340: // simple_field_or_const_definition -> tkConst, only_const_decl + case 343: // simple_field_or_const_definition -> tkConst, only_const_decl { CurrentSemanticValue.stn = ValueStack[ValueStack.Depth-1].stn; CurrentSemanticValue.stn.source_context = CurrentLocationSpan; } break; - case 341: // simple_field_or_const_definition -> field_definition + case 344: // simple_field_or_const_definition -> field_definition { CurrentSemanticValue.stn = ValueStack[ValueStack.Depth-1].stn; } break; - case 342: // simple_field_or_const_definition -> tkClass, field_definition + case 345: // simple_field_or_const_definition -> tkClass, field_definition { (ValueStack[ValueStack.Depth-1].stn as var_def_statement).var_attr = definition_attribute.Static; (ValueStack[ValueStack.Depth-1].stn as var_def_statement).source_context = CurrentLocationSpan; CurrentSemanticValue.stn = ValueStack[ValueStack.Depth-1].stn; } break; - case 343: // field_definition -> var_decl_part + case 346: // field_definition -> var_decl_part { CurrentSemanticValue.stn = ValueStack[ValueStack.Depth-1].stn; } break; - case 344: // field_definition -> tkEvent, ident_list, tkColon, type_ref + case 347: // field_definition -> tkEvent, ident_list, tkColon, type_ref { CurrentSemanticValue.stn = new var_def_statement(ValueStack[ValueStack.Depth-3].stn as ident_list, ValueStack[ValueStack.Depth-1].td, null, definition_attribute.None, true, CurrentLocationSpan); } break; - case 345: // method_decl_withattr -> attribute_declarations, method_header + case 348: // method_decl_withattr -> attribute_declarations, method_header { (ValueStack[ValueStack.Depth-1].td as declaration).attributes = ValueStack[ValueStack.Depth-2].stn as attribute_list; CurrentSemanticValue.stn = ValueStack[ValueStack.Depth-1].td; } break; - case 346: // method_decl_withattr -> attribute_declarations, method_decl + case 349: // method_decl_withattr -> attribute_declarations, method_decl { (ValueStack[ValueStack.Depth-1].stn as declaration).attributes = ValueStack[ValueStack.Depth-2].stn as attribute_list; CurrentSemanticValue.stn = ValueStack[ValueStack.Depth-1].stn; } break; - case 347: // method_decl -> inclass_proc_func_decl + case 350: // method_decl -> inclass_proc_func_decl { CurrentSemanticValue.stn = ValueStack[ValueStack.Depth-1].stn; } break; - case 348: // method_decl -> inclass_constr_destr_decl + case 351: // method_decl -> inclass_constr_destr_decl { CurrentSemanticValue.stn = ValueStack[ValueStack.Depth-1].stn; } break; - case 349: // method_header -> tkClass, method_procfunc_header + case 352: // method_header -> tkClass, method_procfunc_header { (ValueStack[ValueStack.Depth-1].td as procedure_header).class_keyword = true; CurrentSemanticValue.td = ValueStack[ValueStack.Depth-1].td; } break; - case 350: // method_header -> method_procfunc_header + case 353: // method_header -> method_procfunc_header { CurrentSemanticValue.td = ValueStack[ValueStack.Depth-1].td; } break; - case 351: // method_header -> constr_destr_header + case 354: // method_header -> constr_destr_header { CurrentSemanticValue.td = ValueStack[ValueStack.Depth-1].td; } break; - case 352: // method_procfunc_header -> proc_func_header + case 355: // method_procfunc_header -> proc_func_header { CurrentSemanticValue.td = NewProcfuncHeading(ValueStack[ValueStack.Depth-1].td as procedure_header); } break; - case 353: // proc_func_header -> proc_header + case 356: // proc_func_header -> proc_header { CurrentSemanticValue.td = ValueStack[ValueStack.Depth-1].td; } break; - case 354: // proc_func_header -> func_header + case 357: // proc_func_header -> func_header { CurrentSemanticValue.td = ValueStack[ValueStack.Depth-1].td; } break; - case 355: // constr_destr_header -> tkConstructor, optional_proc_name, fp_list, + case 358: // constr_destr_header -> tkConstructor, optional_proc_name, fp_list, // optional_method_modificators { CurrentSemanticValue.td = new constructor(null,ValueStack[ValueStack.Depth-2].stn as formal_parameters,ValueStack[ValueStack.Depth-1].stn as procedure_attributes_list,ValueStack[ValueStack.Depth-3].stn as method_name,false,false,null,null,CurrentLocationSpan); } break; - case 356: // constr_destr_header -> tkClass, tkConstructor, optional_proc_name, fp_list, + case 359: // constr_destr_header -> tkClass, tkConstructor, optional_proc_name, fp_list, // optional_method_modificators { CurrentSemanticValue.td = new constructor(null,ValueStack[ValueStack.Depth-2].stn as formal_parameters,ValueStack[ValueStack.Depth-1].stn as procedure_attributes_list,ValueStack[ValueStack.Depth-3].stn as method_name,false,true,null,null,CurrentLocationSpan); } break; - case 357: // constr_destr_header -> tkDestructor, optional_proc_name, fp_list, + case 360: // constr_destr_header -> tkDestructor, optional_proc_name, fp_list, // optional_method_modificators { CurrentSemanticValue.td = new destructor(null,ValueStack[ValueStack.Depth-2].stn as formal_parameters,ValueStack[ValueStack.Depth-1].stn as procedure_attributes_list,ValueStack[ValueStack.Depth-3].stn as method_name, false,false,null,null,CurrentLocationSpan); } break; - case 358: // optional_proc_name -> proc_name + case 361: // optional_proc_name -> proc_name { CurrentSemanticValue.stn = ValueStack[ValueStack.Depth-1].stn; } break; - case 359: // optional_proc_name -> /* empty */ + case 362: // optional_proc_name -> /* empty */ { CurrentSemanticValue.stn = null; } break; - case 360: // qualified_identifier -> identifier + case 363: // qualified_identifier -> identifier { CurrentSemanticValue.stn = new method_name(null,null,ValueStack[ValueStack.Depth-1].id,null,CurrentLocationSpan); } break; - case 361: // qualified_identifier -> visibility_specifier + case 364: // qualified_identifier -> visibility_specifier { CurrentSemanticValue.stn = new method_name(null,null,ValueStack[ValueStack.Depth-1].id,null,CurrentLocationSpan); } break; - case 362: // qualified_identifier -> qualified_identifier, tkPoint, identifier + case 365: // qualified_identifier -> qualified_identifier, tkPoint, identifier { CurrentSemanticValue.stn = NewQualifiedIdentifier(ValueStack[ValueStack.Depth-3].stn as method_name, ValueStack[ValueStack.Depth-1].id, CurrentLocationSpan); } break; - case 363: // qualified_identifier -> qualified_identifier, tkPoint, visibility_specifier + case 366: // qualified_identifier -> qualified_identifier, tkPoint, visibility_specifier { CurrentSemanticValue.stn = NewQualifiedIdentifier(ValueStack[ValueStack.Depth-3].stn as method_name, ValueStack[ValueStack.Depth-1].id, CurrentLocationSpan); } break; - case 364: // property_definition -> attribute_declarations, simple_prim_property_definition + case 367: // property_definition -> attribute_declarations, simple_prim_property_definition { CurrentSemanticValue.stn = NewPropertyDefinition(ValueStack[ValueStack.Depth-2].stn as attribute_list, ValueStack[ValueStack.Depth-1].stn as declaration, LocationStack[LocationStack.Depth-1]); } break; - case 365: // simple_prim_property_definition -> simple_property_definition + case 368: // simple_prim_property_definition -> simple_property_definition { CurrentSemanticValue.stn = ValueStack[ValueStack.Depth-1].stn; } break; - case 366: // simple_prim_property_definition -> tkClass, simple_property_definition + case 369: // simple_prim_property_definition -> tkClass, simple_property_definition { CurrentSemanticValue.stn = NewSimplePrimPropertyDefinition(ValueStack[ValueStack.Depth-1].stn as simple_property, CurrentLocationSpan); } break; - case 367: // simple_property_definition -> tkProperty, qualified_identifier, + case 370: // simple_property_definition -> tkProperty, qualified_identifier, // property_interface, property_specifiers, // tkSemiColon, array_defaultproperty { CurrentSemanticValue.stn = NewSimplePropertyDefinition(ValueStack[ValueStack.Depth-5].stn as method_name, ValueStack[ValueStack.Depth-4].stn as property_interface, ValueStack[ValueStack.Depth-3].stn as property_accessors, proc_attribute.attr_none, ValueStack[ValueStack.Depth-1].stn as property_array_default, CurrentLocationSpan); } break; - case 368: // simple_property_definition -> tkProperty, qualified_identifier, + case 371: // simple_property_definition -> tkProperty, qualified_identifier, // property_interface, property_specifiers, // tkSemiColon, property_modificator, tkSemiColon, // array_defaultproperty @@ -4011,109 +4032,109 @@ public partial class GPPGParser: ShiftReduceParser /* empty */ + case 372: // array_defaultproperty -> /* empty */ { CurrentSemanticValue.stn = null; } break; - case 370: // array_defaultproperty -> tkDefault, tkSemiColon + case 373: // array_defaultproperty -> tkDefault, tkSemiColon { CurrentSemanticValue.stn = new property_array_default(); CurrentSemanticValue.stn.source_context = CurrentLocationSpan; } break; - case 371: // property_interface -> /* empty */ + case 374: // property_interface -> /* empty */ { CurrentSemanticValue.stn = null; } break; - case 372: // property_interface -> property_parameter_list, tkColon, fptype + case 375: // property_interface -> property_parameter_list, tkColon, fptype { CurrentSemanticValue.stn = new property_interface(ValueStack[ValueStack.Depth-3].stn as property_parameter_list, ValueStack[ValueStack.Depth-1].td, null, CurrentLocationSpan); } break; - case 373: // property_parameter_list -> /* empty */ + case 376: // property_parameter_list -> /* empty */ { CurrentSemanticValue.stn = null; } break; - case 374: // property_parameter_list -> tkSquareOpen, parameter_decl_list, tkSquareClose + case 377: // property_parameter_list -> tkSquareOpen, parameter_decl_list, tkSquareClose { CurrentSemanticValue.stn = ValueStack[ValueStack.Depth-2].stn; } break; - case 375: // parameter_decl_list -> parameter_decl + case 378: // parameter_decl_list -> parameter_decl { CurrentSemanticValue.stn = new property_parameter_list(ValueStack[ValueStack.Depth-1].stn as property_parameter, CurrentLocationSpan); } break; - case 376: // parameter_decl_list -> parameter_decl_list, tkSemiColon, parameter_decl + case 379: // parameter_decl_list -> parameter_decl_list, tkSemiColon, parameter_decl { CurrentSemanticValue.stn = (ValueStack[ValueStack.Depth-3].stn as property_parameter_list).Add(ValueStack[ValueStack.Depth-1].stn as property_parameter, CurrentLocationSpan); } break; - case 377: // parameter_decl -> ident_list, tkColon, fptype + case 380: // parameter_decl -> ident_list, tkColon, fptype { CurrentSemanticValue.stn = new property_parameter(ValueStack[ValueStack.Depth-3].stn as ident_list, ValueStack[ValueStack.Depth-1].td, CurrentLocationSpan); } break; - case 378: // optional_identifier -> identifier + case 381: // optional_identifier -> identifier { CurrentSemanticValue.id = ValueStack[ValueStack.Depth-1].id; } break; - case 379: // optional_identifier -> /* empty */ + case 382: // optional_identifier -> /* empty */ { CurrentSemanticValue.id = null; } break; - case 381: // property_specifiers -> tkRead, optional_identifier, write_property_specifiers + case 384: // property_specifiers -> tkRead, optional_identifier, write_property_specifiers { CurrentSemanticValue.stn = NewPropertySpecifiersRead(ValueStack[ValueStack.Depth-3].id, ValueStack[ValueStack.Depth-2].id, ValueStack[ValueStack.Depth-1].stn as property_accessors, CurrentLocationSpan); } break; - case 382: // property_specifiers -> tkWrite, optional_identifier, read_property_specifiers + case 385: // property_specifiers -> tkWrite, optional_identifier, read_property_specifiers { CurrentSemanticValue.stn = NewPropertySpecifiersWrite(ValueStack[ValueStack.Depth-3].id, ValueStack[ValueStack.Depth-2].id, ValueStack[ValueStack.Depth-1].stn as property_accessors, CurrentLocationSpan); } break; - case 384: // write_property_specifiers -> tkWrite, optional_identifier + case 387: // write_property_specifiers -> tkWrite, optional_identifier { CurrentSemanticValue.stn = NewPropertySpecifiersWrite(ValueStack[ValueStack.Depth-2].id, ValueStack[ValueStack.Depth-1].id, null, CurrentLocationSpan); } break; - case 386: // read_property_specifiers -> tkRead, optional_identifier + case 389: // read_property_specifiers -> tkRead, optional_identifier { CurrentSemanticValue.stn = NewPropertySpecifiersRead(ValueStack[ValueStack.Depth-2].id, ValueStack[ValueStack.Depth-1].id, null, CurrentLocationSpan); } break; - case 387: // var_decl -> var_decl_part, tkSemiColon + case 390: // var_decl -> var_decl_part, tkSemiColon { CurrentSemanticValue.stn = ValueStack[ValueStack.Depth-2].stn; } break; - case 390: // var_decl_part -> ident_list, tkColon, type_ref + case 393: // var_decl_part -> ident_list, tkColon, type_ref { CurrentSemanticValue.stn = new var_def_statement(ValueStack[ValueStack.Depth-3].stn as ident_list, ValueStack[ValueStack.Depth-1].td, null, definition_attribute.None, false, CurrentLocationSpan); } break; - case 391: // var_decl_part -> ident_list, tkAssign, expr + case 394: // var_decl_part -> ident_list, tkAssign, expr { CurrentSemanticValue.stn = new var_def_statement(ValueStack[ValueStack.Depth-3].stn as ident_list, null, ValueStack[ValueStack.Depth-1].ex, definition_attribute.None, false, CurrentLocationSpan); } break; - case 392: // var_decl_part -> ident_list, tkColon, type_ref, tkAssignOrEqual, + case 395: // var_decl_part -> ident_list, tkColon, type_ref, tkAssignOrEqual, // typed_var_init_expression { CurrentSemanticValue.stn = new var_def_statement(ValueStack[ValueStack.Depth-5].stn as ident_list, ValueStack[ValueStack.Depth-3].td, ValueStack[ValueStack.Depth-1].ex, definition_attribute.None, false, CurrentLocationSpan); } break; - case 393: // typed_var_init_expression -> typed_const_plus + case 396: // typed_var_init_expression -> typed_const_plus { CurrentSemanticValue.ex = ValueStack[ValueStack.Depth-1].ex; } break; - case 394: // typed_var_init_expression -> expl_func_decl_lambda + case 397: // typed_var_init_expression -> expl_func_decl_lambda { CurrentSemanticValue.ex = ValueStack[ValueStack.Depth-1].ex; } break; - case 395: // typed_var_init_expression -> identifier, tkArrow, lambda_function_body + case 398: // typed_var_init_expression -> identifier, tkArrow, lambda_function_body { var idList = new ident_list(ValueStack[ValueStack.Depth-3].id, LocationStack[LocationStack.Depth-3]); var formalPars = new formal_parameters(new typed_parameters(idList, new lambda_inferred_type(new PascalABCCompiler.TreeRealization.lambda_any_type_node(), LocationStack[LocationStack.Depth-3]), parametr_kind.none, null, LocationStack[LocationStack.Depth-3]), LocationStack[LocationStack.Depth-3]); CurrentSemanticValue.ex = new function_lambda_definition(lambdaHelper.CreateLambdaName(), formalPars, new lambda_inferred_type(new PascalABCCompiler.TreeRealization.lambda_any_type_node(), LocationStack[LocationStack.Depth-3]), ValueStack[ValueStack.Depth-1].stn as statement_list, CurrentLocationSpan); } break; - case 396: // typed_var_init_expression -> tkRoundOpen, tkRoundClose, lambda_type_ref, + case 399: // typed_var_init_expression -> tkRoundOpen, tkRoundClose, lambda_type_ref, // tkArrow, lambda_function_body { CurrentSemanticValue.ex = new function_lambda_definition(lambdaHelper.CreateLambdaName(), null, ValueStack[ValueStack.Depth-3].td, ValueStack[ValueStack.Depth-1].stn as statement_list, CurrentLocationSpan); } break; - case 397: // typed_var_init_expression -> tkRoundOpen, typed_const_list, tkRoundClose, + case 400: // typed_var_init_expression -> tkRoundOpen, typed_const_list, tkRoundClose, // tkArrow, lambda_function_body { var el = ValueStack[ValueStack.Depth-4].stn as expression_list; @@ -4135,18 +4156,18 @@ public partial class GPPGParser: ShiftReduceParser typed_const + case 401: // typed_const_plus -> typed_const { CurrentSemanticValue.ex = ValueStack[ValueStack.Depth-1].ex; } break; - case 399: // typed_const_plus -> default_expr + case 402: // typed_const_plus -> default_expr { CurrentSemanticValue.ex = ValueStack[ValueStack.Depth-1].ex; } break; - case 400: // constr_destr_decl -> constr_destr_header, block + case 403: // constr_destr_decl -> constr_destr_header, block { CurrentSemanticValue.stn = new procedure_definition(ValueStack[ValueStack.Depth-2].td as procedure_header, ValueStack[ValueStack.Depth-1].stn as block, CurrentLocationSpan); } break; - case 401: // constr_destr_decl -> tkConstructor, optional_proc_name, fp_list, tkAssign, + case 404: // constr_destr_decl -> tkConstructor, optional_proc_name, fp_list, tkAssign, // unlabelled_stmt, tkSemiColon { if (ValueStack[ValueStack.Depth-2].stn is empty_statement) @@ -4157,12 +4178,12 @@ public partial class GPPGParser: ShiftReduceParser constr_destr_header, inclass_block + case 405: // inclass_constr_destr_decl -> constr_destr_header, inclass_block { CurrentSemanticValue.stn = new procedure_definition(ValueStack[ValueStack.Depth-2].td as procedure_header, ValueStack[ValueStack.Depth-1].stn as block, CurrentLocationSpan); } break; - case 403: // inclass_constr_destr_decl -> tkConstructor, optional_proc_name, fp_list, + case 406: // inclass_constr_destr_decl -> tkConstructor, optional_proc_name, fp_list, // tkAssign, unlabelled_stmt, tkSemiColon { if (ValueStack[ValueStack.Depth-2].stn is empty_statement) @@ -4173,49 +4194,49 @@ public partial class GPPGParser: ShiftReduceParser proc_func_decl_noclass + case 407: // proc_func_decl -> proc_func_decl_noclass { CurrentSemanticValue.stn = ValueStack[ValueStack.Depth-1].stn; } break; - case 405: // proc_func_decl -> tkClass, proc_func_decl_noclass + case 408: // proc_func_decl -> tkClass, proc_func_decl_noclass { (ValueStack[ValueStack.Depth-1].stn as procedure_definition).proc_header.class_keyword = true; CurrentSemanticValue.stn = ValueStack[ValueStack.Depth-1].stn; } break; - case 406: // proc_func_decl_noclass -> proc_func_header, proc_func_external_block + case 409: // proc_func_decl_noclass -> proc_func_header, proc_func_external_block { CurrentSemanticValue.stn = new procedure_definition(ValueStack[ValueStack.Depth-2].td as procedure_header, ValueStack[ValueStack.Depth-1].stn as proc_block, CurrentLocationSpan); } break; - case 407: // proc_func_decl_noclass -> tkFunction, func_name, fp_list, tkColon, fptype, + case 410: // proc_func_decl_noclass -> tkFunction, func_name, fp_list, tkColon, fptype, // optional_method_modificators1, tkAssign, expr_l1, // tkSemiColon { CurrentSemanticValue.stn = SyntaxTreeBuilder.BuildShortFuncDefinition(ValueStack[ValueStack.Depth-7].stn as formal_parameters, ValueStack[ValueStack.Depth-4].stn as procedure_attributes_list, ValueStack[ValueStack.Depth-8].stn as method_name, ValueStack[ValueStack.Depth-5].td as type_definition, ValueStack[ValueStack.Depth-2].ex, LocationStack[LocationStack.Depth-9].Merge(LocationStack[LocationStack.Depth-4])); } break; - case 408: // proc_func_decl_noclass -> tkFunction, func_name, fp_list, + case 411: // proc_func_decl_noclass -> tkFunction, func_name, fp_list, // optional_method_modificators1, tkAssign, expr_l1, // tkSemiColon { CurrentSemanticValue.stn = SyntaxTreeBuilder.BuildShortFuncDefinition(ValueStack[ValueStack.Depth-5].stn as formal_parameters, ValueStack[ValueStack.Depth-4].stn as procedure_attributes_list, ValueStack[ValueStack.Depth-6].stn as method_name, null, ValueStack[ValueStack.Depth-2].ex, LocationStack[LocationStack.Depth-7].Merge(LocationStack[LocationStack.Depth-4])); } break; - case 409: // proc_func_decl_noclass -> tkFunction, func_name, fp_list, tkColon, fptype, + case 412: // proc_func_decl_noclass -> tkFunction, func_name, fp_list, tkColon, fptype, // optional_method_modificators1, tkAssign, // func_decl_lambda, tkSemiColon { CurrentSemanticValue.stn = SyntaxTreeBuilder.BuildShortFuncDefinition(ValueStack[ValueStack.Depth-7].stn as formal_parameters, ValueStack[ValueStack.Depth-4].stn as procedure_attributes_list, ValueStack[ValueStack.Depth-8].stn as method_name, ValueStack[ValueStack.Depth-5].td as type_definition, ValueStack[ValueStack.Depth-2].ex, LocationStack[LocationStack.Depth-9].Merge(LocationStack[LocationStack.Depth-4])); } break; - case 410: // proc_func_decl_noclass -> tkFunction, func_name, fp_list, + case 413: // proc_func_decl_noclass -> tkFunction, func_name, fp_list, // optional_method_modificators1, tkAssign, // func_decl_lambda, tkSemiColon { CurrentSemanticValue.stn = SyntaxTreeBuilder.BuildShortFuncDefinition(ValueStack[ValueStack.Depth-5].stn as formal_parameters, ValueStack[ValueStack.Depth-4].stn as procedure_attributes_list, ValueStack[ValueStack.Depth-6].stn as method_name, null, ValueStack[ValueStack.Depth-2].ex, LocationStack[LocationStack.Depth-7].Merge(LocationStack[LocationStack.Depth-4])); } break; - case 411: // proc_func_decl_noclass -> tkProcedure, proc_name, fp_list, + case 414: // proc_func_decl_noclass -> tkProcedure, proc_name, fp_list, // optional_method_modificators1, tkAssign, // unlabelled_stmt, tkSemiColon { @@ -4224,30 +4245,30 @@ public partial class GPPGParser: ShiftReduceParser proc_func_header, tkForward, tkSemiColon + case 415: // proc_func_decl_noclass -> proc_func_header, tkForward, tkSemiColon { CurrentSemanticValue.stn = new procedure_definition(ValueStack[ValueStack.Depth-3].td as procedure_header, null, CurrentLocationSpan); (CurrentSemanticValue.stn as procedure_definition).proc_header.proc_attributes.Add((procedure_attribute)ValueStack[ValueStack.Depth-2].id, ValueStack[ValueStack.Depth-2].id.source_context); } break; - case 413: // inclass_proc_func_decl -> inclass_proc_func_decl_noclass + case 416: // inclass_proc_func_decl -> inclass_proc_func_decl_noclass { CurrentSemanticValue.stn = ValueStack[ValueStack.Depth-1].stn; } break; - case 414: // inclass_proc_func_decl -> tkClass, inclass_proc_func_decl_noclass + case 417: // inclass_proc_func_decl -> tkClass, inclass_proc_func_decl_noclass { if ((ValueStack[ValueStack.Depth-1].stn as procedure_definition).proc_header != null) (ValueStack[ValueStack.Depth-1].stn as procedure_definition).proc_header.class_keyword = true; CurrentSemanticValue.stn = ValueStack[ValueStack.Depth-1].stn; } break; - case 415: // inclass_proc_func_decl_noclass -> proc_func_header, inclass_block + case 418: // inclass_proc_func_decl_noclass -> proc_func_header, inclass_block { CurrentSemanticValue.stn = new procedure_definition(ValueStack[ValueStack.Depth-2].td as procedure_header, ValueStack[ValueStack.Depth-1].stn as proc_block, CurrentLocationSpan); } break; - case 416: // inclass_proc_func_decl_noclass -> tkFunction, func_name, fp_list, tkColon, + case 419: // inclass_proc_func_decl_noclass -> tkFunction, func_name, fp_list, tkColon, // fptype, optional_method_modificators1, // tkAssign, expr_l1, tkSemiColon { @@ -4256,7 +4277,7 @@ public partial class GPPGParser: ShiftReduceParser tkFunction, func_name, fp_list, + case 420: // inclass_proc_func_decl_noclass -> tkFunction, func_name, fp_list, // optional_method_modificators1, tkAssign, // expr_l1, tkSemiColon { @@ -4265,7 +4286,7 @@ public partial class GPPGParser: ShiftReduceParser tkProcedure, proc_name, fp_list, + case 421: // inclass_proc_func_decl_noclass -> tkProcedure, proc_name, fp_list, // optional_method_modificators1, tkAssign, // unlabelled_stmt, tkSemiColon { @@ -4274,21 +4295,21 @@ public partial class GPPGParser: ShiftReduceParser block + case 422: // proc_func_external_block -> block { CurrentSemanticValue.stn = ValueStack[ValueStack.Depth-1].stn; } break; - case 420: // proc_func_external_block -> external_block + case 423: // proc_func_external_block -> external_block { CurrentSemanticValue.stn = ValueStack[ValueStack.Depth-1].stn; } break; - case 421: // proc_name -> func_name + case 424: // proc_name -> func_name { CurrentSemanticValue.stn = ValueStack[ValueStack.Depth-1].stn; } break; - case 422: // func_name -> func_meth_name_ident + case 425: // func_name -> func_meth_name_ident { CurrentSemanticValue.stn = new method_name(null,null, ValueStack[ValueStack.Depth-1].id, null, CurrentLocationSpan); } break; - case 423: // func_name -> func_class_name_ident_list, tkPoint, func_meth_name_ident + case 426: // func_name -> func_class_name_ident_list, tkPoint, func_meth_name_ident { var ln = ValueStack[ValueStack.Depth-3].ob as List; var cnt = ln.Count; @@ -4298,288 +4319,288 @@ public partial class GPPGParser: ShiftReduceParser func_name_with_template_args + case 427: // func_class_name_ident -> func_name_with_template_args { CurrentSemanticValue.id = ValueStack[ValueStack.Depth-1].id; } break; - case 425: // func_class_name_ident_list -> func_class_name_ident + case 428: // func_class_name_ident_list -> func_class_name_ident { CurrentSemanticValue.ob = new List(); (CurrentSemanticValue.ob as List).Add(ValueStack[ValueStack.Depth-1].id); } break; - case 426: // func_class_name_ident_list -> func_class_name_ident_list, tkPoint, + case 429: // func_class_name_ident_list -> func_class_name_ident_list, tkPoint, // func_class_name_ident { (ValueStack[ValueStack.Depth-3].ob as List).Add(ValueStack[ValueStack.Depth-1].id); CurrentSemanticValue.ob = ValueStack[ValueStack.Depth-3].ob; } break; - case 427: // func_meth_name_ident -> func_name_with_template_args + case 430: // func_meth_name_ident -> func_name_with_template_args { CurrentSemanticValue.id = ValueStack[ValueStack.Depth-1].id; } break; - case 428: // func_meth_name_ident -> operator_name_ident + case 431: // func_meth_name_ident -> operator_name_ident { CurrentSemanticValue.id = (ident)ValueStack[ValueStack.Depth-1].ex; } break; - case 429: // func_meth_name_ident -> operator_name_ident, template_arguments + case 432: // func_meth_name_ident -> operator_name_ident, template_arguments { CurrentSemanticValue.id = new template_operator_name(null, ValueStack[ValueStack.Depth-1].stn as ident_list, ValueStack[ValueStack.Depth-2].ex as operator_name_ident, CurrentLocationSpan); } break; - case 430: // func_name_with_template_args -> func_name_ident + case 433: // func_name_with_template_args -> func_name_ident { CurrentSemanticValue.id = ValueStack[ValueStack.Depth-1].id; } break; - case 431: // func_name_with_template_args -> func_name_ident, template_arguments + case 434: // func_name_with_template_args -> func_name_ident, template_arguments { CurrentSemanticValue.id = new template_type_name(ValueStack[ValueStack.Depth-2].id.name, ValueStack[ValueStack.Depth-1].stn as ident_list, CurrentLocationSpan); } break; - case 432: // func_name_ident -> identifier + case 435: // func_name_ident -> identifier { CurrentSemanticValue.id = ValueStack[ValueStack.Depth-1].id; } break; - case 433: // proc_header -> tkProcedure, proc_name, fp_list, optional_method_modificators, + case 436: // proc_header -> tkProcedure, proc_name, fp_list, optional_method_modificators, // optional_where_section { CurrentSemanticValue.td = new procedure_header(ValueStack[ValueStack.Depth-3].stn as formal_parameters, ValueStack[ValueStack.Depth-2].stn as procedure_attributes_list, ValueStack[ValueStack.Depth-4].stn as method_name, ValueStack[ValueStack.Depth-1].stn as where_definition_list, CurrentLocationSpan); } break; - case 434: // func_header -> tkFunction, func_name, fp_list, optional_method_modificators, + case 437: // func_header -> tkFunction, func_name, fp_list, optional_method_modificators, // optional_where_section { CurrentSemanticValue.td = new function_header(ValueStack[ValueStack.Depth-3].stn as formal_parameters, ValueStack[ValueStack.Depth-2].stn as procedure_attributes_list, ValueStack[ValueStack.Depth-4].stn as method_name, ValueStack[ValueStack.Depth-1].stn as where_definition_list, null, CurrentLocationSpan); } break; - case 435: // func_header -> tkFunction, func_name, fp_list, tkColon, fptype, + case 438: // func_header -> tkFunction, func_name, fp_list, tkColon, fptype, // optional_method_modificators, optional_where_section { CurrentSemanticValue.td = new function_header(ValueStack[ValueStack.Depth-5].stn as formal_parameters, ValueStack[ValueStack.Depth-2].stn as procedure_attributes_list, ValueStack[ValueStack.Depth-6].stn as method_name, ValueStack[ValueStack.Depth-1].stn as where_definition_list, ValueStack[ValueStack.Depth-3].td as type_definition, CurrentLocationSpan); } break; - case 436: // external_block -> tkExternal, external_directive_ident, tkName, + case 439: // external_block -> tkExternal, external_directive_ident, tkName, // external_directive_ident, tkSemiColon { CurrentSemanticValue.stn = new external_directive(ValueStack[ValueStack.Depth-4].ex, ValueStack[ValueStack.Depth-2].ex, CurrentLocationSpan); } break; - case 437: // external_block -> tkExternal, external_directive_ident, tkSemiColon + case 440: // external_block -> tkExternal, external_directive_ident, tkSemiColon { CurrentSemanticValue.stn = new external_directive(ValueStack[ValueStack.Depth-2].ex, null, CurrentLocationSpan); } break; - case 438: // external_block -> tkExternal, tkSemiColon + case 441: // external_block -> tkExternal, tkSemiColon { CurrentSemanticValue.stn = new external_directive(null, null, CurrentLocationSpan); } break; - case 439: // external_directive_ident -> identifier + case 442: // external_directive_ident -> identifier { CurrentSemanticValue.ex = ValueStack[ValueStack.Depth-1].id; } break; - case 440: // external_directive_ident -> literal + case 443: // external_directive_ident -> literal { CurrentSemanticValue.ex = ValueStack[ValueStack.Depth-1].ex; } break; - case 441: // block -> decl_sect_list, compound_stmt, tkSemiColon + case 444: // block -> decl_sect_list, compound_stmt, tkSemiColon { CurrentSemanticValue.stn = new block(ValueStack[ValueStack.Depth-3].stn as declarations, ValueStack[ValueStack.Depth-2].stn as statement_list, CurrentLocationSpan); } break; - case 442: // inclass_block -> inclass_decl_sect_list, compound_stmt, tkSemiColon + case 445: // inclass_block -> inclass_decl_sect_list, compound_stmt, tkSemiColon { CurrentSemanticValue.stn = new block(ValueStack[ValueStack.Depth-3].stn as declarations, ValueStack[ValueStack.Depth-2].stn as statement_list, CurrentLocationSpan); } break; - case 443: // inclass_block -> external_block + case 446: // inclass_block -> external_block { CurrentSemanticValue.stn = ValueStack[ValueStack.Depth-1].stn; } break; - case 444: // fp_list -> /* empty */ + case 447: // fp_list -> /* empty */ { CurrentSemanticValue.stn = null; } break; - case 445: // fp_list -> tkRoundOpen, tkRoundClose + case 448: // fp_list -> tkRoundOpen, tkRoundClose { CurrentSemanticValue.stn = null; } break; - case 446: // fp_list -> tkRoundOpen, fp_sect_list, tkRoundClose + case 449: // fp_list -> tkRoundOpen, fp_sect_list, tkRoundClose { CurrentSemanticValue.stn = ValueStack[ValueStack.Depth-2].stn; if (CurrentSemanticValue.stn != null) CurrentSemanticValue.stn.source_context = CurrentLocationSpan; } break; - case 447: // fp_sect_list -> fp_sect + case 450: // fp_sect_list -> fp_sect { CurrentSemanticValue.stn = new formal_parameters(ValueStack[ValueStack.Depth-1].stn as typed_parameters, CurrentLocationSpan); } break; - case 448: // fp_sect_list -> fp_sect_list, tkSemiColon, fp_sect + case 451: // fp_sect_list -> fp_sect_list, tkSemiColon, fp_sect { CurrentSemanticValue.stn = (ValueStack[ValueStack.Depth-3].stn as formal_parameters).Add(ValueStack[ValueStack.Depth-1].stn as typed_parameters, CurrentLocationSpan); } break; - case 449: // fp_sect -> attribute_declarations, simple_fp_sect + case 452: // fp_sect -> attribute_declarations, simple_fp_sect { (ValueStack[ValueStack.Depth-1].stn as declaration).attributes = ValueStack[ValueStack.Depth-2].stn as attribute_list; CurrentSemanticValue.stn = ValueStack[ValueStack.Depth-1].stn; } break; - case 450: // simple_fp_sect -> param_name_list, tkColon, fptype + case 453: // simple_fp_sect -> param_name_list, tkColon, fptype { CurrentSemanticValue.stn = new typed_parameters(ValueStack[ValueStack.Depth-3].stn as ident_list, ValueStack[ValueStack.Depth-1].td, parametr_kind.none, null, CurrentLocationSpan); } break; - case 451: // simple_fp_sect -> tkVar, param_name_list, tkColon, fptype + case 454: // simple_fp_sect -> tkVar, param_name_list, tkColon, fptype { CurrentSemanticValue.stn = new typed_parameters(ValueStack[ValueStack.Depth-3].stn as ident_list, ValueStack[ValueStack.Depth-1].td, parametr_kind.var_parametr, null, CurrentLocationSpan); } break; - case 452: // simple_fp_sect -> tkConst, param_name_list, tkColon, fptype + case 455: // simple_fp_sect -> tkConst, param_name_list, tkColon, fptype { CurrentSemanticValue.stn = new typed_parameters(ValueStack[ValueStack.Depth-3].stn as ident_list, ValueStack[ValueStack.Depth-1].td, parametr_kind.const_parametr, null, CurrentLocationSpan); } break; - case 453: // simple_fp_sect -> tkParams, param_name_list, tkColon, fptype + case 456: // simple_fp_sect -> tkParams, param_name_list, tkColon, fptype { CurrentSemanticValue.stn = new typed_parameters(ValueStack[ValueStack.Depth-3].stn as ident_list, ValueStack[ValueStack.Depth-1].td,parametr_kind.params_parametr,null, CurrentLocationSpan); } break; - case 454: // simple_fp_sect -> param_name_list, tkColon, fptype, tkAssign, const_expr + case 457: // simple_fp_sect -> param_name_list, tkColon, fptype, tkAssign, const_expr { CurrentSemanticValue.stn = new typed_parameters(ValueStack[ValueStack.Depth-5].stn as ident_list, ValueStack[ValueStack.Depth-3].td, parametr_kind.none, ValueStack[ValueStack.Depth-1].ex, CurrentLocationSpan); } break; - case 455: // simple_fp_sect -> tkVar, param_name_list, tkColon, fptype, tkAssign, const_expr + case 458: // simple_fp_sect -> tkVar, param_name_list, tkColon, fptype, tkAssign, const_expr { CurrentSemanticValue.stn = new typed_parameters(ValueStack[ValueStack.Depth-5].stn as ident_list, ValueStack[ValueStack.Depth-3].td, parametr_kind.var_parametr, ValueStack[ValueStack.Depth-1].ex, CurrentLocationSpan); } break; - case 456: // simple_fp_sect -> tkConst, param_name_list, tkColon, fptype, tkAssign, + case 459: // simple_fp_sect -> tkConst, param_name_list, tkColon, fptype, tkAssign, // const_expr { CurrentSemanticValue.stn = new typed_parameters(ValueStack[ValueStack.Depth-5].stn as ident_list, ValueStack[ValueStack.Depth-3].td, parametr_kind.const_parametr, ValueStack[ValueStack.Depth-1].ex, CurrentLocationSpan); } break; - case 457: // param_name_list -> param_name + case 460: // param_name_list -> param_name { CurrentSemanticValue.stn = new ident_list(ValueStack[ValueStack.Depth-1].id, CurrentLocationSpan); } break; - case 458: // param_name_list -> param_name_list, tkComma, param_name + case 461: // param_name_list -> param_name_list, tkComma, param_name { CurrentSemanticValue.stn = (ValueStack[ValueStack.Depth-3].stn as ident_list).Add(ValueStack[ValueStack.Depth-1].id, CurrentLocationSpan); } break; - case 459: // param_name -> identifier + case 462: // param_name -> identifier { CurrentSemanticValue.id = ValueStack[ValueStack.Depth-1].id; } break; - case 460: // fptype -> type_ref + case 463: // fptype -> type_ref { CurrentSemanticValue.td = ValueStack[ValueStack.Depth-1].td; } break; - case 461: // fptype_noproctype -> simple_type + case 464: // fptype_noproctype -> simple_type { CurrentSemanticValue.td = ValueStack[ValueStack.Depth-1].td; } break; - case 462: // fptype_noproctype -> string_type + case 465: // fptype_noproctype -> string_type { CurrentSemanticValue.td = ValueStack[ValueStack.Depth-1].td; } break; - case 463: // fptype_noproctype -> pointer_type + case 466: // fptype_noproctype -> pointer_type { CurrentSemanticValue.td = ValueStack[ValueStack.Depth-1].td; } break; - case 464: // fptype_noproctype -> structured_type + case 467: // fptype_noproctype -> structured_type { CurrentSemanticValue.td = ValueStack[ValueStack.Depth-1].td; } break; - case 465: // fptype_noproctype -> template_type + case 468: // fptype_noproctype -> template_type { CurrentSemanticValue.td = ValueStack[ValueStack.Depth-1].td; } break; - case 466: // stmt -> unlabelled_stmt + case 469: // stmt -> unlabelled_stmt { CurrentSemanticValue.stn = ValueStack[ValueStack.Depth-1].stn; } break; - case 467: // stmt -> label_name, tkColon, stmt + case 470: // stmt -> label_name, tkColon, stmt { CurrentSemanticValue.stn = new labeled_statement(ValueStack[ValueStack.Depth-3].id, ValueStack[ValueStack.Depth-1].stn as statement, CurrentLocationSpan); } break; - case 468: // unlabelled_stmt -> /* empty */ + case 471: // unlabelled_stmt -> /* empty */ { CurrentSemanticValue.stn = new empty_statement(); CurrentSemanticValue.stn.source_context = null; } break; - case 469: // unlabelled_stmt -> assignment + case 472: // unlabelled_stmt -> assignment { CurrentSemanticValue.stn = ValueStack[ValueStack.Depth-1].stn; } break; - case 470: // unlabelled_stmt -> proc_call + case 473: // unlabelled_stmt -> proc_call { CurrentSemanticValue.stn = ValueStack[ValueStack.Depth-1].stn; } break; - case 471: // unlabelled_stmt -> goto_stmt + case 474: // unlabelled_stmt -> goto_stmt { CurrentSemanticValue.stn = ValueStack[ValueStack.Depth-1].stn; } break; - case 472: // unlabelled_stmt -> compound_stmt + case 475: // unlabelled_stmt -> compound_stmt { CurrentSemanticValue.stn = ValueStack[ValueStack.Depth-1].stn; } break; - case 473: // unlabelled_stmt -> if_stmt + case 476: // unlabelled_stmt -> if_stmt { CurrentSemanticValue.stn = ValueStack[ValueStack.Depth-1].stn; } break; - case 474: // unlabelled_stmt -> case_stmt + case 477: // unlabelled_stmt -> case_stmt { CurrentSemanticValue.stn = ValueStack[ValueStack.Depth-1].stn; } break; - case 475: // unlabelled_stmt -> repeat_stmt + case 478: // unlabelled_stmt -> repeat_stmt { CurrentSemanticValue.stn = ValueStack[ValueStack.Depth-1].stn; } break; - case 476: // unlabelled_stmt -> while_stmt + case 479: // unlabelled_stmt -> while_stmt { CurrentSemanticValue.stn = ValueStack[ValueStack.Depth-1].stn; } break; - case 477: // unlabelled_stmt -> for_stmt + case 480: // unlabelled_stmt -> for_stmt { CurrentSemanticValue.stn = ValueStack[ValueStack.Depth-1].stn; } break; - case 478: // unlabelled_stmt -> with_stmt + case 481: // unlabelled_stmt -> with_stmt { CurrentSemanticValue.stn = ValueStack[ValueStack.Depth-1].stn; } break; - case 479: // unlabelled_stmt -> inherited_message + case 482: // unlabelled_stmt -> inherited_message { CurrentSemanticValue.stn = ValueStack[ValueStack.Depth-1].stn; } break; - case 480: // unlabelled_stmt -> try_stmt + case 483: // unlabelled_stmt -> try_stmt { CurrentSemanticValue.stn = ValueStack[ValueStack.Depth-1].stn; } break; - case 481: // unlabelled_stmt -> raise_stmt + case 484: // unlabelled_stmt -> raise_stmt { CurrentSemanticValue.stn = ValueStack[ValueStack.Depth-1].stn; } break; - case 482: // unlabelled_stmt -> foreach_stmt + case 485: // unlabelled_stmt -> foreach_stmt { CurrentSemanticValue.stn = ValueStack[ValueStack.Depth-1].stn; } break; - case 483: // unlabelled_stmt -> var_stmt + case 486: // unlabelled_stmt -> var_stmt { CurrentSemanticValue.stn = ValueStack[ValueStack.Depth-1].stn; } break; - case 484: // unlabelled_stmt -> expr_as_stmt + case 487: // unlabelled_stmt -> expr_as_stmt { CurrentSemanticValue.stn = ValueStack[ValueStack.Depth-1].stn; } break; - case 485: // unlabelled_stmt -> lock_stmt + case 488: // unlabelled_stmt -> lock_stmt { CurrentSemanticValue.stn = ValueStack[ValueStack.Depth-1].stn; } break; - case 486: // unlabelled_stmt -> yield_stmt + case 489: // unlabelled_stmt -> yield_stmt { CurrentSemanticValue.stn = ValueStack[ValueStack.Depth-1].stn; } break; - case 487: // unlabelled_stmt -> yield_sequence_stmt + case 490: // unlabelled_stmt -> yield_sequence_stmt { CurrentSemanticValue.stn = ValueStack[ValueStack.Depth-1].stn; } break; - case 488: // unlabelled_stmt -> loop_stmt + case 491: // unlabelled_stmt -> loop_stmt { CurrentSemanticValue.stn = ValueStack[ValueStack.Depth-1].stn; } break; - case 489: // loop_stmt -> tkLoop, expr_l1, tkDo, unlabelled_stmt + case 492: // loop_stmt -> tkLoop, expr_l1, tkDo, unlabelled_stmt { CurrentSemanticValue.stn = new loop_stmt(ValueStack[ValueStack.Depth-3].ex,ValueStack[ValueStack.Depth-1].stn as statement,CurrentLocationSpan); } break; - case 490: // yield_stmt -> tkYield, expr_l1 + case 493: // yield_stmt -> tkYield, expr_l1 { CurrentSemanticValue.stn = new yield_node(ValueStack[ValueStack.Depth-1].ex,CurrentLocationSpan); } break; - case 491: // yield_sequence_stmt -> tkYield, tkSequence, expr_l1 + case 494: // yield_sequence_stmt -> tkYield, tkSequence, expr_l1 { CurrentSemanticValue.stn = new yield_sequence_node(ValueStack[ValueStack.Depth-1].ex,CurrentLocationSpan); } break; - case 492: // var_stmt -> tkVar, var_decl_part + case 495: // var_stmt -> tkVar, var_decl_part { CurrentSemanticValue.stn = new var_statement(ValueStack[ValueStack.Depth-1].stn as var_def_statement, CurrentLocationSpan); } break; - case 493: // var_stmt -> tkRoundOpen, tkVar, identifier, tkComma, var_ident_list, + case 496: // var_stmt -> tkRoundOpen, tkVar, identifier, tkComma, var_ident_list, // tkRoundClose, tkAssign, expr { (ValueStack[ValueStack.Depth-4].ob as ident_list).Insert(0,ValueStack[ValueStack.Depth-6].id); @@ -4587,7 +4608,7 @@ public partial class GPPGParser: ShiftReduceParser tkVar, tkRoundOpen, identifier, tkComma, ident_list, tkRoundClose, + case 497: // var_stmt -> tkVar, tkRoundOpen, identifier, tkComma, ident_list, tkRoundClose, // tkAssign, expr { (ValueStack[ValueStack.Depth-4].stn as ident_list).Insert(0,ValueStack[ValueStack.Depth-6].id); @@ -4595,12 +4616,12 @@ public partial class GPPGParser: ShiftReduceParser var_reference, assign_operator, expr_with_func_decl_lambda + case 498: // assignment -> var_reference, assign_operator, expr_with_func_decl_lambda { CurrentSemanticValue.stn = new assign(ValueStack[ValueStack.Depth-3].ex as addressed_value, ValueStack[ValueStack.Depth-1].ex, ValueStack[ValueStack.Depth-2].op.type, CurrentLocationSpan); } break; - case 496: // assignment -> tkRoundOpen, variable, tkComma, variable_list, tkRoundClose, + case 499: // assignment -> tkRoundOpen, variable, tkComma, variable_list, tkRoundClose, // assign_operator, expr { if (ValueStack[ValueStack.Depth-2].op.type != Operators.Assignment) @@ -4610,41 +4631,41 @@ public partial class GPPGParser: ShiftReduceParser variable + case 500: // variable_list -> variable { CurrentSemanticValue.ob = new addressed_value_list(ValueStack[ValueStack.Depth-1].ex as addressed_value,LocationStack[LocationStack.Depth-1]); } break; - case 498: // variable_list -> variable_list, tkComma, variable + case 501: // variable_list -> variable_list, tkComma, variable { (ValueStack[ValueStack.Depth-3].ob as addressed_value_list).Add(ValueStack[ValueStack.Depth-1].ex as addressed_value); (ValueStack[ValueStack.Depth-3].ob as syntax_tree_node).source_context = LexLocation.MergeAll(LocationStack[LocationStack.Depth-3],LocationStack[LocationStack.Depth-2],LocationStack[LocationStack.Depth-1]); CurrentSemanticValue.ob = ValueStack[ValueStack.Depth-3].ob; } break; - case 499: // var_ident_list -> tkVar, identifier + case 502: // var_ident_list -> tkVar, identifier { CurrentSemanticValue.ob = new ident_list(ValueStack[ValueStack.Depth-1].id,CurrentLocationSpan); } break; - case 500: // var_ident_list -> var_ident_list, tkComma, tkVar, identifier + case 503: // var_ident_list -> var_ident_list, tkComma, tkVar, identifier { (ValueStack[ValueStack.Depth-4].ob as ident_list).Add(ValueStack[ValueStack.Depth-1].id); (ValueStack[ValueStack.Depth-4].ob as ident_list).source_context = LexLocation.MergeAll(LocationStack[LocationStack.Depth-4],LocationStack[LocationStack.Depth-3],LocationStack[LocationStack.Depth-2],LocationStack[LocationStack.Depth-1]); CurrentSemanticValue.ob = ValueStack[ValueStack.Depth-4].ob; } break; - case 501: // proc_call -> var_reference + case 504: // proc_call -> var_reference { CurrentSemanticValue.stn = new procedure_call(ValueStack[ValueStack.Depth-1].ex as addressed_value, CurrentLocationSpan); } break; - case 502: // goto_stmt -> tkGoto, label_name + case 505: // goto_stmt -> tkGoto, label_name { CurrentSemanticValue.stn = new goto_statement(ValueStack[ValueStack.Depth-1].id, CurrentLocationSpan); } break; - case 503: // compound_stmt -> tkBegin, stmt_list, tkEnd + case 506: // compound_stmt -> tkBegin, stmt_list, tkEnd { CurrentSemanticValue.stn = ValueStack[ValueStack.Depth-2].stn; (CurrentSemanticValue.stn as statement_list).left_logical_bracket = ValueStack[ValueStack.Depth-3].ti; @@ -4652,73 +4673,73 @@ public partial class GPPGParser: ShiftReduceParser stmt + case 507: // stmt_list -> stmt { CurrentSemanticValue.stn = new statement_list(ValueStack[ValueStack.Depth-1].stn as statement, LocationStack[LocationStack.Depth-1]); } break; - case 505: // stmt_list -> stmt_list, tkSemiColon, stmt + case 508: // stmt_list -> stmt_list, tkSemiColon, stmt { CurrentSemanticValue.stn = (ValueStack[ValueStack.Depth-3].stn as statement_list).Add(ValueStack[ValueStack.Depth-1].stn as statement, CurrentLocationSpan); } break; - case 506: // if_stmt -> tkIf, expr_l1, tkThen, unlabelled_stmt + case 509: // if_stmt -> tkIf, expr_l1, tkThen, unlabelled_stmt { CurrentSemanticValue.stn = new if_node(ValueStack[ValueStack.Depth-3].ex, ValueStack[ValueStack.Depth-1].stn as statement, null, CurrentLocationSpan); } break; - case 507: // if_stmt -> tkIf, expr_l1, tkThen, unlabelled_stmt, tkElse, unlabelled_stmt + case 510: // if_stmt -> tkIf, expr_l1, tkThen, unlabelled_stmt, tkElse, unlabelled_stmt { CurrentSemanticValue.stn = new if_node(ValueStack[ValueStack.Depth-5].ex, ValueStack[ValueStack.Depth-3].stn as statement, ValueStack[ValueStack.Depth-1].stn as statement, CurrentLocationSpan); } break; - case 508: // case_stmt -> tkCase, expr_l1, tkOf, case_list, else_case, tkEnd + case 511: // case_stmt -> tkCase, expr_l1, tkOf, case_list, else_case, tkEnd { CurrentSemanticValue.stn = new case_node(ValueStack[ValueStack.Depth-5].ex, ValueStack[ValueStack.Depth-3].stn as case_variants, ValueStack[ValueStack.Depth-2].stn as statement, CurrentLocationSpan); } break; - case 509: // case_list -> case_item + case 512: // case_list -> case_item { if (ValueStack[ValueStack.Depth-1].stn is empty_statement) CurrentSemanticValue.stn = NewCaseItem(ValueStack[ValueStack.Depth-1].stn, null); else CurrentSemanticValue.stn = NewCaseItem(ValueStack[ValueStack.Depth-1].stn, CurrentLocationSpan); } break; - case 510: // case_list -> case_list, tkSemiColon, case_item + case 513: // case_list -> case_list, tkSemiColon, case_item { CurrentSemanticValue.stn = AddCaseItem(ValueStack[ValueStack.Depth-3].stn as case_variants, ValueStack[ValueStack.Depth-1].stn, CurrentLocationSpan); } break; - case 511: // case_item -> /* empty */ + case 514: // case_item -> /* empty */ { CurrentSemanticValue.stn = new empty_statement(); } break; - case 512: // case_item -> case_label_list, tkColon, unlabelled_stmt + case 515: // case_item -> case_label_list, tkColon, unlabelled_stmt { CurrentSemanticValue.stn = new case_variant(ValueStack[ValueStack.Depth-3].stn as expression_list, ValueStack[ValueStack.Depth-1].stn as statement, CurrentLocationSpan); } break; - case 513: // case_label_list -> case_label + case 516: // case_label_list -> case_label { CurrentSemanticValue.stn = new expression_list(ValueStack[ValueStack.Depth-1].ex, CurrentLocationSpan); } break; - case 514: // case_label_list -> case_label_list, tkComma, case_label + case 517: // case_label_list -> case_label_list, tkComma, case_label { CurrentSemanticValue.stn = (ValueStack[ValueStack.Depth-3].stn as expression_list).Add(ValueStack[ValueStack.Depth-1].ex, CurrentLocationSpan); } break; - case 515: // case_label -> const_elem + case 518: // case_label -> const_elem { CurrentSemanticValue.ex = ValueStack[ValueStack.Depth-1].ex; } break; - case 516: // else_case -> /* empty */ + case 519: // else_case -> /* empty */ { CurrentSemanticValue.stn = null;} break; - case 517: // else_case -> tkElse, stmt_list + case 520: // else_case -> tkElse, stmt_list { CurrentSemanticValue.stn = ValueStack[ValueStack.Depth-1].stn; } break; - case 518: // repeat_stmt -> tkRepeat, stmt_list, tkUntil, expr + case 521: // repeat_stmt -> tkRepeat, stmt_list, tkUntil, expr { CurrentSemanticValue.stn = new repeat_node(ValueStack[ValueStack.Depth-3].stn as statement_list, ValueStack[ValueStack.Depth-1].ex, CurrentLocationSpan); (ValueStack[ValueStack.Depth-3].stn as statement_list).left_logical_bracket = ValueStack[ValueStack.Depth-4].ti; @@ -4726,23 +4747,23 @@ public partial class GPPGParser: ShiftReduceParser tkWhile, expr_l1, optional_tk_do, unlabelled_stmt + case 522: // while_stmt -> tkWhile, expr_l1, optional_tk_do, unlabelled_stmt { CurrentSemanticValue.stn = NewWhileStmt(ValueStack[ValueStack.Depth-4].ti, ValueStack[ValueStack.Depth-3].ex, ValueStack[ValueStack.Depth-2].ti, ValueStack[ValueStack.Depth-1].stn as statement, CurrentLocationSpan); } break; - case 520: // optional_tk_do -> tkDo + case 523: // optional_tk_do -> tkDo { CurrentSemanticValue.ti = ValueStack[ValueStack.Depth-1].ti; } break; - case 521: // optional_tk_do -> /* empty */ + case 524: // optional_tk_do -> /* empty */ { CurrentSemanticValue.ti = null; } break; - case 522: // lock_stmt -> tkLock, expr_l1, tkDo, unlabelled_stmt + case 525: // lock_stmt -> tkLock, expr_l1, tkDo, unlabelled_stmt { CurrentSemanticValue.stn = new lock_stmt(ValueStack[ValueStack.Depth-3].ex, ValueStack[ValueStack.Depth-1].stn as statement, CurrentLocationSpan); } break; - case 523: // foreach_stmt -> tkForeach, identifier, foreach_stmt_ident_dype_opt, tkIn, + case 526: // foreach_stmt -> tkForeach, identifier, foreach_stmt_ident_dype_opt, tkIn, // expr_l1, tkDo, unlabelled_stmt { CurrentSemanticValue.stn = new foreach_stmt(ValueStack[ValueStack.Depth-6].id, ValueStack[ValueStack.Depth-5].td, ValueStack[ValueStack.Depth-3].ex, ValueStack[ValueStack.Depth-1].stn as statement, CurrentLocationSpan); @@ -4750,68 +4771,68 @@ public partial class GPPGParser: ShiftReduceParser tkForeach, tkVar, identifier, tkColon, type_ref, tkIn, expr_l1, + case 527: // foreach_stmt -> tkForeach, tkVar, identifier, tkColon, type_ref, tkIn, expr_l1, // tkDo, unlabelled_stmt { CurrentSemanticValue.stn = new foreach_stmt(ValueStack[ValueStack.Depth-7].id, ValueStack[ValueStack.Depth-5].td, ValueStack[ValueStack.Depth-3].ex, ValueStack[ValueStack.Depth-1].stn as statement, CurrentLocationSpan); } break; - case 525: // foreach_stmt -> tkForeach, tkVar, identifier, tkIn, expr_l1, tkDo, + case 528: // foreach_stmt -> tkForeach, tkVar, identifier, tkIn, expr_l1, tkDo, // unlabelled_stmt { CurrentSemanticValue.stn = new foreach_stmt(ValueStack[ValueStack.Depth-5].id, new no_type_foreach(), ValueStack[ValueStack.Depth-3].ex, (statement)ValueStack[ValueStack.Depth-1].stn, CurrentLocationSpan); } break; - case 526: // foreach_stmt_ident_dype_opt -> tkColon, type_ref + case 529: // foreach_stmt_ident_dype_opt -> tkColon, type_ref { CurrentSemanticValue.td = ValueStack[ValueStack.Depth-1].td; } break; - case 528: // for_stmt -> tkFor, optional_var, identifier, for_stmt_decl_or_assign, expr_l1, + case 531: // for_stmt -> tkFor, optional_var, identifier, for_stmt_decl_or_assign, expr_l1, // for_cycle_type, expr_l1, optional_tk_do, unlabelled_stmt { CurrentSemanticValue.stn = NewForStmt((bool)ValueStack[ValueStack.Depth-8].ob, ValueStack[ValueStack.Depth-7].id, ValueStack[ValueStack.Depth-6].td, ValueStack[ValueStack.Depth-5].ex, (for_cycle_type)ValueStack[ValueStack.Depth-4].ob, ValueStack[ValueStack.Depth-3].ex, ValueStack[ValueStack.Depth-2].ti, ValueStack[ValueStack.Depth-1].stn as statement, CurrentLocationSpan); } break; - case 529: // optional_var -> tkVar + case 532: // optional_var -> tkVar { CurrentSemanticValue.ob = true; } break; - case 530: // optional_var -> /* empty */ + case 533: // optional_var -> /* empty */ { CurrentSemanticValue.ob = false; } break; - case 532: // for_stmt_decl_or_assign -> tkColon, simple_type_identifier, tkAssign + case 535: // for_stmt_decl_or_assign -> tkColon, simple_type_identifier, tkAssign { CurrentSemanticValue.td = ValueStack[ValueStack.Depth-2].td; } break; - case 533: // for_cycle_type -> tkTo + case 536: // for_cycle_type -> tkTo { CurrentSemanticValue.ob = for_cycle_type.to; } break; - case 534: // for_cycle_type -> tkDownto + case 537: // for_cycle_type -> tkDownto { CurrentSemanticValue.ob = for_cycle_type.downto; } break; - case 535: // with_stmt -> tkWith, expr_list, tkDo, unlabelled_stmt + case 538: // with_stmt -> tkWith, expr_list, tkDo, unlabelled_stmt { CurrentSemanticValue.stn = new with_statement(ValueStack[ValueStack.Depth-1].stn as statement, ValueStack[ValueStack.Depth-3].stn as expression_list, CurrentLocationSpan); } break; - case 536: // inherited_message -> tkInherited + case 539: // inherited_message -> tkInherited { CurrentSemanticValue.stn = new inherited_message(); CurrentSemanticValue.stn.source_context = CurrentLocationSpan; } break; - case 537: // try_stmt -> tkTry, stmt_list, try_handler + case 540: // try_stmt -> tkTry, stmt_list, try_handler { CurrentSemanticValue.stn = new try_stmt(ValueStack[ValueStack.Depth-2].stn as statement_list, ValueStack[ValueStack.Depth-1].stn as try_handler, CurrentLocationSpan); (ValueStack[ValueStack.Depth-2].stn as statement_list).left_logical_bracket = ValueStack[ValueStack.Depth-3].ti; ValueStack[ValueStack.Depth-2].stn.source_context = LocationStack[LocationStack.Depth-3].Merge(LocationStack[LocationStack.Depth-2]); } break; - case 538: // try_handler -> tkFinally, stmt_list, tkEnd + case 541: // try_handler -> tkFinally, stmt_list, tkEnd { CurrentSemanticValue.stn = new try_handler_finally(ValueStack[ValueStack.Depth-2].stn as statement_list, CurrentLocationSpan); (ValueStack[ValueStack.Depth-2].stn as statement_list).left_logical_bracket = ValueStack[ValueStack.Depth-3].ti; (ValueStack[ValueStack.Depth-2].stn as statement_list).right_logical_bracket = ValueStack[ValueStack.Depth-1].ti; } break; - case 539: // try_handler -> tkExcept, exception_block, tkEnd + case 542: // try_handler -> tkExcept, exception_block, tkEnd { CurrentSemanticValue.stn = new try_handler_except((exception_block)ValueStack[ValueStack.Depth-2].stn, CurrentLocationSpan); if ((ValueStack[ValueStack.Depth-2].stn as exception_block).stmt_list != null) @@ -4821,160 +4842,160 @@ public partial class GPPGParser: ShiftReduceParser exception_handler_list, exception_block_else_branch + case 543: // exception_block -> exception_handler_list, exception_block_else_branch { CurrentSemanticValue.stn = new exception_block(null, (exception_handler_list)ValueStack[ValueStack.Depth-2].stn, (statement_list)ValueStack[ValueStack.Depth-1].stn, CurrentLocationSpan); } break; - case 541: // exception_block -> exception_handler_list, tkSemiColon, + case 544: // exception_block -> exception_handler_list, tkSemiColon, // exception_block_else_branch { CurrentSemanticValue.stn = new exception_block(null, (exception_handler_list)ValueStack[ValueStack.Depth-3].stn, (statement_list)ValueStack[ValueStack.Depth-1].stn, CurrentLocationSpan); } break; - case 542: // exception_block -> stmt_list + case 545: // exception_block -> stmt_list { CurrentSemanticValue.stn = new exception_block(ValueStack[ValueStack.Depth-1].stn as statement_list, null, null, LocationStack[LocationStack.Depth-1]); } break; - case 543: // exception_handler_list -> exception_handler + case 546: // exception_handler_list -> exception_handler { CurrentSemanticValue.stn = new exception_handler_list(ValueStack[ValueStack.Depth-1].stn as exception_handler, CurrentLocationSpan); } break; - case 544: // exception_handler_list -> exception_handler_list, tkSemiColon, + case 547: // exception_handler_list -> exception_handler_list, tkSemiColon, // exception_handler { CurrentSemanticValue.stn = (ValueStack[ValueStack.Depth-3].stn as exception_handler_list).Add(ValueStack[ValueStack.Depth-1].stn as exception_handler, CurrentLocationSpan); } break; - case 545: // exception_block_else_branch -> /* empty */ + case 548: // exception_block_else_branch -> /* empty */ { CurrentSemanticValue.stn = null; } break; - case 546: // exception_block_else_branch -> tkElse, stmt_list + case 549: // exception_block_else_branch -> tkElse, stmt_list { CurrentSemanticValue.stn = ValueStack[ValueStack.Depth-1].stn; } break; - case 547: // exception_handler -> tkOn, exception_identifier, tkDo, unlabelled_stmt + case 550: // exception_handler -> tkOn, exception_identifier, tkDo, unlabelled_stmt { CurrentSemanticValue.stn = new exception_handler((ValueStack[ValueStack.Depth-3].stn as exception_ident).variable, (ValueStack[ValueStack.Depth-3].stn as exception_ident).type_name, ValueStack[ValueStack.Depth-1].stn as statement, CurrentLocationSpan); } break; - case 548: // exception_identifier -> exception_class_type_identifier + case 551: // exception_identifier -> exception_class_type_identifier { CurrentSemanticValue.stn = new exception_ident(null, (named_type_reference)ValueStack[ValueStack.Depth-1].td, CurrentLocationSpan); } break; - case 549: // exception_identifier -> exception_variable, tkColon, + case 552: // exception_identifier -> exception_variable, tkColon, // exception_class_type_identifier { CurrentSemanticValue.stn = new exception_ident(ValueStack[ValueStack.Depth-3].id, (named_type_reference)ValueStack[ValueStack.Depth-1].td, CurrentLocationSpan); } break; - case 550: // exception_class_type_identifier -> simple_type_identifier + case 553: // exception_class_type_identifier -> simple_type_identifier { CurrentSemanticValue.td = ValueStack[ValueStack.Depth-1].td; } break; - case 551: // exception_variable -> identifier + case 554: // exception_variable -> identifier { CurrentSemanticValue.id = ValueStack[ValueStack.Depth-1].id; } break; - case 552: // raise_stmt -> tkRaise + case 555: // raise_stmt -> tkRaise { CurrentSemanticValue.stn = new raise_stmt(); CurrentSemanticValue.stn.source_context = CurrentLocationSpan; } break; - case 553: // raise_stmt -> tkRaise, expr + case 556: // raise_stmt -> tkRaise, expr { CurrentSemanticValue.stn = new raise_stmt(ValueStack[ValueStack.Depth-1].ex, null, CurrentLocationSpan); } break; - case 554: // expr_list -> expr_with_func_decl_lambda + case 557: // expr_list -> expr_with_func_decl_lambda { CurrentSemanticValue.stn = new expression_list(ValueStack[ValueStack.Depth-1].ex, CurrentLocationSpan); } break; - case 555: // expr_list -> expr_list, tkComma, expr_with_func_decl_lambda + case 558: // expr_list -> expr_list, tkComma, expr_with_func_decl_lambda { CurrentSemanticValue.stn = (ValueStack[ValueStack.Depth-3].stn as expression_list).Add(ValueStack[ValueStack.Depth-1].ex, CurrentLocationSpan); } break; - case 556: // expr_as_stmt -> allowable_expr_as_stmt + case 559: // expr_as_stmt -> allowable_expr_as_stmt { CurrentSemanticValue.stn = new expression_as_statement(ValueStack[ValueStack.Depth-1].ex, CurrentLocationSpan); } break; - case 557: // allowable_expr_as_stmt -> new_expr + case 560: // allowable_expr_as_stmt -> new_expr { CurrentSemanticValue.ex = ValueStack[ValueStack.Depth-1].ex; } break; - case 558: // expr_with_func_decl_lambda -> expr + case 561: // expr_with_func_decl_lambda -> expr { CurrentSemanticValue.ex = ValueStack[ValueStack.Depth-1].ex; } break; - case 559: // expr_with_func_decl_lambda -> func_decl_lambda + case 562: // expr_with_func_decl_lambda -> func_decl_lambda { CurrentSemanticValue.ex = ValueStack[ValueStack.Depth-1].ex; } break; - case 560: // expr -> expr_l1 + case 563: // expr -> expr_l1 { CurrentSemanticValue.ex = ValueStack[ValueStack.Depth-1].ex; } break; - case 561: // expr -> format_expr + case 564: // expr -> format_expr { CurrentSemanticValue.ex = ValueStack[ValueStack.Depth-1].ex; } break; - case 562: // expr_l1 -> expr_dq + case 565: // expr_l1 -> expr_dq { CurrentSemanticValue.ex = ValueStack[ValueStack.Depth-1].ex; } break; - case 563: // expr_l1 -> question_expr + case 566: // expr_l1 -> question_expr { CurrentSemanticValue.ex = ValueStack[ValueStack.Depth-1].ex; } break; - case 564: // expr_dq -> relop_expr + case 567: // expr_dq -> relop_expr { CurrentSemanticValue.ex = ValueStack[ValueStack.Depth-1].ex; } break; - case 565: // expr_dq -> expr_dq, tkDoubleQuestion, relop_expr + case 568: // expr_dq -> expr_dq, tkDoubleQuestion, relop_expr { CurrentSemanticValue.ex = new double_question_node(ValueStack[ValueStack.Depth-3].ex as expression, ValueStack[ValueStack.Depth-1].ex as expression, CurrentLocationSpan);} break; - case 566: // sizeof_expr -> tkSizeOf, tkRoundOpen, simple_or_template_type_reference, + case 569: // sizeof_expr -> tkSizeOf, tkRoundOpen, simple_or_template_type_reference, // tkRoundClose { CurrentSemanticValue.ex = new sizeof_operator((named_type_reference)ValueStack[ValueStack.Depth-2].td, null, CurrentLocationSpan); } break; - case 567: // typeof_expr -> tkTypeOf, tkRoundOpen, simple_or_template_type_reference, + case 570: // typeof_expr -> tkTypeOf, tkRoundOpen, simple_or_template_type_reference, // tkRoundClose { CurrentSemanticValue.ex = new typeof_operator((named_type_reference)ValueStack[ValueStack.Depth-2].td, CurrentLocationSpan); } break; - case 568: // question_expr -> expr_l1, tkQuestion, expr_l1, tkColon, expr_l1 + case 571: // question_expr -> expr_l1, tkQuestion, expr_l1, tkColon, expr_l1 { CurrentSemanticValue.ex = new question_colon_expression(ValueStack[ValueStack.Depth-5].ex, ValueStack[ValueStack.Depth-3].ex, ValueStack[ValueStack.Depth-1].ex, CurrentLocationSpan); } break; - case 569: // simple_or_template_type_reference -> simple_type_identifier + case 572: // simple_or_template_type_reference -> simple_type_identifier { CurrentSemanticValue.td = ValueStack[ValueStack.Depth-1].td; } break; - case 570: // simple_or_template_type_reference -> simple_type_identifier, + case 573: // simple_or_template_type_reference -> simple_type_identifier, // template_type_params { CurrentSemanticValue.td = new template_type_reference((named_type_reference)ValueStack[ValueStack.Depth-2].td, (template_param_list)ValueStack[ValueStack.Depth-1].stn, CurrentLocationSpan); } break; - case 571: // simple_or_template_type_reference -> simple_type_identifier, tkAmpersend, - // template_type_params + case 574: // simple_or_template_type_reference -> simple_type_identifier, tkAmpersend, + // template_type_or_typeclass_params { CurrentSemanticValue.td = new template_type_reference((named_type_reference)ValueStack[ValueStack.Depth-3].td, (template_param_list)ValueStack[ValueStack.Depth-1].stn, CurrentLocationSpan); } break; - case 572: // optional_array_initializer -> tkRoundOpen, typed_const_list, tkRoundClose + case 575: // optional_array_initializer -> tkRoundOpen, typed_const_list, tkRoundClose { CurrentSemanticValue.stn = new array_const((expression_list)ValueStack[ValueStack.Depth-2].stn, CurrentLocationSpan); } break; - case 574: // new_expr -> tkNew, simple_or_template_type_reference, + case 577: // new_expr -> tkNew, simple_or_template_type_reference, // optional_expr_list_with_bracket { CurrentSemanticValue.ex = new new_expr(ValueStack[ValueStack.Depth-2].td, ValueStack[ValueStack.Depth-1].stn as expression_list, false, null, CurrentLocationSpan); } break; - case 575: // new_expr -> tkNew, array_name_for_new_expr, tkSquareOpen, optional_expr_list, + case 578: // new_expr -> tkNew, array_name_for_new_expr, tkSquareOpen, optional_expr_list, // tkSquareClose, optional_array_initializer { var el = ValueStack[ValueStack.Depth-3].stn as expression_list; @@ -4990,7 +5011,7 @@ public partial class GPPGParser: ShiftReduceParser tkNew, tkClass, tkRoundOpen, list_fields_in_unnamed_object, + case 579: // new_expr -> tkNew, tkClass, tkRoundOpen, list_fields_in_unnamed_object, // tkRoundClose { // sugared node @@ -5005,12 +5026,12 @@ public partial class GPPGParser: ShiftReduceParser identifier, tkAssign, relop_expr + case 580: // field_in_unnamed_object -> identifier, tkAssign, relop_expr { CurrentSemanticValue.ob = new name_assign_expr(ValueStack[ValueStack.Depth-3].id,ValueStack[ValueStack.Depth-1].ex,CurrentLocationSpan); } break; - case 578: // field_in_unnamed_object -> relop_expr + case 581: // field_in_unnamed_object -> relop_expr { ident name = null; var id = ValueStack[ValueStack.Depth-1].ex as ident; @@ -5030,13 +5051,13 @@ public partial class GPPGParser: ShiftReduceParser field_in_unnamed_object + case 582: // list_fields_in_unnamed_object -> field_in_unnamed_object { var l = new name_assign_expr_list(); CurrentSemanticValue.ob = l.Add(ValueStack[ValueStack.Depth-1].ob as name_assign_expr); } break; - case 580: // list_fields_in_unnamed_object -> list_fields_in_unnamed_object, tkComma, + case 583: // list_fields_in_unnamed_object -> list_fields_in_unnamed_object, tkComma, // field_in_unnamed_object { var nel = ValueStack[ValueStack.Depth-3].ob as name_assign_expr_list; @@ -5047,169 +5068,169 @@ public partial class GPPGParser: ShiftReduceParser simple_type_identifier + case 584: // array_name_for_new_expr -> simple_type_identifier { CurrentSemanticValue.td = ValueStack[ValueStack.Depth-1].td; } break; - case 582: // array_name_for_new_expr -> unsized_array_type + case 585: // array_name_for_new_expr -> unsized_array_type { CurrentSemanticValue.td = ValueStack[ValueStack.Depth-1].td; } break; - case 583: // optional_expr_list_with_bracket -> /* empty */ + case 586: // optional_expr_list_with_bracket -> /* empty */ { CurrentSemanticValue.stn = null; } break; - case 584: // optional_expr_list_with_bracket -> tkRoundOpen, optional_expr_list, + case 587: // optional_expr_list_with_bracket -> tkRoundOpen, optional_expr_list, // tkRoundClose { CurrentSemanticValue.stn = ValueStack[ValueStack.Depth-2].stn; } break; - case 585: // relop_expr -> simple_expr + case 588: // relop_expr -> simple_expr { CurrentSemanticValue.ex = ValueStack[ValueStack.Depth-1].ex; } break; - case 586: // relop_expr -> relop_expr, relop, simple_expr + case 589: // relop_expr -> relop_expr, relop, simple_expr { CurrentSemanticValue.ex = new bin_expr(ValueStack[ValueStack.Depth-3].ex, ValueStack[ValueStack.Depth-1].ex, ValueStack[ValueStack.Depth-2].op.type, CurrentLocationSpan); } break; - case 587: // simple_expr_or_nothing -> simple_expr + case 590: // simple_expr_or_nothing -> simple_expr { CurrentSemanticValue.ex = ValueStack[ValueStack.Depth-1].ex; } break; - case 588: // simple_expr_or_nothing -> /* empty */ + case 591: // simple_expr_or_nothing -> /* empty */ { CurrentSemanticValue.ex = null; } break; - case 589: // format_expr -> simple_expr, tkColon, simple_expr_or_nothing + case 592: // format_expr -> simple_expr, tkColon, simple_expr_or_nothing { CurrentSemanticValue.ex = new format_expr(ValueStack[ValueStack.Depth-3].ex, ValueStack[ValueStack.Depth-1].ex, null, CurrentLocationSpan); } break; - case 590: // format_expr -> tkColon, simple_expr_or_nothing + case 593: // format_expr -> tkColon, simple_expr_or_nothing { CurrentSemanticValue.ex = new format_expr(null, ValueStack[ValueStack.Depth-1].ex, null, CurrentLocationSpan); } break; - case 591: // format_expr -> simple_expr, tkColon, simple_expr_or_nothing, tkColon, + case 594: // format_expr -> simple_expr, tkColon, simple_expr_or_nothing, tkColon, // simple_expr { CurrentSemanticValue.ex = new format_expr(ValueStack[ValueStack.Depth-5].ex, ValueStack[ValueStack.Depth-3].ex, ValueStack[ValueStack.Depth-1].ex, CurrentLocationSpan); } break; - case 592: // format_expr -> tkColon, simple_expr_or_nothing, tkColon, simple_expr + case 595: // format_expr -> tkColon, simple_expr_or_nothing, tkColon, simple_expr { CurrentSemanticValue.ex = new format_expr(null, ValueStack[ValueStack.Depth-3].ex, ValueStack[ValueStack.Depth-1].ex, CurrentLocationSpan); } break; - case 593: // relop -> tkEqual + case 596: // relop -> tkEqual { CurrentSemanticValue.op = ValueStack[ValueStack.Depth-1].op; } break; - case 594: // relop -> tkNotEqual + case 597: // relop -> tkNotEqual { CurrentSemanticValue.op = ValueStack[ValueStack.Depth-1].op; } break; - case 595: // relop -> tkLower + case 598: // relop -> tkLower { CurrentSemanticValue.op = ValueStack[ValueStack.Depth-1].op; } break; - case 596: // relop -> tkGreater + case 599: // relop -> tkGreater { CurrentSemanticValue.op = ValueStack[ValueStack.Depth-1].op; } break; - case 597: // relop -> tkLowerEqual + case 600: // relop -> tkLowerEqual { CurrentSemanticValue.op = ValueStack[ValueStack.Depth-1].op; } break; - case 598: // relop -> tkGreaterEqual + case 601: // relop -> tkGreaterEqual { CurrentSemanticValue.op = ValueStack[ValueStack.Depth-1].op; } break; - case 599: // relop -> tkIn + case 602: // relop -> tkIn { CurrentSemanticValue.op = ValueStack[ValueStack.Depth-1].op; } break; - case 600: // simple_expr -> term + case 603: // simple_expr -> term { CurrentSemanticValue.ex = ValueStack[ValueStack.Depth-1].ex; } break; - case 601: // simple_expr -> simple_expr, addop, term + case 604: // simple_expr -> simple_expr, addop, term { CurrentSemanticValue.ex = new bin_expr(ValueStack[ValueStack.Depth-3].ex, ValueStack[ValueStack.Depth-1].ex, ValueStack[ValueStack.Depth-2].op.type, CurrentLocationSpan); } break; - case 602: // addop -> tkPlus + case 605: // addop -> tkPlus { CurrentSemanticValue.op = ValueStack[ValueStack.Depth-1].op; } break; - case 603: // addop -> tkMinus + case 606: // addop -> tkMinus { CurrentSemanticValue.op = ValueStack[ValueStack.Depth-1].op; } break; - case 604: // addop -> tkOr + case 607: // addop -> tkOr { CurrentSemanticValue.op = ValueStack[ValueStack.Depth-1].op; } break; - case 605: // addop -> tkXor + case 608: // addop -> tkXor { CurrentSemanticValue.op = ValueStack[ValueStack.Depth-1].op; } break; - case 606: // addop -> tkCSharpStyleOr + case 609: // addop -> tkCSharpStyleOr { CurrentSemanticValue.op = ValueStack[ValueStack.Depth-1].op; } break; - case 607: // typecast_op -> tkAs + case 610: // typecast_op -> tkAs { CurrentSemanticValue.ob = op_typecast.as_op; } break; - case 608: // typecast_op -> tkIs + case 611: // typecast_op -> tkIs { CurrentSemanticValue.ob = op_typecast.is_op; } break; - case 609: // as_is_expr -> term, typecast_op, simple_or_template_type_reference + case 612: // as_is_expr -> term, typecast_op, simple_or_template_type_reference { CurrentSemanticValue.ex = NewAsIsExpr(ValueStack[ValueStack.Depth-3].ex, (op_typecast)ValueStack[ValueStack.Depth-2].ob, ValueStack[ValueStack.Depth-1].td, CurrentLocationSpan); } break; - case 610: // simple_term -> factor + case 613: // simple_term -> factor { CurrentSemanticValue.ex = ValueStack[ValueStack.Depth-1].ex; } break; - case 611: // power_expr -> simple_term, tkStarStar, factor + case 614: // power_expr -> simple_term, tkStarStar, factor { CurrentSemanticValue.ex = new bin_expr(ValueStack[ValueStack.Depth-3].ex,ValueStack[ValueStack.Depth-1].ex,(ValueStack[ValueStack.Depth-2].op).type, CurrentLocationSpan); } break; - case 612: // term -> factor + case 615: // term -> factor { CurrentSemanticValue.ex = ValueStack[ValueStack.Depth-1].ex; } break; - case 613: // term -> new_expr + case 616: // term -> new_expr { CurrentSemanticValue.ex = ValueStack[ValueStack.Depth-1].ex; } break; - case 614: // term -> power_expr + case 617: // term -> power_expr { CurrentSemanticValue.ex = ValueStack[ValueStack.Depth-1].ex; } break; - case 615: // term -> term, mulop, factor + case 618: // term -> term, mulop, factor { CurrentSemanticValue.ex = new bin_expr(ValueStack[ValueStack.Depth-3].ex,ValueStack[ValueStack.Depth-1].ex,(ValueStack[ValueStack.Depth-2].op).type, CurrentLocationSpan); } break; - case 616: // term -> term, mulop, power_expr + case 619: // term -> term, mulop, power_expr { CurrentSemanticValue.ex = new bin_expr(ValueStack[ValueStack.Depth-3].ex,ValueStack[ValueStack.Depth-1].ex,(ValueStack[ValueStack.Depth-2].op).type, CurrentLocationSpan); } break; - case 617: // term -> as_is_expr + case 620: // term -> as_is_expr { CurrentSemanticValue.ex = ValueStack[ValueStack.Depth-1].ex; } break; - case 618: // mulop -> tkStar + case 621: // mulop -> tkStar { CurrentSemanticValue.op = ValueStack[ValueStack.Depth-1].op; } break; - case 619: // mulop -> tkSlash + case 622: // mulop -> tkSlash { CurrentSemanticValue.op = ValueStack[ValueStack.Depth-1].op; } break; - case 620: // mulop -> tkDiv + case 623: // mulop -> tkDiv { CurrentSemanticValue.op = ValueStack[ValueStack.Depth-1].op; } break; - case 621: // mulop -> tkMod + case 624: // mulop -> tkMod { CurrentSemanticValue.op = ValueStack[ValueStack.Depth-1].op; } break; - case 622: // mulop -> tkShl + case 625: // mulop -> tkShl { CurrentSemanticValue.op = ValueStack[ValueStack.Depth-1].op; } break; - case 623: // mulop -> tkShr + case 626: // mulop -> tkShr { CurrentSemanticValue.op = ValueStack[ValueStack.Depth-1].op; } break; - case 624: // mulop -> tkAnd + case 627: // mulop -> tkAnd { CurrentSemanticValue.op = ValueStack[ValueStack.Depth-1].op; } break; - case 625: // default_expr -> tkDefault, tkRoundOpen, simple_or_template_type_reference, + case 628: // default_expr -> tkDefault, tkRoundOpen, simple_or_template_type_reference, // tkRoundClose { CurrentSemanticValue.ex = new default_operator(ValueStack[ValueStack.Depth-2].td as named_type_reference, CurrentLocationSpan); } break; - case 626: // tuple -> tkRoundOpen, expr_l1, tkComma, expr_l1_list, lambda_type_ref, + case 629: // tuple -> tkRoundOpen, expr_l1, tkComma, expr_l1_list, lambda_type_ref, // optional_full_lambda_fp_list, tkRoundClose { /*if ($5 != null) @@ -5223,112 +5244,112 @@ public partial class GPPGParser: ShiftReduceParser tkNil + case 630: // factor -> tkNil { CurrentSemanticValue.ex = new nil_const(); CurrentSemanticValue.ex.source_context = CurrentLocationSpan; } break; - case 628: // factor -> literal_or_number + case 631: // factor -> literal_or_number { CurrentSemanticValue.ex = ValueStack[ValueStack.Depth-1].ex; } break; - case 629: // factor -> default_expr + case 632: // factor -> default_expr { CurrentSemanticValue.ex = ValueStack[ValueStack.Depth-1].ex; } break; - case 630: // factor -> tkSquareOpen, elem_list, tkSquareClose + case 633: // factor -> tkSquareOpen, elem_list, tkSquareClose { CurrentSemanticValue.ex = new pascal_set_constant(ValueStack[ValueStack.Depth-2].stn as expression_list, CurrentLocationSpan); } break; - case 631: // factor -> tkNot, factor + case 634: // factor -> tkNot, factor { CurrentSemanticValue.ex = new un_expr(ValueStack[ValueStack.Depth-1].ex, ValueStack[ValueStack.Depth-2].op.type, CurrentLocationSpan); } break; - case 632: // factor -> sign, factor + case 635: // factor -> sign, factor { CurrentSemanticValue.ex = new un_expr(ValueStack[ValueStack.Depth-1].ex, ValueStack[ValueStack.Depth-2].op.type, CurrentLocationSpan); } break; - case 633: // factor -> tkDeref, factor + case 636: // factor -> tkDeref, factor { CurrentSemanticValue.ex = new roof_dereference(ValueStack[ValueStack.Depth-1].ex as addressed_value, CurrentLocationSpan); } break; - case 634: // factor -> var_reference + case 637: // factor -> var_reference { CurrentSemanticValue.ex = ValueStack[ValueStack.Depth-1].ex; } break; - case 635: // factor -> tuple + case 638: // factor -> tuple { CurrentSemanticValue.ex = ValueStack[ValueStack.Depth-1].ex; } break; - case 636: // literal_or_number -> literal + case 639: // literal_or_number -> literal { CurrentSemanticValue.ex = ValueStack[ValueStack.Depth-1].ex; } break; - case 637: // literal_or_number -> unsigned_number + case 640: // literal_or_number -> unsigned_number { CurrentSemanticValue.ex = ValueStack[ValueStack.Depth-1].ex; } break; - case 638: // var_question_point -> variable, tkQuestionPoint, variable + case 641: // var_question_point -> variable, tkQuestionPoint, variable { CurrentSemanticValue.ex = new dot_question_node(ValueStack[ValueStack.Depth-3].ex as addressed_value,ValueStack[ValueStack.Depth-1].ex as addressed_value,CurrentLocationSpan); } break; - case 639: // var_question_point -> variable, tkQuestionPoint, var_question_point + case 642: // var_question_point -> variable, tkQuestionPoint, var_question_point { CurrentSemanticValue.ex = new dot_question_node(ValueStack[ValueStack.Depth-3].ex as addressed_value,ValueStack[ValueStack.Depth-1].ex as addressed_value,CurrentLocationSpan); } break; - case 640: // var_reference -> var_address, variable + case 643: // var_reference -> var_address, variable { CurrentSemanticValue.ex = NewVarReference(ValueStack[ValueStack.Depth-2].stn as get_address, ValueStack[ValueStack.Depth-1].ex as addressed_value, CurrentLocationSpan); } break; - case 641: // var_reference -> variable + case 644: // var_reference -> variable { CurrentSemanticValue.ex = ValueStack[ValueStack.Depth-1].ex; } break; - case 642: // var_reference -> var_question_point + case 645: // var_reference -> var_question_point { CurrentSemanticValue.ex = ValueStack[ValueStack.Depth-1].ex; } break; - case 643: // var_address -> tkAddressOf + case 646: // var_address -> tkAddressOf { CurrentSemanticValue.stn = NewVarAddress(CurrentLocationSpan); } break; - case 644: // var_address -> var_address, tkAddressOf + case 647: // var_address -> var_address, tkAddressOf { CurrentSemanticValue.stn = NewVarAddress(ValueStack[ValueStack.Depth-2].stn as get_address, CurrentLocationSpan); } break; - case 645: // attribute_variable -> simple_type_identifier, optional_expr_list_with_bracket + case 648: // attribute_variable -> simple_type_identifier, optional_expr_list_with_bracket { CurrentSemanticValue.stn = new attribute(null, ValueStack[ValueStack.Depth-2].td as named_type_reference, ValueStack[ValueStack.Depth-1].stn as expression_list, CurrentLocationSpan); } break; - case 646: // dotted_identifier -> identifier + case 649: // dotted_identifier -> identifier { CurrentSemanticValue.ex = ValueStack[ValueStack.Depth-1].id; } break; - case 647: // dotted_identifier -> dotted_identifier, tkPoint, identifier_or_keyword + case 650: // dotted_identifier -> dotted_identifier, tkPoint, identifier_or_keyword { CurrentSemanticValue.ex = new dot_node(ValueStack[ValueStack.Depth-3].ex as addressed_value, ValueStack[ValueStack.Depth-1].id as addressed_value, CurrentLocationSpan); } break; - case 648: // variable_as_type -> dotted_identifier + case 651: // variable_as_type -> dotted_identifier { CurrentSemanticValue.ex = ValueStack[ValueStack.Depth-1].ex;} break; - case 649: // variable_as_type -> dotted_identifier, template_type_params + case 652: // variable_as_type -> dotted_identifier, template_type_params { CurrentSemanticValue.ex = new ident_with_templateparams(ValueStack[ValueStack.Depth-2].ex as addressed_value, ValueStack[ValueStack.Depth-1].stn as template_param_list, CurrentLocationSpan); } break; - case 650: // variable -> identifier + case 653: // variable -> identifier { CurrentSemanticValue.ex = ValueStack[ValueStack.Depth-1].id; } break; - case 651: // variable -> operator_name_ident + case 654: // variable -> operator_name_ident { CurrentSemanticValue.ex = ValueStack[ValueStack.Depth-1].ex; } break; - case 652: // variable -> tkInherited, identifier + case 655: // variable -> tkInherited, identifier { CurrentSemanticValue.ex = new inherited_ident(ValueStack[ValueStack.Depth-1].id.name, CurrentLocationSpan); } break; - case 653: // variable -> tkRoundOpen, expr, tkRoundClose + case 656: // variable -> tkRoundOpen, expr, tkRoundClose { if (!parsertools.build_tree_for_formatter) { @@ -5338,18 +5359,18 @@ public partial class GPPGParser: ShiftReduceParser sizeof_expr + case 657: // variable -> sizeof_expr { CurrentSemanticValue.ex = ValueStack[ValueStack.Depth-1].ex; } break; - case 655: // variable -> typeof_expr + case 658: // variable -> typeof_expr { CurrentSemanticValue.ex = ValueStack[ValueStack.Depth-1].ex; } break; - case 656: // variable -> literal_or_number, tkPoint, identifier_or_keyword + case 659: // variable -> literal_or_number, tkPoint, identifier_or_keyword { CurrentSemanticValue.ex = new dot_node(ValueStack[ValueStack.Depth-3].ex as addressed_value, ValueStack[ValueStack.Depth-1].id as addressed_value, CurrentLocationSpan); } break; - case 657: // variable -> variable, tkSquareOpen, expr_list, tkSquareClose + case 660: // variable -> variable, tkSquareOpen, expr_list, tkSquareClose { var el = ValueStack[ValueStack.Depth-2].stn as expression_list; // SSM 10/03/16 if (el.Count==1 && el.expressions[0] is format_expr) @@ -5367,7 +5388,7 @@ public partial class GPPGParser: ShiftReduceParser variable, tkQuestionSquareOpen, format_expr, tkSquareClose + case 661: // variable -> variable, tkQuestionSquareOpen, format_expr, tkSquareClose { var fe = ValueStack[ValueStack.Depth-2].ex as format_expr; // SSM 9/01/17 if (fe.expr == null) @@ -5377,71 +5398,71 @@ public partial class GPPGParser: ShiftReduceParser variable, tkRoundOpen, optional_expr_list, tkRoundClose + case 662: // variable -> variable, tkRoundOpen, optional_expr_list, tkRoundClose { CurrentSemanticValue.ex = new method_call(ValueStack[ValueStack.Depth-4].ex as addressed_value,ValueStack[ValueStack.Depth-2].stn as expression_list, CurrentLocationSpan); } break; - case 660: // variable -> variable, tkPoint, identifier_keyword_operatorname + case 663: // variable -> variable, tkPoint, identifier_keyword_operatorname { CurrentSemanticValue.ex = new dot_node(ValueStack[ValueStack.Depth-3].ex as addressed_value, ValueStack[ValueStack.Depth-1].id as addressed_value, CurrentLocationSpan); } break; - case 661: // variable -> tuple, tkPoint, identifier_keyword_operatorname + case 664: // variable -> tuple, tkPoint, identifier_keyword_operatorname { CurrentSemanticValue.ex = new dot_node(ValueStack[ValueStack.Depth-3].ex as addressed_value, ValueStack[ValueStack.Depth-1].id as addressed_value, CurrentLocationSpan); } break; - case 662: // variable -> variable, tkDeref + case 665: // variable -> variable, tkDeref { CurrentSemanticValue.ex = new roof_dereference(ValueStack[ValueStack.Depth-2].ex as addressed_value,CurrentLocationSpan); } break; - case 663: // variable -> variable, tkAmpersend, template_type_params + case 666: // variable -> variable, tkAmpersend, template_type_or_typeclass_params { CurrentSemanticValue.ex = new ident_with_templateparams(ValueStack[ValueStack.Depth-3].ex as addressed_value, ValueStack[ValueStack.Depth-1].stn as template_param_list, CurrentLocationSpan); } break; - case 664: // optional_expr_list -> expr_list + case 667: // optional_expr_list -> expr_list { CurrentSemanticValue.stn = ValueStack[ValueStack.Depth-1].stn; } break; - case 665: // optional_expr_list -> /* empty */ + case 668: // optional_expr_list -> /* empty */ { CurrentSemanticValue.stn = null; } break; - case 666: // elem_list -> elem_list1 + case 669: // elem_list -> elem_list1 { CurrentSemanticValue.stn = ValueStack[ValueStack.Depth-1].stn; } break; - case 667: // elem_list -> /* empty */ + case 670: // elem_list -> /* empty */ { CurrentSemanticValue.stn = null; } break; - case 668: // elem_list1 -> elem + case 671: // elem_list1 -> elem { CurrentSemanticValue.stn = new expression_list(ValueStack[ValueStack.Depth-1].ex, CurrentLocationSpan); } break; - case 669: // elem_list1 -> elem_list1, tkComma, elem + case 672: // elem_list1 -> elem_list1, tkComma, elem { CurrentSemanticValue.stn = (ValueStack[ValueStack.Depth-3].stn as expression_list).Add(ValueStack[ValueStack.Depth-1].ex, CurrentLocationSpan); } break; - case 670: // elem -> expr + case 673: // elem -> expr { CurrentSemanticValue.ex = ValueStack[ValueStack.Depth-1].ex; } break; - case 671: // elem -> expr, tkDotDot, expr + case 674: // elem -> expr, tkDotDot, expr { CurrentSemanticValue.ex = new diapason_expr(ValueStack[ValueStack.Depth-3].ex, ValueStack[ValueStack.Depth-1].ex, CurrentLocationSpan); } break; - case 672: // one_literal -> tkStringLiteral + case 675: // one_literal -> tkStringLiteral { CurrentSemanticValue.ex = ValueStack[ValueStack.Depth-1].stn as literal; } break; - case 673: // one_literal -> tkAsciiChar + case 676: // one_literal -> tkAsciiChar { CurrentSemanticValue.ex = ValueStack[ValueStack.Depth-1].stn as literal; } break; - case 674: // literal -> literal_list + case 677: // literal -> literal_list { CurrentSemanticValue.ex = NewLiteral(ValueStack[ValueStack.Depth-1].stn as literal_const_line); } break; - case 675: // literal -> tkFormatStringLiteral + case 678: // literal -> tkFormatStringLiteral { if (parsertools.build_tree_for_formatter) { @@ -5453,444 +5474,444 @@ public partial class GPPGParser: ShiftReduceParser one_literal + case 679: // literal_list -> one_literal { CurrentSemanticValue.stn = new literal_const_line(ValueStack[ValueStack.Depth-1].ex as literal, CurrentLocationSpan); } break; - case 677: // literal_list -> literal_list, one_literal + case 680: // literal_list -> literal_list, one_literal { CurrentSemanticValue.stn = (ValueStack[ValueStack.Depth-2].stn as literal_const_line).Add(ValueStack[ValueStack.Depth-1].ex as literal, CurrentLocationSpan); } break; - case 678: // operator_name_ident -> tkOperator, overload_operator + case 681: // operator_name_ident -> tkOperator, overload_operator { CurrentSemanticValue.ex = new operator_name_ident((ValueStack[ValueStack.Depth-1].op as op_type_node).text, (ValueStack[ValueStack.Depth-1].op as op_type_node).type, CurrentLocationSpan); } break; - case 679: // optional_method_modificators -> tkSemiColon + case 682: // optional_method_modificators -> tkSemiColon { CurrentSemanticValue.stn = new procedure_attributes_list(new List(),CurrentLocationSpan); } break; - case 680: // optional_method_modificators -> tkSemiColon, meth_modificators, tkSemiColon + case 683: // optional_method_modificators -> tkSemiColon, meth_modificators, tkSemiColon { //parsertools.AddModifier((procedure_attributes_list)$2, proc_attribute.attr_overload); CurrentSemanticValue.stn = ValueStack[ValueStack.Depth-2].stn; } break; - case 681: // optional_method_modificators1 -> /* empty */ + case 684: // optional_method_modificators1 -> /* empty */ { CurrentSemanticValue.stn = new procedure_attributes_list(new List(),CurrentLocationSpan); } break; - case 682: // optional_method_modificators1 -> tkSemiColon, meth_modificators + case 685: // optional_method_modificators1 -> tkSemiColon, meth_modificators { //parsertools.AddModifier((procedure_attributes_list)$2, proc_attribute.attr_overload); CurrentSemanticValue.stn = ValueStack[ValueStack.Depth-1].stn; } break; - case 683: // meth_modificators -> meth_modificator + case 686: // meth_modificators -> meth_modificator { CurrentSemanticValue.stn = new procedure_attributes_list(ValueStack[ValueStack.Depth-1].id as procedure_attribute, CurrentLocationSpan); } break; - case 684: // meth_modificators -> meth_modificators, tkSemiColon, meth_modificator + case 687: // meth_modificators -> meth_modificators, tkSemiColon, meth_modificator { CurrentSemanticValue.stn = (ValueStack[ValueStack.Depth-3].stn as procedure_attributes_list).Add(ValueStack[ValueStack.Depth-1].id as procedure_attribute, CurrentLocationSpan); } break; - case 685: // identifier -> tkIdentifier + case 688: // identifier -> tkIdentifier { CurrentSemanticValue.id = ValueStack[ValueStack.Depth-1].id; } break; - case 686: // identifier -> property_specifier_directives + case 689: // identifier -> property_specifier_directives { CurrentSemanticValue.id = ValueStack[ValueStack.Depth-1].id; } break; - case 687: // identifier -> non_reserved + case 690: // identifier -> non_reserved { CurrentSemanticValue.id = ValueStack[ValueStack.Depth-1].id; } break; - case 688: // identifier_or_keyword -> identifier + case 691: // identifier_or_keyword -> identifier { CurrentSemanticValue.id = ValueStack[ValueStack.Depth-1].id; } break; - case 689: // identifier_or_keyword -> keyword + case 692: // identifier_or_keyword -> keyword { CurrentSemanticValue.id = new ident(ValueStack[ValueStack.Depth-1].ti.text, CurrentLocationSpan); } break; - case 690: // identifier_or_keyword -> reserved_keyword + case 693: // identifier_or_keyword -> reserved_keyword { CurrentSemanticValue.id = new ident(ValueStack[ValueStack.Depth-1].ti.text, CurrentLocationSpan); } break; - case 691: // identifier_keyword_operatorname -> identifier + case 694: // identifier_keyword_operatorname -> identifier { CurrentSemanticValue.id = ValueStack[ValueStack.Depth-1].id; } break; - case 692: // identifier_keyword_operatorname -> keyword + case 695: // identifier_keyword_operatorname -> keyword { CurrentSemanticValue.id = new ident(ValueStack[ValueStack.Depth-1].ti.text, CurrentLocationSpan); } break; - case 693: // identifier_keyword_operatorname -> operator_name_ident + case 696: // identifier_keyword_operatorname -> operator_name_ident { CurrentSemanticValue.id = (ident)ValueStack[ValueStack.Depth-1].ex; } break; - case 694: // meth_modificator -> tkAbstract + case 697: // meth_modificator -> tkAbstract { CurrentSemanticValue.id = ValueStack[ValueStack.Depth-1].id; } break; - case 695: // meth_modificator -> tkOverload + case 698: // meth_modificator -> tkOverload { CurrentSemanticValue.id = ValueStack[ValueStack.Depth-1].id; parsertools.AddWarningFromResource("OVERLOAD_IS_NOT_USED", ValueStack[ValueStack.Depth-1].id.source_context); } break; - case 696: // meth_modificator -> tkReintroduce + case 699: // meth_modificator -> tkReintroduce { CurrentSemanticValue.id = ValueStack[ValueStack.Depth-1].id; } break; - case 697: // meth_modificator -> tkOverride + case 700: // meth_modificator -> tkOverride { CurrentSemanticValue.id = ValueStack[ValueStack.Depth-1].id; } break; - case 698: // meth_modificator -> tkExtensionMethod + case 701: // meth_modificator -> tkExtensionMethod { CurrentSemanticValue.id = ValueStack[ValueStack.Depth-1].id; } break; - case 699: // meth_modificator -> tkVirtual + case 702: // meth_modificator -> tkVirtual { CurrentSemanticValue.id = ValueStack[ValueStack.Depth-1].id; } break; - case 700: // property_modificator -> tkVirtual + case 703: // property_modificator -> tkVirtual { CurrentSemanticValue.id = ValueStack[ValueStack.Depth-1].id; } break; - case 701: // property_modificator -> tkOverride + case 704: // property_modificator -> tkOverride { CurrentSemanticValue.id = ValueStack[ValueStack.Depth-1].id; } break; - case 702: // property_specifier_directives -> tkRead + case 705: // property_specifier_directives -> tkRead { CurrentSemanticValue.id = ValueStack[ValueStack.Depth-1].id; } break; - case 703: // property_specifier_directives -> tkWrite + case 706: // property_specifier_directives -> tkWrite { CurrentSemanticValue.id = ValueStack[ValueStack.Depth-1].id; } break; - case 704: // non_reserved -> tkName + case 707: // non_reserved -> tkName { CurrentSemanticValue.id = ValueStack[ValueStack.Depth-1].id; } break; - case 705: // non_reserved -> tkNew + case 708: // non_reserved -> tkNew { CurrentSemanticValue.id = ValueStack[ValueStack.Depth-1].id; } break; - case 706: // visibility_specifier -> tkInternal + case 709: // visibility_specifier -> tkInternal { CurrentSemanticValue.id = ValueStack[ValueStack.Depth-1].id; } break; - case 707: // visibility_specifier -> tkPublic + case 710: // visibility_specifier -> tkPublic { CurrentSemanticValue.id = ValueStack[ValueStack.Depth-1].id; } break; - case 708: // visibility_specifier -> tkProtected + case 711: // visibility_specifier -> tkProtected { CurrentSemanticValue.id = ValueStack[ValueStack.Depth-1].id; } break; - case 709: // visibility_specifier -> tkPrivate + case 712: // visibility_specifier -> tkPrivate { CurrentSemanticValue.id = ValueStack[ValueStack.Depth-1].id; } break; - case 710: // keyword -> visibility_specifier + case 713: // keyword -> visibility_specifier { CurrentSemanticValue.ti = new token_info(ValueStack[ValueStack.Depth-1].id.name, CurrentLocationSpan); } break; - case 711: // keyword -> tkSealed + case 714: // keyword -> tkSealed { CurrentSemanticValue.ti = ValueStack[ValueStack.Depth-1].ti; } break; - case 712: // keyword -> tkTemplate + case 715: // keyword -> tkTemplate { CurrentSemanticValue.ti = ValueStack[ValueStack.Depth-1].ti; } break; - case 713: // keyword -> tkOr + case 716: // keyword -> tkOr { CurrentSemanticValue.ti = ValueStack[ValueStack.Depth-1].op; } break; - case 714: // keyword -> tkTypeOf + case 717: // keyword -> tkTypeOf { CurrentSemanticValue.ti = ValueStack[ValueStack.Depth-1].ti; } break; - case 715: // keyword -> tkSizeOf + case 718: // keyword -> tkSizeOf { CurrentSemanticValue.ti = ValueStack[ValueStack.Depth-1].ti; } break; - case 716: // keyword -> tkDefault + case 719: // keyword -> tkDefault { CurrentSemanticValue.ti = ValueStack[ValueStack.Depth-1].ti; } break; - case 717: // keyword -> tkWhere + case 720: // keyword -> tkWhere { CurrentSemanticValue.ti = ValueStack[ValueStack.Depth-1].ti; } break; - case 718: // keyword -> tkXor + case 721: // keyword -> tkXor { CurrentSemanticValue.ti = ValueStack[ValueStack.Depth-1].op; } break; - case 719: // keyword -> tkAnd + case 722: // keyword -> tkAnd { CurrentSemanticValue.ti = ValueStack[ValueStack.Depth-1].op; } break; - case 720: // keyword -> tkDiv + case 723: // keyword -> tkDiv { CurrentSemanticValue.ti = ValueStack[ValueStack.Depth-1].op; } break; - case 721: // keyword -> tkMod + case 724: // keyword -> tkMod { CurrentSemanticValue.ti = ValueStack[ValueStack.Depth-1].op; } break; - case 722: // keyword -> tkShl + case 725: // keyword -> tkShl { CurrentSemanticValue.ti = ValueStack[ValueStack.Depth-1].op; } break; - case 723: // keyword -> tkShr + case 726: // keyword -> tkShr { CurrentSemanticValue.ti = ValueStack[ValueStack.Depth-1].op; } break; - case 724: // keyword -> tkNot + case 727: // keyword -> tkNot { CurrentSemanticValue.ti = ValueStack[ValueStack.Depth-1].op; } break; - case 725: // keyword -> tkAs + case 728: // keyword -> tkAs { CurrentSemanticValue.ti = ValueStack[ValueStack.Depth-1].op; } break; - case 726: // keyword -> tkIn + case 729: // keyword -> tkIn { CurrentSemanticValue.ti = ValueStack[ValueStack.Depth-1].op; } break; - case 727: // keyword -> tkIs + case 730: // keyword -> tkIs { CurrentSemanticValue.ti = ValueStack[ValueStack.Depth-1].op; } break; - case 728: // keyword -> tkArray + case 731: // keyword -> tkArray { CurrentSemanticValue.ti = ValueStack[ValueStack.Depth-1].ti; } break; - case 729: // keyword -> tkSequence + case 732: // keyword -> tkSequence { CurrentSemanticValue.ti = ValueStack[ValueStack.Depth-1].ti; } break; - case 730: // keyword -> tkBegin + case 733: // keyword -> tkBegin { CurrentSemanticValue.ti = ValueStack[ValueStack.Depth-1].ti; } break; - case 731: // keyword -> tkCase + case 734: // keyword -> tkCase { CurrentSemanticValue.ti = ValueStack[ValueStack.Depth-1].ti; } break; - case 732: // keyword -> tkClass + case 735: // keyword -> tkClass { CurrentSemanticValue.ti = ValueStack[ValueStack.Depth-1].ti; } break; - case 733: // keyword -> tkConst + case 736: // keyword -> tkConst { CurrentSemanticValue.ti = ValueStack[ValueStack.Depth-1].ti; } break; - case 734: // keyword -> tkConstructor + case 737: // keyword -> tkConstructor { CurrentSemanticValue.ti = ValueStack[ValueStack.Depth-1].ti; } break; - case 735: // keyword -> tkDestructor + case 738: // keyword -> tkDestructor { CurrentSemanticValue.ti = ValueStack[ValueStack.Depth-1].ti; } break; - case 736: // keyword -> tkDownto + case 739: // keyword -> tkDownto { CurrentSemanticValue.ti = ValueStack[ValueStack.Depth-1].ti; } break; - case 737: // keyword -> tkDo + case 740: // keyword -> tkDo { CurrentSemanticValue.ti = ValueStack[ValueStack.Depth-1].ti; } break; - case 738: // keyword -> tkElse + case 741: // keyword -> tkElse { CurrentSemanticValue.ti = ValueStack[ValueStack.Depth-1].ti; } break; - case 739: // keyword -> tkExcept + case 742: // keyword -> tkExcept { CurrentSemanticValue.ti = ValueStack[ValueStack.Depth-1].ti; } break; - case 740: // keyword -> tkFile + case 743: // keyword -> tkFile { CurrentSemanticValue.ti = ValueStack[ValueStack.Depth-1].ti; } break; - case 741: // keyword -> tkAuto + case 744: // keyword -> tkAuto { CurrentSemanticValue.ti = ValueStack[ValueStack.Depth-1].ti; } break; - case 742: // keyword -> tkFinalization + case 745: // keyword -> tkFinalization { CurrentSemanticValue.ti = ValueStack[ValueStack.Depth-1].ti; } break; - case 743: // keyword -> tkFinally + case 746: // keyword -> tkFinally { CurrentSemanticValue.ti = ValueStack[ValueStack.Depth-1].ti; } break; - case 744: // keyword -> tkFor + case 747: // keyword -> tkFor { CurrentSemanticValue.ti = ValueStack[ValueStack.Depth-1].ti; } break; - case 745: // keyword -> tkForeach + case 748: // keyword -> tkForeach { CurrentSemanticValue.ti = ValueStack[ValueStack.Depth-1].ti; } break; - case 746: // keyword -> tkFunction + case 749: // keyword -> tkFunction { CurrentSemanticValue.ti = ValueStack[ValueStack.Depth-1].ti; } break; - case 747: // keyword -> tkIf + case 750: // keyword -> tkIf { CurrentSemanticValue.ti = ValueStack[ValueStack.Depth-1].ti; } break; - case 748: // keyword -> tkImplementation + case 751: // keyword -> tkImplementation { CurrentSemanticValue.ti = ValueStack[ValueStack.Depth-1].ti; } break; - case 749: // keyword -> tkInherited + case 752: // keyword -> tkInherited { CurrentSemanticValue.ti = ValueStack[ValueStack.Depth-1].ti; } break; - case 750: // keyword -> tkInitialization + case 753: // keyword -> tkInitialization { CurrentSemanticValue.ti = ValueStack[ValueStack.Depth-1].ti; } break; - case 751: // keyword -> tkInterface + case 754: // keyword -> tkInterface { CurrentSemanticValue.ti = ValueStack[ValueStack.Depth-1].ti; } break; - case 752: // keyword -> tkProcedure + case 755: // keyword -> tkProcedure { CurrentSemanticValue.ti = ValueStack[ValueStack.Depth-1].ti; } break; - case 753: // keyword -> tkProperty + case 756: // keyword -> tkProperty { CurrentSemanticValue.ti = ValueStack[ValueStack.Depth-1].ti; } break; - case 754: // keyword -> tkRaise + case 757: // keyword -> tkRaise { CurrentSemanticValue.ti = ValueStack[ValueStack.Depth-1].ti; } break; - case 755: // keyword -> tkRecord + case 758: // keyword -> tkRecord { CurrentSemanticValue.ti = ValueStack[ValueStack.Depth-1].ti; } break; - case 756: // keyword -> tkRepeat + case 759: // keyword -> tkRepeat { CurrentSemanticValue.ti = ValueStack[ValueStack.Depth-1].ti; } break; - case 757: // keyword -> tkSet + case 760: // keyword -> tkSet { CurrentSemanticValue.ti = ValueStack[ValueStack.Depth-1].ti; } break; - case 758: // keyword -> tkTry + case 761: // keyword -> tkTry { CurrentSemanticValue.ti = ValueStack[ValueStack.Depth-1].ti; } break; - case 759: // keyword -> tkType + case 762: // keyword -> tkType { CurrentSemanticValue.ti = ValueStack[ValueStack.Depth-1].ti; } break; - case 760: // keyword -> tkThen + case 763: // keyword -> tkThen { CurrentSemanticValue.ti = ValueStack[ValueStack.Depth-1].ti; } break; - case 761: // keyword -> tkTo + case 764: // keyword -> tkTo { CurrentSemanticValue.ti = ValueStack[ValueStack.Depth-1].ti; } break; - case 762: // keyword -> tkUntil + case 765: // keyword -> tkUntil { CurrentSemanticValue.ti = ValueStack[ValueStack.Depth-1].ti; } break; - case 763: // keyword -> tkUses + case 766: // keyword -> tkUses { CurrentSemanticValue.ti = ValueStack[ValueStack.Depth-1].ti; } break; - case 764: // keyword -> tkVar + case 767: // keyword -> tkVar { CurrentSemanticValue.ti = ValueStack[ValueStack.Depth-1].ti; } break; - case 765: // keyword -> tkWhile + case 768: // keyword -> tkWhile { CurrentSemanticValue.ti = ValueStack[ValueStack.Depth-1].ti; } break; - case 766: // keyword -> tkWith + case 769: // keyword -> tkWith { CurrentSemanticValue.ti = ValueStack[ValueStack.Depth-1].ti; } break; - case 767: // keyword -> tkNil + case 770: // keyword -> tkNil { CurrentSemanticValue.ti = ValueStack[ValueStack.Depth-1].ti; } break; - case 768: // keyword -> tkGoto + case 771: // keyword -> tkGoto { CurrentSemanticValue.ti = ValueStack[ValueStack.Depth-1].ti; } break; - case 769: // keyword -> tkOf + case 772: // keyword -> tkOf { CurrentSemanticValue.ti = ValueStack[ValueStack.Depth-1].ti; } break; - case 770: // keyword -> tkLabel + case 773: // keyword -> tkLabel { CurrentSemanticValue.ti = ValueStack[ValueStack.Depth-1].ti; } break; - case 771: // keyword -> tkProgram + case 774: // keyword -> tkProgram { CurrentSemanticValue.ti = ValueStack[ValueStack.Depth-1].ti; } break; - case 772: // keyword -> tkUnit + case 775: // keyword -> tkUnit { CurrentSemanticValue.ti = ValueStack[ValueStack.Depth-1].ti; } break; - case 773: // keyword -> tkLibrary + case 776: // keyword -> tkLibrary { CurrentSemanticValue.ti = ValueStack[ValueStack.Depth-1].ti; } break; - case 774: // keyword -> tkNamespace + case 777: // keyword -> tkNamespace { CurrentSemanticValue.ti = ValueStack[ValueStack.Depth-1].ti; } break; - case 775: // keyword -> tkExternal + case 778: // keyword -> tkExternal { CurrentSemanticValue.ti = ValueStack[ValueStack.Depth-1].ti; } break; - case 776: // keyword -> tkParams + case 779: // keyword -> tkParams { CurrentSemanticValue.ti = ValueStack[ValueStack.Depth-1].ti; } break; - case 777: // keyword -> tkEvent + case 780: // keyword -> tkEvent { CurrentSemanticValue.ti = ValueStack[ValueStack.Depth-1].ti; } break; - case 778: // keyword -> tkYield + case 781: // keyword -> tkYield { CurrentSemanticValue.ti = ValueStack[ValueStack.Depth-1].ti; } break; - case 779: // reserved_keyword -> tkOperator + case 782: // reserved_keyword -> tkOperator { CurrentSemanticValue.ti = ValueStack[ValueStack.Depth-1].ti; } break; - case 780: // reserved_keyword -> tkEnd + case 783: // reserved_keyword -> tkEnd { CurrentSemanticValue.ti = ValueStack[ValueStack.Depth-1].ti; } break; - case 781: // overload_operator -> tkMinus + case 784: // overload_operator -> tkMinus { CurrentSemanticValue.op = ValueStack[ValueStack.Depth-1].op; } break; - case 782: // overload_operator -> tkPlus + case 785: // overload_operator -> tkPlus { CurrentSemanticValue.op = ValueStack[ValueStack.Depth-1].op; } break; - case 783: // overload_operator -> tkSlash + case 786: // overload_operator -> tkSlash { CurrentSemanticValue.op = ValueStack[ValueStack.Depth-1].op; } break; - case 784: // overload_operator -> tkStar + case 787: // overload_operator -> tkStar { CurrentSemanticValue.op = ValueStack[ValueStack.Depth-1].op; } break; - case 785: // overload_operator -> tkEqual + case 788: // overload_operator -> tkEqual { CurrentSemanticValue.op = ValueStack[ValueStack.Depth-1].op; } break; - case 786: // overload_operator -> tkGreater + case 789: // overload_operator -> tkGreater { CurrentSemanticValue.op = ValueStack[ValueStack.Depth-1].op; } break; - case 787: // overload_operator -> tkGreaterEqual + case 790: // overload_operator -> tkGreaterEqual { CurrentSemanticValue.op = ValueStack[ValueStack.Depth-1].op; } break; - case 788: // overload_operator -> tkLower + case 791: // overload_operator -> tkLower { CurrentSemanticValue.op = ValueStack[ValueStack.Depth-1].op; } break; - case 789: // overload_operator -> tkLowerEqual + case 792: // overload_operator -> tkLowerEqual { CurrentSemanticValue.op = ValueStack[ValueStack.Depth-1].op; } break; - case 790: // overload_operator -> tkNotEqual + case 793: // overload_operator -> tkNotEqual { CurrentSemanticValue.op = ValueStack[ValueStack.Depth-1].op; } break; - case 791: // overload_operator -> tkOr + case 794: // overload_operator -> tkOr { CurrentSemanticValue.op = ValueStack[ValueStack.Depth-1].op; } break; - case 792: // overload_operator -> tkXor + case 795: // overload_operator -> tkXor { CurrentSemanticValue.op = ValueStack[ValueStack.Depth-1].op; } break; - case 793: // overload_operator -> tkAnd + case 796: // overload_operator -> tkAnd { CurrentSemanticValue.op = ValueStack[ValueStack.Depth-1].op; } break; - case 794: // overload_operator -> tkDiv + case 797: // overload_operator -> tkDiv { CurrentSemanticValue.op = ValueStack[ValueStack.Depth-1].op; } break; - case 795: // overload_operator -> tkMod + case 798: // overload_operator -> tkMod { CurrentSemanticValue.op = ValueStack[ValueStack.Depth-1].op; } break; - case 796: // overload_operator -> tkShl + case 799: // overload_operator -> tkShl { CurrentSemanticValue.op = ValueStack[ValueStack.Depth-1].op; } break; - case 797: // overload_operator -> tkShr + case 800: // overload_operator -> tkShr { CurrentSemanticValue.op = ValueStack[ValueStack.Depth-1].op; } break; - case 798: // overload_operator -> tkNot + case 801: // overload_operator -> tkNot { CurrentSemanticValue.op = ValueStack[ValueStack.Depth-1].op; } break; - case 799: // overload_operator -> tkIn + case 802: // overload_operator -> tkIn { CurrentSemanticValue.op = ValueStack[ValueStack.Depth-1].op; } break; - case 800: // overload_operator -> tkImplicit + case 803: // overload_operator -> tkImplicit { CurrentSemanticValue.op = ValueStack[ValueStack.Depth-1].op; } break; - case 801: // overload_operator -> tkExplicit + case 804: // overload_operator -> tkExplicit { CurrentSemanticValue.op = ValueStack[ValueStack.Depth-1].op; } break; - case 802: // overload_operator -> assign_operator + case 805: // overload_operator -> assign_operator { CurrentSemanticValue.op = ValueStack[ValueStack.Depth-1].op; } break; - case 803: // overload_operator -> tkStarStar + case 806: // overload_operator -> tkStarStar { CurrentSemanticValue.op = ValueStack[ValueStack.Depth-1].op; } break; - case 804: // assign_operator -> tkAssign + case 807: // assign_operator -> tkAssign { CurrentSemanticValue.op = ValueStack[ValueStack.Depth-1].op; } break; - case 805: // assign_operator -> tkPlusEqual + case 808: // assign_operator -> tkPlusEqual { CurrentSemanticValue.op = ValueStack[ValueStack.Depth-1].op; } break; - case 806: // assign_operator -> tkMinusEqual + case 809: // assign_operator -> tkMinusEqual { CurrentSemanticValue.op = ValueStack[ValueStack.Depth-1].op; } break; - case 807: // assign_operator -> tkMultEqual + case 810: // assign_operator -> tkMultEqual { CurrentSemanticValue.op = ValueStack[ValueStack.Depth-1].op; } break; - case 808: // assign_operator -> tkDivEqual + case 811: // assign_operator -> tkDivEqual { CurrentSemanticValue.op = ValueStack[ValueStack.Depth-1].op; } break; - case 809: // func_decl_lambda -> identifier, tkArrow, lambda_function_body + case 812: // func_decl_lambda -> identifier, tkArrow, lambda_function_body { var idList = new ident_list(ValueStack[ValueStack.Depth-3].id, LocationStack[LocationStack.Depth-3]); var formalPars = new formal_parameters(new typed_parameters(idList, new lambda_inferred_type(new PascalABCCompiler.TreeRealization.lambda_any_type_node(), LocationStack[LocationStack.Depth-3]), parametr_kind.none, null, LocationStack[LocationStack.Depth-3]), LocationStack[LocationStack.Depth-3]); CurrentSemanticValue.ex = new function_lambda_definition(lambdaHelper.CreateLambdaName(), formalPars, new lambda_inferred_type(new PascalABCCompiler.TreeRealization.lambda_any_type_node(), LocationStack[LocationStack.Depth-3]), ValueStack[ValueStack.Depth-1].stn as statement_list, CurrentLocationSpan); } break; - case 810: // func_decl_lambda -> tkRoundOpen, tkRoundClose, lambda_type_ref_noproctype, + case 813: // func_decl_lambda -> tkRoundOpen, tkRoundClose, lambda_type_ref_noproctype, // tkArrow, lambda_function_body { CurrentSemanticValue.ex = new function_lambda_definition(lambdaHelper.CreateLambdaName(), null, ValueStack[ValueStack.Depth-3].td, ValueStack[ValueStack.Depth-1].stn as statement_list, CurrentLocationSpan); } break; - case 811: // func_decl_lambda -> tkRoundOpen, identifier, tkColon, fptype, tkRoundClose, + case 814: // func_decl_lambda -> tkRoundOpen, identifier, tkColon, fptype, tkRoundClose, // lambda_type_ref_noproctype, tkArrow, lambda_function_body { var idList = new ident_list(ValueStack[ValueStack.Depth-7].id, LocationStack[LocationStack.Depth-7]); @@ -5899,7 +5920,7 @@ public partial class GPPGParser: ShiftReduceParser tkRoundOpen, identifier, tkSemiColon, full_lambda_fp_list, + case 815: // func_decl_lambda -> tkRoundOpen, identifier, tkSemiColon, full_lambda_fp_list, // tkRoundClose, lambda_type_ref_noproctype, tkArrow, // lambda_function_body { @@ -5910,7 +5931,7 @@ public partial class GPPGParser: ShiftReduceParser tkRoundOpen, identifier, tkColon, fptype, tkSemiColon, + case 816: // func_decl_lambda -> tkRoundOpen, identifier, tkColon, fptype, tkSemiColon, // full_lambda_fp_list, tkRoundClose, // lambda_type_ref_noproctype, tkArrow, lambda_function_body { @@ -5922,7 +5943,7 @@ public partial class GPPGParser: ShiftReduceParser tkRoundOpen, expr_l1, tkComma, expr_l1_list, + case 817: // func_decl_lambda -> tkRoundOpen, expr_l1, tkComma, expr_l1_list, // lambda_type_ref, optional_full_lambda_fp_list, // tkRoundClose, rem_lambda { @@ -5984,61 +6005,61 @@ public partial class GPPGParser: ShiftReduceParser expl_func_decl_lambda + case 818: // func_decl_lambda -> expl_func_decl_lambda { CurrentSemanticValue.ex = ValueStack[ValueStack.Depth-1].ex; } break; - case 816: // optional_full_lambda_fp_list -> /* empty */ + case 819: // optional_full_lambda_fp_list -> /* empty */ { CurrentSemanticValue.stn = null; } break; - case 817: // optional_full_lambda_fp_list -> tkSemiColon, full_lambda_fp_list + case 820: // optional_full_lambda_fp_list -> tkSemiColon, full_lambda_fp_list { CurrentSemanticValue.stn = ValueStack[ValueStack.Depth-1].stn; } break; - case 818: // rem_lambda -> lambda_type_ref_noproctype, tkArrow, lambda_function_body + case 821: // rem_lambda -> lambda_type_ref_noproctype, tkArrow, lambda_function_body { CurrentSemanticValue.ob = new pair_type_stlist(ValueStack[ValueStack.Depth-3].td,ValueStack[ValueStack.Depth-1].stn as statement_list); } break; - case 819: // expl_func_decl_lambda -> tkFunction, lambda_type_ref, tkArrow, + case 822: // expl_func_decl_lambda -> tkFunction, lambda_type_ref, tkArrow, // lambda_function_body { CurrentSemanticValue.ex = new function_lambda_definition(lambdaHelper.CreateLambdaName(), null, ValueStack[ValueStack.Depth-3].td, ValueStack[ValueStack.Depth-1].stn as statement_list, 1, CurrentLocationSpan); } break; - case 820: // expl_func_decl_lambda -> tkFunction, tkRoundOpen, tkRoundClose, lambda_type_ref, + case 823: // expl_func_decl_lambda -> tkFunction, tkRoundOpen, tkRoundClose, lambda_type_ref, // tkArrow, lambda_function_body { CurrentSemanticValue.ex = new function_lambda_definition(lambdaHelper.CreateLambdaName(), null, ValueStack[ValueStack.Depth-3].td, ValueStack[ValueStack.Depth-1].stn as statement_list, 1, CurrentLocationSpan); } break; - case 821: // expl_func_decl_lambda -> tkFunction, tkRoundOpen, full_lambda_fp_list, + case 824: // expl_func_decl_lambda -> tkFunction, tkRoundOpen, full_lambda_fp_list, // tkRoundClose, lambda_type_ref, tkArrow, // lambda_function_body { CurrentSemanticValue.ex = new function_lambda_definition(lambdaHelper.CreateLambdaName(), ValueStack[ValueStack.Depth-5].stn as formal_parameters, ValueStack[ValueStack.Depth-3].td, ValueStack[ValueStack.Depth-1].stn as statement_list, 1, CurrentLocationSpan); } break; - case 822: // expl_func_decl_lambda -> tkProcedure, tkArrow, lambda_procedure_body + case 825: // expl_func_decl_lambda -> tkProcedure, tkArrow, lambda_procedure_body { CurrentSemanticValue.ex = new function_lambda_definition(lambdaHelper.CreateLambdaName(), null, null, ValueStack[ValueStack.Depth-1].stn as statement_list, 2, CurrentLocationSpan); } break; - case 823: // expl_func_decl_lambda -> tkProcedure, tkRoundOpen, tkRoundClose, tkArrow, + case 826: // expl_func_decl_lambda -> tkProcedure, tkRoundOpen, tkRoundClose, tkArrow, // lambda_procedure_body { CurrentSemanticValue.ex = new function_lambda_definition(lambdaHelper.CreateLambdaName(), null, null, ValueStack[ValueStack.Depth-1].stn as statement_list, 2, CurrentLocationSpan); } break; - case 824: // expl_func_decl_lambda -> tkProcedure, tkRoundOpen, full_lambda_fp_list, + case 827: // expl_func_decl_lambda -> tkProcedure, tkRoundOpen, full_lambda_fp_list, // tkRoundClose, tkArrow, lambda_procedure_body { CurrentSemanticValue.ex = new function_lambda_definition(lambdaHelper.CreateLambdaName(), ValueStack[ValueStack.Depth-4].stn as formal_parameters, null, ValueStack[ValueStack.Depth-1].stn as statement_list, 2, CurrentLocationSpan); } break; - case 825: // full_lambda_fp_list -> lambda_simple_fp_sect + case 828: // full_lambda_fp_list -> lambda_simple_fp_sect { var typed_pars = ValueStack[ValueStack.Depth-1].stn as typed_parameters; if (typed_pars.vars_type is lambda_inferred_type) @@ -6058,147 +6079,147 @@ public partial class GPPGParser: ShiftReduceParser full_lambda_fp_list, tkSemiColon, lambda_simple_fp_sect + case 829: // full_lambda_fp_list -> full_lambda_fp_list, tkSemiColon, lambda_simple_fp_sect { CurrentSemanticValue.stn =(ValueStack[ValueStack.Depth-3].stn as formal_parameters).Add(ValueStack[ValueStack.Depth-1].stn as typed_parameters, CurrentLocationSpan); } break; - case 827: // lambda_simple_fp_sect -> ident_list, lambda_type_ref + case 830: // lambda_simple_fp_sect -> ident_list, lambda_type_ref { CurrentSemanticValue.stn = new typed_parameters(ValueStack[ValueStack.Depth-2].stn as ident_list, ValueStack[ValueStack.Depth-1].td, parametr_kind.none, null, CurrentLocationSpan); } break; - case 828: // lambda_type_ref -> /* empty */ + case 831: // lambda_type_ref -> /* empty */ { CurrentSemanticValue.td = new lambda_inferred_type(new PascalABCCompiler.TreeRealization.lambda_any_type_node(), null); } break; - case 829: // lambda_type_ref -> tkColon, fptype + case 832: // lambda_type_ref -> tkColon, fptype { CurrentSemanticValue.td = ValueStack[ValueStack.Depth-1].td; } break; - case 830: // lambda_type_ref_noproctype -> /* empty */ + case 833: // lambda_type_ref_noproctype -> /* empty */ { CurrentSemanticValue.td = new lambda_inferred_type(new PascalABCCompiler.TreeRealization.lambda_any_type_node(), null); } break; - case 831: // lambda_type_ref_noproctype -> tkColon, fptype_noproctype + case 834: // lambda_type_ref_noproctype -> tkColon, fptype_noproctype { CurrentSemanticValue.td = ValueStack[ValueStack.Depth-1].td; } break; - case 832: // lambda_function_body -> expr_l1 + case 835: // lambda_function_body -> expr_l1 { CurrentSemanticValue.stn = NewLambdaBody(ValueStack[ValueStack.Depth-1].ex, CurrentLocationSpan); } break; - case 833: // lambda_function_body -> compound_stmt + case 836: // lambda_function_body -> compound_stmt { CurrentSemanticValue.stn = ValueStack[ValueStack.Depth-1].stn; } break; - case 834: // lambda_function_body -> if_stmt + case 837: // lambda_function_body -> if_stmt { CurrentSemanticValue.stn = new statement_list(ValueStack[ValueStack.Depth-1].stn as statement, CurrentLocationSpan); } break; - case 835: // lambda_function_body -> while_stmt + case 838: // lambda_function_body -> while_stmt { CurrentSemanticValue.stn = new statement_list(ValueStack[ValueStack.Depth-1].stn as statement, CurrentLocationSpan); } break; - case 836: // lambda_function_body -> repeat_stmt + case 839: // lambda_function_body -> repeat_stmt { CurrentSemanticValue.stn = new statement_list(ValueStack[ValueStack.Depth-1].stn as statement, CurrentLocationSpan); } break; - case 837: // lambda_function_body -> for_stmt + case 840: // lambda_function_body -> for_stmt { CurrentSemanticValue.stn = new statement_list(ValueStack[ValueStack.Depth-1].stn as statement, CurrentLocationSpan); } break; - case 838: // lambda_function_body -> foreach_stmt + case 841: // lambda_function_body -> foreach_stmt { CurrentSemanticValue.stn = new statement_list(ValueStack[ValueStack.Depth-1].stn as statement, CurrentLocationSpan); } break; - case 839: // lambda_function_body -> case_stmt + case 842: // lambda_function_body -> case_stmt { CurrentSemanticValue.stn = new statement_list(ValueStack[ValueStack.Depth-1].stn as statement, CurrentLocationSpan); } break; - case 840: // lambda_function_body -> try_stmt + case 843: // lambda_function_body -> try_stmt { CurrentSemanticValue.stn = new statement_list(ValueStack[ValueStack.Depth-1].stn as statement, CurrentLocationSpan); } break; - case 841: // lambda_function_body -> lock_stmt + case 844: // lambda_function_body -> lock_stmt { CurrentSemanticValue.stn = new statement_list(ValueStack[ValueStack.Depth-1].stn as statement, CurrentLocationSpan); } break; - case 842: // lambda_function_body -> yield_stmt + case 845: // lambda_function_body -> yield_stmt { CurrentSemanticValue.stn = new statement_list(ValueStack[ValueStack.Depth-1].stn as statement, CurrentLocationSpan); } break; - case 843: // lambda_procedure_body -> proc_call + case 846: // lambda_procedure_body -> proc_call { CurrentSemanticValue.stn = new statement_list(ValueStack[ValueStack.Depth-1].stn as statement, CurrentLocationSpan); } break; - case 844: // lambda_procedure_body -> compound_stmt + case 847: // lambda_procedure_body -> compound_stmt { CurrentSemanticValue.stn = ValueStack[ValueStack.Depth-1].stn; } break; - case 845: // lambda_procedure_body -> if_stmt + case 848: // lambda_procedure_body -> if_stmt { CurrentSemanticValue.stn = new statement_list(ValueStack[ValueStack.Depth-1].stn as statement, CurrentLocationSpan); } break; - case 846: // lambda_procedure_body -> while_stmt + case 849: // lambda_procedure_body -> while_stmt { CurrentSemanticValue.stn = new statement_list(ValueStack[ValueStack.Depth-1].stn as statement, CurrentLocationSpan); } break; - case 847: // lambda_procedure_body -> repeat_stmt + case 850: // lambda_procedure_body -> repeat_stmt { CurrentSemanticValue.stn = new statement_list(ValueStack[ValueStack.Depth-1].stn as statement, CurrentLocationSpan); } break; - case 848: // lambda_procedure_body -> for_stmt + case 851: // lambda_procedure_body -> for_stmt { CurrentSemanticValue.stn = new statement_list(ValueStack[ValueStack.Depth-1].stn as statement, CurrentLocationSpan); } break; - case 849: // lambda_procedure_body -> foreach_stmt + case 852: // lambda_procedure_body -> foreach_stmt { CurrentSemanticValue.stn = new statement_list(ValueStack[ValueStack.Depth-1].stn as statement, CurrentLocationSpan); } break; - case 850: // lambda_procedure_body -> case_stmt + case 853: // lambda_procedure_body -> case_stmt { CurrentSemanticValue.stn = new statement_list(ValueStack[ValueStack.Depth-1].stn as statement, CurrentLocationSpan); } break; - case 851: // lambda_procedure_body -> try_stmt + case 854: // lambda_procedure_body -> try_stmt { CurrentSemanticValue.stn = new statement_list(ValueStack[ValueStack.Depth-1].stn as statement, CurrentLocationSpan); } break; - case 852: // lambda_procedure_body -> lock_stmt + case 855: // lambda_procedure_body -> lock_stmt { CurrentSemanticValue.stn = new statement_list(ValueStack[ValueStack.Depth-1].stn as statement, CurrentLocationSpan); } break; - case 853: // lambda_procedure_body -> yield_stmt + case 856: // lambda_procedure_body -> yield_stmt { CurrentSemanticValue.stn = new statement_list(ValueStack[ValueStack.Depth-1].stn as statement, CurrentLocationSpan); } break; - case 854: // lambda_procedure_body -> assignment + case 857: // lambda_procedure_body -> assignment { CurrentSemanticValue.stn = new statement_list(ValueStack[ValueStack.Depth-1].stn as statement, CurrentLocationSpan); } diff --git a/SyntaxTree/tree/AbstractVisitor.cs b/SyntaxTree/tree/AbstractVisitor.cs index f49d1b94e..8ce7d317f 100644 --- a/SyntaxTree/tree/AbstractVisitor.cs +++ b/SyntaxTree/tree/AbstractVisitor.cs @@ -1137,6 +1137,11 @@ namespace PascalABCCompiler.SyntaxTree { DefaultVisit(_where_typeclass_constraint); } + + public virtual void visit(typeclass_param_list _typeclass_param_list) + { + DefaultVisit(_typeclass_param_list); + } } diff --git a/SyntaxTree/tree/HierarchyVisitor.cs b/SyntaxTree/tree/HierarchyVisitor.cs index d9964b067..fd3134cba 100644 --- a/SyntaxTree/tree/HierarchyVisitor.cs +++ b/SyntaxTree/tree/HierarchyVisitor.cs @@ -1813,6 +1813,14 @@ namespace PascalABCCompiler.SyntaxTree { } + public virtual void pre_do_visit(typeclass_param_list _typeclass_param_list) + { + } + + public virtual void post_do_visit(typeclass_param_list _typeclass_param_list) + { + } + public override void visit(expression _expression) { DefaultVisit(_expression); @@ -3748,6 +3756,13 @@ namespace PascalABCCompiler.SyntaxTree visit(where_typeclass_constraint.restriction); post_do_visit(_where_typeclass_constraint); } + + public override void visit(typeclass_param_list _typeclass_param_list) + { + DefaultVisit(_typeclass_param_list); + pre_do_visit(_typeclass_param_list); + post_do_visit(_typeclass_param_list); + } } diff --git a/SyntaxTree/tree/SyntaxTreeStreamReader.cs b/SyntaxTree/tree/SyntaxTreeStreamReader.cs index 92618966d..9d0239964 100644 --- a/SyntaxTree/tree/SyntaxTreeStreamReader.cs +++ b/SyntaxTree/tree/SyntaxTreeStreamReader.cs @@ -472,6 +472,8 @@ namespace PascalABCCompiler.SyntaxTree return new typeclass_definition(); case 225: return new where_typeclass_constraint(); + case 226: + return new typeclass_param_list(); } return null; } @@ -3977,6 +3979,17 @@ namespace PascalABCCompiler.SyntaxTree _where_typeclass_constraint.restriction = _read_node() as typeclass_restriction; } + + public void visit(typeclass_param_list _typeclass_param_list) + { + read_typeclass_param_list(_typeclass_param_list); + } + + public void read_typeclass_param_list(typeclass_param_list _typeclass_param_list) + { + read_template_param_list(_typeclass_param_list); + } + } diff --git a/SyntaxTree/tree/SyntaxTreeStreamWriter.cs b/SyntaxTree/tree/SyntaxTreeStreamWriter.cs index 9688668d1..792567e2e 100644 --- a/SyntaxTree/tree/SyntaxTreeStreamWriter.cs +++ b/SyntaxTree/tree/SyntaxTreeStreamWriter.cs @@ -6232,6 +6232,18 @@ namespace PascalABCCompiler.SyntaxTree } } + + public void visit(typeclass_param_list _typeclass_param_list) + { + bw.Write((Int16)226); + write_typeclass_param_list(_typeclass_param_list); + } + + public void write_typeclass_param_list(typeclass_param_list _typeclass_param_list) + { + write_template_param_list(_typeclass_param_list); + } + } diff --git a/SyntaxTree/tree/Tree.cs b/SyntaxTree/tree/Tree.cs index 277b91bd5..15f6773f6 100644 --- a/SyntaxTree/tree/Tree.cs +++ b/SyntaxTree/tree/Tree.cs @@ -48188,6 +48188,191 @@ namespace PascalABCCompiler.SyntaxTree } + /// + ///Список параметров тайпкласса + /// + [Serializable] + public partial class typeclass_param_list : template_param_list + { + + /// + ///Конструктор без параметров. + /// + public typeclass_param_list() + { + + } + + + /// + ///Конструктор с параметрами. + /// + public typeclass_param_list(addressed_value _dereferencing_value,List _params_list) + { + this._dereferencing_value=_dereferencing_value; + this._params_list=_params_list; + FillParentsInDirectChilds(); + } + + /// + ///Конструктор с параметрами. + /// + public typeclass_param_list(addressed_value _dereferencing_value,List _params_list,SourceContext sc) + { + this._dereferencing_value=_dereferencing_value; + this._params_list=_params_list; + source_context = sc; + FillParentsInDirectChilds(); + } + public typeclass_param_list(template_param_list _template_param_list): this(_template_param_list.dereferencing_value, _template_param_list.params_list, _template_param_list.source_context) + { + } + + /// Создает копию узла + public override syntax_tree_node Clone() + { + typeclass_param_list copy = new typeclass_param_list(); + copy.Parent = this.Parent; + if (source_context != null) + copy.source_context = new SourceContext(source_context); + if (attributes != null) + { + copy.attributes = (attribute_list)attributes.Clone(); + copy.attributes.Parent = copy; + } + if (dereferencing_value != null) + { + copy.dereferencing_value = (addressed_value)dereferencing_value.Clone(); + copy.dereferencing_value.Parent = copy; + } + if (params_list != null) + { + foreach (type_definition elem in params_list) + { + if (elem != null) + { + copy.Add((type_definition)elem.Clone()); + copy.Last().Parent = copy; + } + else + copy.Add(null); + } + } + return copy; + } + + /// Получает копию данного узла корректного типа + public new typeclass_param_list TypedClone() + { + return Clone() as typeclass_param_list; + } + + /// Заполняет поля Parent в непосредственных дочерних узлах + public override void FillParentsInDirectChilds() + { + if (attributes != null) + attributes.Parent = this; + if (dereferencing_value != null) + dereferencing_value.Parent = this; + if (params_list != null) + { + foreach (var child in params_list) + if (child != null) + child.Parent = this; + } + } + + /// Заполняет поля Parent во всем поддереве + public override void FillParentsInAllChilds() + { + FillParentsInDirectChilds(); + attributes?.FillParentsInAllChilds(); + dereferencing_value?.FillParentsInAllChilds(); + if (params_list != null) + { + foreach (var child in params_list) + child?.FillParentsInAllChilds(); + } + } + + /// + ///Свойство для получения количества всех подузлов без элементов поля типа List + /// + public override Int32 subnodes_without_list_elements_count + { + get + { + return 1; + } + } + /// + ///Свойство для получения количества всех подузлов. Подузлом также считается каждый элемент поля типа List + /// + public override Int32 subnodes_count + { + get + { + return 1 + (params_list == null ? 0 : params_list.Count); + } + } + /// + ///Индексатор для получения всех подузлов + /// + public override syntax_tree_node this[Int32 ind] + { + get + { + if(subnodes_count == 0 || ind < 0 || ind > subnodes_count-1) + throw new IndexOutOfRangeException(); + switch(ind) + { + case 0: + return dereferencing_value; + } + Int32 index_counter=ind - 1; + if(params_list != null) + { + if(index_counter < params_list.Count) + { + return params_list[index_counter]; + } + } + return null; + } + set + { + if(subnodes_count == 0 || ind < 0 || ind > subnodes_count-1) + throw new IndexOutOfRangeException(); + switch(ind) + { + case 0: + dereferencing_value = (addressed_value)value; + break; + } + Int32 index_counter=ind - 1; + if(params_list != null) + { + if(index_counter < params_list.Count) + { + params_list[index_counter]= (type_definition)value; + return; + } + } + } + } + /// + ///Метод для обхода дерева посетителем + /// + ///Объект-посетитель. + ///Return value is void + public override void visit(IVisitor visitor) + { + visitor.visit(this); + } + + } + + } diff --git a/SyntaxTree/tree/Visitor.cs b/SyntaxTree/tree/Visitor.cs index f50fbc0b6..1a59ae516 100644 --- a/SyntaxTree/tree/Visitor.cs +++ b/SyntaxTree/tree/Visitor.cs @@ -1360,6 +1360,12 @@ namespace PascalABCCompiler.SyntaxTree ///Node to visit /// Return value is void void visit(where_typeclass_constraint _where_typeclass_constraint); + /// + ///Method to visit typeclass_param_list. + /// + ///Node to visit + /// Return value is void + void visit(typeclass_param_list _typeclass_param_list); } diff --git a/SyntaxTree/tree/tree.xml b/SyntaxTree/tree/tree.xml index 68daaec60..dda99b84e 100644 --- a/SyntaxTree/tree/tree.xml +++ b/SyntaxTree/tree/tree.xml @@ -7,9 +7,11 @@ 0 + 0 1 + 9 @@ -2920,6 +2922,24 @@ + + + + + public typeclass_param_list(template_param_list _template_param_list): this(_template_param_list.dereferencing_value, _template_param_list.params_list, _template_param_list.source_context) +{ +} + + + + + 0 + + + 9 + + + Tree.cs @@ -2945,7 +2965,7 @@ - + @@ -4139,6 +4159,9 @@ + + +