From d46bd8cf580c68104d2c19e7168ff04dd0af8bf1 Mon Sep 17 00:00:00 2001 From: Johnni Winther Date: Mon, 17 Nov 2025 04:50:52 -0800 Subject: [PATCH] [parser] Merge parser listener endX methods This merges endX methods for non-top-level members into endMethod, endConstructor, endFactory and endFields. These methods now have a DeclarationKind parameter that can be used to distinguish them. Change-Id: I458d37a70b6c7839612f7199dad95f9a61e76e7a Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/462120 Reviewed-by: Jens Johansen Reviewed-by: Konstantin Shcheglov Commit-Queue: Johnni Winther --- .../lib/src/parser/forwarding_listener.dart | 303 +---- .../lib/src/parser/listener.dart | 311 +---- .../lib/src/parser/parser_impl.dart | 229 +--- pkg/analyzer/lib/src/fasta/ast_builder.dart | 441 ++----- .../test/generated/parser_fasta_listener.dart | 295 +---- pkg/analyzer/tool/summary/mini_ast.dart | 88 +- .../lib/src/kernel/body_builder.dart | 6 +- .../lib/src/source/diet_listener.dart | 263 +--- .../lib/src/source/outline_builder.dart | 395 +----- .../src/type_inference/inference_visitor.dart | 3 +- .../lib/src/util/abstracted_ast_nodes.dart | 177 +-- .../lib/src/util/outline_extractor.dart | 120 +- pkg/front_end/lib/src/util/parser_ast.dart | 784 +----------- .../lib/src/util/parser_ast_helper.dart | 1114 +---------------- .../lib/src/util/textual_outline.dart | 250 +--- .../also-nnbd/issue_40288.dart.expect | 8 +- .../issue_40288.dart.intertwined.expect | 8 +- .../also-nnbd/issue_40288_prime.dart.expect | 8 +- .../issue_40288_prime.dart.intertwined.expect | 8 +- .../use_late_in_non_nnbd.dart.expect | 12 +- ...e_late_in_non_nnbd.dart.intertwined.expect | 12 +- .../use_required_in_non_nnbd.dart.expect | 2 +- ...quired_in_non_nnbd.dart.intertwined.expect | 2 +- .../augmentation/augment_super.dart.expect | 10 +- .../augment_super.dart.intertwined.expect | 10 +- .../member_declarations.dart.expect | 104 +- ...ember_declarations.dart.intertwined.expect | 104 +- .../augmentation/member_errors.dart.expect | 130 +- .../member_errors.dart.intertwined.expect | 130 +- ...primary_constructor_body_error.dart.expect | 8 +- ...tructor_body_error.dart.intertwined.expect | 8 +- .../declaring_parameter_error.dart.expect | 4 +- ...ng_parameter_error.dart.intertwined.expect | 4 +- ...primary_constructor_body_error.dart.expect | 8 +- ...tructor_body_error.dart.intertwined.expect | 8 +- .../factory_constructor_head.dart.expect | 130 +- ...y_constructor_head.dart.intertwined.expect | 130 +- .../const_no_identifier_recovery.dart.expect | 4 +- ...dentifier_recovery.dart.intertwined.expect | 4 +- .../const_property_recovery.dart.expect | 4 +- ..._property_recovery.dart.intertwined.expect | 4 +- .../entries_with_type_arguments.dart.expect | 4 +- ...ith_type_arguments.dart.intertwined.expect | 4 +- .../bracket_mismatch_01.dart.expect | 8 +- ...racket_mismatch_01.dart.intertwined.expect | 8 +- ...ecovery_bad_name_general.crash_dart.expect | 38 +- ...name_general.crash_dart.intertwined.expect | 38 +- ...or_recovery_bad_name_get.crash_dart.expect | 6 +- ...bad_name_get.crash_dart.intertwined.expect | 6 +- ...ery_bad_name_return_type.crash_dart.expect | 6 +- ..._return_type.crash_dart.intertwined.expect | 6 +- ...or_recovery_bad_name_set.crash_dart.expect | 6 +- ...bad_name_set.crash_dart.intertwined.expect | 6 +- .../constructor_recovery_get.dart.expect | 8 +- ...uctor_recovery_get.dart.intertwined.expect | 8 +- .../constructor_recovery_ok.dart.expect | 8 +- ...ructor_recovery_ok.dart.intertwined.expect | 8 +- ...ructor_recovery_operator.crash_dart.expect | 16 +- ...ery_operator.crash_dart.intertwined.expect | 16 +- ...nstructor_recovery_return_type.dart.expect | 8 +- ...covery_return_type.dart.intertwined.expect | 8 +- .../constructor_recovery_set.dart.expect | 8 +- ...uctor_recovery_set.dart.intertwined.expect | 8 +- ...er_contributor_test_completion.dart.expect | 6 +- ...or_test_completion.dart.intertwined.expect | 6 +- .../error_recovery/issue_000032.dart.expect | 2 +- .../issue_000032.dart.intertwined.expect | 2 +- .../error_recovery/issue_22313.dart.expect | 6 +- .../issue_22313.dart.intertwined.expect | 6 +- .../error_recovery/issue_22314.dart.expect | 6 +- .../issue_22314.dart.intertwined.expect | 6 +- .../error_recovery/issue_26810.dart.expect | 44 +- .../issue_26810.dart.intertwined.expect | 44 +- .../issue_26810_and.dart.expect | 44 +- .../issue_26810_and.dart.intertwined.expect | 44 +- .../error_recovery/issue_26810_or.dart.expect | 44 +- .../issue_26810_or.dart.intertwined.expect | 44 +- .../issue_39026.crash_dart.expect | 2 +- .../issue_39026.crash_dart.intertwined.expect | 2 +- .../issue_39026_prime.crash_dart.expect | 2 +- ..._39026_prime.crash_dart.intertwined.expect | 2 +- .../issue_39230.crash_dart.expect | 4 +- .../issue_39230.crash_dart.intertwined.expect | 4 +- .../error_recovery/issue_45251.dart.expect | 18 +- .../issue_45251.dart.intertwined.expect | 18 +- .../issue_45251_const.dart.expect | 18 +- .../issue_45251_const.dart.intertwined.expect | 18 +- .../issue_45251_list.dart.expect | 18 +- .../issue_45251_list.dart.intertwined.expect | 18 +- .../issue_45251_list_const.dart.expect | 18 +- ...e_45251_list_const.dart.intertwined.expect | 18 +- .../issue_45251_list_new.dart.expect | 18 +- ...sue_45251_list_new.dart.intertwined.expect | 18 +- .../issue_45251_new.dart.expect | 18 +- .../issue_45251_new.dart.intertwined.expect | 18 +- .../issue_45251_set.dart.expect | 18 +- .../issue_45251_set.dart.intertwined.expect | 18 +- .../issue_45251_set_const.dart.expect | 18 +- ...ue_45251_set_const.dart.intertwined.expect | 18 +- .../issue_45251_set_new.dart.expect | 18 +- ...ssue_45251_set_new.dart.intertwined.expect | 18 +- .../issue_45327_prime_1.crash_dart.expect | 2 +- ...5327_prime_1.crash_dart.intertwined.expect | 2 +- .../issue_45662.crash_dart.expect | 2 +- .../issue_45662.crash_dart.intertwined.expect | 2 +- .../issue_45662_gt_gt.crash_dart.expect | 2 +- ..._45662_gt_gt.crash_dart.intertwined.expect | 2 +- .../issue_45662_gt_gt_prime.crash_dart.expect | 2 +- ..._gt_gt_prime.crash_dart.intertwined.expect | 2 +- .../issue_45662_prime.crash_dart.expect | 2 +- ..._45662_prime.crash_dart.intertwined.expect | 2 +- .../issue_46505.crash_dart.expect | 4 +- .../issue_46505.crash_dart.intertwined.expect | 4 +- .../issue_46505_prime_1.crash_dart.expect | 2 +- ...6505_prime_1.crash_dart.intertwined.expect | 2 +- .../issue_46505_prime_2.crash_dart.expect | 2 +- ...6505_prime_2.crash_dart.intertwined.expect | 2 +- .../issue_46505_prime_3.crash_dart.expect | 2 +- ...6505_prime_3.crash_dart.intertwined.expect | 2 +- .../issue_46505_prime_4.crash_dart.expect | 2 +- ...6505_prime_4.crash_dart.intertwined.expect | 2 +- .../issue_46505_prime_5.crash_dart.expect | 12 +- ...6505_prime_5.crash_dart.intertwined.expect | 12 +- .../issue_46505_prime_6.crash_dart.expect | 6 +- ...6505_prime_6.crash_dart.intertwined.expect | 6 +- .../issue_48371_prime3.dart.expect | 2 +- ...issue_48371_prime3.dart.intertwined.expect | 2 +- .../error_recovery/issue_48380_1.dart.expect | 4 +- .../issue_48380_1.dart.intertwined.expect | 4 +- .../issue_48380_1_comma.dart.expect | 4 +- ...ssue_48380_1_comma.dart.intertwined.expect | 4 +- .../issue_48380_1_comma_ok.dart.expect | 4 +- ...e_48380_1_comma_ok.dart.intertwined.expect | 4 +- .../issue_48380_1_ok.dart.expect | 4 +- .../issue_48380_1_ok.dart.intertwined.expect | 4 +- .../error_recovery/issue_48380_2.dart.expect | 4 +- .../issue_48380_2.dart.intertwined.expect | 4 +- .../issue_48380_2_comma.dart.expect | 4 +- ...ssue_48380_2_comma.dart.intertwined.expect | 4 +- .../issue_48380_2_comma_ok.dart.expect | 4 +- ...e_48380_2_comma_ok.dart.intertwined.expect | 4 +- .../issue_48380_2_ok.dart.expect | 4 +- .../issue_48380_2_ok.dart.intertwined.expect | 4 +- .../error_recovery/issue_48380_3.dart.expect | 4 +- .../issue_48380_3.dart.intertwined.expect | 4 +- .../issue_48380_3_comma.dart.expect | 4 +- ...ssue_48380_3_comma.dart.intertwined.expect | 4 +- .../issue_48380_3_comma_ok.dart.expect | 4 +- ...e_48380_3_comma_ok.dart.intertwined.expect | 4 +- .../issue_48380_3_ok.dart.expect | 4 +- .../issue_48380_3_ok.dart.intertwined.expect | 4 +- .../error_recovery/issue_48380_4.dart.expect | 2 +- .../issue_48380_4.dart.intertwined.expect | 2 +- .../error_recovery/issue_48411.dart.expect | 22 +- .../issue_48411.dart.intertwined.expect | 22 +- .../issue_48411_prime.dart.expect | 22 +- .../issue_48411_prime.dart.intertwined.expect | 22 +- .../issue_48411_prime_1.dart.expect | 10 +- ...ssue_48411_prime_1.dart.intertwined.expect | 10 +- .../error_recovery/issue_54284.dart.expect | 18 +- .../issue_54284.dart.intertwined.expect | 18 +- .../keyword_named_class_fields.dart.expect | 138 +- ...named_class_fields.dart.intertwined.expect | 138 +- .../keyword_named_class_methods.dart.expect | 140 +-- ...amed_class_methods.dart.intertwined.expect | 140 +-- .../keyword_named_class_methods_2.dart.expect | 140 +-- ...ed_class_methods_2.dart.intertwined.expect | 140 +-- .../method_called_with.dart.expect | 8 +- ...method_called_with.dart.intertwined.expect | 8 +- .../method_called_with_prime.dart.expect | 8 +- ..._called_with_prime.dart.intertwined.expect | 8 +- .../method_called_with_prime2.dart.expect | 2 +- ...called_with_prime2.dart.intertwined.expect | 2 +- .../with_outline/typing_01.dart.expect | 8 +- .../typing_01.dart.intertwined.expect | 8 +- .../typing_01.dart.outline.expect | 8 +- .../with_outline/typing_02.dart.expect | 4 +- .../typing_02.dart.intertwined.expect | 4 +- .../typing_02.dart.outline.expect | 4 +- .../with_outline/typing_03.dart.expect | 8 +- .../typing_03.dart.intertwined.expect | 8 +- .../typing_03.dart.outline.expect | 8 +- .../with_outline/typing_04.dart.expect | 8 +- .../typing_04.dart.intertwined.expect | 8 +- .../typing_04.dart.outline.expect | 8 +- .../with_outline/typing_05.dart.expect | 8 +- .../typing_05.dart.intertwined.expect | 8 +- .../typing_05.dart.outline.expect | 8 +- .../with_outline/typing_06.dart.expect | 4 +- .../typing_06.dart.intertwined.expect | 4 +- .../typing_06.dart.outline.expect | 4 +- .../with_outline/typing_07.dart.expect | 4 +- .../typing_07.dart.intertwined.expect | 4 +- .../typing_07.dart.outline.expect | 4 +- .../with_outline/typing_08.dart.expect | 4 +- .../typing_08.dart.intertwined.expect | 4 +- .../typing_08.dart.outline.expect | 4 +- .../with_outline/typing_09.dart.expect | 4 +- .../typing_09.dart.intertwined.expect | 4 +- .../typing_09.dart.outline.expect | 4 +- .../with_outline/typing_10.dart.expect | 4 +- .../typing_10.dart.intertwined.expect | 4 +- .../typing_10.dart.outline.expect | 4 +- .../with_outline/typing_11.dart.expect | 4 +- .../typing_11.dart.intertwined.expect | 4 +- .../typing_11.dart.outline.expect | 4 +- .../with_outline/typing_12.dart.expect | 4 +- .../typing_12.dart.intertwined.expect | 4 +- .../typing_12.dart.outline.expect | 4 +- .../with_outline/typing_13.dart.expect | 4 +- .../typing_13.dart.intertwined.expect | 4 +- .../typing_13.dart.outline.expect | 4 +- .../with_outline/typing_14.dart.expect | 4 +- .../typing_14.dart.intertwined.expect | 4 +- .../typing_14.dart.outline.expect | 4 +- .../with_outline/typing_15.dart.expect | 4 +- .../typing_15.dart.intertwined.expect | 4 +- .../typing_15.dart.outline.expect | 4 +- .../typing_string_interpolation_1.dart.expect | 12 +- ...ng_interpolation_1.dart.intertwined.expect | 12 +- ...string_interpolation_1.dart.outline.expect | 12 +- .../typing_string_interpolation_2.dart.expect | 12 +- ...ng_interpolation_2.dart.intertwined.expect | 12 +- ...string_interpolation_2.dart.outline.expect | 12 +- ...yping_string_missing_end_quote.dart.expect | 12 +- ..._missing_end_quote.dart.intertwined.expect | 12 +- ...ring_missing_end_quote.dart.outline.expect | 12 +- .../extension_named_type.dart.expect | 2 +- ...tension_named_type.dart.intertwined.expect | 2 +- .../extensions/covariant.dart.expect | 2 +- .../covariant.dart.intertwined.expect | 2 +- .../extensions/not_covariant.dart.expect | 2 +- .../not_covariant.dart.intertwined.expect | 2 +- .../extensions/static.dart.expect | 2 +- .../extensions/static.dart.intertwined.expect | 2 +- .../extensions/static_covariant.dart.expect | 2 +- .../static_covariant.dart.intertwined.expect | 2 +- .../general/augment_super.dart.expect | 18 +- .../augment_super.dart.intertwined.expect | 18 +- .../general/augment_super_2.dart.expect | 18 +- .../augment_super_2.dart.intertwined.expect | 18 +- ...ilt_in_identifier_class_fields.dart.expect | 40 +- ...ifier_class_fields.dart.intertwined.expect | 40 +- ...lt_in_identifier_class_methods.dart.expect | 40 +- ...fier_class_methods.dart.intertwined.expect | 40 +- ...y_constructor_head_pre_feature.dart.expect | 114 +- ...r_head_pre_feature.dart.intertwined.expect | 114 +- .../general/issue_41121.dart.expect | 14 +- .../issue_41121.dart.intertwined.expect | 14 +- .../general/issue_45848_06.dart.expect | 2 +- .../issue_45848_06.dart.intertwined.expect | 2 +- .../general/new_as_identifier.dart.expect | 30 +- .../new_as_identifier.dart.intertwined.expect | 30 +- .../general/operator_01.dart.expect | 10 +- .../operator_01.dart.intertwined.expect | 10 +- .../operator_hat_class.crash_dart.expect | 2 +- ...or_hat_class.crash_dart.intertwined.expect | 2 +- .../inline_class/extension_type.dart.expect | 32 +- .../extension_type.dart.intertwined.expect | 32 +- .../extension_type_const.dart.expect | 32 +- ...tension_type_const.dart.intertwined.expect | 32 +- .../abstract_placement.dart.expect | 18 +- ...abstract_placement.dart.intertwined.expect | 18 +- .../external_placement.dart.expect | 12 +- ...external_placement.dart.intertwined.expect | 12 +- .../late_without_var_etc.dart.expect | 6 +- ...te_without_var_etc.dart.intertwined.expect | 6 +- .../nnbd/issue_39723.dart.expect | 2 +- .../nnbd/issue_39723.dart.intertwined.expect | 2 +- .../nnbd/issue_39723_prime.dart.expect | 2 +- .../issue_39723_prime.dart.intertwined.expect | 2 +- .../nnbd/issue_39858.dart.expect | 12 +- .../nnbd/issue_39858.dart.intertwined.expect | 12 +- .../nnbd/issue_39858_prime1.dart.expect | 12 +- ...issue_39858_prime1.dart.intertwined.expect | 12 +- .../nnbd/issue_40805_01.dart.expect | 2 +- .../issue_40805_01.dart.intertwined.expect | 2 +- .../nnbd/issue_40805_02.dart.expect | 2 +- .../issue_40805_02.dart.intertwined.expect | 2 +- .../nnbd/issue_40805_03.dart.expect | 2 +- .../issue_40805_03.dart.intertwined.expect | 2 +- .../nnbd/issue_40834_01.dart.expect | 14 +- .../issue_40834_01.dart.intertwined.expect | 14 +- .../nnbd/issue_40834_02.dart.expect | 6 +- .../issue_40834_02.dart.intertwined.expect | 6 +- .../nnbd/issue_40834_03.dart.expect | 10 +- .../issue_40834_03.dart.intertwined.expect | 10 +- .../nnbd/issue_41597.dart.expect | 4 +- .../nnbd/issue_41597.dart.intertwined.expect | 4 +- .../nnbd/issue_42621.dart.expect | 4 +- .../nnbd/issue_42621.dart.intertwined.expect | 4 +- .../nnbd/issue_49132.dart.expect | 16 +- .../nnbd/issue_49132.dart.intertwined.expect | 16 +- .../nnbd/issue_49132_not_nullable.dart.expect | 10 +- ...49132_not_nullable.dart.intertwined.expect | 10 +- .../nnbd/issue_49132_prime.dart.expect | 16 +- .../issue_49132_prime.dart.intertwined.expect | 16 +- .../nnbd/late_member.dart.expect | 4 +- .../nnbd/late_member.dart.intertwined.expect | 4 +- .../nnbd/late_modifier.dart.expect | 4 +- .../late_modifier.dart.intertwined.expect | 4 +- .../nnbd/null_shorting_index.dart.expect | 4 +- ...ull_shorting_index.dart.intertwined.expect | 4 +- .../nnbd/required_member.dart.expect | 4 +- .../required_member.dart.intertwined.expect | 4 +- .../nnbd/required_modifier.dart.expect | 4 +- .../required_modifier.dart.intertwined.expect | 4 +- .../define_triple_shift_method.dart.expect | 2 +- ...riple_shift_method.dart.intertwined.expect | 2 +- ...fine_triple_shift_method_prime.dart.expect | 2 +- ...shift_method_prime.dart.intertwined.expect | 2 +- .../triple_shift_not_triple_shift.dart.expect | 4 +- ...t_not_triple_shift.dart.intertwined.expect | 4 +- .../cast_inside_extractor_pattern.dart.expect | 2 +- ..._extractor_pattern.dart.intertwined.expect | 2 +- ...actor_pattern_implicitly_named.dart.expect | 2 +- ...n_implicitly_named.dart.intertwined.expect | 2 +- .../patterns/const_patterns.dart.expect | 10 +- .../const_patterns.dart.intertwined.expect | 10 +- .../const_patterns_binary.dart.expect | 2 +- ...st_patterns_binary.dart.intertwined.expect | 2 +- .../extractor_pattern_inside_cast.dart.expect | 2 +- ...attern_inside_cast.dart.intertwined.expect | 2 +- ...tor_pattern_inside_null_assert.dart.expect | 2 +- ...inside_null_assert.dart.intertwined.expect | 2 +- ...ctor_pattern_inside_null_check.dart.expect | 2 +- ..._inside_null_check.dart.intertwined.expect | 2 +- ...h_type_args_inside_null_assert.dart.expect | 2 +- ...inside_null_assert.dart.intertwined.expect | 2 +- .../patterns/issue_51169.dart.expect | 4 +- .../issue_51169.dart.intertwined.expect | 4 +- ...ssert_inside_extractor_pattern.dart.expect | 2 +- ..._extractor_pattern.dart.intertwined.expect | 2 +- ...actor_pattern_implicitly_named.dart.expect | 2 +- ...n_implicitly_named.dart.intertwined.expect | 2 +- ...check_inside_extractor_pattern.dart.expect | 2 +- ..._extractor_pattern.dart.intertwined.expect | 2 +- ...actor_pattern_implicitly_named.dart.expect | 2 +- ...n_implicitly_named.dart.intertwined.expect | 2 +- ...ernVariableDeclaration_inClass.dart.expect | 2 +- ...eclaration_inClass.dart.intertwined.expect | 2 +- ...ional_inside_extractor_pattern.dart.expect | 2 +- ..._extractor_pattern.dart.intertwined.expect | 2 +- ...eter_with_explicit_record_type.dart.expect | 12 +- ...plicit_record_type.dart.intertwined.expect | 12 +- .../record/issue_52365.dart.expect | 12 +- .../issue_52365.dart.intertwined.expect | 12 +- .../modifier_before_type_question.dart.expect | 24 +- ...fore_type_question.dart.intertwined.expect | 24 +- .../operator_returning_record.dart.expect | 4 +- ...r_returning_record.dart.intertwined.expect | 4 +- .../record/record_type_03.dart.expect | 2 +- .../record_type_03.dart.intertwined.expect | 2 +- .../record/record_type_getter.dart.expect | 96 +- ...record_type_getter.dart.intertwined.expect | 96 +- .../record/record_type_setter.dart.expect | 16 +- ...record_type_setter.dart.intertwined.expect | 16 +- .../record_type_with_modifiers.dart.expect | 12 +- ...ype_with_modifiers.dart.intertwined.expect | 12 +- .../super_parameters_record_type.dart.expect | 8 +- ...meters_record_type.dart.intertwined.expect | 8 +- .../crashing_test_case_minimizer_impl.dart | 156 +-- pkg/front_end/test/lint_suite.dart | 5 +- .../test/parser/parser_ast_test.dart | 230 +--- pkg/front_end/test/parser_suite.dart | 6 +- pkg/front_end/test/parser_test_listener.dart | 432 +------ .../test/parser_test_listener_creator.dart | 3 +- .../test/parser_test_parser_creator.dart | 6 +- .../tool/kernel_ast_file_rewriter.dart | 36 +- .../tool/parser_ast_helper_creator.dart | 3 +- pkg/front_end/tool/parser_ast_indexer.dart | 88 +- 371 files changed, 3051 insertions(+), 7501 deletions(-) diff --git a/pkg/_fe_analyzer_shared/lib/src/parser/forwarding_listener.dart b/pkg/_fe_analyzer_shared/lib/src/parser/forwarding_listener.dart index 3781dd4cc2f..f2a434cae9c 100644 --- a/pkg/_fe_analyzer_shared/lib/src/parser/forwarding_listener.dart +++ b/pkg/_fe_analyzer_shared/lib/src/parser/forwarding_listener.dart @@ -195,13 +195,13 @@ class ForwardingListener implements Listener { } @override - void beginFactoryMethod( + void beginFactory( DeclarationKind declarationKind, Token lastConsumed, Token? externalToken, Token? constToken, ) { - listener?.beginFactoryMethod( + listener?.beginFactory( declarationKind, lastConsumed, externalToken, @@ -725,13 +725,15 @@ class ForwardingListener implements Listener { } @override - void endClassConstructor( + void endConstructor( + DeclarationKind kind, Token beginToken, Token beginParam, Token? beginInitializers, Token endToken, ) { - listener?.endClassConstructor( + listener?.endConstructor( + kind, beginToken, beginParam, beginInitializers, @@ -745,16 +747,18 @@ class ForwardingListener implements Listener { } @override - void endClassFactoryMethod( + void endFactory( + DeclarationKind kind, Token beginToken, Token factoryKeyword, Token endToken, ) { - listener?.endClassFactoryMethod(beginToken, factoryKeyword, endToken); + listener?.endFactory(kind, beginToken, factoryKeyword, endToken); } @override - void endClassFields( + void endFields( + DeclarationKind kind, Token? abstractToken, Token? augmentToken, Token? externalToken, @@ -766,7 +770,8 @@ class ForwardingListener implements Listener { Token beginToken, Token endToken, ) { - listener?.endClassFields( + listener?.endFields( + kind, abstractToken, augmentToken, externalToken, @@ -781,14 +786,16 @@ class ForwardingListener implements Listener { } @override - void endClassMethod( + void endMethod( + DeclarationKind kind, Token? getOrSet, Token beginToken, Token beginParam, Token? beginInitializers, Token endToken, ) { - listener?.endClassMethod( + listener?.endMethod( + kind, getOrSet, beginToken, beginParam, @@ -898,21 +905,6 @@ class ForwardingListener implements Listener { ); } - @override - void endEnumConstructor( - Token beginToken, - Token beginParam, - Token? beginInitializers, - Token endToken, - ) { - listener?.endEnumConstructor( - beginToken, - beginParam, - beginInitializers, - endToken, - ); - } - @override void handleEnumElement(Token beginToken, Token? augmentToken) { listener?.handleEnumElement(beginToken, augmentToken); @@ -942,79 +934,11 @@ class ForwardingListener implements Listener { listener?.endEnumBody(beginToken, endToken); } - @override - void endEnumFactoryMethod( - Token beginToken, - Token factoryKeyword, - Token endToken, - ) { - listener?.endEnumFactoryMethod(beginToken, factoryKeyword, endToken); - } - - @override - void endEnumFields( - Token? abstractToken, - Token? augmentToken, - Token? externalToken, - Token? staticToken, - Token? covariantToken, - Token? lateToken, - Token? varFinalOrConst, - int count, - Token beginToken, - Token endToken, - ) { - listener?.endClassFields( - abstractToken, - augmentToken, - externalToken, - staticToken, - covariantToken, - lateToken, - varFinalOrConst, - count, - beginToken, - endToken, - ); - } - - @override - void endEnumMethod( - Token? getOrSet, - Token beginToken, - Token beginParam, - Token? beginInitializers, - Token endToken, - ) { - listener?.endEnumMethod( - getOrSet, - beginToken, - beginParam, - beginInitializers, - endToken, - ); - } - @override void endExport(Token exportKeyword, Token semicolon) { listener?.endExport(exportKeyword, semicolon); } - @override - void endExtensionConstructor( - Token beginToken, - Token beginParam, - Token? beginInitializers, - Token endToken, - ) { - listener?.endExtensionConstructor( - beginToken, - beginParam, - beginInitializers, - endToken, - ); - } - @override void endExtensionDeclaration( Token beginToken, @@ -1030,59 +954,6 @@ class ForwardingListener implements Listener { ); } - @override - void endExtensionFactoryMethod( - Token beginToken, - Token factoryKeyword, - Token endToken, - ) { - listener?.endExtensionFactoryMethod(beginToken, factoryKeyword, endToken); - } - - @override - void endExtensionFields( - Token? abstractToken, - Token? augmentToken, - Token? externalToken, - Token? staticToken, - Token? covariantToken, - Token? lateToken, - Token? varFinalOrConst, - int count, - Token beginToken, - Token endToken, - ) { - listener?.endExtensionFields( - abstractToken, - augmentToken, - externalToken, - staticToken, - covariantToken, - lateToken, - varFinalOrConst, - count, - beginToken, - endToken, - ); - } - - @override - void endExtensionMethod( - Token? getOrSet, - Token beginToken, - Token beginParam, - Token? beginInitializers, - Token endToken, - ) { - listener?.endExtensionMethod( - getOrSet, - beginToken, - beginParam, - beginInitializers, - endToken, - ); - } - @override void endFieldInitializer(Token assignment, Token endToken) { listener?.endFieldInitializer(assignment, endToken); @@ -1311,79 +1182,11 @@ class ForwardingListener implements Listener { listener?.endMetadataStar(count); } - @override - void endMixinConstructor( - Token beginToken, - Token beginParam, - Token? beginInitializers, - Token endToken, - ) { - listener?.endMixinConstructor( - beginToken, - beginParam, - beginInitializers, - endToken, - ); - } - @override void endMixinDeclaration(Token beginToken, Token endToken) { listener?.endMixinDeclaration(beginToken, endToken); } - @override - void endMixinFactoryMethod( - Token beginToken, - Token factoryKeyword, - Token endToken, - ) { - listener?.endMixinFactoryMethod(beginToken, factoryKeyword, endToken); - } - - @override - void endMixinFields( - Token? abstractToken, - Token? augmentToken, - Token? externalToken, - Token? staticToken, - Token? covariantToken, - Token? lateToken, - Token? varFinalOrConst, - int count, - Token beginToken, - Token endToken, - ) { - listener?.endMixinFields( - abstractToken, - augmentToken, - externalToken, - staticToken, - covariantToken, - lateToken, - varFinalOrConst, - count, - beginToken, - endToken, - ); - } - - @override - void endMixinMethod( - Token? getOrSet, - Token beginToken, - Token beginParam, - Token? beginInitializers, - Token endToken, - ) { - listener?.endMixinMethod( - getOrSet, - beginToken, - beginParam, - beginInitializers, - endToken, - ); - } - @override void endNamedFunctionExpression(Token endToken) { listener?.endNamedFunctionExpression(endToken); @@ -2522,21 +2325,6 @@ class ForwardingListener implements Listener { ); } - @override - void endExtensionTypeConstructor( - Token beginToken, - Token beginParam, - Token? beginInitializers, - Token endToken, - ) { - listener?.endExtensionTypeConstructor( - beginToken, - beginParam, - beginInitializers, - endToken, - ); - } - @override void endExtensionTypeDeclaration( Token beginToken, @@ -2554,63 +2342,6 @@ class ForwardingListener implements Listener { ); } - @override - void endExtensionTypeFactoryMethod( - Token beginToken, - Token factoryKeyword, - Token endToken, - ) { - listener?.endExtensionTypeFactoryMethod( - beginToken, - factoryKeyword, - endToken, - ); - } - - @override - void endExtensionTypeFields( - Token? abstractToken, - Token? augmentToken, - Token? externalToken, - Token? staticToken, - Token? covariantToken, - Token? lateToken, - Token? varFinalOrConst, - int count, - Token beginToken, - Token endToken, - ) { - listener?.endExtensionTypeFields( - abstractToken, - augmentToken, - externalToken, - staticToken, - covariantToken, - lateToken, - varFinalOrConst, - count, - beginToken, - endToken, - ); - } - - @override - void endExtensionTypeMethod( - Token? getOrSet, - Token beginToken, - Token beginParam, - Token? beginInitializers, - Token endToken, - ) { - listener?.endExtensionTypeMethod( - getOrSet, - beginToken, - beginParam, - beginInitializers, - endToken, - ); - } - @override void beginPrimaryConstructor(Token beginToken) { listener?.beginPrimaryConstructor(beginToken); diff --git a/pkg/_fe_analyzer_shared/lib/src/parser/listener.dart b/pkg/_fe_analyzer_shared/lib/src/parser/listener.dart index a6e25fa1928..300a23a2133 100644 --- a/pkg/_fe_analyzer_shared/lib/src/parser/listener.dart +++ b/pkg/_fe_analyzer_shared/lib/src/parser/listener.dart @@ -468,24 +468,6 @@ abstract class Listener implements UnescapeErrorListener { logEvent("Enum"); } - /// Handle the end of an enum constructor declaration. Substructures: - /// - metadata - /// - return type - /// - method name (identifier, possibly qualified) - /// - type variables - /// - formal parameters - /// - initializers - /// - async marker - /// - body - void endEnumConstructor( - Token beginToken, - Token beginParam, - Token? beginInitializers, - Token endToken, - ) { - logEvent("EnumConstructor"); - } - /// Handle the enum elements. Substructures: /// - [elementsCount] times: /// - Enum element @@ -520,14 +502,6 @@ abstract class Listener implements UnescapeErrorListener { logEvent("EnumElement"); } - void endEnumFactoryMethod( - Token beginToken, - Token factoryKeyword, - Token endToken, - ) { - logEvent("EnumFactoryMethod"); - } - void beginExport(Token token) {} /// Handle the end of an export directive. Substructures: @@ -550,45 +524,20 @@ abstract class Listener implements UnescapeErrorListener { logEvent("ExpressionStatement"); } - /// Note that this is ended by [endClassFactoryMethod], - /// [endMixinFactoryMethod] or [endExtensionFactoryMethod]. - void beginFactoryMethod( + void beginFactory( DeclarationKind declarationKind, Token lastConsumed, Token? externalToken, Token? constToken, ) {} - void endClassFactoryMethod( + void endFactory( + DeclarationKind kind, Token beginToken, Token factoryKeyword, Token endToken, ) { - logEvent("ClassFactoryMethod"); - } - - void endMixinFactoryMethod( - Token beginToken, - Token factoryKeyword, - Token endToken, - ) { - logEvent("MixinFactoryMethod"); - } - - void endExtensionFactoryMethod( - Token beginToken, - Token factoryKeyword, - Token endToken, - ) { - logEvent("ExtensionFactoryMethod"); - } - - void endExtensionTypeFactoryMethod( - Token beginToken, - Token factoryKeyword, - Token endToken, - ) { - logEvent("ExtensionTypeFactoryMethod"); + logEvent("Factory"); } void beginFormalParameter( @@ -635,7 +584,8 @@ abstract class Listener implements UnescapeErrorListener { /// - Variable declarations (count times) /// /// Started by [beginFields]. - void endClassFields( + void endFields( + DeclarationKind kind, Token? abstractToken, Token? augmentToken, Token? externalToken, @@ -647,114 +597,7 @@ abstract class Listener implements UnescapeErrorListener { Token beginToken, Token endToken, ) { - logEvent("ClassFields"); - } - - /// Handle the end of a mixin field declaration. Substructures: - /// - Metadata - /// - Modifiers - /// - Type - /// - Variable declarations (count times) - /// - /// Started by [beginFields]. - void endMixinFields( - Token? abstractToken, - Token? augmentToken, - Token? externalToken, - Token? staticToken, - Token? covariantToken, - Token? lateToken, - Token? varFinalOrConst, - int count, - Token beginToken, - Token endToken, - ) { - logEvent("MixinFields"); - } - - /// Handle the end of a extension field declaration. Substructures: - /// - Metadata - /// - Modifiers - /// - Type - /// - Variable declarations (count times) - /// - /// Started by [beginFields]. - void endExtensionFields( - Token? abstractToken, - Token? augmentToken, - Token? externalToken, - Token? staticToken, - Token? covariantToken, - Token? lateToken, - Token? varFinalOrConst, - int count, - Token beginToken, - Token endToken, - ) { - logEvent("ExtensionFields"); - } - - /// Handle the end of a extension type field declaration. Substructures: - /// - Metadata - /// - Modifiers - /// - Type - /// - Variable declarations (count times) - /// - /// Started by [beginFields]. - void endExtensionTypeFields( - Token? abstractToken, - Token? augmentToken, - Token? externalToken, - Token? staticToken, - Token? covariantToken, - Token? lateToken, - Token? varFinalOrConst, - int count, - Token beginToken, - Token endToken, - ) { - logEvent("ExtensionTypeFields"); - } - - /// Handle the end of an enum field declaration. Substructures: - /// - Metadata - /// - Modifiers - /// - Type - /// - Variable declarations (count times) - /// - /// Started by [beginFields]. - void endEnumFields( - Token? abstractToken, - Token? augmentToken, - Token? externalToken, - Token? staticToken, - Token? covariantToken, - Token? lateToken, - Token? varFinalOrConst, - int count, - Token beginToken, - Token endToken, - ) { - logEvent("EnumFields"); - } - - /// Handle the end of an enum method declaration. Substructures: - /// - metadata - /// - return type - /// - method name (identifier, possibly qualified) - /// - type variables - /// - formal parameters - /// - initializers - /// - async marker - /// - body - void endEnumMethod( - Token? getOrSet, - Token beginToken, - Token beginParam, - Token? beginInitializers, - Token endToken, - ) { - logEvent("EnumMethod"); + logEvent("Fields"); } /// Marks that the grammar term `forInitializerStatement` has been parsed and @@ -1296,8 +1139,7 @@ abstract class Listener implements UnescapeErrorListener { /// Called for class-like members (class, mixin, extension), but each member /// should also have a more specific begin/end pair, e.g. - /// [beginFactoryMethod]/[endClassFactoryMethod]/[endMixinFactoryMethod]/ - /// [endExtensionFactoryMethod]. + /// [beginFactory]/[endFactory]. void beginMember() {} /// Handle an invalid member declaration. Substructures: @@ -1311,19 +1153,14 @@ abstract class Listener implements UnescapeErrorListener { /// Members will actually be begin/end'ed by more specific /// events as well. /// Normally listeners should probably override - /// [endClassFields], [endMixinFields], [endExtensionFields], - /// [endClassMethod], [endMixinMethod], [endExtensionMethod], - /// [endClassConstructor], [endMixinConstructor], - /// or [endExtensionConstructor] instead. + /// [endFields], [endMethod] or [endConstructor] instead. void endMember() { logEvent("Member"); } /// Handle the beginning of a class-like method declaration. Substructures: /// - metadata - /// Note that this is ended with [endClassConstructor], [endClassMethod], - /// [endExtensionConstructor], [endExtensionMethod], [endMixinConstructor] or - /// [endMixinMethod]. + /// Note that this is ended with [endConstructor] or [endMethod]. void beginMethod( DeclarationKind declarationKind, Token? augmentToken, @@ -1336,7 +1173,8 @@ abstract class Listener implements UnescapeErrorListener { String? enclosingDeclarationName, ) {} - /// Handle the end of a class method declaration. Substructures: + /// Handle the end of a method declaration in a class, enum, mixin, extension + /// or extension type. Substructures: /// - metadata /// - return type /// - method name (identifier, possibly qualified) @@ -1345,17 +1183,18 @@ abstract class Listener implements UnescapeErrorListener { /// - initializers /// - async marker /// - body - void endClassMethod( + void endMethod( + DeclarationKind kind, Token? getOrSet, Token beginToken, Token beginParam, Token? beginInitializers, Token endToken, ) { - logEvent("ClassMethod"); + logEvent("Method"); } - /// Handle the end of a mixin method declaration. Substructures: + /// Handle the end of a constructor declaration. Substructures: /// - metadata /// - return type /// - method name (identifier, possibly qualified) @@ -1364,64 +1203,8 @@ abstract class Listener implements UnescapeErrorListener { /// - initializers /// - async marker /// - body - void endMixinMethod( - Token? getOrSet, - Token beginToken, - Token beginParam, - Token? beginInitializers, - Token endToken, - ) { - logEvent("MixinMethod"); - } - - /// Handle the end of a extension method declaration. Substructures: - /// - metadata - /// - return type - /// - method name (identifier, possibly qualified) - /// - type variables - /// - formal parameters - /// - initializers - /// - async marker - /// - body - void endExtensionMethod( - Token? getOrSet, - Token beginToken, - Token beginParam, - Token? beginInitializers, - Token endToken, - ) { - logEvent("ExtensionMethod"); - } - - /// Handle the end of a extension type method declaration. Substructures: - /// - metadata - /// - return type - /// - method name (identifier, possibly qualified) - /// - type variables - /// - formal parameters - /// - initializers - /// - async marker - /// - body - void endExtensionTypeMethod( - Token? getOrSet, - Token beginToken, - Token beginParam, - Token? beginInitializers, - Token endToken, - ) { - logEvent("ExtensionTypeMethod"); - } - - /// Handle the end of a class constructor declaration. Substructures: - /// - metadata - /// - return type - /// - method name (identifier, possibly qualified) - /// - type variables - /// - formal parameters - /// - initializers - /// - async marker - /// - body - void endClassConstructor( + void endConstructor( + DeclarationKind kind, Token beginToken, Token beginParam, Token? beginInitializers, @@ -1430,61 +1213,6 @@ abstract class Listener implements UnescapeErrorListener { logEvent("ClassConstructor"); } - /// Handle the end of a mixin constructor declaration. Substructures: - /// - metadata - /// - return type - /// - method name (identifier, possibly qualified) - /// - type variables - /// - formal parameters - /// - initializers - /// - async marker - /// - body - void endMixinConstructor( - Token beginToken, - Token beginParam, - Token? beginInitializers, - Token endToken, - ) { - logEvent("MixinConstructor"); - } - - /// Handle the end of a extension constructor declaration. Substructures: - /// - metadata - /// - return type - /// - method name (identifier, possibly qualified) - /// - type variables - /// - formal parameters - /// - initializers - /// - async marker - /// - body - void endExtensionConstructor( - Token beginToken, - Token beginParam, - Token? beginInitializers, - Token endToken, - ) { - logEvent("ExtensionConstructor"); - } - - /// Handle the end of an extension type constructor declaration. - /// Substructures: - /// - metadata - /// - return type - /// - method name (identifier, possibly qualified) - /// - type variables - /// - formal parameters - /// - initializers - /// - async marker - /// - body - void endExtensionTypeConstructor( - Token beginToken, - Token beginParam, - Token? beginInitializers, - Token endToken, - ) { - logEvent("ExtensionTypeConstructor"); - } - void beginMetadataStar(Token token) {} void endMetadataStar(int count) { @@ -1687,8 +1415,7 @@ abstract class Listener implements UnescapeErrorListener { void beginTopLevelMember(Token token) {} /// Marks the beginning of a fields declaration. - /// Note that this is ended with [endTopLevelFields], [endClassFields], - /// [endMixinFields] or [endExtensionFields]. + /// Note that this is ended with [endTopLevelFields] or [endFields]. void beginFields( DeclarationKind declarationKind, Token? abstractToken, diff --git a/pkg/_fe_analyzer_shared/lib/src/parser/parser_impl.dart b/pkg/_fe_analyzer_shared/lib/src/parser/parser_impl.dart index ad1b9b59d7b..b0f577db332 100644 --- a/pkg/_fe_analyzer_shared/lib/src/parser/parser_impl.dart +++ b/pkg/_fe_analyzer_shared/lib/src/parser/parser_impl.dart @@ -4326,45 +4326,10 @@ class Parser { switch (kind) { case DeclarationKind.TopLevel: assert(abstractToken == null); - listener.endTopLevelFields( - augmentToken, - externalToken, - staticToken, - covariantToken, - lateToken, - varFinalOrConst, - fieldCount, - beforeStart.next!, - token, - ); break; case DeclarationKind.Class: - listener.endClassFields( - abstractToken, - augmentToken, - externalToken, - staticToken, - covariantToken, - lateToken, - varFinalOrConst, - fieldCount, - beforeStart.next!, - token, - ); - break; case DeclarationKind.Mixin: - listener.endMixinFields( - abstractToken, - augmentToken, - externalToken, - staticToken, - covariantToken, - lateToken, - varFinalOrConst, - fieldCount, - beforeStart.next!, - token, - ); + case DeclarationKind.Enum: break; case DeclarationKind.Extension: if (abstractToken != null) { @@ -4376,18 +4341,6 @@ class Parser { codes.codeExtensionDeclaresInstanceField, ); } - listener.endExtensionFields( - abstractToken, - augmentToken, - externalToken, - staticToken, - covariantToken, - lateToken, - varFinalOrConst, - fieldCount, - beforeStart.next!, - token, - ); break; case DeclarationKind.ExtensionType: if (staticToken == null && externalToken == null) { @@ -4396,34 +4349,35 @@ class Parser { codes.codeExtensionTypeDeclaresInstanceField, ); } - listener.endExtensionTypeFields( - abstractToken, - augmentToken, - externalToken, - staticToken, - covariantToken, - lateToken, - varFinalOrConst, - fieldCount, - beforeStart.next!, - token, - ); - break; - case DeclarationKind.Enum: - listener.endEnumFields( - abstractToken, - augmentToken, - externalToken, - staticToken, - covariantToken, - lateToken, - varFinalOrConst, - fieldCount, - beforeStart.next!, - token, - ); break; } + if (kind == DeclarationKind.TopLevel) { + listener.endTopLevelFields( + augmentToken, + externalToken, + staticToken, + covariantToken, + lateToken, + varFinalOrConst, + fieldCount, + beforeStart.next!, + token, + ); + } else { + listener.endFields( + kind, + abstractToken, + augmentToken, + externalToken, + staticToken, + covariantToken, + lateToken, + varFinalOrConst, + fieldCount, + beforeStart.next!, + token, + ); + } return token; } @@ -5841,51 +5795,26 @@ class Parser { } switch (kind) { - case DeclarationKind.Class: - listener.endClassConstructor( - beforeStart.next!, - beforeParam.next!, - beforeInitializers?.next, - token, - ); - break; case DeclarationKind.Mixin: reportRecoverableError(name, codes.codeMixinDeclaresConstructor); - listener.endMixinConstructor( - beforeStart.next!, - beforeParam.next!, - beforeInitializers?.next, - token, - ); break; case DeclarationKind.Extension: reportRecoverableError(name, codes.codeExtensionDeclaresConstructor); - listener.endExtensionConstructor( - beforeStart.next!, - beforeParam.next!, - beforeInitializers?.next, - token, - ); break; + case DeclarationKind.Class: case DeclarationKind.ExtensionType: - listener.endExtensionTypeConstructor( - beforeStart.next!, - beforeParam.next!, - beforeInitializers?.next, - token, - ); + case DeclarationKind.Enum: break; case DeclarationKind.TopLevel: throw "Internal error: TopLevel constructor."; - case DeclarationKind.Enum: - listener.endEnumConstructor( - beforeStart.next!, - beforeParam.next!, - beforeInitializers?.next, - token, - ); - break; } + listener.endConstructor( + kind, + beforeStart.next!, + beforeParam.next!, + beforeInitializers?.next, + token, + ); } else { // // method @@ -5902,23 +5831,8 @@ class Parser { } switch (kind) { case DeclarationKind.Class: - // TODO(danrubel): Remove beginInitializers token from method events - listener.endClassMethod( - getOrSet, - beforeStart.next!, - beforeParam.next!, - beforeInitializers?.next, - token, - ); - break; case DeclarationKind.Mixin: - listener.endMixinMethod( - getOrSet, - beforeStart.next!, - beforeParam.next!, - beforeInitializers?.next, - token, - ); + case DeclarationKind.Enum: break; case DeclarationKind.Extension: if (bodyStart.isA(TokenType.SEMICOLON) && externalToken == null) { @@ -5927,13 +5841,6 @@ class Parser { codes.codeExtensionDeclaresAbstractMember, ); } - listener.endExtensionMethod( - getOrSet, - beforeStart.next!, - beforeParam.next!, - beforeInitializers?.next, - token, - ); break; case DeclarationKind.ExtensionType: if (bodyStart.isA(TokenType.SEMICOLON) && externalToken == null) { @@ -5942,26 +5849,19 @@ class Parser { codes.codeExtensionTypeDeclaresAbstractMember, ); } - listener.endExtensionTypeMethod( - getOrSet, - beforeStart.next!, - beforeParam.next!, - beforeInitializers?.next, - token, - ); break; case DeclarationKind.TopLevel: throw "Internal error: TopLevel method."; - case DeclarationKind.Enum: - listener.endEnumMethod( - getOrSet, - beforeStart.next!, - beforeParam.next!, - beforeInitializers?.next, - token, - ); - break; } + // TODO(danrubel): Remove beginInitializers token from method events + listener.endMethod( + kind, + getOrSet, + beforeStart.next!, + beforeParam.next!, + beforeInitializers?.next, + token, + ); } return token; } @@ -6006,12 +5906,7 @@ class Parser { varFinalOrConst = null; } - listener.beginFactoryMethod( - kind, - beforeStart, - externalToken, - varFinalOrConst, - ); + listener.beginFactory(kind, beforeStart, externalToken, varFinalOrConst); if (!hasName) { listener.handleNoIdentifier(token); } else { @@ -6057,47 +5952,25 @@ class Parser { } switch (kind) { case DeclarationKind.Class: - listener.endClassFactoryMethod( - beforeStart.next!, - factoryKeyword, - token, - ); + case DeclarationKind.Enum: + case DeclarationKind.ExtensionType: break; case DeclarationKind.Mixin: reportRecoverableError( factoryKeyword, codes.codeMixinDeclaresConstructor, ); - listener.endMixinFactoryMethod( - beforeStart.next!, - factoryKeyword, - token, - ); break; case DeclarationKind.Extension: reportRecoverableError( factoryKeyword, codes.codeExtensionDeclaresConstructor, ); - listener.endExtensionFactoryMethod( - beforeStart.next!, - factoryKeyword, - token, - ); - break; - case DeclarationKind.ExtensionType: - listener.endExtensionTypeFactoryMethod( - beforeStart.next!, - factoryKeyword, - token, - ); break; case DeclarationKind.TopLevel: throw "Internal error: TopLevel factory."; - case DeclarationKind.Enum: - listener.endEnumFactoryMethod(beforeStart.next!, factoryKeyword, token); - break; } + listener.endFactory(kind, beforeStart.next!, factoryKeyword, token); return token; } diff --git a/pkg/analyzer/lib/src/fasta/ast_builder.dart b/pkg/analyzer/lib/src/fasta/ast_builder.dart index 48c01570352..b2abd41e444 100644 --- a/pkg/analyzer/lib/src/fasta/ast_builder.dart +++ b/pkg/analyzer/lib/src/fasta/ast_builder.dart @@ -404,7 +404,7 @@ class AstBuilder extends StackListener { } @override - void beginFactoryMethod( + void beginFactory( DeclarationKind declarationKind, Token lastConsumed, Token? externalToken, @@ -1227,17 +1227,6 @@ class AstBuilder extends StackListener { } } - @override - void endClassConstructor( - Token beginToken, - Token beginParam, - Token? beginInitializers, - Token endToken, - ) { - debugEvent("endClassConstructor"); - _endClassConstructor(beginToken, beginParam, beginInitializers, endToken); - } - @override void endClassDeclaration(Token beginToken, Token endToken) { debugEvent("ClassDeclaration"); @@ -1248,62 +1237,6 @@ class AstBuilder extends StackListener { _classLikeBuilder = null; } - @override - void endClassFactoryMethod( - Token beginToken, - Token factoryKeyword, - Token endToken, - ) { - debugEvent("endClassFactoryMethod"); - _endFactoryMethod(beginToken, factoryKeyword, endToken); - } - - @override - void endClassFields( - Token? abstractToken, - Token? augmentToken, - Token? externalToken, - Token? staticToken, - Token? covariantToken, - Token? lateToken, - Token? varFinalOrConst, - int count, - Token beginToken, - Token endToken, - ) { - debugEvent("endClassFields"); - _endClassFields( - abstractToken, - augmentToken, - externalToken, - staticToken, - covariantToken, - lateToken, - varFinalOrConst, - count, - beginToken, - endToken, - ); - } - - @override - void endClassMethod( - Token? getOrSet, - Token beginToken, - Token beginParam, - Token? beginInitializers, - Token endToken, - ) { - debugEvent("endClassMethod"); - _endClassMethod( - getOrSet, - beginToken, - beginParam, - beginInitializers, - endToken, - ); - } - @override void endClassOrMixinOrExtensionBody( DeclarationKind kind, @@ -1474,6 +1407,38 @@ class AstBuilder extends StackListener { debugEvent("endConstLiteral"); } + @override + void endConstructor( + DeclarationKind kind, + Token beginToken, + Token beginParam, + Token? beginInitializers, + Token endToken, + ) { + debugEvent("endConstructor"); + switch (kind) { + case DeclarationKind.Class: + case DeclarationKind.ExtensionType: + case DeclarationKind.Enum: + _endClassConstructor( + beginToken, + beginParam, + beginInitializers, + endToken, + ); + case DeclarationKind.Mixin: + case DeclarationKind.Extension: + invalidNodes.add( + _buildConstructorDeclaration( + beginToken: beginToken, + endToken: endToken, + ), + ); + case DeclarationKind.TopLevel: + throw UnsupportedError("Unexpected constructor kind $kind."); + } + } + @override void endConstructorReference( Token start, @@ -1535,17 +1500,6 @@ class AstBuilder extends StackListener { debugEvent("endElseStatement"); } - @override - void endEnumConstructor( - Token beginToken, - Token beginParam, - Token? beginInitializers, - Token endToken, - ) { - debugEvent("endEnumConstructor"); - _endClassConstructor(beginToken, beginParam, beginInitializers, endToken); - } - @override void endEnumDeclaration( Token beginToken, @@ -1563,62 +1517,6 @@ class AstBuilder extends StackListener { _classLikeBuilder = null; } - @override - void endEnumFactoryMethod( - Token beginToken, - Token factoryKeyword, - Token endToken, - ) { - debugEvent("endEnumFactoryMethod"); - _endFactoryMethod(beginToken, factoryKeyword, endToken); - } - - @override - void endEnumFields( - Token? abstractToken, - Token? augmentToken, - Token? externalToken, - Token? staticToken, - Token? covariantToken, - Token? lateToken, - Token? varFinalOrConst, - int count, - Token beginToken, - Token endToken, - ) { - debugEvent("endEnumFields"); - _endClassFields( - abstractToken, - augmentToken, - externalToken, - staticToken, - covariantToken, - lateToken, - varFinalOrConst, - count, - beginToken, - endToken, - ); - } - - @override - void endEnumMethod( - Token? getOrSet, - Token beginToken, - Token beginParam, - Token? beginInitializers, - Token endToken, - ) { - debugEvent("endEnumMethod"); - _endClassMethod( - getOrSet, - beginToken, - beginParam, - beginInitializers, - endToken, - ); - } - @override void endExport(Token exportKeyword, Token semicolon) { assert(optional('export', exportKeyword)); @@ -1643,20 +1541,6 @@ class AstBuilder extends StackListener { ); } - @override - void endExtensionConstructor( - Token beginToken, - Token beginParam, - Token? beginInitializers, - Token endToken, - ) { - debugEvent("ExtensionConstructor"); - - invalidNodes.add( - _buildConstructorDeclaration(beginToken: beginToken, endToken: endToken), - ); - } - @override void endExtensionDeclaration( Token beginToken, @@ -1680,88 +1564,6 @@ class AstBuilder extends StackListener { _classLikeBuilder = null; } - @override - void endExtensionFactoryMethod( - Token beginToken, - Token factoryKeyword, - Token endToken, - ) { - assert(optional('factory', factoryKeyword)); - assert(optional(';', endToken) || optional('}', endToken)); - debugEvent("ExtensionFactoryMethod"); - - invalidNodes.add( - _buildFactoryConstructorDeclaration( - beginToken: beginToken, - factoryKeyword: factoryKeyword, - endToken: endToken, - ), - ); - } - - @override - void endExtensionFields( - Token? abstractToken, - Token? augmentToken, - Token? externalToken, - Token? staticToken, - Token? covariantToken, - Token? lateToken, - Token? varFinalOrConst, - int count, - Token beginToken, - Token endToken, - ) { - debugEvent("endExtensionFields"); - if (staticToken == null) { - // TODO(danrubel): Decide how to handle instance field declarations - // within extensions. They are invalid and the parser has already reported - // an error at this point, but we include them in order to get navigation, - // search, etc. - } - _endClassFields( - abstractToken, - augmentToken, - externalToken, - staticToken, - covariantToken, - lateToken, - varFinalOrConst, - count, - beginToken, - endToken, - ); - } - - @override - void endExtensionMethod( - Token? getOrSet, - Token beginToken, - Token beginParam, - Token? beginInitializers, - Token endToken, - ) { - debugEvent("ExtensionMethod"); - endClassMethod( - getOrSet, - beginToken, - beginParam, - beginInitializers, - endToken, - ); - } - - @override - void endExtensionTypeConstructor( - Token beginToken, - Token beginParam, - Token? beginInitializers, - Token endToken, - ) { - debugEvent("endExtensionTypeConstructor"); - _endClassConstructor(beginToken, beginParam, beginInitializers, endToken); - } - @override void endExtensionTypeDeclaration( Token beginToken, @@ -1825,59 +1627,33 @@ class AstBuilder extends StackListener { } @override - void endExtensionTypeFactoryMethod( + void endFactory( + DeclarationKind kind, Token beginToken, Token factoryKeyword, Token endToken, ) { - debugEvent("endExtensionTypeFactoryMethod"); - _endFactoryMethod(beginToken, factoryKeyword, endToken); - } + assert(optional('factory', factoryKeyword)); + assert(optional(';', endToken) || optional('}', endToken)); + debugEvent("endFactory"); - @override - void endExtensionTypeFields( - Token? abstractToken, - Token? augmentToken, - Token? externalToken, - Token? staticToken, - Token? covariantToken, - Token? lateToken, - Token? varFinalOrConst, - int count, - Token beginToken, - Token endToken, - ) { - debugEvent("endExtensionTypeFields"); - _endClassFields( - abstractToken, - augmentToken, - externalToken, - staticToken, - covariantToken, - lateToken, - varFinalOrConst, - count, - beginToken, - endToken, - ); - } - - @override - void endExtensionTypeMethod( - Token? getOrSet, - Token beginToken, - Token beginParam, - Token? beginInitializers, - Token endToken, - ) { - debugEvent("endExtensionTypeMethod"); - _endClassMethod( - getOrSet, - beginToken, - beginParam, - beginInitializers, - endToken, - ); + switch (kind) { + case DeclarationKind.Class: + case DeclarationKind.Enum: + case DeclarationKind.ExtensionType: + _endFactoryMethod(beginToken, factoryKeyword, endToken); + case DeclarationKind.Mixin: + case DeclarationKind.Extension: + invalidNodes.add( + _buildFactoryConstructorDeclaration( + beginToken: beginToken, + factoryKeyword: factoryKeyword, + endToken: endToken, + ), + ); + case DeclarationKind.TopLevel: + throw UnsupportedError("Unexpected factory kind $kind."); + } } @override @@ -1899,6 +1675,35 @@ class AstBuilder extends StackListener { ); } + @override + void endFields( + DeclarationKind kind, + Token? abstractToken, + Token? augmentToken, + Token? externalToken, + Token? staticToken, + Token? covariantToken, + Token? lateToken, + Token? varFinalOrConst, + int count, + Token beginToken, + Token endToken, + ) { + debugEvent("endFields"); + _endClassFields( + abstractToken, + augmentToken, + externalToken, + staticToken, + covariantToken, + lateToken, + varFinalOrConst, + count, + beginToken, + endToken, + ); + } + @override void endForControlFlow(Token token) { debugEvent("endForControlFlow"); @@ -2697,16 +2502,21 @@ class AstBuilder extends StackListener { } @override - void endMixinConstructor( + void endMethod( + DeclarationKind kind, + Token? getOrSet, Token beginToken, Token beginParam, Token? beginInitializers, Token endToken, ) { - debugEvent("MixinConstructor"); - - invalidNodes.add( - _buildConstructorDeclaration(beginToken: beginToken, endToken: endToken), + debugEvent("endMethod"); + _endClassMethod( + getOrSet, + beginToken, + beginParam, + beginInitializers, + endToken, ); } @@ -2720,69 +2530,6 @@ class AstBuilder extends StackListener { _classLikeBuilder = null; } - @override - void endMixinFactoryMethod( - Token beginToken, - Token factoryKeyword, - Token endToken, - ) { - debugEvent("MixinFactoryMethod"); - - invalidNodes.add( - _buildFactoryConstructorDeclaration( - beginToken: beginToken, - factoryKeyword: factoryKeyword, - endToken: endToken, - ), - ); - } - - @override - void endMixinFields( - Token? abstractToken, - Token? augmentToken, - Token? externalToken, - Token? staticToken, - Token? covariantToken, - Token? lateToken, - Token? varFinalOrConst, - int count, - Token beginToken, - Token endToken, - ) { - debugEvent("endMixinFields"); - _endClassFields( - abstractToken, - augmentToken, - externalToken, - staticToken, - covariantToken, - lateToken, - varFinalOrConst, - count, - beginToken, - endToken, - ); - } - - @override - void endMixinMethod( - Token? getOrSet, - Token beginToken, - Token beginParam, - Token? beginInitializers, - Token endToken, - ) { - debugEvent("MixinMethod"); - endClassMethod( - getOrSet, - beginToken, - beginParam, - beginInitializers, - endToken, - ); - } - @override void endNamedFunctionExpression(Token endToken) { debugEvent("NamedFunctionExpression"); diff --git a/pkg/analyzer/test/generated/parser_fasta_listener.dart b/pkg/analyzer/test/generated/parser_fasta_listener.dart index 5cea8413769..409ca7b4183 100644 --- a/pkg/analyzer/test/generated/parser_fasta_listener.dart +++ b/pkg/analyzer/test/generated/parser_fasta_listener.dart @@ -216,19 +216,19 @@ class ForwardingTestListener extends ForwardingListener { } @override - void beginFactoryMethod( + void beginFactory( DeclarationKind declarationKind, Token lastConsumed, Token? externalToken, Token? constToken, ) { - super.beginFactoryMethod( + super.beginFactory( declarationKind, lastConsumed, externalToken, constToken, ); - begin('FactoryMethod'); + begin('Factory'); } @override @@ -707,22 +707,6 @@ class ForwardingTestListener extends ForwardingListener { super.endCatchClause(token); } - @override - void endClassConstructor( - Token beginToken, - Token beginParam, - Token? beginInitializers, - Token endToken, - ) { - end('Method'); - super.endClassConstructor( - beginToken, - beginParam, - beginInitializers, - endToken, - ); - } - @override void endClassDeclaration(Token beginToken, Token endToken) { end('ClassDeclaration'); @@ -730,63 +714,6 @@ class ForwardingTestListener extends ForwardingListener { super.endClassDeclaration(beginToken, endToken); } - @override - void endClassFactoryMethod( - Token beginToken, - Token factoryKeyword, - Token endToken, - ) { - end('FactoryMethod'); - super.endClassFactoryMethod(beginToken, factoryKeyword, endToken); - } - - @override - void endClassFields( - Token? abstractToken, - Token? augmentToken, - Token? externalToken, - Token? staticToken, - Token? covariantToken, - Token? lateToken, - Token? varFinalOrConst, - int count, - Token beginToken, - Token endToken, - ) { - // beginMember --> endClassFields, endMember - expectIn('Member'); - super.endClassFields( - abstractToken, - augmentToken, - externalToken, - staticToken, - covariantToken, - lateToken, - varFinalOrConst, - count, - beginToken, - endToken, - ); - } - - @override - void endClassMethod( - Token? getOrSet, - Token beginToken, - Token beginParam, - Token? beginInitializers, - Token endToken, - ) { - end('Method'); - super.endClassMethod( - getOrSet, - beginToken, - beginParam, - beginInitializers, - endToken, - ); - } - @override void endClassOrMixinOrExtensionBody( DeclarationKind kind, @@ -840,6 +767,24 @@ class ForwardingTestListener extends ForwardingListener { super.endConstLiteral(endToken); } + @override + void endConstructor( + DeclarationKind kind, + Token beginToken, + Token beginParam, + Token? beginInitializers, + Token endToken, + ) { + end('Method'); + super.endConstructor( + kind, + beginToken, + beginParam, + beginInitializers, + endToken, + ); + } + @override void endConstructorReference( Token start, @@ -878,22 +823,6 @@ class ForwardingTestListener extends ForwardingListener { super.endElseStatement(beginToken, endToken); } - @override - void endEnumConstructor( - Token beginToken, - Token beginParam, - Token? beginInitializers, - Token endToken, - ) { - end('Method'); - super.endEnumConstructor( - beginToken, - beginParam, - beginInitializers, - endToken, - ); - } - @override void endEnumDeclaration( Token beginToken, @@ -912,84 +841,12 @@ class ForwardingTestListener extends ForwardingListener { ); } - @override - void endEnumFactoryMethod( - Token beginToken, - Token factoryKeyword, - Token endToken, - ) { - end('FactoryMethod'); - super.endEnumFactoryMethod(beginToken, factoryKeyword, endToken); - } - - @override - void endEnumFields( - Token? abstractToken, - Token? augmentToken, - Token? externalToken, - Token? staticToken, - Token? covariantToken, - Token? lateToken, - Token? varFinalOrConst, - int count, - Token beginToken, - Token endToken, - ) { - expectIn('Member'); - super.endEnumFields( - abstractToken, - augmentToken, - externalToken, - staticToken, - covariantToken, - lateToken, - varFinalOrConst, - count, - beginToken, - endToken, - ); - } - - @override - void endEnumMethod( - Token? getOrSet, - Token beginToken, - Token beginParam, - Token? beginInitializers, - Token endToken, - ) { - end('Method'); - super.endEnumMethod( - getOrSet, - beginToken, - beginParam, - beginInitializers, - endToken, - ); - } - @override void endExport(Token exportKeyword, Token semicolon) { end('Export'); super.endExport(exportKeyword, semicolon); } - @override - void endExtensionConstructor( - Token beginToken, - Token beginParam, - Token? beginInitializers, - Token endToken, - ) { - end('Method'); - super.endExtensionConstructor( - beginToken, - beginParam, - beginInitializers, - endToken, - ); - } - @override void endExtensionDeclaration( Token beginToken, @@ -1007,17 +864,25 @@ class ForwardingTestListener extends ForwardingListener { } @override - void endExtensionFactoryMethod( + void endFactory( + DeclarationKind kind, Token beginToken, Token factoryKeyword, Token endToken, ) { - end('FactoryMethod'); - super.endExtensionFactoryMethod(beginToken, factoryKeyword, endToken); + end('Factory'); + super.endFactory(kind, beginToken, factoryKeyword, endToken); } @override - void endExtensionFields( + void endFieldInitializer(Token assignment, Token endToken) { + end('FieldInitializer'); + super.endFieldInitializer(assignment, endToken); + } + + @override + void endFields( + DeclarationKind kind, Token? abstractToken, Token? augmentToken, Token? externalToken, @@ -1029,9 +894,10 @@ class ForwardingTestListener extends ForwardingListener { Token beginToken, Token endToken, ) { - // beginMember --> endExtensionFields, endMember + // beginMember --> endFields, endMember expectIn('Member'); - super.endExtensionFields( + super.endFields( + kind, abstractToken, augmentToken, externalToken, @@ -1045,30 +911,6 @@ class ForwardingTestListener extends ForwardingListener { ); } - @override - void endExtensionMethod( - Token? getOrSet, - Token beginToken, - Token beginParam, - Token? beginInitializers, - Token endToken, - ) { - end('Method'); - super.endExtensionMethod( - getOrSet, - beginToken, - beginParam, - beginInitializers, - endToken, - ); - } - - @override - void endFieldInitializer(Token assignment, Token endToken) { - end('FieldInitializer'); - super.endFieldInitializer(assignment, endToken); - } - @override void endForControlFlow(Token token) { end('ForControlFlow'); @@ -1295,14 +1137,18 @@ class ForwardingTestListener extends ForwardingListener { } @override - void endMixinConstructor( + void endMethod( + DeclarationKind kind, + Token? getOrSet, Token beginToken, Token beginParam, Token? beginInitializers, Token endToken, ) { end('Method'); - super.endMixinConstructor( + super.endMethod( + kind, + getOrSet, beginToken, beginParam, beginInitializers, @@ -1317,63 +1163,6 @@ class ForwardingTestListener extends ForwardingListener { super.endMixinDeclaration(beginToken, endToken); } - @override - void endMixinFactoryMethod( - Token beginToken, - Token factoryKeyword, - Token endToken, - ) { - end('FactoryMethod'); - super.endMixinFactoryMethod(beginToken, factoryKeyword, endToken); - } - - @override - void endMixinFields( - Token? abstractToken, - Token? augmentToken, - Token? externalToken, - Token? staticToken, - Token? covariantToken, - Token? lateToken, - Token? varFinalOrConst, - int count, - Token beginToken, - Token endToken, - ) { - // beginMember --> endMixinFields, endMember - expectIn('Member'); - super.endMixinFields( - abstractToken, - augmentToken, - externalToken, - staticToken, - covariantToken, - lateToken, - varFinalOrConst, - count, - beginToken, - endToken, - ); - } - - @override - void endMixinMethod( - Token? getOrSet, - Token beginToken, - Token beginParam, - Token? beginInitializers, - Token endToken, - ) { - end('Method'); - super.endMixinMethod( - getOrSet, - beginToken, - beginParam, - beginInitializers, - endToken, - ); - } - @override void endNamedFunctionExpression(Token endToken) { end('NamedFunctionExpression'); diff --git a/pkg/analyzer/tool/summary/mini_ast.dart b/pkg/analyzer/tool/summary/mini_ast.dart index 22439c3a7a0..ae41dc5816f 100644 --- a/pkg/analyzer/tool/summary/mini_ast.dart +++ b/pkg/analyzer/tool/summary/mini_ast.dart @@ -241,49 +241,6 @@ class MiniAstBuilder extends StackListener { ); } - @override - void endClassFactoryMethod( - Token beginToken, - Token factoryKeyword, - Token endToken, - ) { - debugEvent("ClassFactoryMethod"); - pop(); // Body - pop(); // Type variables - var name = pop() as String; - var metadata = popTypedList() as List?; - var comment = pop() as Comment?; - push(ConstructorDeclaration(comment, metadata, name)); - } - - @override - void endClassMethod( - Token? getOrSet, - Token beginToken, - Token beginParam, - Token? beginInitializers, - Token endToken, - ) { - debugEvent("Method"); - pop(); // Body - pop(); // Initializers - pop(); // Formal parameters - pop(); // Type variables - var name = pop() as String; - var returnType = pop() as TypeName?; - var metadata = popTypedList(); - var comment = pop() as Comment?; - push( - MethodDeclaration( - comment, - metadata, - getOrSet?.lexeme == 'get', - name, - returnType, - ), - ); - } - @override void endClassOrMixinOrExtensionBody( DeclarationKind kind, @@ -338,6 +295,22 @@ class MiniAstBuilder extends StackListener { debugEvent("Enum"); } + @override + void endFactory( + DeclarationKind kind, + Token beginToken, + Token factoryKeyword, + Token endToken, + ) { + debugEvent("Factory"); + pop(); // Body + pop(); // Type variables + var name = pop() as String; + var metadata = popTypedList() as List?; + var comment = pop() as Comment?; + push(ConstructorDeclaration(comment, metadata, name)); + } + @override void endFieldInitializer(Token assignment, Token token) { debugEvent("FieldInitializer"); @@ -424,6 +397,35 @@ class MiniAstBuilder extends StackListener { ); } + @override + void endMethod( + DeclarationKind kind, + Token? getOrSet, + Token beginToken, + Token beginParam, + Token? beginInitializers, + Token endToken, + ) { + debugEvent("Method"); + pop(); // Body + pop(); // Initializers + pop(); // Formal parameters + pop(); // Type variables + var name = pop() as String; + var returnType = pop() as TypeName?; + var metadata = popTypedList(); + var comment = pop() as Comment?; + push( + MethodDeclaration( + comment, + metadata, + getOrSet?.lexeme == 'get', + name, + returnType, + ), + ); + } + @override void endShow(Token showKeyword) { debugEvent("Show"); diff --git a/pkg/front_end/lib/src/kernel/body_builder.dart b/pkg/front_end/lib/src/kernel/body_builder.dart index 20d319cba7f..091555bb9fb 100644 --- a/pkg/front_end/lib/src/kernel/body_builder.dart +++ b/pkg/front_end/lib/src/kernel/body_builder.dart @@ -16,7 +16,8 @@ import 'package:_fe_analyzer_shared/src/parser/parser.dart' intFromToken, lengthForToken, lengthOfSpan, - stripSeparators; + stripSeparators, + DeclarationKind; import 'package:_fe_analyzer_shared/src/parser/quote.dart' show Quote, @@ -1028,7 +1029,8 @@ class BodyBuilderImpl extends StackListenerImpl } @override - void endClassFields( + void endFields( + DeclarationKind kind, Token? abstractToken, Token? augmentToken, Token? externalToken, diff --git a/pkg/front_end/lib/src/source/diet_listener.dart b/pkg/front_end/lib/src/source/diet_listener.dart index 149a562fcbe..bfd2776222b 100644 --- a/pkg/front_end/lib/src/source/diet_listener.dart +++ b/pkg/front_end/lib/src/source/diet_listener.dart @@ -127,7 +127,9 @@ class DietListener extends StackListenerImpl { bool hasName, ) { debugEvent("PartOf"); - if (hasName) discard(1); + if (hasName) { + discard(1); + } discard(1); // Metadata. } @@ -326,7 +328,9 @@ class DietListener extends StackListenerImpl { ); debugEvent("FunctionTypeAlias"); - if (equals == null) pop(); // endToken + if (equals == null) { + pop(); // endToken + } pop(); // name // Metadata is handled in [SourceTypeAliasBuilder.buildOutlineExpressions]. pop(); // metadata @@ -334,7 +338,8 @@ class DietListener extends StackListenerImpl { } @override - void endClassFields( + void endFields( + DeclarationKind kind, Token? abstractToken, Token? augmentToken, Token? externalToken, @@ -346,58 +351,7 @@ class DietListener extends StackListenerImpl { Token beginToken, Token endToken, ) { - debugEvent("endClassFields"); - _buildFields(count, beginToken, false); - } - - @override - void endMixinFields( - Token? abstractToken, - Token? augmentToken, - Token? externalToken, - Token? staticToken, - Token? covariantToken, - Token? lateToken, - Token? varFinalOrConst, - int count, - Token beginToken, - Token endToken, - ) { - debugEvent("endMixinFields"); - _buildFields(count, beginToken, false); - } - - @override - void endExtensionFields( - Token? abstractToken, - Token? augmentToken, - Token? externalToken, - Token? staticToken, - Token? covariantToken, - Token? lateToken, - Token? varFinalOrConst, - int count, - Token beginToken, - Token endToken, - ) { - debugEvent("endExtensionFields"); - _buildFields(count, beginToken, false); - } - - @override - void endExtensionTypeFields( - Token? abstractToken, - Token? augmentToken, - Token? externalToken, - Token? staticToken, - Token? covariantToken, - Token? lateToken, - Token? varFinalOrConst, - int count, - Token beginToken, - Token endToken, - ) { - debugEvent("endExtensionTypeFields"); + debugEvent("endFields"); _buildFields(count, beginToken, false); } @@ -734,13 +688,30 @@ class DietListener extends StackListenerImpl { } @override - void endClassFactoryMethod( + void endFactory( + DeclarationKind kind, Token beginToken, Token factoryKeyword, Token endToken, ) { - debugEvent("ClassFactoryMethod"); - _endClassFactoryMethod(beginToken, factoryKeyword, endToken); + debugEvent("Factory"); + switch (kind) { + case DeclarationKind.Class: + case DeclarationKind.Enum: + case DeclarationKind.ExtensionType: + case DeclarationKind.Mixin: + _endClassFactoryMethod(beginToken, factoryKeyword, endToken); + case DeclarationKind.Extension: + // Skip the declaration. An error as already been produced by the + // parser. + pop(); // bodyToken + pop(); // name + pop(); // metadata + checkEmpty(beginToken.charOffset); + // Coverage-ignore(suite): Not run. + case DeclarationKind.TopLevel: + throw new UnsupportedError("Unexpected factory kind $kind."); + } } void _endClassFactoryMethod( @@ -783,35 +754,6 @@ class DietListener extends StackListenerImpl { } } - @override - void endExtensionFactoryMethod( - Token beginToken, - Token factoryKeyword, - Token endToken, - ) { - debugEvent("ExtensionFactoryMethod"); - pop(); // bodyToken - pop(); // name - pop(); // metadata - checkEmpty(beginToken.charOffset); - // Skip the declaration. An error as already been produced by the parser. - } - - @override - void endExtensionConstructor( - Token beginToken, - Token beginParam, - Token? beginInitializers, - Token endToken, - ) { - debugEvent("ExtensionConstructor"); - pop(); // bodyToken - pop(); // name - pop(); // metadata - checkEmpty(beginToken.charOffset); - // Skip the declaration. An error as already been produced by the parser. - } - @override void endRedirectingFactoryBody(Token beginToken, Token endToken) { debugEvent("RedirectingFactoryBody"); @@ -848,7 +790,8 @@ class DietListener extends StackListenerImpl { } @override - void endClassMethod( + void endMethod( + DeclarationKind kind, Token? getOrSet, Token beginToken, Token beginParam, @@ -859,55 +802,30 @@ class DietListener extends StackListenerImpl { } @override - void endClassConstructor( + void endConstructor( + DeclarationKind kind, Token beginToken, Token beginParam, Token? beginInitializers, Token endToken, ) { - _endClassConstructor(beginToken, beginParam); - } - - @override - void endMixinMethod( - Token? getOrSet, - Token beginToken, - Token beginParam, - Token? beginInitializers, - Token endToken, - ) { - _endClassMethod(getOrSet, beginToken, beginParam); - } - - @override - void endMixinFactoryMethod( - Token beginToken, - Token factoryKeyword, - Token endToken, - ) { - debugEvent("endMixinFactoryMethod"); - _endClassFactoryMethod(beginToken, factoryKeyword, endToken); - } - - @override - void endExtensionMethod( - Token? getOrSet, - Token beginToken, - Token beginParam, - Token? beginInitializers, - Token endToken, - ) { - _endClassMethod(getOrSet, beginToken, beginParam); - } - - @override - void endMixinConstructor( - Token beginToken, - Token beginParam, - Token? beginInitializers, - Token endToken, - ) { - _endClassConstructor(beginToken, beginParam); + switch (kind) { + case DeclarationKind.Class: + case DeclarationKind.Enum: + case DeclarationKind.ExtensionType: + case DeclarationKind.Mixin: + _endClassConstructor(beginToken, beginParam); + case DeclarationKind.Extension: + // Skip the declaration. An error as already been produced by the + // parser. + pop(); // bodyToken + pop(); // name + pop(); // metadata + checkEmpty(beginToken.charOffset); + // Coverage-ignore(suite): Not run. + case DeclarationKind.TopLevel: + throw new UnsupportedError("Unexpected constructor kind $kind."); + } } void _endClassMethod(Token? getOrSet, Token beginToken, Token beginParam) { @@ -1290,39 +1208,6 @@ class DietListener extends StackListenerImpl { checkEmpty(extensionKeyword.charOffset); } - @override - void endExtensionTypeConstructor( - Token beginToken, - Token beginParam, - Token? beginInitializers, - Token endToken, - ) { - debugEvent("endExtensionTypeConstructor"); - _endClassConstructor(beginToken, beginParam); - } - - @override - void endExtensionTypeMethod( - Token? getOrSet, - Token beginToken, - Token beginParam, - Token? beginInitializers, - Token endToken, - ) { - debugEvent("endExtensionTypeFactoryMethod"); - _endClassMethod(getOrSet, beginToken, beginParam); - } - - @override - void endExtensionTypeFactoryMethod( - Token beginToken, - Token factoryKeyword, - Token endToken, - ) { - debugEvent("endExtensionTypeFactoryMethod"); - _endClassFactoryMethod(beginToken, factoryKeyword, endToken); - } - @override void beginEnumBody(Token token) { assert(checkState(token, [ValueKinds.IdentifierOrParserRecovery])); @@ -1377,54 +1262,6 @@ class DietListener extends StackListenerImpl { debugEvent("EnumHeader"); } - @override - void endEnumConstructor( - Token beginToken, - Token beginParam, - Token? beginInitializers, - Token endToken, - ) { - _endClassConstructor(beginToken, beginParam); - } - - @override - void endEnumMethod( - Token? getOrSet, - Token beginToken, - Token beginParam, - Token? beginInitializers, - Token endToken, - ) { - _endClassMethod(getOrSet, beginToken, beginParam); - } - - @override - void endEnumFactoryMethod( - Token beginToken, - Token factoryKeyword, - Token endToken, - ) { - debugEvent("endEnumFactoryMethod"); - _endClassFactoryMethod(beginToken, factoryKeyword, endToken); - } - - @override - void endEnumFields( - Token? abstractToken, - Token? augmentToken, - Token? externalToken, - Token? staticToken, - Token? covariantToken, - Token? lateToken, - Token? varFinalOrConst, - int count, - Token beginToken, - Token endToken, - ) { - debugEvent("Fields"); - _buildFields(count, beginToken, false); - } - @override void endNamedMixinApplication( Token beginToken, diff --git a/pkg/front_end/lib/src/source/outline_builder.dart b/pkg/front_end/lib/src/source/outline_builder.dart index 9a7a2db49c4..607e2892f7b 100644 --- a/pkg/front_end/lib/src/source/outline_builder.dart +++ b/pkg/front_end/lib/src/source/outline_builder.dart @@ -2270,7 +2270,8 @@ class OutlineBuilder extends StackListenerImpl { } @override - void endClassMethod( + void endMethod( + DeclarationKind kind, Token? getOrSet, Token beginToken, Token beginParam, @@ -2278,134 +2279,69 @@ class OutlineBuilder extends StackListenerImpl { Token endToken, ) { debugEvent("endClassMethod"); + + if (kind == DeclarationKind.Enum) { + reportIfNotEnabled( + libraryFeatures.enhancedEnums, + beginToken.charOffset, + noLength, + ); + } + _endClassMethod( getOrSet, beginToken, beginParam, beginInitializers, endToken, - _MethodKind.classMethod, + switch (kind) { + DeclarationKind.Class => _MethodKind.classMethod, + DeclarationKind.Mixin => _MethodKind.mixinMethod, + DeclarationKind.Extension => _MethodKind.extensionMethod, + DeclarationKind.ExtensionType => _MethodKind.extensionTypeMethod, + DeclarationKind.Enum => _MethodKind.enumMethod, + // Coverage-ignore(suite): Not run. + DeclarationKind.TopLevel => throw new UnsupportedError( + "Unexpected method kind $kind.", + ), + }, ); } @override - void endClassConstructor( + void endConstructor( + DeclarationKind kind, Token beginToken, Token beginParam, Token? beginInitializers, Token endToken, ) { - debugEvent("endClassConstructor"); + debugEvent("endConstructor"); + + if (kind == DeclarationKind.Enum) { + reportIfNotEnabled( + libraryFeatures.enhancedEnums, + beginToken.charOffset, + noLength, + ); + } + _endClassConstructor( beginToken, beginInitializers, endToken, - _ConstructorKind.classConstructor, - ); - } - - @override - void endMixinMethod( - Token? getOrSet, - Token beginToken, - Token beginParam, - Token? beginInitializers, - Token endToken, - ) { - debugEvent("endMixinMethod"); - _endClassMethod( - getOrSet, - beginToken, - beginParam, - beginInitializers, - endToken, - _MethodKind.mixinMethod, - ); - } - - @override - void endExtensionMethod( - Token? getOrSet, - Token beginToken, - Token beginParam, - Token? beginInitializers, - Token endToken, - ) { - debugEvent("endExtensionMethod"); - _endClassMethod( - getOrSet, - beginToken, - beginParam, - beginInitializers, - endToken, - _MethodKind.extensionMethod, - ); - } - - @override - void endExtensionTypeMethod( - Token? getOrSet, - Token beginToken, - Token beginParam, - Token? beginInitializers, - Token endToken, - ) { - debugEvent("endExtensionTypeMethod"); - _endClassMethod( - getOrSet, - beginToken, - beginParam, - beginInitializers, - endToken, - _MethodKind.extensionTypeMethod, - ); - } - - @override - void endMixinConstructor( - Token beginToken, - Token beginParam, - Token? beginInitializers, - Token endToken, - ) { - debugEvent("endMixinConstructor"); - _endClassConstructor( - beginToken, - beginInitializers, - endToken, - _ConstructorKind.mixinConstructor, - ); - } - - @override - void endExtensionConstructor( - Token beginToken, - Token beginParam, - Token? beginInitializers, - Token endToken, - ) { - debugEvent("endExtensionConstructor"); - _endClassConstructor( - beginToken, - beginInitializers, - endToken, - _ConstructorKind.extensionConstructor, - ); - } - - @override - void endExtensionTypeConstructor( - Token beginToken, - Token beginParam, - Token? beginInitializers, - Token endToken, - ) { - debugEvent("endExtensionTypeConstructor"); - _endClassConstructor( - beginToken, - beginInitializers, - endToken, - _ConstructorKind.extensionTypeConstructor, + switch (kind) { + DeclarationKind.Class => _ConstructorKind.classConstructor, + DeclarationKind.Mixin => _ConstructorKind.mixinConstructor, + DeclarationKind.Extension => _ConstructorKind.extensionConstructor, + DeclarationKind.ExtensionType => + _ConstructorKind.extensionTypeConstructor, + DeclarationKind.Enum => _ConstructorKind.enumConstructor, + // Coverage-ignore(suite): Not run. + DeclarationKind.TopLevel => throw new UnsupportedError( + "Unexpected constructor kind $kind.", + ), + }, ); } @@ -3967,7 +3903,8 @@ class OutlineBuilder extends StackListenerImpl { } @override - void endExtensionFields( + void endFields( + DeclarationKind kind, Token? abstractToken, Token? augmentToken, Token? externalToken, @@ -3979,63 +3916,14 @@ class OutlineBuilder extends StackListenerImpl { Token beginToken, Token endToken, ) { - debugEvent("ExtensionFields"); - _endClassFields( - abstractToken, - augmentToken, - externalToken, - staticToken, - covariantToken, - lateToken, - varFinalOrConst, - count, - beginToken, - endToken, - ); - } - - @override - void endMixinFields( - Token? abstractToken, - Token? augmentToken, - Token? externalToken, - Token? staticToken, - Token? covariantToken, - Token? lateToken, - Token? varFinalOrConst, - int count, - Token beginToken, - Token endToken, - ) { - debugEvent("MixinFields"); - _endClassFields( - abstractToken, - augmentToken, - externalToken, - staticToken, - covariantToken, - lateToken, - varFinalOrConst, - count, - beginToken, - endToken, - ); - } - - @override - void endClassFields( - Token? abstractToken, - Token? augmentToken, - Token? externalToken, - Token? staticToken, - Token? covariantToken, - Token? lateToken, - Token? varFinalOrConst, - int count, - Token beginToken, - Token endToken, - ) { - debugEvent("ClassFields"); + debugEvent("Fields"); + if (kind == DeclarationKind.Enum) { + reportIfNotEnabled( + libraryFeatures.enhancedEnums, + beginToken.charOffset, + noLength, + ); + } _endClassFields( abstractToken, augmentToken, @@ -4412,7 +4300,7 @@ class OutlineBuilder extends StackListenerImpl { } @override - void beginFactoryMethod( + void beginFactory( DeclarationKind declarationKind, Token lastConsumed, Token? externalToken, @@ -4526,176 +4414,25 @@ class OutlineBuilder extends StackListenerImpl { } @override - void endClassFactoryMethod( + void endFactory( + DeclarationKind kind, Token beginToken, Token factoryKeyword, Token endToken, ) { debugEvent("endClassFactoryMethod"); - _endFactoryMethod(beginToken, factoryKeyword, endToken); - } - - @override - void endMixinFactoryMethod( - Token beginToken, - Token factoryKeyword, - Token endToken, - ) { - debugEvent("endMixinFactoryMethod"); + if (kind == DeclarationKind.Enum) { + reportIfNotEnabled( + libraryFeatures.enhancedEnums, + beginToken.charOffset, + noLength, + ); + } _endFactoryMethod(beginToken, factoryKeyword, endToken); } - @override - void endExtensionFactoryMethod( - Token beginToken, - Token factoryKeyword, - Token endToken, - ) { - debugEvent("endExtensionFactoryMethod"); - - _endFactoryMethod(beginToken, factoryKeyword, endToken); - } - - @override - void endExtensionTypeFactoryMethod( - Token beginToken, - Token factoryKeyword, - Token endToken, - ) { - debugEvent("endExtensionTypeFactoryMethod"); - - _endFactoryMethod(beginToken, factoryKeyword, endToken); - } - - @override - void endExtensionTypeFields( - Token? abstractToken, - Token? augmentToken, - Token? externalToken, - Token? staticToken, - Token? covariantToken, - Token? lateToken, - Token? varFinalOrConst, - int count, - Token beginToken, - Token endToken, - ) { - debugEvent("endExtensionTypeFields"); - _endClassFields( - abstractToken, - augmentToken, - externalToken, - staticToken, - covariantToken, - lateToken, - varFinalOrConst, - count, - beginToken, - endToken, - ); - } - - @override - void endEnumFactoryMethod( - Token beginToken, - Token factoryKeyword, - Token endToken, - ) { - debugEvent("endEnumFactoryMethod"); - - reportIfNotEnabled( - libraryFeatures.enhancedEnums, - beginToken.charOffset, - noLength, - ); - - _endFactoryMethod(beginToken, factoryKeyword, endToken); - } - - @override - void endEnumMethod( - Token? getOrSet, - Token beginToken, - Token beginParam, - Token? beginInitializers, - Token endToken, - ) { - debugEvent("endEnumMethod"); - - reportIfNotEnabled( - libraryFeatures.enhancedEnums, - beginToken.charOffset, - noLength, - ); - - _endClassMethod( - getOrSet, - beginToken, - beginParam, - beginInitializers, - endToken, - _MethodKind.enumMethod, - ); - } - - @override - void endEnumFields( - Token? abstractToken, - Token? augmentToken, - Token? externalToken, - Token? staticToken, - Token? covariantToken, - Token? lateToken, - Token? varFinalOrConst, - int count, - Token beginToken, - Token endToken, - ) { - reportIfNotEnabled( - libraryFeatures.enhancedEnums, - beginToken.charOffset, - noLength, - ); - - endClassFields( - abstractToken, - augmentToken, - externalToken, - staticToken, - covariantToken, - lateToken, - varFinalOrConst, - count, - beginToken, - endToken, - ); - } - - @override - void endEnumConstructor( - Token beginToken, - Token beginParam, - Token? beginInitializers, - Token endToken, - ) { - debugEvent("endEnumConstructor"); - - reportIfNotEnabled( - libraryFeatures.enhancedEnums, - beginToken.charOffset, - noLength, - ); - - _endClassConstructor( - beginToken, - beginInitializers, - endToken, - _ConstructorKind.enumConstructor, - ); - } - @override void endRedirectingFactoryBody(Token beginToken, Token endToken) { debugEvent("RedirectingFactoryBody"); diff --git a/pkg/front_end/lib/src/type_inference/inference_visitor.dart b/pkg/front_end/lib/src/type_inference/inference_visitor.dart index e89fcb8cf76..d67dabe645f 100644 --- a/pkg/front_end/lib/src/type_inference/inference_visitor.dart +++ b/pkg/front_end/lib/src/type_inference/inference_visitor.dart @@ -10706,7 +10706,8 @@ class InferenceVisitorImpl extends InferenceVisitorBase if (unaryTarget.isNullable) { List? context = getWhyNotPromotedContext( whyNotPromoted(), - unary, // Coverage-ignore(suite): Not run. + unary, + // Coverage-ignore(suite): Not run. (type) => !type.isPotentiallyNullable, ); // TODO(johnniwinther): Special case 'unary-' in messages. It should diff --git a/pkg/front_end/lib/src/util/abstracted_ast_nodes.dart b/pkg/front_end/lib/src/util/abstracted_ast_nodes.dart index cd5cb15454a..8411ca9c41b 100644 --- a/pkg/front_end/lib/src/util/abstracted_ast_nodes.dart +++ b/pkg/front_end/lib/src/util/abstracted_ast_nodes.dart @@ -235,21 +235,16 @@ class Extension extends Container { } } -class ClassConstructor extends AstNode { +class Constructor extends AstNode { @override - final ClassConstructorEnd node; + final ConstructorEnd node; final String name; @override final Token startInclusive; @override final Token endInclusive; - ClassConstructor( - this.node, - this.name, - this.startInclusive, - this.endInclusive, - ); + Constructor(this.node, this.name, this.startInclusive, this.endInclusive); @override StringBuffer toStringInternal(StringBuffer sb, int indent) { @@ -258,7 +253,7 @@ class ClassConstructor extends AstNode { if (marked != Coloring.Untouched) { sb.write("(marked) "); } - sb.writeln("Class constructor $name"); + sb.writeln("Constructor $name"); return sb; } @@ -272,21 +267,16 @@ class ClassConstructor extends AstNode { } } -class ClassFactoryMethod extends AstNode { +class Factory extends AstNode { @override - final ClassFactoryMethodEnd node; + final FactoryEnd node; final String name; @override final Token startInclusive; @override final Token endInclusive; - ClassFactoryMethod( - this.node, - this.name, - this.startInclusive, - this.endInclusive, - ); + Factory(this.node, this.name, this.startInclusive, this.endInclusive); @override StringBuffer toStringInternal(StringBuffer sb, int indent) { @@ -295,7 +285,7 @@ class ClassFactoryMethod extends AstNode { if (marked != Coloring.Untouched) { sb.write("(marked) "); } - sb.writeln("Class factory constructor $name"); + sb.writeln("Factory $name"); return sb; } @@ -309,16 +299,16 @@ class ClassFactoryMethod extends AstNode { } } -class ClassMethod extends AstNode { +class Method extends AstNode { @override - final ClassMethodEnd node; + final MethodEnd node; final String name; @override final Token startInclusive; @override final Token endInclusive; - ClassMethod(this.node, this.name, this.startInclusive, this.endInclusive); + Method(this.node, this.name, this.startInclusive, this.endInclusive); @override StringBuffer toStringInternal(StringBuffer sb, int indent) { @@ -340,68 +330,6 @@ class ClassMethod extends AstNode { } } -class ExtensionMethod extends AstNode { - @override - final ExtensionMethodEnd node; - final String name; - @override - final Token startInclusive; - @override - final Token endInclusive; - - ExtensionMethod(this.node, this.name, this.startInclusive, this.endInclusive); - - @override - StringBuffer toStringInternal(StringBuffer sb, int indent) { - String stringIndent = " " * (indent * 2); - sb.write(stringIndent); - if (marked != Coloring.Untouched) { - sb.write("(marked) "); - } - sb.writeln("Extension method $name"); - return sb; - } - - @override - void buildScope() {} - - @override - Map selfScope() { - return {name: this}; - } -} - -class MixinMethod extends AstNode { - @override - final MixinMethodEnd node; - final String name; - @override - final Token startInclusive; - @override - final Token endInclusive; - - MixinMethod(this.node, this.name, this.startInclusive, this.endInclusive); - - @override - StringBuffer toStringInternal(StringBuffer sb, int indent) { - String stringIndent = " " * (indent * 2); - sb.write(stringIndent); - if (marked != Coloring.Untouched) { - sb.write("(marked) "); - } - sb.writeln("Mixin method $name"); - return sb; - } - - @override - void buildScope() {} - - @override - Map selfScope() { - return {name: this}; - } -} - class Enum extends AstNode { @override final EnumDeclarationEnd node; @@ -661,16 +589,16 @@ class Typedef extends AstNode { } } -class ClassFields extends AstNode { +class Fields extends AstNode { @override - final ClassFieldsEnd node; + final FieldsEnd node; final List names; @override final Token startInclusive; @override final Token endInclusive; - ClassFields(this.node, this.names, this.startInclusive, this.endInclusive); + Fields(this.node, this.names, this.startInclusive, this.endInclusive); @override StringBuffer toStringInternal(StringBuffer sb, int indent) { @@ -679,82 +607,7 @@ class ClassFields extends AstNode { if (marked != Coloring.Untouched) { sb.write("(marked) "); } - sb.writeln("Class field(s) ${names.join(", ")}"); - return sb; - } - - @override - void buildScope() {} - - @override - Map selfScope() { - Map scope = {}; - for (String name in names) { - scope[name] = this; - } - return scope; - } -} - -class MixinFields extends AstNode { - @override - final MixinFieldsEnd node; - final List names; - @override - final Token startInclusive; - @override - final Token endInclusive; - - MixinFields(this.node, this.names, this.startInclusive, this.endInclusive); - - @override - StringBuffer toStringInternal(StringBuffer sb, int indent) { - String stringIndent = " " * (indent * 2); - sb.write(stringIndent); - if (marked != Coloring.Untouched) { - sb.write("(marked) "); - } - sb.writeln("Mixin field(s) ${names.join(", ")}"); - return sb; - } - - @override - void buildScope() {} - - @override - Map selfScope() { - Map scope = {}; - for (String name in names) { - scope[name] = this; - } - return scope; - } -} - -class ExtensionFields extends AstNode { - @override - final ExtensionFieldsEnd node; - final List names; - @override - final Token startInclusive; - @override - final Token endInclusive; - - ExtensionFields( - this.node, - this.names, - this.startInclusive, - this.endInclusive, - ); - - @override - StringBuffer toStringInternal(StringBuffer sb, int indent) { - String stringIndent = " " * (indent * 2); - sb.write(stringIndent); - if (marked != Coloring.Untouched) { - sb.write("(marked) "); - } - sb.writeln("Extension field(s) ${names.join(", ")}"); + sb.writeln("Field(s) ${names.join(", ")}"); return sb; } diff --git a/pkg/front_end/lib/src/util/outline_extractor.dart b/pkg/front_end/lib/src/util/outline_extractor.dart index 29f99ca11fa..a35eedf7e38 100644 --- a/pkg/front_end/lib/src/util/outline_extractor.dart +++ b/pkg/front_end/lib/src/util/outline_extractor.dart @@ -700,41 +700,41 @@ class _ParserAstVisitor extends IgnoreSomeForCompatibilityAstVisitor { } @override - void visitClassConstructorEnd(ClassConstructorEnd node) { - assert(currentContainer is Class); + void visitConstructorEnd(ConstructorEnd node) { + assert(currentContainer is! TopLevel); List ids = node.getIdentifiers(); if (ids.length == 1) { - ClassConstructor classConstructor = new ClassConstructor( + Constructor constructor = new Constructor( node, ids.single.token.lexeme, node.beginToken, node.endToken, ); - currentContainer.addChild(classConstructor, map); + currentContainer.addChild(constructor, map); log("Hello from constructor ${ids.single.token}"); } else if (ids.length == 2) { - ClassConstructor classConstructor = new ClassConstructor( + Constructor constructor = new Constructor( node, "${ids.first.token}.${ids.last.token}", node.beginToken, node.endToken, ); - map[node] = classConstructor; - currentContainer.addChild(classConstructor, map); + map[node] = constructor; + currentContainer.addChild(constructor, map); log("Hello from constructor ${ids.first.token}.${ids.last.token}"); } else { throw "Unexpected identifiers in class constructor"; } - super.visitClassConstructorEnd(node); + super.visitConstructorEnd(node); } @override - void visitClassFactoryMethodEnd(ClassFactoryMethodEnd node) { + void visitFactoryEnd(FactoryEnd node) { assert(currentContainer is Class); List ids = node.getIdentifiers(); if (ids.length == 1) { - ClassFactoryMethod classFactoryMethod = new ClassFactoryMethod( + Factory classFactoryMethod = new Factory( node, ids.single.token.lexeme, node.beginToken, @@ -743,7 +743,7 @@ class _ParserAstVisitor extends IgnoreSomeForCompatibilityAstVisitor { currentContainer.addChild(classFactoryMethod, map); log("Hello from factory method ${ids.single.token}"); } else if (ids.length == 2) { - ClassFactoryMethod classFactoryMethod = new ClassFactoryMethod( + Factory classFactoryMethod = new Factory( node, "${ids.first.token}.${ids.last.token}", node.beginToken, @@ -762,41 +762,41 @@ class _ParserAstVisitor extends IgnoreSomeForCompatibilityAstVisitor { ); } - super.visitClassFactoryMethodEnd(node); + super.visitFactoryEnd(node); } @override - void visitClassFieldsEnd(ClassFieldsEnd node) { - assert(currentContainer is Class); + void visitFieldsEnd(FieldsEnd node) { + assert(currentContainer is! TopLevel); List fields = node .getFieldIdentifiers() .map((e) => e.token.lexeme) .toList(); - ClassFields classFields = new ClassFields( + Fields classFields = new Fields( node, fields, node.beginToken, node.endToken, ); currentContainer.addChild(classFields, map); - log("Hello from class fields ${fields.join(", ")}"); - super.visitClassFieldsEnd(node); + log("Hello from fields ${fields.join(", ")}"); + super.visitFieldsEnd(node); } @override - void visitClassMethodEnd(ClassMethodEnd node) { - assert(currentContainer is Class); + void visitMethodEnd(MethodEnd node) { + assert(currentContainer is! TopLevel); String identifier = node.getNameIdentifier(); - ClassMethod classMethod = new ClassMethod( + Method classMethod = new Method( node, identifier, node.beginToken, node.endToken, ); currentContainer.addChild(classMethod, map); - log("Hello from class method $identifier"); - super.visitClassMethodEnd(node); + log("Hello from method $identifier"); + super.visitMethodEnd(node); } @override @@ -867,50 +867,6 @@ class _ParserAstVisitor extends IgnoreSomeForCompatibilityAstVisitor { currentContainer = previousContainer; } - @override - void visitExtensionConstructorEnd(ExtensionConstructorEnd node) { - // TODO: implement visitExtensionConstructorEnd - throw node; - } - - @override - void visitExtensionFactoryMethodEnd(ExtensionFactoryMethodEnd node) { - // TODO: implement visitExtensionFactoryMethodEnd - throw node; - } - - @override - void visitExtensionFieldsEnd(ExtensionFieldsEnd node) { - assert(currentContainer is Extension); - List fields = node - .getFieldIdentifiers() - .map((e) => e.token.lexeme) - .toList(); - ExtensionFields classFields = new ExtensionFields( - node, - fields, - node.beginToken, - node.endToken, - ); - currentContainer.addChild(classFields, map); - log("Hello from extension fields ${fields.join(", ")}"); - super.visitExtensionFieldsEnd(node); - } - - @override - void visitExtensionMethodEnd(ExtensionMethodEnd node) { - assert(currentContainer is Extension); - ExtensionMethod extensionMethod = new ExtensionMethod( - node, - node.getNameIdentifier(), - node.beginToken, - node.endToken, - ); - currentContainer.addChild(extensionMethod, map); - log("Hello from extension method ${node.getNameIdentifier()}"); - super.visitExtensionMethodEnd(node); - } - void debugDumpSource( Token startInclusive, Token endInclusive, @@ -1000,38 +956,6 @@ class _ParserAstVisitor extends IgnoreSomeForCompatibilityAstVisitor { currentContainer = previousContainer; } - @override - void visitMixinFieldsEnd(MixinFieldsEnd node) { - assert(currentContainer is Mixin); - List fields = node - .getFieldIdentifiers() - .map((e) => e.token.lexeme) - .toList(); - MixinFields mixinFields = new MixinFields( - node, - fields, - node.beginToken, - node.endToken, - ); - currentContainer.addChild(mixinFields, map); - log("Hello from mixin fields ${fields.join(", ")}"); - super.visitMixinFieldsEnd(node); - } - - @override - void visitMixinMethodEnd(MixinMethodEnd node) { - assert(currentContainer is Mixin); - MixinMethod classMethod = new MixinMethod( - node, - node.getNameIdentifier(), - node.beginParam, - node.endToken, - ); - currentContainer.addChild(classMethod, map); - log("Hello from mixin method ${node.getNameIdentifier()}"); - super.visitMixinMethodEnd(node); - } - @override void visitNamedMixinApplicationEnd(NamedMixinApplicationEnd node) { TopLevelDeclarationEnd parent = node.parent! as TopLevelDeclarationEnd; diff --git a/pkg/front_end/lib/src/util/parser_ast.dart b/pkg/front_end/lib/src/util/parser_ast.dart index 9faa804be2e..356cc5deb51 100644 --- a/pkg/front_end/lib/src/util/parser_ast.dart +++ b/pkg/front_end/lib/src/util/parser_ast.dart @@ -176,24 +176,9 @@ class BestEffortParserAstVisitor { visitTopLevelMethod(method, method.beginToken, method.endToken); return; } - if (node is ClassMethodEnd) { - ClassMethodEnd method = node; - visitClassMethod(method, method.beginToken, method.endToken); - return; - } - if (node is ExtensionMethodEnd) { - ExtensionMethodEnd method = node; - visitExtensionMethod(method, method.beginToken, method.endToken); - return; - } - if (node is ExtensionTypeMethodEnd) { - ExtensionTypeMethodEnd method = node; - visitExtensionTypeMethod(method, method.beginToken, method.endToken); - return; - } - if (node is MixinMethodEnd) { - MixinMethodEnd method = node; - visitMixinMethod(method, method.beginToken, method.endToken); + if (node is MethodEnd) { + MethodEnd method = node; + visitMethod(method, method.beginToken, method.endToken); return; } if (node is ImportEnd) { @@ -213,32 +198,11 @@ class BestEffortParserAstVisitor { visitTopLevelFields(fields, fields.beginToken, fields.endToken); return; } - if (node is ClassFieldsEnd) { + if (node is FieldsEnd) { // TODO(jensj): Possibly this could go into more details too // (e.g. to split up a field declaration). - ClassFieldsEnd fields = node; - visitClassFields(fields, fields.beginToken, fields.endToken); - return; - } - if (node is ExtensionFieldsEnd) { - // TODO(jensj): Possibly this could go into more details too - // (e.g. to split up a field declaration). - ExtensionFieldsEnd fields = node; - visitExtensionFields(fields, fields.beginToken, fields.endToken); - return; - } - if (node is ExtensionTypeFieldsEnd) { - // TODO(jensj): Possibly this could go into more details too - // (e.g. to split up a field declaration). - ExtensionTypeFieldsEnd fields = node; - visitExtensionTypeFields(fields, fields.beginToken, fields.endToken); - return; - } - if (node is MixinFieldsEnd) { - // TODO(jensj): Possibly this could go into more details too - // (e.g. to split up a field declaration). - MixinFieldsEnd fields = node; - visitMixinFields(fields, fields.beginToken, fields.endToken); + FieldsEnd fields = node; + visitFields(fields, fields.beginToken, fields.endToken); return; } if (node is NamedMixinApplicationEnd) { @@ -285,34 +249,14 @@ class BestEffortParserAstVisitor { visitExtensionTypeDeclaration(ext, ext.extensionKeyword, ext.endToken); return; } - if (node is ClassConstructorEnd) { - ClassConstructorEnd decl = node; - visitClassConstructor(decl, decl.beginToken, decl.endToken); + if (node is ConstructorEnd) { + ConstructorEnd decl = node; + visitConstructor(decl, decl.beginToken, decl.endToken); return; } - if (node is ExtensionConstructorEnd) { - ExtensionConstructorEnd decl = node; - visitExtensionConstructor(decl, decl.beginToken, decl.endToken); - return; - } - if (node is ExtensionTypeConstructorEnd) { - ExtensionTypeConstructorEnd decl = node; - visitExtensionTypeConstructor(decl, decl.beginToken, decl.endToken); - return; - } - if (node is ClassFactoryMethodEnd) { - ClassFactoryMethodEnd decl = node; - visitClassFactoryMethod(decl, decl.beginToken, decl.endToken); - return; - } - if (node is ExtensionFactoryMethodEnd) { - ExtensionFactoryMethodEnd decl = node; - visitExtensionFactoryMethod(decl, decl.beginToken, decl.endToken); - return; - } - if (node is ExtensionTypeFactoryMethodEnd) { - ExtensionTypeFactoryMethodEnd decl = node; - visitExtensionTypeFactoryMethod(decl, decl.beginToken, decl.endToken); + if (node is FactoryEnd) { + FactoryEnd decl = node; + visitFactory(decl, decl.beginToken, decl.endToken); return; } if (node is MetadataEnd) { @@ -368,32 +312,7 @@ class BestEffortParserAstVisitor { ) {} /// Note: Implementers are NOT expected to call visitChildren on this node. - void visitClassMethod( - ClassMethodEnd node, - Token startInclusive, - Token endInclusive, - ) {} - - /// Note: Implementers are NOT expected to call visitChildren on this node. - void visitExtensionMethod( - ExtensionMethodEnd node, - Token startInclusive, - Token endInclusive, - ) {} - - /// Note: Implementers are NOT expected to call visitChildren on this node. - void visitExtensionTypeMethod( - ExtensionTypeMethodEnd node, - Token startInclusive, - Token endInclusive, - ) {} - - /// Note: Implementers are NOT expected to call visitChildren on this node. - void visitMixinMethod( - MixinMethodEnd node, - Token startInclusive, - Token endInclusive, - ) {} + void visitMethod(MethodEnd node, Token startInclusive, Token endInclusive) {} /// Note: Implementers are NOT expected to call visitChildren on this node. void visitTopLevelFields( @@ -403,32 +322,7 @@ class BestEffortParserAstVisitor { ) {} /// Note: Implementers are NOT expected to call visitChildren on this node. - void visitClassFields( - ClassFieldsEnd node, - Token startInclusive, - Token endInclusive, - ) {} - - /// Note: Implementers are NOT expected to call visitChildren on this node. - void visitExtensionFields( - ExtensionFieldsEnd node, - Token startInclusive, - Token endInclusive, - ) {} - - /// Note: Implementers are NOT expected to call visitChildren on this node. - void visitExtensionTypeFields( - ExtensionTypeFieldsEnd node, - Token startInclusive, - Token endInclusive, - ) {} - - /// Note: Implementers are NOT expected to call visitChildren on this node. - void visitMixinFields( - MixinFieldsEnd node, - Token startInclusive, - Token endInclusive, - ) {} + void visitFields(FieldsEnd node, Token startInclusive, Token endInclusive) {} /// Note: Implementers can call visitChildren on this node. void visitNamedMixin( @@ -487,43 +381,15 @@ class BestEffortParserAstVisitor { } /// Note: Implementers are NOT expected to call visitChildren on this node. - void visitClassConstructor( - ClassConstructorEnd node, + void visitConstructor( + ConstructorEnd node, Token startInclusive, Token endInclusive, ) {} /// Note: Implementers are NOT expected to call visitChildren on this node. - void visitExtensionConstructor( - ExtensionConstructorEnd node, - Token startInclusive, - Token endInclusive, - ) {} - - /// Note: Implementers are NOT expected to call visitChildren on this node. - void visitExtensionTypeConstructor( - ExtensionTypeConstructorEnd node, - Token startInclusive, - Token endInclusive, - ) {} - - /// Note: Implementers are NOT expected to call visitChildren on this node. - void visitClassFactoryMethod( - ClassFactoryMethodEnd node, - Token startInclusive, - Token endInclusive, - ) {} - - /// Note: Implementers are NOT expected to call visitChildren on this node. - void visitExtensionFactoryMethod( - ExtensionFactoryMethodEnd node, - Token startInclusive, - Token endInclusive, - ) {} - - /// Note: Implementers are NOT expected to call visitChildren on this node. - void visitExtensionTypeFactoryMethod( - ExtensionTypeFactoryMethodEnd node, + void visitFactory( + FactoryEnd node, Token startInclusive, Token endInclusive, ) {} @@ -537,28 +403,12 @@ class BestEffortParserAstVisitor { } enum MemberContentType { - ClassConstructor, - ClassFactoryMethod, - ClassFields, - ClassMethod, ClassRecoverableError, - EnumConstructor, - EnumFactoryMethod, - EnumFields, - EnumMethod, + Constructor, ExperimentNotEnabled, - ExtensionConstructor, - ExtensionFactoryMethod, - ExtensionFields, - ExtensionMethod, - ExtensionTypeConstructor, - ExtensionTypeFactoryMethod, - ExtensionTypeFields, - ExtensionTypeMethod, - MixinConstructor, - MixinFactoryMethod, - MixinFields, - MixinMethod, + Factory, + Fields, + Method, Unknown, } @@ -1243,36 +1093,10 @@ extension MemberExtension on MemberEnd { // here, but will then have to do more if's or a switch at the call site to // do anything useful with it, which might not be optimal. MemberContentType getMemberType() { - if (isClassConstructor()) return MemberContentType.ClassConstructor; - if (isClassFactoryMethod()) return MemberContentType.ClassFactoryMethod; - if (isClassFields()) return MemberContentType.ClassFields; - if (isClassMethod()) return MemberContentType.ClassMethod; - - if (isMixinConstructor()) return MemberContentType.MixinConstructor; - if (isMixinFactoryMethod()) return MemberContentType.MixinFactoryMethod; - if (isMixinFields()) return MemberContentType.MixinFields; - if (isMixinMethod()) return MemberContentType.MixinMethod; - - if (isExtensionConstructor()) return MemberContentType.ExtensionConstructor; - if (isExtensionFactoryMethod()) { - return MemberContentType.ExtensionFactoryMethod; - } - if (isExtensionFields()) return MemberContentType.ExtensionFields; - if (isExtensionMethod()) return MemberContentType.ExtensionMethod; - - if (isExtensionTypeConstructor()) { - return MemberContentType.ExtensionTypeConstructor; - } - if (isExtensionTypeFactoryMethod()) { - return MemberContentType.ExtensionTypeFactoryMethod; - } - if (isExtensionTypeFields()) return MemberContentType.ExtensionTypeFields; - if (isExtensionTypeMethod()) return MemberContentType.ExtensionTypeMethod; - - if (isEnumConstructor()) return MemberContentType.EnumConstructor; - if (isEnumFactoryMethod()) return MemberContentType.EnumFactoryMethod; - if (isEnumFields()) return MemberContentType.EnumFields; - if (isEnumMethod()) return MemberContentType.EnumMethod; + if (isConstructor()) return MemberContentType.Constructor; + if (isFactory()) return MemberContentType.Factory; + if (isFields()) return MemberContentType.Fields; + if (isMethod()) return MemberContentType.Method; if (isClassRecoverableError()) { return MemberContentType.ClassRecoverableError; @@ -1282,99 +1106,51 @@ extension MemberExtension on MemberEnd { return MemberContentType.Unknown; } - bool isClassConstructor() { + bool isConstructor() { ParserAstNode child = children![1]; - if (child is ClassConstructorEnd) return true; + if (child is ConstructorEnd) return true; return false; } - ClassConstructorEnd getClassConstructor() { + ConstructorEnd getConstructor() { ParserAstNode child = children![1]; - if (child is ClassConstructorEnd) return child; + if (child is ConstructorEnd) return child; throw "Not found"; } - bool isClassFactoryMethod() { + bool isFactory() { ParserAstNode child = children![1]; - if (child is ClassFactoryMethodEnd) return true; + if (child is FactoryEnd) return true; return false; } - ClassFactoryMethodEnd getClassFactoryMethod() { + FactoryEnd getFactory() { ParserAstNode child = children![1]; - if (child is ClassFactoryMethodEnd) return child; + if (child is FactoryEnd) return child; throw "Not found"; } - bool isClassFields() { + bool isFields() { ParserAstNode child = children![1]; - if (child is ClassFieldsEnd) return true; + if (child is FieldsEnd) return true; return false; } - ClassFieldsEnd getClassFields() { + FieldsEnd getFields() { ParserAstNode child = children![1]; - if (child is ClassFieldsEnd) return child; + if (child is FieldsEnd) return child; throw "Not found"; } - bool isMixinFields() { + bool isMethod() { ParserAstNode child = children![1]; - if (child is MixinFieldsEnd) return true; + if (child is MethodEnd) return true; return false; } - MixinFieldsEnd getMixinFields() { + MethodEnd getMethod() { ParserAstNode child = children![1]; - if (child is MixinFieldsEnd) return child; - throw "Not found"; - } - - bool isMixinMethod() { - ParserAstNode child = children![1]; - if (child is MixinMethodEnd) return true; - return false; - } - - MixinMethodEnd getMixinMethod() { - ParserAstNode child = children![1]; - if (child is MixinMethodEnd) return child; - throw "Not found"; - } - - bool isMixinFactoryMethod() { - ParserAstNode child = children![1]; - if (child is MixinFactoryMethodEnd) return true; - return false; - } - - MixinFactoryMethodEnd getMixinFactoryMethod() { - ParserAstNode child = children![1]; - if (child is MixinFactoryMethodEnd) return child; - throw "Not found"; - } - - bool isMixinConstructor() { - ParserAstNode child = children![1]; - if (child is MixinConstructorEnd) return true; - return false; - } - - MixinConstructorEnd getMixinConstructor() { - ParserAstNode child = children![1]; - if (child is MixinConstructorEnd) return child; - throw "Not found"; - } - - bool isClassMethod() { - ParserAstNode child = children![1]; - if (child is ClassMethodEnd) return true; - return false; - } - - ClassMethodEnd getClassMethod() { - ParserAstNode child = children![1]; - if (child is ClassMethodEnd) return child; + if (child is MethodEnd) return child; throw "Not found"; } @@ -1390,150 +1166,6 @@ extension MemberExtension on MemberEnd { return false; } - bool isExtensionMethod() { - ParserAstNode child = children![1]; - if (child is ExtensionMethodEnd) return true; - return false; - } - - ExtensionMethodEnd getExtensionMethod() { - ParserAstNode child = children![1]; - if (child is ExtensionMethodEnd) return child; - throw "Not found"; - } - - bool isExtensionFields() { - ParserAstNode child = children![1]; - if (child is ExtensionFieldsEnd) return true; - return false; - } - - ExtensionFieldsEnd getExtensionFields() { - ParserAstNode child = children![1]; - if (child is ExtensionFieldsEnd) return child; - throw "Not found"; - } - - bool isExtensionConstructor() { - ParserAstNode child = children![1]; - if (child is ExtensionConstructorEnd) return true; - return false; - } - - ExtensionConstructorEnd getExtensionConstructor() { - ParserAstNode child = children![1]; - if (child is ExtensionConstructorEnd) return child; - throw "Not found"; - } - - bool isExtensionFactoryMethod() { - ParserAstNode child = children![1]; - if (child is ExtensionFactoryMethodEnd) return true; - return false; - } - - ExtensionFactoryMethodEnd getExtensionFactoryMethod() { - ParserAstNode child = children![1]; - if (child is ExtensionFactoryMethodEnd) return child; - throw "Not found"; - } - - bool isExtensionTypeMethod() { - ParserAstNode child = children![1]; - if (child is ExtensionTypeMethodEnd) return true; - return false; - } - - ExtensionTypeMethodEnd getExtensionTypeMethod() { - ParserAstNode child = children![1]; - if (child is ExtensionTypeMethodEnd) return child; - throw "Not found"; - } - - bool isExtensionTypeFields() { - ParserAstNode child = children![1]; - if (child is ExtensionTypeFieldsEnd) return true; - return false; - } - - ExtensionTypeFieldsEnd getExtensionTypeFields() { - ParserAstNode child = children![1]; - if (child is ExtensionTypeFieldsEnd) return child; - throw "Not found"; - } - - bool isExtensionTypeConstructor() { - ParserAstNode child = children![1]; - if (child is ExtensionTypeConstructorEnd) return true; - return false; - } - - ExtensionTypeConstructorEnd getExtensionTypeConstructor() { - ParserAstNode child = children![1]; - if (child is ExtensionTypeConstructorEnd) return child; - throw "Not found"; - } - - bool isExtensionTypeFactoryMethod() { - ParserAstNode child = children![1]; - if (child is ExtensionTypeFactoryMethodEnd) return true; - return false; - } - - ExtensionTypeFactoryMethodEnd getExtensionTypeFactoryMethod() { - ParserAstNode child = children![1]; - if (child is ExtensionTypeFactoryMethodEnd) return child; - throw "Not found"; - } - - bool isEnumMethod() { - ParserAstNode child = children![1]; - if (child is EnumMethodEnd) return true; - return false; - } - - EnumMethodEnd getEnumMethod() { - ParserAstNode child = children![1]; - if (child is EnumMethodEnd) return child; - throw "Not found"; - } - - bool isEnumFields() { - ParserAstNode child = children![1]; - if (child is EnumFieldsEnd) return true; - return false; - } - - EnumFieldsEnd getEnumFields() { - ParserAstNode child = children![1]; - if (child is EnumFieldsEnd) return child; - throw "Not found"; - } - - bool isEnumConstructor() { - ParserAstNode child = children![1]; - if (child is EnumConstructorEnd) return true; - return false; - } - - EnumConstructorEnd getEnumConstructor() { - ParserAstNode child = children![1]; - if (child is EnumConstructorEnd) return child; - throw "Not found"; - } - - bool isEnumFactoryMethod() { - ParserAstNode child = children![1]; - if (child is EnumFactoryMethodEnd) return true; - return false; - } - - EnumFactoryMethodEnd getEnumFactoryMethod() { - ParserAstNode child = children![1]; - if (child is EnumFactoryMethodEnd) return child; - throw "Not found"; - } - bool isPrimaryConstructorBody() { ParserAstNode child = children![1]; if (child is PrimaryConstructorBodyEnd) return true; @@ -1548,99 +1180,7 @@ extension MemberExtension on MemberEnd { } // Coverage-ignore(suite): Not run. -extension MixinFieldsExtension on MixinFieldsEnd { - List getFieldIdentifiers() { - int countLeft = count; - List? identifiers; - for (int i = children!.length - 1; i >= 0; i--) { - ParserAstNode child = children![i]; - if (child is IdentifierHandle && - child.context == IdentifierContext.fieldDeclaration) { - countLeft--; - if (identifiers == null) { - identifiers = new List.filled(count, child); - } else { - identifiers[countLeft] = child; - } - if (countLeft == 0) break; - } - } - if (countLeft != 0) throw "Didn't find the expected number of identifiers"; - return identifiers ?? []; - } -} - -// Coverage-ignore(suite): Not run. -extension ExtensionFieldsExtension on ExtensionFieldsEnd { - List getFieldIdentifiers() { - int countLeft = count; - List? identifiers; - for (int i = children!.length - 1; i >= 0; i--) { - ParserAstNode child = children![i]; - if (child is IdentifierHandle && - child.context == IdentifierContext.fieldDeclaration) { - countLeft--; - if (identifiers == null) { - identifiers = new List.filled(count, child); - } else { - identifiers[countLeft] = child; - } - if (countLeft == 0) break; - } - } - if (countLeft != 0) throw "Didn't find the expected number of identifiers"; - return identifiers ?? []; - } -} - -// Coverage-ignore(suite): Not run. -extension ExtensionTypeFieldsExtension on ExtensionTypeFieldsEnd { - List getFieldIdentifiers() { - int countLeft = count; - List? identifiers; - for (int i = children!.length - 1; i >= 0; i--) { - ParserAstNode child = children![i]; - if (child is IdentifierHandle && - child.context == IdentifierContext.fieldDeclaration) { - countLeft--; - if (identifiers == null) { - identifiers = new List.filled(count, child); - } else { - identifiers[countLeft] = child; - } - if (countLeft == 0) break; - } - } - if (countLeft != 0) throw "Didn't find the expected number of identifiers"; - return identifiers ?? []; - } -} - -// Coverage-ignore(suite): Not run. -extension EnumFieldsExtension on EnumFieldsEnd { - List getFieldIdentifiers() { - int countLeft = count; - List? identifiers; - for (int i = children!.length - 1; i >= 0; i--) { - ParserAstNode child = children![i]; - if (child is IdentifierHandle && - child.context == IdentifierContext.fieldDeclaration) { - countLeft--; - if (identifiers == null) { - identifiers = new List.filled(count, child); - } else { - identifiers[countLeft] = child; - } - if (countLeft == 0) break; - } - } - if (countLeft != 0) throw "Didn't find the expected number of identifiers"; - return identifiers ?? []; - } -} - -// Coverage-ignore(suite): Not run. -extension ClassFieldsExtension on ClassFieldsEnd { +extension FieldsExtension on FieldsEnd { List getFieldIdentifiers() { int countLeft = count; List? identifiers; @@ -2006,7 +1546,7 @@ bool _isTypeOrNoType(ParserAstNode node) { node is FunctionTypeEnd; } -extension ClassMethodExtension on ClassMethodEnd { +extension MethodExtension on MethodEnd { // Coverage-ignore(suite): Not run. BlockFunctionBodyEnd? getBlockFunctionBody() { for (ParserAstNode child in children!) { @@ -2040,91 +1580,7 @@ extension ClassMethodExtension on ClassMethodEnd { } // Coverage-ignore(suite): Not run. -extension MixinMethodExtension on MixinMethodEnd { - Token getNameIdentifierToken() { - bool foundType = false; - for (ParserAstNode child in children!) { - if (_isTypeOrNoType(child)) { - foundType = true; - } - if (foundType && child is IdentifierHandle) { - return child.token; - } else if (foundType && child is OperatorNameHandle) { - return child.token; - } - } - throw "No identifier found: $children"; - } - - String getNameIdentifier() { - return getNameIdentifierToken().lexeme; - } -} - -// Coverage-ignore(suite): Not run. -extension ExtensionMethodExtension on ExtensionMethodEnd { - Token getNameIdentifierToken() { - bool foundType = false; - for (ParserAstNode child in children!) { - if (_isTypeOrNoType(child)) { - foundType = true; - } - if (foundType && child is IdentifierHandle) { - return child.token; - } else if (foundType && child is OperatorNameHandle) { - return child.token; - } - } - throw "No identifier found: $children"; - } - - String getNameIdentifier() { - return getNameIdentifierToken().lexeme; - } -} - -// Coverage-ignore(suite): Not run. -extension ExtensionTypeMethodExtension on ExtensionTypeMethodEnd { - Token getNameIdentifierToken() { - bool foundType = false; - for (ParserAstNode child in children!) { - if (_isTypeOrNoType(child)) { - foundType = true; - } - if (foundType && child is IdentifierHandle) { - return child.token; - } else if (foundType && child is OperatorNameHandle) { - return child.token; - } - } - throw "No identifier found: $children"; - } - - String getNameIdentifier() { - return getNameIdentifierToken().lexeme; - } -} - -// Coverage-ignore(suite): Not run. -extension EnumMethodExtension on EnumMethodEnd { - String getNameIdentifier() { - bool foundType = false; - for (ParserAstNode child in children!) { - if (_isTypeOrNoType(child)) { - foundType = true; - } - if (foundType && child is IdentifierHandle) { - return child.token.lexeme; - } else if (foundType && child is OperatorNameHandle) { - return child.token.lexeme; - } - } - throw "No identifier found: $children"; - } -} - -// Coverage-ignore(suite): Not run. -extension ClassFactoryMethodExtension on ClassFactoryMethodEnd { +extension FactoryExtension on FactoryEnd { List getIdentifiers() { List result = []; for (ParserAstNode child in children!) { @@ -2139,67 +1595,7 @@ extension ClassFactoryMethodExtension on ClassFactoryMethodEnd { } // Coverage-ignore(suite): Not run. -extension MixinFactoryMethodExtension on MixinFactoryMethodEnd { - List getIdentifiers() { - List result = []; - for (ParserAstNode child in children!) { - if (child is IdentifierHandle) { - result.add(child); - } else if (child is FormalParametersEnd) { - break; - } - } - return result; - } -} - -// Coverage-ignore(suite): Not run. -extension ExtensionFactoryMethodExtension on ExtensionFactoryMethodEnd { - List getIdentifiers() { - List result = []; - for (ParserAstNode child in children!) { - if (child is IdentifierHandle) { - result.add(child); - } else if (child is FormalParametersEnd) { - break; - } - } - return result; - } -} - -// Coverage-ignore(suite): Not run. -extension ExtensionTypeFactoryMethodExtension on ExtensionTypeFactoryMethodEnd { - List getIdentifiers() { - List result = []; - for (ParserAstNode child in children!) { - if (child is IdentifierHandle) { - result.add(child); - } else if (child is FormalParametersEnd) { - break; - } - } - return result; - } -} - -// Coverage-ignore(suite): Not run. -extension EnumFactoryMethodExtension on EnumFactoryMethodEnd { - List getIdentifiers() { - List result = []; - for (ParserAstNode child in children!) { - if (child is IdentifierHandle) { - result.add(child); - } else if (child is FormalParametersEnd) { - break; - } - } - return result; - } -} - -// Coverage-ignore(suite): Not run. -extension ClassConstructorExtension on ClassConstructorEnd { +extension ConstructorExtension on ConstructorEnd { FormalParametersEnd getFormalParameters() { for (ParserAstNode child in children!) { if (child is FormalParametersEnd) { @@ -2238,58 +1634,6 @@ extension ClassConstructorExtension on ClassConstructorEnd { } } -// Coverage-ignore(suite): Not run. -extension ExtensionConstructorExtension on ExtensionConstructorEnd { - List getIdentifiers() { - List result = []; - for (ParserAstNode child in children!) { - if (child is IdentifierHandle) { - result.add(child); - } - } - return result; - } -} - -// Coverage-ignore(suite): Not run. -extension ExtensionTypeConstructorExtension on ExtensionTypeConstructorEnd { - List getIdentifiers() { - List result = []; - for (ParserAstNode child in children!) { - if (child is IdentifierHandle) { - result.add(child); - } - } - return result; - } -} - -// Coverage-ignore(suite): Not run. -extension EnumConstructorExtension on EnumConstructorEnd { - List getIdentifiers() { - List result = []; - for (ParserAstNode child in children!) { - if (child is IdentifierHandle) { - result.add(child); - } - } - return result; - } -} - -// Coverage-ignore(suite): Not run. -extension MixinConstructorExtension on MixinConstructorEnd { - List getIdentifiers() { - List result = []; - for (ParserAstNode child in children!) { - if (child is IdentifierHandle) { - result.add(child); - } - } - return result; - } -} - // Coverage-ignore(suite): Not run. extension FormalParametersExtension on FormalParametersEnd { List getFormalParameters() { @@ -2432,40 +1776,12 @@ class ParserASTListener extends AbstractParserAstListener { // beginExtensionDeclarationPrelude, // beginClassOrNamedMixinApplicationPrelude // beginTopLevelMember or beginUncategorizedTopLevelDeclaration. - } else if (begin == "Method" && - (end == "ClassConstructor" || - end == "ClassMethod" || - end == "ExtensionConstructor" || - end == "ExtensionMethod" || - end == "ExtensionTypeConstructor" || - end == "ExtensionTypeMethod" || - end == "MixinConstructor" || - end == "MixinMethod" || - end == "EnumConstructor" || - end == "EnumMethod")) { - // beginMethod is ended by one of endClassConstructor, - // endClassMethod, endExtensionMethod, endMixinConstructor, - // endMixinMethod, endEnumMethod or endEnumConstructor. - } else if (begin == "Fields" && - (end == "TopLevelFields" || - end == "ClassFields" || - end == "MixinFields" || - end == "ExtensionFields" || - end == "ExtensionTypeFields" || - end == "EnumFields")) { - // beginFields is ended by one of endTopLevelFields, endMixinFields, - // endEnumFields or endExtensionFields. + } else if (begin == "Method" && end == "Constructor") { + // beginMethod is ended by one of endMethod or endConstructor. + } else if (begin == "Fields" && end == "TopLevelFields") { + // beginFields is ended by one of endTopLevelFields or endFields. } else if (begin == "ForStatement" && end == "ForIn") { // beginForStatement is ended by either endForStatement or endForIn. - } else if (begin == "FactoryMethod" && - (end == "ClassFactoryMethod" || - end == "MixinFactoryMethod" || - end == "ExtensionFactoryMethod" || - end == "ExtensionTypeFactoryMethod" || - end == "EnumFactoryMethod")) { - // beginFactoryMethod is ended by either endClassFactoryMethod, - // endMixinFactoryMethod, endExtensionFactoryMethod, or - // endEnumFactoryMethod. } else if (begin == "ForControlFlow" && (end == "ForInControlFlow")) { // beginForControlFlow is ended by either endForControlFlow or // endForInControlFlow. diff --git a/pkg/front_end/lib/src/util/parser_ast_helper.dart b/pkg/front_end/lib/src/util/parser_ast_helper.dart index fe21fda7f5e..748f3fb2be4 100644 --- a/pkg/front_end/lib/src/util/parser_ast_helper.dart +++ b/pkg/front_end/lib/src/util/parser_ast_helper.dart @@ -761,23 +761,6 @@ abstract class AbstractParserAstListener implements Listener { seen(data); } - @override - void endEnumConstructor( - Token beginToken, - Token beginParam, - Token? beginInitializers, - Token endToken, - ) { - EnumConstructorEnd data = new EnumConstructorEnd( - ParserAstType.END, - beginToken: beginToken, - beginParam: beginParam, - beginInitializers: beginInitializers, - endToken: endToken, - ); - seen(data); - } - @override void handleEnumElements(Token elementsEndToken, int elementsCount) { EnumElementsHandle data = new EnumElementsHandle( @@ -829,21 +812,6 @@ abstract class AbstractParserAstListener implements Listener { seen(data); } - @override - void endEnumFactoryMethod( - Token beginToken, - Token factoryKeyword, - Token endToken, - ) { - EnumFactoryMethodEnd data = new EnumFactoryMethodEnd( - ParserAstType.END, - beginToken: beginToken, - factoryKeyword: factoryKeyword, - endToken: endToken, - ); - seen(data); - } - @override void beginExport(Token token) { ExportBegin data = new ExportBegin(ParserAstType.BEGIN, token: token); @@ -881,13 +849,13 @@ abstract class AbstractParserAstListener implements Listener { } @override - void beginFactoryMethod( + void beginFactory( DeclarationKind declarationKind, Token lastConsumed, Token? externalToken, Token? constToken, ) { - FactoryMethodBegin data = new FactoryMethodBegin( + FactoryBegin data = new FactoryBegin( ParserAstType.BEGIN, declarationKind: declarationKind, lastConsumed: lastConsumed, @@ -898,58 +866,15 @@ abstract class AbstractParserAstListener implements Listener { } @override - void endClassFactoryMethod( + void endFactory( + DeclarationKind kind, Token beginToken, Token factoryKeyword, Token endToken, ) { - ClassFactoryMethodEnd data = new ClassFactoryMethodEnd( - ParserAstType.END, - beginToken: beginToken, - factoryKeyword: factoryKeyword, - endToken: endToken, - ); - seen(data); - } - - @override - void endMixinFactoryMethod( - Token beginToken, - Token factoryKeyword, - Token endToken, - ) { - MixinFactoryMethodEnd data = new MixinFactoryMethodEnd( - ParserAstType.END, - beginToken: beginToken, - factoryKeyword: factoryKeyword, - endToken: endToken, - ); - seen(data); - } - - @override - void endExtensionFactoryMethod( - Token beginToken, - Token factoryKeyword, - Token endToken, - ) { - ExtensionFactoryMethodEnd data = new ExtensionFactoryMethodEnd( - ParserAstType.END, - beginToken: beginToken, - factoryKeyword: factoryKeyword, - endToken: endToken, - ); - seen(data); - } - - @override - void endExtensionTypeFactoryMethod( - Token beginToken, - Token factoryKeyword, - Token endToken, - ) { - ExtensionTypeFactoryMethodEnd data = new ExtensionTypeFactoryMethodEnd( + FactoryEnd data = new FactoryEnd( ParserAstType.END, + kind: kind, beginToken: beginToken, factoryKeyword: factoryKeyword, endToken: endToken, @@ -1041,7 +966,8 @@ abstract class AbstractParserAstListener implements Listener { } @override - void endClassFields( + void endFields( + DeclarationKind kind, Token? abstractToken, Token? augmentToken, Token? externalToken, @@ -1053,8 +979,9 @@ abstract class AbstractParserAstListener implements Listener { Token beginToken, Token endToken, ) { - ClassFieldsEnd data = new ClassFieldsEnd( + FieldsEnd data = new FieldsEnd( ParserAstType.END, + kind: kind, abstractToken: abstractToken, augmentToken: augmentToken, externalToken: externalToken, @@ -1069,141 +996,6 @@ abstract class AbstractParserAstListener implements Listener { seen(data); } - @override - void endMixinFields( - Token? abstractToken, - Token? augmentToken, - Token? externalToken, - Token? staticToken, - Token? covariantToken, - Token? lateToken, - Token? varFinalOrConst, - int count, - Token beginToken, - Token endToken, - ) { - MixinFieldsEnd data = new MixinFieldsEnd( - ParserAstType.END, - abstractToken: abstractToken, - augmentToken: augmentToken, - externalToken: externalToken, - staticToken: staticToken, - covariantToken: covariantToken, - lateToken: lateToken, - varFinalOrConst: varFinalOrConst, - count: count, - beginToken: beginToken, - endToken: endToken, - ); - seen(data); - } - - @override - void endExtensionFields( - Token? abstractToken, - Token? augmentToken, - Token? externalToken, - Token? staticToken, - Token? covariantToken, - Token? lateToken, - Token? varFinalOrConst, - int count, - Token beginToken, - Token endToken, - ) { - ExtensionFieldsEnd data = new ExtensionFieldsEnd( - ParserAstType.END, - abstractToken: abstractToken, - augmentToken: augmentToken, - externalToken: externalToken, - staticToken: staticToken, - covariantToken: covariantToken, - lateToken: lateToken, - varFinalOrConst: varFinalOrConst, - count: count, - beginToken: beginToken, - endToken: endToken, - ); - seen(data); - } - - @override - void endExtensionTypeFields( - Token? abstractToken, - Token? augmentToken, - Token? externalToken, - Token? staticToken, - Token? covariantToken, - Token? lateToken, - Token? varFinalOrConst, - int count, - Token beginToken, - Token endToken, - ) { - ExtensionTypeFieldsEnd data = new ExtensionTypeFieldsEnd( - ParserAstType.END, - abstractToken: abstractToken, - augmentToken: augmentToken, - externalToken: externalToken, - staticToken: staticToken, - covariantToken: covariantToken, - lateToken: lateToken, - varFinalOrConst: varFinalOrConst, - count: count, - beginToken: beginToken, - endToken: endToken, - ); - seen(data); - } - - @override - void endEnumFields( - Token? abstractToken, - Token? augmentToken, - Token? externalToken, - Token? staticToken, - Token? covariantToken, - Token? lateToken, - Token? varFinalOrConst, - int count, - Token beginToken, - Token endToken, - ) { - EnumFieldsEnd data = new EnumFieldsEnd( - ParserAstType.END, - abstractToken: abstractToken, - augmentToken: augmentToken, - externalToken: externalToken, - staticToken: staticToken, - covariantToken: covariantToken, - lateToken: lateToken, - varFinalOrConst: varFinalOrConst, - count: count, - beginToken: beginToken, - endToken: endToken, - ); - seen(data); - } - - @override - void endEnumMethod( - Token? getOrSet, - Token beginToken, - Token beginParam, - Token? beginInitializers, - Token endToken, - ) { - EnumMethodEnd data = new EnumMethodEnd( - ParserAstType.END, - getOrSet: getOrSet, - beginToken: beginToken, - beginParam: beginParam, - beginInitializers: beginInitializers, - endToken: endToken, - ); - seen(data); - } - @override void handleForInitializerEmptyStatement(Token token) { ForInitializerEmptyStatementHandle data = @@ -2112,15 +1904,17 @@ abstract class AbstractParserAstListener implements Listener { } @override - void endClassMethod( + void endMethod( + DeclarationKind kind, Token? getOrSet, Token beginToken, Token beginParam, Token? beginInitializers, Token endToken, ) { - ClassMethodEnd data = new ClassMethodEnd( + MethodEnd data = new MethodEnd( ParserAstType.END, + kind: kind, getOrSet: getOrSet, beginToken: beginToken, beginParam: beginParam, @@ -2131,122 +1925,16 @@ abstract class AbstractParserAstListener implements Listener { } @override - void endMixinMethod( - Token? getOrSet, + void endConstructor( + DeclarationKind kind, Token beginToken, Token beginParam, Token? beginInitializers, Token endToken, ) { - MixinMethodEnd data = new MixinMethodEnd( - ParserAstType.END, - getOrSet: getOrSet, - beginToken: beginToken, - beginParam: beginParam, - beginInitializers: beginInitializers, - endToken: endToken, - ); - seen(data); - } - - @override - void endExtensionMethod( - Token? getOrSet, - Token beginToken, - Token beginParam, - Token? beginInitializers, - Token endToken, - ) { - ExtensionMethodEnd data = new ExtensionMethodEnd( - ParserAstType.END, - getOrSet: getOrSet, - beginToken: beginToken, - beginParam: beginParam, - beginInitializers: beginInitializers, - endToken: endToken, - ); - seen(data); - } - - @override - void endExtensionTypeMethod( - Token? getOrSet, - Token beginToken, - Token beginParam, - Token? beginInitializers, - Token endToken, - ) { - ExtensionTypeMethodEnd data = new ExtensionTypeMethodEnd( - ParserAstType.END, - getOrSet: getOrSet, - beginToken: beginToken, - beginParam: beginParam, - beginInitializers: beginInitializers, - endToken: endToken, - ); - seen(data); - } - - @override - void endClassConstructor( - Token beginToken, - Token beginParam, - Token? beginInitializers, - Token endToken, - ) { - ClassConstructorEnd data = new ClassConstructorEnd( - ParserAstType.END, - beginToken: beginToken, - beginParam: beginParam, - beginInitializers: beginInitializers, - endToken: endToken, - ); - seen(data); - } - - @override - void endMixinConstructor( - Token beginToken, - Token beginParam, - Token? beginInitializers, - Token endToken, - ) { - MixinConstructorEnd data = new MixinConstructorEnd( - ParserAstType.END, - beginToken: beginToken, - beginParam: beginParam, - beginInitializers: beginInitializers, - endToken: endToken, - ); - seen(data); - } - - @override - void endExtensionConstructor( - Token beginToken, - Token beginParam, - Token? beginInitializers, - Token endToken, - ) { - ExtensionConstructorEnd data = new ExtensionConstructorEnd( - ParserAstType.END, - beginToken: beginToken, - beginParam: beginParam, - beginInitializers: beginInitializers, - endToken: endToken, - ); - seen(data); - } - - @override - void endExtensionTypeConstructor( - Token beginToken, - Token beginParam, - Token? beginInitializers, - Token endToken, - ) { - ExtensionTypeConstructorEnd data = new ExtensionTypeConstructorEnd( + ConstructorEnd data = new ConstructorEnd( ParserAstType.END, + kind: kind, beginToken: beginToken, beginParam: beginParam, beginInitializers: beginInitializers, @@ -5430,35 +5118,6 @@ class EnumDeclarationEnd extends ParserAstNode R accept(ParserAstVisitor v) => v.visitEnumDeclarationEnd(this); } -class EnumConstructorEnd extends ParserAstNode - implements BeginAndEndTokenParserAstNode { - @override - final Token beginToken; - final Token beginParam; - final Token? beginInitializers; - @override - final Token endToken; - - EnumConstructorEnd( - ParserAstType type, { - required this.beginToken, - required this.beginParam, - this.beginInitializers, - required this.endToken, - }) : super("EnumConstructor", type); - - @override - Map get deprecatedArguments => { - "beginToken": beginToken, - "beginParam": beginParam, - "beginInitializers": beginInitializers, - "endToken": endToken, - }; - - @override - R accept(ParserAstVisitor v) => v.visitEnumConstructorEnd(this); -} - class EnumElementsHandle extends ParserAstNode { final Token elementsEndToken; final int elementsCount; @@ -5558,32 +5217,6 @@ class EnumElementHandle extends ParserAstNode { R accept(ParserAstVisitor v) => v.visitEnumElementHandle(this); } -class EnumFactoryMethodEnd extends ParserAstNode - implements BeginAndEndTokenParserAstNode { - @override - final Token beginToken; - final Token factoryKeyword; - @override - final Token endToken; - - EnumFactoryMethodEnd( - ParserAstType type, { - required this.beginToken, - required this.factoryKeyword, - required this.endToken, - }) : super("EnumFactoryMethod", type); - - @override - Map get deprecatedArguments => { - "beginToken": beginToken, - "factoryKeyword": factoryKeyword, - "endToken": endToken, - }; - - @override - R accept(ParserAstVisitor v) => v.visitEnumFactoryMethodEnd(this); -} - class ExportBegin extends ParserAstNode { final Token token; @@ -5660,19 +5293,19 @@ class ExpressionStatementHandle extends ParserAstNode R accept(ParserAstVisitor v) => v.visitExpressionStatementHandle(this); } -class FactoryMethodBegin extends ParserAstNode { +class FactoryBegin extends ParserAstNode { final DeclarationKind declarationKind; final Token lastConsumed; final Token? externalToken; final Token? constToken; - FactoryMethodBegin( + FactoryBegin( ParserAstType type, { required this.declarationKind, required this.lastConsumed, this.externalToken, this.constToken, - }) : super("FactoryMethod", type); + }) : super("Factory", type); @override Map get deprecatedArguments => { @@ -5683,112 +5316,36 @@ class FactoryMethodBegin extends ParserAstNode { }; @override - R accept(ParserAstVisitor v) => v.visitFactoryMethodBegin(this); + R accept(ParserAstVisitor v) => v.visitFactoryBegin(this); } -class ClassFactoryMethodEnd extends ParserAstNode +class FactoryEnd extends ParserAstNode implements BeginAndEndTokenParserAstNode { + final DeclarationKind kind; @override final Token beginToken; final Token factoryKeyword; @override final Token endToken; - ClassFactoryMethodEnd( + FactoryEnd( ParserAstType type, { + required this.kind, required this.beginToken, required this.factoryKeyword, required this.endToken, - }) : super("ClassFactoryMethod", type); + }) : super("Factory", type); @override Map get deprecatedArguments => { + "kind": kind, "beginToken": beginToken, "factoryKeyword": factoryKeyword, "endToken": endToken, }; @override - R accept(ParserAstVisitor v) => v.visitClassFactoryMethodEnd(this); -} - -class MixinFactoryMethodEnd extends ParserAstNode - implements BeginAndEndTokenParserAstNode { - @override - final Token beginToken; - final Token factoryKeyword; - @override - final Token endToken; - - MixinFactoryMethodEnd( - ParserAstType type, { - required this.beginToken, - required this.factoryKeyword, - required this.endToken, - }) : super("MixinFactoryMethod", type); - - @override - Map get deprecatedArguments => { - "beginToken": beginToken, - "factoryKeyword": factoryKeyword, - "endToken": endToken, - }; - - @override - R accept(ParserAstVisitor v) => v.visitMixinFactoryMethodEnd(this); -} - -class ExtensionFactoryMethodEnd extends ParserAstNode - implements BeginAndEndTokenParserAstNode { - @override - final Token beginToken; - final Token factoryKeyword; - @override - final Token endToken; - - ExtensionFactoryMethodEnd( - ParserAstType type, { - required this.beginToken, - required this.factoryKeyword, - required this.endToken, - }) : super("ExtensionFactoryMethod", type); - - @override - Map get deprecatedArguments => { - "beginToken": beginToken, - "factoryKeyword": factoryKeyword, - "endToken": endToken, - }; - - @override - R accept(ParserAstVisitor v) => v.visitExtensionFactoryMethodEnd(this); -} - -class ExtensionTypeFactoryMethodEnd extends ParserAstNode - implements BeginAndEndTokenParserAstNode { - @override - final Token beginToken; - final Token factoryKeyword; - @override - final Token endToken; - - ExtensionTypeFactoryMethodEnd( - ParserAstType type, { - required this.beginToken, - required this.factoryKeyword, - required this.endToken, - }) : super("ExtensionTypeFactoryMethod", type); - - @override - Map get deprecatedArguments => { - "beginToken": beginToken, - "factoryKeyword": factoryKeyword, - "endToken": endToken, - }; - - @override - R accept(ParserAstVisitor v) => - v.visitExtensionTypeFactoryMethodEnd(this); + R accept(ParserAstVisitor v) => v.visitFactoryEnd(this); } class FormalParameterBegin extends ParserAstNode { @@ -5930,8 +5487,8 @@ class FormalParametersEnd extends ParserAstNode R accept(ParserAstVisitor v) => v.visitFormalParametersEnd(this); } -class ClassFieldsEnd extends ParserAstNode - implements BeginAndEndTokenParserAstNode { +class FieldsEnd extends ParserAstNode implements BeginAndEndTokenParserAstNode { + final DeclarationKind kind; final Token? abstractToken; final Token? augmentToken; final Token? externalToken; @@ -5945,8 +5502,9 @@ class ClassFieldsEnd extends ParserAstNode @override final Token endToken; - ClassFieldsEnd( + FieldsEnd( ParserAstType type, { + required this.kind, this.abstractToken, this.augmentToken, this.externalToken, @@ -5957,10 +5515,11 @@ class ClassFieldsEnd extends ParserAstNode required this.count, required this.beginToken, required this.endToken, - }) : super("ClassFields", type); + }) : super("Fields", type); @override Map get deprecatedArguments => { + "kind": kind, "abstractToken": abstractToken, "augmentToken": augmentToken, "externalToken": externalToken, @@ -5974,227 +5533,7 @@ class ClassFieldsEnd extends ParserAstNode }; @override - R accept(ParserAstVisitor v) => v.visitClassFieldsEnd(this); -} - -class MixinFieldsEnd extends ParserAstNode - implements BeginAndEndTokenParserAstNode { - final Token? abstractToken; - final Token? augmentToken; - final Token? externalToken; - final Token? staticToken; - final Token? covariantToken; - final Token? lateToken; - final Token? varFinalOrConst; - final int count; - @override - final Token beginToken; - @override - final Token endToken; - - MixinFieldsEnd( - ParserAstType type, { - this.abstractToken, - this.augmentToken, - this.externalToken, - this.staticToken, - this.covariantToken, - this.lateToken, - this.varFinalOrConst, - required this.count, - required this.beginToken, - required this.endToken, - }) : super("MixinFields", type); - - @override - Map get deprecatedArguments => { - "abstractToken": abstractToken, - "augmentToken": augmentToken, - "externalToken": externalToken, - "staticToken": staticToken, - "covariantToken": covariantToken, - "lateToken": lateToken, - "varFinalOrConst": varFinalOrConst, - "count": count, - "beginToken": beginToken, - "endToken": endToken, - }; - - @override - R accept(ParserAstVisitor v) => v.visitMixinFieldsEnd(this); -} - -class ExtensionFieldsEnd extends ParserAstNode - implements BeginAndEndTokenParserAstNode { - final Token? abstractToken; - final Token? augmentToken; - final Token? externalToken; - final Token? staticToken; - final Token? covariantToken; - final Token? lateToken; - final Token? varFinalOrConst; - final int count; - @override - final Token beginToken; - @override - final Token endToken; - - ExtensionFieldsEnd( - ParserAstType type, { - this.abstractToken, - this.augmentToken, - this.externalToken, - this.staticToken, - this.covariantToken, - this.lateToken, - this.varFinalOrConst, - required this.count, - required this.beginToken, - required this.endToken, - }) : super("ExtensionFields", type); - - @override - Map get deprecatedArguments => { - "abstractToken": abstractToken, - "augmentToken": augmentToken, - "externalToken": externalToken, - "staticToken": staticToken, - "covariantToken": covariantToken, - "lateToken": lateToken, - "varFinalOrConst": varFinalOrConst, - "count": count, - "beginToken": beginToken, - "endToken": endToken, - }; - - @override - R accept(ParserAstVisitor v) => v.visitExtensionFieldsEnd(this); -} - -class ExtensionTypeFieldsEnd extends ParserAstNode - implements BeginAndEndTokenParserAstNode { - final Token? abstractToken; - final Token? augmentToken; - final Token? externalToken; - final Token? staticToken; - final Token? covariantToken; - final Token? lateToken; - final Token? varFinalOrConst; - final int count; - @override - final Token beginToken; - @override - final Token endToken; - - ExtensionTypeFieldsEnd( - ParserAstType type, { - this.abstractToken, - this.augmentToken, - this.externalToken, - this.staticToken, - this.covariantToken, - this.lateToken, - this.varFinalOrConst, - required this.count, - required this.beginToken, - required this.endToken, - }) : super("ExtensionTypeFields", type); - - @override - Map get deprecatedArguments => { - "abstractToken": abstractToken, - "augmentToken": augmentToken, - "externalToken": externalToken, - "staticToken": staticToken, - "covariantToken": covariantToken, - "lateToken": lateToken, - "varFinalOrConst": varFinalOrConst, - "count": count, - "beginToken": beginToken, - "endToken": endToken, - }; - - @override - R accept(ParserAstVisitor v) => v.visitExtensionTypeFieldsEnd(this); -} - -class EnumFieldsEnd extends ParserAstNode - implements BeginAndEndTokenParserAstNode { - final Token? abstractToken; - final Token? augmentToken; - final Token? externalToken; - final Token? staticToken; - final Token? covariantToken; - final Token? lateToken; - final Token? varFinalOrConst; - final int count; - @override - final Token beginToken; - @override - final Token endToken; - - EnumFieldsEnd( - ParserAstType type, { - this.abstractToken, - this.augmentToken, - this.externalToken, - this.staticToken, - this.covariantToken, - this.lateToken, - this.varFinalOrConst, - required this.count, - required this.beginToken, - required this.endToken, - }) : super("EnumFields", type); - - @override - Map get deprecatedArguments => { - "abstractToken": abstractToken, - "augmentToken": augmentToken, - "externalToken": externalToken, - "staticToken": staticToken, - "covariantToken": covariantToken, - "lateToken": lateToken, - "varFinalOrConst": varFinalOrConst, - "count": count, - "beginToken": beginToken, - "endToken": endToken, - }; - - @override - R accept(ParserAstVisitor v) => v.visitEnumFieldsEnd(this); -} - -class EnumMethodEnd extends ParserAstNode - implements BeginAndEndTokenParserAstNode { - final Token? getOrSet; - @override - final Token beginToken; - final Token beginParam; - final Token? beginInitializers; - @override - final Token endToken; - - EnumMethodEnd( - ParserAstType type, { - this.getOrSet, - required this.beginToken, - required this.beginParam, - this.beginInitializers, - required this.endToken, - }) : super("EnumMethod", type); - - @override - Map get deprecatedArguments => { - "getOrSet": getOrSet, - "beginToken": beginToken, - "beginParam": beginParam, - "beginInitializers": beginInitializers, - "endToken": endToken, - }; - - @override - R accept(ParserAstVisitor v) => v.visitEnumMethodEnd(this); + R accept(ParserAstVisitor v) => v.visitFieldsEnd(this); } class ForInitializerEmptyStatementHandle extends ParserAstNode { @@ -7704,8 +7043,8 @@ class MethodBegin extends ParserAstNode { R accept(ParserAstVisitor v) => v.visitMethodBegin(this); } -class ClassMethodEnd extends ParserAstNode - implements BeginAndEndTokenParserAstNode { +class MethodEnd extends ParserAstNode implements BeginAndEndTokenParserAstNode { + final DeclarationKind kind; final Token? getOrSet; @override final Token beginToken; @@ -7714,17 +7053,19 @@ class ClassMethodEnd extends ParserAstNode @override final Token endToken; - ClassMethodEnd( + MethodEnd( ParserAstType type, { + required this.kind, this.getOrSet, required this.beginToken, required this.beginParam, this.beginInitializers, required this.endToken, - }) : super("ClassMethod", type); + }) : super("Method", type); @override Map get deprecatedArguments => { + "kind": kind, "getOrSet": getOrSet, "beginToken": beginToken, "beginParam": beginParam, @@ -7733,12 +7074,12 @@ class ClassMethodEnd extends ParserAstNode }; @override - R accept(ParserAstVisitor v) => v.visitClassMethodEnd(this); + R accept(ParserAstVisitor v) => v.visitMethodEnd(this); } -class MixinMethodEnd extends ParserAstNode +class ConstructorEnd extends ParserAstNode implements BeginAndEndTokenParserAstNode { - final Token? getOrSet; + final DeclarationKind kind; @override final Token beginToken; final Token beginParam; @@ -7746,18 +7087,18 @@ class MixinMethodEnd extends ParserAstNode @override final Token endToken; - MixinMethodEnd( + ConstructorEnd( ParserAstType type, { - this.getOrSet, + required this.kind, required this.beginToken, required this.beginParam, this.beginInitializers, required this.endToken, - }) : super("MixinMethod", type); + }) : super("Constructor", type); @override Map get deprecatedArguments => { - "getOrSet": getOrSet, + "kind": kind, "beginToken": beginToken, "beginParam": beginParam, "beginInitializers": beginInitializers, @@ -7765,188 +7106,7 @@ class MixinMethodEnd extends ParserAstNode }; @override - R accept(ParserAstVisitor v) => v.visitMixinMethodEnd(this); -} - -class ExtensionMethodEnd extends ParserAstNode - implements BeginAndEndTokenParserAstNode { - final Token? getOrSet; - @override - final Token beginToken; - final Token beginParam; - final Token? beginInitializers; - @override - final Token endToken; - - ExtensionMethodEnd( - ParserAstType type, { - this.getOrSet, - required this.beginToken, - required this.beginParam, - this.beginInitializers, - required this.endToken, - }) : super("ExtensionMethod", type); - - @override - Map get deprecatedArguments => { - "getOrSet": getOrSet, - "beginToken": beginToken, - "beginParam": beginParam, - "beginInitializers": beginInitializers, - "endToken": endToken, - }; - - @override - R accept(ParserAstVisitor v) => v.visitExtensionMethodEnd(this); -} - -class ExtensionTypeMethodEnd extends ParserAstNode - implements BeginAndEndTokenParserAstNode { - final Token? getOrSet; - @override - final Token beginToken; - final Token beginParam; - final Token? beginInitializers; - @override - final Token endToken; - - ExtensionTypeMethodEnd( - ParserAstType type, { - this.getOrSet, - required this.beginToken, - required this.beginParam, - this.beginInitializers, - required this.endToken, - }) : super("ExtensionTypeMethod", type); - - @override - Map get deprecatedArguments => { - "getOrSet": getOrSet, - "beginToken": beginToken, - "beginParam": beginParam, - "beginInitializers": beginInitializers, - "endToken": endToken, - }; - - @override - R accept(ParserAstVisitor v) => v.visitExtensionTypeMethodEnd(this); -} - -class ClassConstructorEnd extends ParserAstNode - implements BeginAndEndTokenParserAstNode { - @override - final Token beginToken; - final Token beginParam; - final Token? beginInitializers; - @override - final Token endToken; - - ClassConstructorEnd( - ParserAstType type, { - required this.beginToken, - required this.beginParam, - this.beginInitializers, - required this.endToken, - }) : super("ClassConstructor", type); - - @override - Map get deprecatedArguments => { - "beginToken": beginToken, - "beginParam": beginParam, - "beginInitializers": beginInitializers, - "endToken": endToken, - }; - - @override - R accept(ParserAstVisitor v) => v.visitClassConstructorEnd(this); -} - -class MixinConstructorEnd extends ParserAstNode - implements BeginAndEndTokenParserAstNode { - @override - final Token beginToken; - final Token beginParam; - final Token? beginInitializers; - @override - final Token endToken; - - MixinConstructorEnd( - ParserAstType type, { - required this.beginToken, - required this.beginParam, - this.beginInitializers, - required this.endToken, - }) : super("MixinConstructor", type); - - @override - Map get deprecatedArguments => { - "beginToken": beginToken, - "beginParam": beginParam, - "beginInitializers": beginInitializers, - "endToken": endToken, - }; - - @override - R accept(ParserAstVisitor v) => v.visitMixinConstructorEnd(this); -} - -class ExtensionConstructorEnd extends ParserAstNode - implements BeginAndEndTokenParserAstNode { - @override - final Token beginToken; - final Token beginParam; - final Token? beginInitializers; - @override - final Token endToken; - - ExtensionConstructorEnd( - ParserAstType type, { - required this.beginToken, - required this.beginParam, - this.beginInitializers, - required this.endToken, - }) : super("ExtensionConstructor", type); - - @override - Map get deprecatedArguments => { - "beginToken": beginToken, - "beginParam": beginParam, - "beginInitializers": beginInitializers, - "endToken": endToken, - }; - - @override - R accept(ParserAstVisitor v) => v.visitExtensionConstructorEnd(this); -} - -class ExtensionTypeConstructorEnd extends ParserAstNode - implements BeginAndEndTokenParserAstNode { - @override - final Token beginToken; - final Token beginParam; - final Token? beginInitializers; - @override - final Token endToken; - - ExtensionTypeConstructorEnd( - ParserAstType type, { - required this.beginToken, - required this.beginParam, - this.beginInitializers, - required this.endToken, - }) : super("ExtensionTypeConstructor", type); - - @override - Map get deprecatedArguments => { - "beginToken": beginToken, - "beginParam": beginParam, - "beginInitializers": beginInitializers, - "endToken": endToken, - }; - - @override - R accept(ParserAstVisitor v) => - v.visitExtensionTypeConstructorEnd(this); + R accept(ParserAstVisitor v) => v.visitConstructorEnd(this); } class MetadataStarBegin extends ParserAstNode { @@ -11438,33 +10598,23 @@ abstract class ParserAstVisitor { R visitEnumDeclarationPreludeBegin(EnumDeclarationPreludeBegin node); R visitEnumDeclarationBegin(EnumDeclarationBegin node); R visitEnumDeclarationEnd(EnumDeclarationEnd node); - R visitEnumConstructorEnd(EnumConstructorEnd node); R visitEnumElementsHandle(EnumElementsHandle node); R visitEnumHeaderHandle(EnumHeaderHandle node); R visitEnumBodyBegin(EnumBodyBegin node); R visitEnumBodyEnd(EnumBodyEnd node); R visitEnumElementHandle(EnumElementHandle node); - R visitEnumFactoryMethodEnd(EnumFactoryMethodEnd node); R visitExportBegin(ExportBegin node); R visitExportEnd(ExportEnd node); R visitExtraneousExpressionHandle(ExtraneousExpressionHandle node); R visitExpressionStatementHandle(ExpressionStatementHandle node); - R visitFactoryMethodBegin(FactoryMethodBegin node); - R visitClassFactoryMethodEnd(ClassFactoryMethodEnd node); - R visitMixinFactoryMethodEnd(MixinFactoryMethodEnd node); - R visitExtensionFactoryMethodEnd(ExtensionFactoryMethodEnd node); - R visitExtensionTypeFactoryMethodEnd(ExtensionTypeFactoryMethodEnd node); + R visitFactoryBegin(FactoryBegin node); + R visitFactoryEnd(FactoryEnd node); R visitFormalParameterBegin(FormalParameterBegin node); R visitFormalParameterEnd(FormalParameterEnd node); R visitNoFormalParametersHandle(NoFormalParametersHandle node); R visitFormalParametersBegin(FormalParametersBegin node); R visitFormalParametersEnd(FormalParametersEnd node); - R visitClassFieldsEnd(ClassFieldsEnd node); - R visitMixinFieldsEnd(MixinFieldsEnd node); - R visitExtensionFieldsEnd(ExtensionFieldsEnd node); - R visitExtensionTypeFieldsEnd(ExtensionTypeFieldsEnd node); - R visitEnumFieldsEnd(EnumFieldsEnd node); - R visitEnumMethodEnd(EnumMethodEnd node); + R visitFieldsEnd(FieldsEnd node); R visitForInitializerEmptyStatementHandle( ForInitializerEmptyStatementHandle node, ); @@ -11565,14 +10715,8 @@ abstract class ParserAstVisitor { R visitInvalidMemberHandle(InvalidMemberHandle node); R visitMemberEnd(MemberEnd node); R visitMethodBegin(MethodBegin node); - R visitClassMethodEnd(ClassMethodEnd node); - R visitMixinMethodEnd(MixinMethodEnd node); - R visitExtensionMethodEnd(ExtensionMethodEnd node); - R visitExtensionTypeMethodEnd(ExtensionTypeMethodEnd node); - R visitClassConstructorEnd(ClassConstructorEnd node); - R visitMixinConstructorEnd(MixinConstructorEnd node); - R visitExtensionConstructorEnd(ExtensionConstructorEnd node); - R visitExtensionTypeConstructorEnd(ExtensionTypeConstructorEnd node); + R visitMethodEnd(MethodEnd node); + R visitConstructorEnd(ConstructorEnd node); R visitMetadataStarBegin(MetadataStarBegin node); R visitMetadataStarEnd(MetadataStarEnd node); R visitMetadataBegin(MetadataBegin node); @@ -12035,10 +11179,6 @@ class RecursiveParserAstVisitor implements ParserAstVisitor { void visitEnumDeclarationEnd(EnumDeclarationEnd node) => node.visitChildren(this); - @override - void visitEnumConstructorEnd(EnumConstructorEnd node) => - node.visitChildren(this); - @override void visitEnumElementsHandle(EnumElementsHandle node) => node.visitChildren(this); @@ -12056,10 +11196,6 @@ class RecursiveParserAstVisitor implements ParserAstVisitor { void visitEnumElementHandle(EnumElementHandle node) => node.visitChildren(this); - @override - void visitEnumFactoryMethodEnd(EnumFactoryMethodEnd node) => - node.visitChildren(this); - @override void visitExportBegin(ExportBegin node) => node.visitChildren(this); @@ -12075,24 +11211,10 @@ class RecursiveParserAstVisitor implements ParserAstVisitor { node.visitChildren(this); @override - void visitFactoryMethodBegin(FactoryMethodBegin node) => - node.visitChildren(this); + void visitFactoryBegin(FactoryBegin node) => node.visitChildren(this); @override - void visitClassFactoryMethodEnd(ClassFactoryMethodEnd node) => - node.visitChildren(this); - - @override - void visitMixinFactoryMethodEnd(MixinFactoryMethodEnd node) => - node.visitChildren(this); - - @override - void visitExtensionFactoryMethodEnd(ExtensionFactoryMethodEnd node) => - node.visitChildren(this); - - @override - void visitExtensionTypeFactoryMethodEnd(ExtensionTypeFactoryMethodEnd node) => - node.visitChildren(this); + void visitFactoryEnd(FactoryEnd node) => node.visitChildren(this); @override void visitFormalParameterBegin(FormalParameterBegin node) => @@ -12115,24 +11237,7 @@ class RecursiveParserAstVisitor implements ParserAstVisitor { node.visitChildren(this); @override - void visitClassFieldsEnd(ClassFieldsEnd node) => node.visitChildren(this); - - @override - void visitMixinFieldsEnd(MixinFieldsEnd node) => node.visitChildren(this); - - @override - void visitExtensionFieldsEnd(ExtensionFieldsEnd node) => - node.visitChildren(this); - - @override - void visitExtensionTypeFieldsEnd(ExtensionTypeFieldsEnd node) => - node.visitChildren(this); - - @override - void visitEnumFieldsEnd(EnumFieldsEnd node) => node.visitChildren(this); - - @override - void visitEnumMethodEnd(EnumMethodEnd node) => node.visitChildren(this); + void visitFieldsEnd(FieldsEnd node) => node.visitChildren(this); @override void visitForInitializerEmptyStatementHandle( @@ -12473,34 +11578,10 @@ class RecursiveParserAstVisitor implements ParserAstVisitor { void visitMethodBegin(MethodBegin node) => node.visitChildren(this); @override - void visitClassMethodEnd(ClassMethodEnd node) => node.visitChildren(this); + void visitMethodEnd(MethodEnd node) => node.visitChildren(this); @override - void visitMixinMethodEnd(MixinMethodEnd node) => node.visitChildren(this); - - @override - void visitExtensionMethodEnd(ExtensionMethodEnd node) => - node.visitChildren(this); - - @override - void visitExtensionTypeMethodEnd(ExtensionTypeMethodEnd node) => - node.visitChildren(this); - - @override - void visitClassConstructorEnd(ClassConstructorEnd node) => - node.visitChildren(this); - - @override - void visitMixinConstructorEnd(MixinConstructorEnd node) => - node.visitChildren(this); - - @override - void visitExtensionConstructorEnd(ExtensionConstructorEnd node) => - node.visitChildren(this); - - @override - void visitExtensionTypeConstructorEnd(ExtensionTypeConstructorEnd node) => - node.visitChildren(this); + void visitConstructorEnd(ConstructorEnd node) => node.visitChildren(this); @override void visitMetadataStarBegin(MetadataStarBegin node) => @@ -13513,10 +12594,6 @@ class RecursiveParserAstVisitorWithDefaultNodeAsync Future visitEnumDeclarationEnd(EnumDeclarationEnd node) => defaultNode(node); - @override - Future visitEnumConstructorEnd(EnumConstructorEnd node) => - defaultNode(node); - @override Future visitEnumElementsHandle(EnumElementsHandle node) => defaultNode(node); @@ -13535,10 +12612,6 @@ class RecursiveParserAstVisitorWithDefaultNodeAsync Future visitEnumElementHandle(EnumElementHandle node) => defaultNode(node); - @override - Future visitEnumFactoryMethodEnd(EnumFactoryMethodEnd node) => - defaultNode(node); - @override Future visitExportBegin(ExportBegin node) => defaultNode(node); @@ -13555,25 +12628,10 @@ class RecursiveParserAstVisitorWithDefaultNodeAsync defaultNode(node); @override - Future visitFactoryMethodBegin(FactoryMethodBegin node) => - defaultNode(node); + Future visitFactoryBegin(FactoryBegin node) => defaultNode(node); @override - Future visitClassFactoryMethodEnd(ClassFactoryMethodEnd node) => - defaultNode(node); - - @override - Future visitMixinFactoryMethodEnd(MixinFactoryMethodEnd node) => - defaultNode(node); - - @override - Future visitExtensionFactoryMethodEnd(ExtensionFactoryMethodEnd node) => - defaultNode(node); - - @override - Future visitExtensionTypeFactoryMethodEnd( - ExtensionTypeFactoryMethodEnd node, - ) => defaultNode(node); + Future visitFactoryEnd(FactoryEnd node) => defaultNode(node); @override Future visitFormalParameterBegin(FormalParameterBegin node) => @@ -13596,24 +12654,7 @@ class RecursiveParserAstVisitorWithDefaultNodeAsync defaultNode(node); @override - Future visitClassFieldsEnd(ClassFieldsEnd node) => defaultNode(node); - - @override - Future visitMixinFieldsEnd(MixinFieldsEnd node) => defaultNode(node); - - @override - Future visitExtensionFieldsEnd(ExtensionFieldsEnd node) => - defaultNode(node); - - @override - Future visitExtensionTypeFieldsEnd(ExtensionTypeFieldsEnd node) => - defaultNode(node); - - @override - Future visitEnumFieldsEnd(EnumFieldsEnd node) => defaultNode(node); - - @override - Future visitEnumMethodEnd(EnumMethodEnd node) => defaultNode(node); + Future visitFieldsEnd(FieldsEnd node) => defaultNode(node); @override Future visitForInitializerEmptyStatementHandle( @@ -13972,35 +13013,10 @@ class RecursiveParserAstVisitorWithDefaultNodeAsync Future visitMethodBegin(MethodBegin node) => defaultNode(node); @override - Future visitClassMethodEnd(ClassMethodEnd node) => defaultNode(node); + Future visitMethodEnd(MethodEnd node) => defaultNode(node); @override - Future visitMixinMethodEnd(MixinMethodEnd node) => defaultNode(node); - - @override - Future visitExtensionMethodEnd(ExtensionMethodEnd node) => - defaultNode(node); - - @override - Future visitExtensionTypeMethodEnd(ExtensionTypeMethodEnd node) => - defaultNode(node); - - @override - Future visitClassConstructorEnd(ClassConstructorEnd node) => - defaultNode(node); - - @override - Future visitMixinConstructorEnd(MixinConstructorEnd node) => - defaultNode(node); - - @override - Future visitExtensionConstructorEnd(ExtensionConstructorEnd node) => - defaultNode(node); - - @override - Future visitExtensionTypeConstructorEnd( - ExtensionTypeConstructorEnd node, - ) => defaultNode(node); + Future visitConstructorEnd(ConstructorEnd node) => defaultNode(node); @override Future visitMetadataStarBegin(MetadataStarBegin node) => diff --git a/pkg/front_end/lib/src/util/textual_outline.dart b/pkg/front_end/lib/src/util/textual_outline.dart index d8ffa9bd2f4..9394c71057b 100644 --- a/pkg/front_end/lib/src/util/textual_outline.dart +++ b/pkg/front_end/lib/src/util/textual_outline.dart @@ -9,6 +9,8 @@ import 'package:_fe_analyzer_shared/src/parser/experimental_features.dart' show ExperimentalFeatures, DefaultExperimentalFeatures; import 'package:_fe_analyzer_shared/src/parser/class_member_parser.dart' show ClassMemberParser; +import 'package:_fe_analyzer_shared/src/parser/declaration_kind.dart' + show DeclarationKind; import 'package:_fe_analyzer_shared/src/parser/identifier_context.dart'; import 'package:_fe_analyzer_shared/src/parser/listener.dart'; import 'package:_fe_analyzer_shared/src/scanner/abstract_scanner.dart' @@ -827,7 +829,8 @@ class TextualOutlineListener extends Listener { } @override - void endClassConstructor( + void endConstructor( + DeclarationKind kind, Token beginToken, Token beginParam, Token? beginInitializers, @@ -840,117 +843,8 @@ class TextualOutlineListener extends Listener { } @override - // Coverage-ignore(suite): Not run. - void endMixinConstructor( - Token beginToken, - Token beginParam, - Token? beginInitializers, - Token endToken, - ) { - elementStartToChunk[beginToken] = new _ClassMethodChunk( - beginToken, - endToken, - ); - } - - @override - void endEnumConstructor( - Token beginToken, - Token beginParam, - Token? beginInitializers, - Token endToken, - ) { - elementStartToChunk[beginToken] = new _ClassMethodChunk( - beginToken, - endToken, - ); - } - - @override - // Coverage-ignore(suite): Not run. - void endExtensionConstructor( - Token beginToken, - Token beginParam, - Token? beginInitializers, - Token endToken, - ) { - elementStartToChunk[beginToken] = new _ClassMethodChunk( - beginToken, - endToken, - ); - } - - @override - void endExtensionTypeConstructor( - Token beginToken, - Token beginParam, - Token? beginInitializers, - Token endToken, - ) { - elementStartToChunk[beginToken] = new _ClassMethodChunk( - beginToken, - endToken, - ); - } - - @override - void endClassMethod( - Token? getOrSet, - Token beginToken, - Token beginParam, - Token? beginInitializers, - Token endToken, - ) { - elementStartToChunk[beginToken] = new _ClassMethodChunk( - beginToken, - endToken, - ); - } - - @override - void endMixinMethod( - Token? getOrSet, - Token beginToken, - Token beginParam, - Token? beginInitializers, - Token endToken, - ) { - elementStartToChunk[beginToken] = new _ClassMethodChunk( - beginToken, - endToken, - ); - } - - @override - void endEnumMethod( - Token? getOrSet, - Token beginToken, - Token beginParam, - Token? beginInitializers, - Token endToken, - ) { - elementStartToChunk[beginToken] = new _ClassMethodChunk( - beginToken, - endToken, - ); - } - - @override - void endExtensionMethod( - Token? getOrSet, - Token beginToken, - Token beginParam, - Token? beginInitializers, - Token endToken, - ) { - elementStartToChunk[beginToken] = new _ClassMethodChunk( - beginToken, - endToken, - ); - } - - @override - void endExtensionTypeMethod( + void endMethod( + DeclarationKind kind, Token? getOrSet, Token beginToken, Token beginParam, @@ -972,57 +866,8 @@ class TextualOutlineListener extends Listener { } @override - void endClassFactoryMethod( - Token beginToken, - Token factoryKeyword, - Token endToken, - ) { - elementStartToChunk[beginToken] = new _ClassFactoryMethodChunk( - beginToken, - endToken, - ); - } - - @override - // Coverage-ignore(suite): Not run. - void endMixinFactoryMethod( - Token beginToken, - Token factoryKeyword, - Token endToken, - ) { - elementStartToChunk[beginToken] = new _ClassFactoryMethodChunk( - beginToken, - endToken, - ); - } - - @override - void endEnumFactoryMethod( - Token beginToken, - Token factoryKeyword, - Token endToken, - ) { - elementStartToChunk[beginToken] = new _ClassFactoryMethodChunk( - beginToken, - endToken, - ); - } - - @override - // Coverage-ignore(suite): Not run. - void endExtensionFactoryMethod( - Token beginToken, - Token factoryKeyword, - Token endToken, - ) { - elementStartToChunk[beginToken] = new _ClassFactoryMethodChunk( - beginToken, - endToken, - ); - } - - @override - void endExtensionTypeFactoryMethod( + void endFactory( + DeclarationKind kind, Token beginToken, Token factoryKeyword, Token endToken, @@ -1039,83 +884,8 @@ class TextualOutlineListener extends Listener { } @override - void endClassFields( - Token? abstractToken, - Token? augmentToken, - Token? externalToken, - Token? staticToken, - Token? covariantToken, - Token? lateToken, - Token? varFinalOrConst, - int count, - Token beginToken, - Token endToken, - ) { - elementStartToChunk[beginToken] = new _ClassFieldsChunk( - beginToken, - endToken, - ); - } - - @override - void endMixinFields( - Token? abstractToken, - Token? augmentToken, - Token? externalToken, - Token? staticToken, - Token? covariantToken, - Token? lateToken, - Token? varFinalOrConst, - int count, - Token beginToken, - Token endToken, - ) { - elementStartToChunk[beginToken] = new _ClassFieldsChunk( - beginToken, - endToken, - ); - } - - @override - void endEnumFields( - Token? abstractToken, - Token? augmentToken, - Token? externalToken, - Token? staticToken, - Token? covariantToken, - Token? lateToken, - Token? varFinalOrConst, - int count, - Token beginToken, - Token endToken, - ) { - elementStartToChunk[beginToken] = new _ClassFieldsChunk( - beginToken, - endToken, - ); - } - - @override - void endExtensionFields( - Token? abstractToken, - Token? augmentToken, - Token? externalToken, - Token? staticToken, - Token? covariantToken, - Token? lateToken, - Token? varFinalOrConst, - int count, - Token beginToken, - Token endToken, - ) { - elementStartToChunk[beginToken] = new _ClassFieldsChunk( - beginToken, - endToken, - ); - } - - @override - void endExtensionTypeFields( + void endFields( + DeclarationKind kind, Token? abstractToken, Token? augmentToken, Token? externalToken, diff --git a/pkg/front_end/parser_testcases/also-nnbd/issue_40288.dart.expect b/pkg/front_end/parser_testcases/also-nnbd/issue_40288.dart.expect index 4f7ba897d07..efbe4ef3562 100644 --- a/pkg/front_end/parser_testcases/also-nnbd/issue_40288.dart.expect +++ b/pkg/front_end/parser_testcases/also-nnbd/issue_40288.dart.expect @@ -49,7 +49,7 @@ beginCompilationUnit(class) handleAsyncModifier(null, null) handleLiteralInt(1) handleExpressionFunctionBody(=>, ;) - endClassMethod(get, int, =>, null, ;) + endMethod(DeclarationKind.Class, get, int, =>, null, ;) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 1, {, }) endClassDeclaration(class, }) @@ -82,7 +82,7 @@ beginCompilationUnit(class) handleAsyncModifier(null, null) handleLiteralInt(2) handleExpressionFunctionBody(=>, ;) - endClassMethod(get, int, =>, null, ;) + endMethod(DeclarationKind.Class, get, int, =>, null, ;) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 1, {, }) endClassDeclaration(class, }) @@ -114,7 +114,7 @@ beginCompilationUnit(class) endArguments(0, (, )) handleSend(late, )) endFieldInitializer(=, )) - endClassFields(null, null, null, null, null, late, null, 1, late, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, late, null, 1, late, ;) endMember() beginMetadataStar(required) endMetadataStar(0) @@ -131,7 +131,7 @@ beginCompilationUnit(class) endArguments(0, (, )) handleSend(required, )) endFieldInitializer(=, )) - endClassFields(null, null, null, null, null, null, null, 1, required, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, required, ;) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 2, {, }) endClassDeclaration(class, }) diff --git a/pkg/front_end/parser_testcases/also-nnbd/issue_40288.dart.intertwined.expect b/pkg/front_end/parser_testcases/also-nnbd/issue_40288.dart.intertwined.expect index a189dab8a0e..d456b7a0fbe 100644 --- a/pkg/front_end/parser_testcases/also-nnbd/issue_40288.dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/also-nnbd/issue_40288.dart.intertwined.expect @@ -66,7 +66,7 @@ parseUnit(class) ensureSemicolon(1) listener: handleExpressionFunctionBody(=>, ;) inGenerator() - listener: endClassMethod(get, int, =>, null, ;) + listener: endMethod(DeclarationKind.Class, get, int, =>, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 1, {, }) @@ -136,7 +136,7 @@ parseUnit(class) ensureSemicolon(2) listener: handleExpressionFunctionBody(=>, ;) inGenerator() - listener: endClassMethod(get, int, =>, null, ;) + listener: endMethod(DeclarationKind.Class, get, int, =>, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 1, {, }) @@ -205,7 +205,7 @@ parseUnit(class) listener: endArguments(0, (, )) listener: handleSend(late, )) listener: endFieldInitializer(=, )) - listener: endClassFields(null, null, null, null, null, late, null, 1, late, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, late, null, 1, late, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, required) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, C) @@ -247,7 +247,7 @@ parseUnit(class) listener: endArguments(0, (, )) listener: handleSend(required, )) listener: endFieldInitializer(=, )) - listener: endClassFields(null, null, null, null, null, null, null, 1, required, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, required, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 2, {, }) diff --git a/pkg/front_end/parser_testcases/also-nnbd/issue_40288_prime.dart.expect b/pkg/front_end/parser_testcases/also-nnbd/issue_40288_prime.dart.expect index e160163ef79..9d3c754304e 100644 --- a/pkg/front_end/parser_testcases/also-nnbd/issue_40288_prime.dart.expect +++ b/pkg/front_end/parser_testcases/also-nnbd/issue_40288_prime.dart.expect @@ -26,7 +26,7 @@ beginCompilationUnit(class) handleAsyncModifier(null, null) handleLiteralInt(1) handleExpressionFunctionBody(=>, ;) - endClassMethod(get, int, =>, null, ;) + endMethod(DeclarationKind.Class, get, int, =>, null, ;) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 1, {, }) endClassDeclaration(class, }) @@ -58,7 +58,7 @@ beginCompilationUnit(class) handleAsyncModifier(null, null) handleLiteralInt(2) handleExpressionFunctionBody(=>, ;) - endClassMethod(get, int, =>, null, ;) + endMethod(DeclarationKind.Class, get, int, =>, null, ;) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 1, {, }) endClassDeclaration(class, }) @@ -91,7 +91,7 @@ beginCompilationUnit(class) endArguments(0, (, )) handleSend(Xlate, )) endFieldInitializer(=, )) - endClassFields(null, null, null, null, null, null, null, 1, Xlate, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, Xlate, ;) endMember() beginMetadataStar(Xrequired) endMetadataStar(0) @@ -108,7 +108,7 @@ beginCompilationUnit(class) endArguments(0, (, )) handleSend(Xrequired, )) endFieldInitializer(=, )) - endClassFields(null, null, null, null, null, null, null, 1, Xrequired, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, Xrequired, ;) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 2, {, }) endClassDeclaration(class, }) diff --git a/pkg/front_end/parser_testcases/also-nnbd/issue_40288_prime.dart.intertwined.expect b/pkg/front_end/parser_testcases/also-nnbd/issue_40288_prime.dart.intertwined.expect index 176099578b9..e2cba3d87f6 100644 --- a/pkg/front_end/parser_testcases/also-nnbd/issue_40288_prime.dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/also-nnbd/issue_40288_prime.dart.intertwined.expect @@ -64,7 +64,7 @@ parseUnit(class) ensureSemicolon(1) listener: handleExpressionFunctionBody(=>, ;) inGenerator() - listener: endClassMethod(get, int, =>, null, ;) + listener: endMethod(DeclarationKind.Class, get, int, =>, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 1, {, }) @@ -132,7 +132,7 @@ parseUnit(class) ensureSemicolon(2) listener: handleExpressionFunctionBody(=>, ;) inGenerator() - listener: endClassMethod(get, int, =>, null, ;) + listener: endMethod(DeclarationKind.Class, get, int, =>, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 1, {, }) @@ -198,7 +198,7 @@ parseUnit(class) listener: endArguments(0, (, )) listener: handleSend(Xlate, )) listener: endFieldInitializer(=, )) - listener: endClassFields(null, null, null, null, null, null, null, 1, Xlate, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, Xlate, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, Xrequired) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, C) @@ -235,7 +235,7 @@ parseUnit(class) listener: endArguments(0, (, )) listener: handleSend(Xrequired, )) listener: endFieldInitializer(=, )) - listener: endClassFields(null, null, null, null, null, null, null, 1, Xrequired, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, Xrequired, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 2, {, }) diff --git a/pkg/front_end/parser_testcases/also-nnbd/use_late_in_non_nnbd.dart.expect b/pkg/front_end/parser_testcases/also-nnbd/use_late_in_non_nnbd.dart.expect index be58b52d466..1124091a04f 100644 --- a/pkg/front_end/parser_testcases/also-nnbd/use_late_in_non_nnbd.dart.expect +++ b/pkg/front_end/parser_testcases/also-nnbd/use_late_in_non_nnbd.dart.expect @@ -231,7 +231,7 @@ beginCompilationUnit(int) handleType(int, null) handleIdentifier(z1, fieldDeclaration) handleNoFieldInitializer(;) - endClassFields(null, null, null, null, null, null, null, 1, int, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) endMember() beginMetadataStar(late) endMetadataStar(0) @@ -242,7 +242,7 @@ beginCompilationUnit(int) handleType(int, null) handleIdentifier(z2, fieldDeclaration) handleNoFieldInitializer(;) - endClassFields(null, null, null, null, null, late, null, 1, late, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, late, null, 1, late, ;) endMember() beginMetadataStar(late) endMetadataStar(0) @@ -257,7 +257,7 @@ beginCompilationUnit(int) handleType(List, null) handleIdentifier(x3, fieldDeclaration) handleNoFieldInitializer(;) - endClassFields(null, null, null, null, null, late, null, 1, late, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, late, null, 1, late, ;) endMember() beginMetadataStar(late) endMetadataStar(0) @@ -268,7 +268,7 @@ beginCompilationUnit(int) handleType(int, null) handleIdentifier(z4, fieldDeclaration) handleNoFieldInitializer(;) - endClassFields(null, null, null, null, null, late, final, 1, late, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, late, final, 1, late, ;) endMember() beginMetadataStar(late) endMetadataStar(0) @@ -278,7 +278,7 @@ beginCompilationUnit(int) handleNoType(late) handleIdentifier(z5, fieldDeclaration) handleNoFieldInitializer(;) - endClassFields(null, null, null, null, null, late, null, 1, late, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, late, null, 1, late, ;) endMember() beginMetadataStar(;) endMetadataStar(0) @@ -294,7 +294,7 @@ beginCompilationUnit(int) handleNoType(;) handleIdentifier(late, fieldDeclaration) handleNoFieldInitializer(;) - endClassFields(null, null, null, null, null, null, null, 1, late, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, late, ;) endMember() beginMetadataStar(;) endMetadataStar(0) diff --git a/pkg/front_end/parser_testcases/also-nnbd/use_late_in_non_nnbd.dart.intertwined.expect b/pkg/front_end/parser_testcases/also-nnbd/use_late_in_non_nnbd.dart.intertwined.expect index c219b86105c..d0c73331ace 100644 --- a/pkg/front_end/parser_testcases/also-nnbd/use_late_in_non_nnbd.dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/also-nnbd/use_late_in_non_nnbd.dart.intertwined.expect @@ -367,7 +367,7 @@ parseUnit(int) listener: handleIdentifier(z1, fieldDeclaration) parseFieldInitializerOpt(z1, z1, null, null, null, null, null, DeclarationKind.Class, Foo) listener: handleNoFieldInitializer(;) - listener: endClassFields(null, null, null, null, null, null, null, 1, int, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, late) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Foo) @@ -384,7 +384,7 @@ parseUnit(int) listener: handleIdentifier(z2, fieldDeclaration) parseFieldInitializerOpt(z2, z2, late, null, null, null, null, DeclarationKind.Class, Foo) listener: handleNoFieldInitializer(;) - listener: endClassFields(null, null, null, null, null, late, null, 1, late, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, late, null, 1, late, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, late) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Foo) @@ -405,7 +405,7 @@ parseUnit(int) listener: handleIdentifier(x3, fieldDeclaration) parseFieldInitializerOpt(x3, x3, late, null, null, null, null, DeclarationKind.Class, Foo) listener: handleNoFieldInitializer(;) - listener: endClassFields(null, null, null, null, null, late, null, 1, late, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, late, null, 1, late, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, late) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Foo) @@ -424,7 +424,7 @@ parseUnit(int) listener: handleIdentifier(z4, fieldDeclaration) parseFieldInitializerOpt(z4, z4, late, null, null, null, final, DeclarationKind.Class, Foo) listener: handleNoFieldInitializer(;) - listener: endClassFields(null, null, null, null, null, late, final, 1, late, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, late, final, 1, late, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, late) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Foo) @@ -442,7 +442,7 @@ parseUnit(int) listener: handleIdentifier(z5, fieldDeclaration) parseFieldInitializerOpt(z5, z5, late, null, null, null, null, DeclarationKind.Class, Foo) listener: handleNoFieldInitializer(;) - listener: endClassFields(null, null, null, null, null, late, null, 1, late, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, late, null, 1, late, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, ;) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Foo) @@ -470,7 +470,7 @@ parseUnit(int) listener: handleIdentifier(late, fieldDeclaration) parseFieldInitializerOpt(late, late, null, null, null, null, null, DeclarationKind.Class, Foo) listener: handleNoFieldInitializer(;) - listener: endClassFields(null, null, null, null, null, null, null, 1, late, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, late, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, ;) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Foo) diff --git a/pkg/front_end/parser_testcases/also-nnbd/use_required_in_non_nnbd.dart.expect b/pkg/front_end/parser_testcases/also-nnbd/use_required_in_non_nnbd.dart.expect index 4e127de0b95..c9e6ec4ac30 100644 --- a/pkg/front_end/parser_testcases/also-nnbd/use_required_in_non_nnbd.dart.expect +++ b/pkg/front_end/parser_testcases/also-nnbd/use_required_in_non_nnbd.dart.expect @@ -159,7 +159,7 @@ beginCompilationUnit(void) handleSend(print, )) handleExpressionStatement(print, ;) endBlockFunctionBody(1, {, }) - endClassMethod(null, void, (, null, }) + endMethod(DeclarationKind.Class, null, void, (, null, }) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 1, {, }) endClassDeclaration(class, }) diff --git a/pkg/front_end/parser_testcases/also-nnbd/use_required_in_non_nnbd.dart.intertwined.expect b/pkg/front_end/parser_testcases/also-nnbd/use_required_in_non_nnbd.dart.intertwined.expect index 2a3cf471a59..e49324db002 100644 --- a/pkg/front_end/parser_testcases/also-nnbd/use_required_in_non_nnbd.dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/also-nnbd/use_required_in_non_nnbd.dart.intertwined.expect @@ -329,7 +329,7 @@ parseUnit(void) listener: handleExpressionStatement(print, ;) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(1, {, }) - listener: endClassMethod(null, void, (, null, }) + listener: endMethod(DeclarationKind.Class, null, void, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 1, {, }) diff --git a/pkg/front_end/parser_testcases/augmentation/augment_super.dart.expect b/pkg/front_end/parser_testcases/augmentation/augment_super.dart.expect index 8681391ef34..969a38e231e 100644 --- a/pkg/front_end/parser_testcases/augmentation/augment_super.dart.expect +++ b/pkg/front_end/parser_testcases/augmentation/augment_super.dart.expect @@ -212,7 +212,7 @@ beginCompilationUnit(augment) handleSend(augment, )) handleExpressionStatement(augment, ;) endBlockFunctionBody(1, {, }) - endClassMethod(null, augment, (, null, }) + endMethod(DeclarationKind.Class, null, augment, (, null, }) endMember() beginMetadataStar(augment) endMetadataStar(0) @@ -244,7 +244,7 @@ beginCompilationUnit(augment) handleSend(augment, augment) handleExpressionStatement(augment, ;) endBlockFunctionBody(2, {, }) - endClassMethod(null, augment, (, null, }) + endMethod(DeclarationKind.Class, null, augment, (, null, }) endMember() beginMetadataStar(augment) endMetadataStar(0) @@ -270,7 +270,7 @@ beginCompilationUnit(augment) handleUnaryPrefixExpression(-) endReturnStatement(true, return, ;) endBlockFunctionBody(3, {, }) - endClassMethod(get, augment, {, null, }) + endMethod(DeclarationKind.Class, get, augment, {, null, }) endMember() beginMetadataStar(augment) endMetadataStar(0) @@ -301,7 +301,7 @@ beginCompilationUnit(augment) handleAssignmentExpression(=, value) handleExpressionStatement(augment, ;) endBlockFunctionBody(1, {, }) - endClassMethod(set, augment, (, null, }) + endMethod(DeclarationKind.Class, set, augment, (, null, }) endMember() beginMetadataStar(void) endMetadataStar(0) @@ -341,7 +341,7 @@ beginCompilationUnit(augment) handleSend(augment, augment) handleExpressionStatement(augment, ;) endBlockFunctionBody(4, {, }) - endClassMethod(null, void, (, null, }) + endMethod(DeclarationKind.Class, null, void, (, null, }) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 5, {, }) endClassDeclaration(augment, }) diff --git a/pkg/front_end/parser_testcases/augmentation/augment_super.dart.intertwined.expect b/pkg/front_end/parser_testcases/augmentation/augment_super.dart.intertwined.expect index 0de16d0334b..09392fee6ab 100644 --- a/pkg/front_end/parser_testcases/augmentation/augment_super.dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/augmentation/augment_super.dart.intertwined.expect @@ -514,7 +514,7 @@ parseUnit(augment) listener: handleExpressionStatement(augment, ;) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(1, {, }) - listener: endClassMethod(null, augment, (, null, }) + listener: endMethod(DeclarationKind.Class, null, augment, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, augment) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Class) @@ -595,7 +595,7 @@ parseUnit(augment) listener: handleExpressionStatement(augment, ;) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(2, {, }) - listener: endClassMethod(null, augment, (, null, }) + listener: endMethod(DeclarationKind.Class, null, augment, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, augment) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Class) @@ -681,7 +681,7 @@ parseUnit(augment) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(3, {, }) - listener: endClassMethod(get, augment, {, null, }) + listener: endMethod(DeclarationKind.Class, get, augment, {, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, augment) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Class) @@ -752,7 +752,7 @@ parseUnit(augment) listener: handleExpressionStatement(augment, ;) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(1, {, }) - listener: endClassMethod(set, augment, (, null, }) + listener: endMethod(DeclarationKind.Class, set, augment, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, void) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Class) @@ -871,7 +871,7 @@ parseUnit(augment) listener: handleExpressionStatement(augment, ;) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(4, {, }) - listener: endClassMethod(null, void, (, null, }) + listener: endMethod(DeclarationKind.Class, null, void, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 5, {, }) diff --git a/pkg/front_end/parser_testcases/augmentation/member_declarations.dart.expect b/pkg/front_end/parser_testcases/augmentation/member_declarations.dart.expect index df3415863c6..823b972956d 100644 --- a/pkg/front_end/parser_testcases/augmentation/member_declarations.dart.expect +++ b/pkg/front_end/parser_testcases/augmentation/member_declarations.dart.expect @@ -25,7 +25,7 @@ beginCompilationUnit(class) handleAsyncModifier(null, null) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) - endClassMethod(null, augment, (, null, }) + endMethod(DeclarationKind.Class, null, augment, (, null, }) endMember() beginMetadataStar(augment) endMetadataStar(0) @@ -40,7 +40,7 @@ beginCompilationUnit(class) handleAsyncModifier(null, null) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) - endClassMethod(null, augment, (, null, }) + endMethod(DeclarationKind.Class, null, augment, (, null, }) endMember() beginMetadataStar(augment) endMetadataStar(0) @@ -54,7 +54,7 @@ beginCompilationUnit(class) handleAsyncModifier(null, null) handleLiteralNull(null) handleExpressionFunctionBody(=>, ;) - endClassMethod(get, augment, =>, null, ;) + endMethod(DeclarationKind.Class, get, augment, =>, null, ;) endMember() beginMetadataStar(augment) endMetadataStar(0) @@ -70,7 +70,7 @@ beginCompilationUnit(class) handleAsyncModifier(null, null) handleLiteralInt(0) handleExpressionFunctionBody(=>, ;) - endClassMethod(get, augment, =>, null, ;) + endMethod(DeclarationKind.Class, get, augment, =>, null, ;) endMember() beginMetadataStar(augment) endMetadataStar(0) @@ -92,7 +92,7 @@ beginCompilationUnit(class) handleAsyncModifier(null, null) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) - endClassMethod(set, augment, (, null, }) + endMethod(DeclarationKind.Class, set, augment, (, null, }) endMember() beginMetadataStar(augment) endMetadataStar(0) @@ -114,7 +114,7 @@ beginCompilationUnit(class) handleAsyncModifier(null, null) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) - endClassMethod(set, augment, (, null, }) + endMethod(DeclarationKind.Class, set, augment, (, null, }) endMember() beginMetadataStar(augment) endMetadataStar(0) @@ -123,7 +123,7 @@ beginCompilationUnit(class) handleNoType(var) handleIdentifier(field, fieldDeclaration) handleNoFieldInitializer(;) - endClassFields(null, augment, null, null, null, null, var, 1, augment, ;) + endFields(DeclarationKind.Class, null, augment, null, null, null, null, var, 1, augment, ;) endMember() beginMetadataStar(augment) endMetadataStar(0) @@ -134,7 +134,7 @@ beginCompilationUnit(class) beginFieldInitializer(=) handleLiteralInt(0) endFieldInitializer(=, 0) - endClassFields(null, augment, null, null, null, null, final, 1, augment, ;) + endFields(DeclarationKind.Class, null, augment, null, null, null, null, final, 1, augment, ;) endMember() beginMetadataStar(augment) endMetadataStar(0) @@ -145,7 +145,7 @@ beginCompilationUnit(class) beginFieldInitializer(=) handleLiteralInt(0) endFieldInitializer(=, 0) - endClassFields(null, augment, null, null, null, null, const, 1, augment, ;) + endFields(DeclarationKind.Class, null, augment, null, null, null, null, const, 1, augment, ;) endMember() beginMetadataStar(augment) endMetadataStar(0) @@ -156,7 +156,7 @@ beginCompilationUnit(class) handleType(int, null) handleIdentifier(field, fieldDeclaration) handleNoFieldInitializer(;) - endClassFields(null, augment, null, null, null, null, null, 1, augment, ;) + endFields(DeclarationKind.Class, null, augment, null, null, null, null, null, 1, augment, ;) endMember() beginMetadataStar(augment) endMetadataStar(0) @@ -165,7 +165,7 @@ beginCompilationUnit(class) handleNoType(var) handleIdentifier(field, fieldDeclaration) handleNoFieldInitializer(;) - endClassFields(null, augment, null, null, null, late, var, 1, augment, ;) + endFields(DeclarationKind.Class, null, augment, null, null, null, late, var, 1, augment, ;) endMember() beginMetadataStar(augment) endMetadataStar(0) @@ -174,7 +174,7 @@ beginCompilationUnit(class) handleNoType(final) handleIdentifier(field, fieldDeclaration) handleNoFieldInitializer(;) - endClassFields(null, augment, null, null, null, late, final, 1, augment, ;) + endFields(DeclarationKind.Class, null, augment, null, null, null, late, final, 1, augment, ;) endMember() beginMetadataStar(augment) endMetadataStar(0) @@ -185,7 +185,7 @@ beginCompilationUnit(class) handleType(int, null) handleIdentifier(field, fieldDeclaration) handleNoFieldInitializer(;) - endClassFields(null, augment, null, null, null, late, null, 1, augment, ;) + endFields(DeclarationKind.Class, null, augment, null, null, null, late, null, 1, augment, ;) endMember() beginMetadataStar(augment) endMetadataStar(0) @@ -200,7 +200,7 @@ beginCompilationUnit(class) handleAsyncModifier(null, null) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) - endClassMethod(null, augment, (, null, }) + endMethod(DeclarationKind.Class, null, augment, (, null, }) endMember() beginMetadataStar(augment) endMetadataStar(0) @@ -215,7 +215,7 @@ beginCompilationUnit(class) handleAsyncModifier(null, null) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) - endClassMethod(null, augment, (, null, }) + endMethod(DeclarationKind.Class, null, augment, (, null, }) endMember() beginMetadataStar(augment) endMetadataStar(0) @@ -229,7 +229,7 @@ beginCompilationUnit(class) handleAsyncModifier(null, null) handleLiteralNull(null) handleExpressionFunctionBody(=>, ;) - endClassMethod(get, augment, =>, null, ;) + endMethod(DeclarationKind.Class, get, augment, =>, null, ;) endMember() beginMetadataStar(augment) endMetadataStar(0) @@ -245,7 +245,7 @@ beginCompilationUnit(class) handleAsyncModifier(null, null) handleLiteralInt(0) handleExpressionFunctionBody(=>, ;) - endClassMethod(get, augment, =>, null, ;) + endMethod(DeclarationKind.Class, get, augment, =>, null, ;) endMember() beginMetadataStar(augment) endMetadataStar(0) @@ -267,7 +267,7 @@ beginCompilationUnit(class) handleAsyncModifier(null, null) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) - endClassMethod(set, augment, (, null, }) + endMethod(DeclarationKind.Class, set, augment, (, null, }) endMember() beginMetadataStar(augment) endMetadataStar(0) @@ -289,7 +289,7 @@ beginCompilationUnit(class) handleAsyncModifier(null, null) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) - endClassMethod(set, augment, (, null, }) + endMethod(DeclarationKind.Class, set, augment, (, null, }) endMember() beginMetadataStar(augment) endMetadataStar(0) @@ -298,7 +298,7 @@ beginCompilationUnit(class) handleNoType(var) handleIdentifier(field, fieldDeclaration) handleNoFieldInitializer(;) - endClassFields(null, augment, null, static, null, null, var, 1, augment, ;) + endFields(DeclarationKind.Class, null, augment, null, static, null, null, var, 1, augment, ;) endMember() beginMetadataStar(augment) endMetadataStar(0) @@ -309,7 +309,7 @@ beginCompilationUnit(class) beginFieldInitializer(=) handleLiteralInt(0) endFieldInitializer(=, 0) - endClassFields(null, augment, null, static, null, null, final, 1, augment, ;) + endFields(DeclarationKind.Class, null, augment, null, static, null, null, final, 1, augment, ;) endMember() beginMetadataStar(augment) endMetadataStar(0) @@ -320,7 +320,7 @@ beginCompilationUnit(class) beginFieldInitializer(=) handleLiteralInt(0) endFieldInitializer(=, 0) - endClassFields(null, augment, null, static, null, null, const, 1, augment, ;) + endFields(DeclarationKind.Class, null, augment, null, static, null, null, const, 1, augment, ;) endMember() beginMetadataStar(augment) endMetadataStar(0) @@ -331,7 +331,7 @@ beginCompilationUnit(class) handleType(int, null) handleIdentifier(field, fieldDeclaration) handleNoFieldInitializer(;) - endClassFields(null, augment, null, static, null, null, null, 1, augment, ;) + endFields(DeclarationKind.Class, null, augment, null, static, null, null, null, 1, augment, ;) endMember() beginMetadataStar(augment) endMetadataStar(0) @@ -340,7 +340,7 @@ beginCompilationUnit(class) handleNoType(var) handleIdentifier(field, fieldDeclaration) handleNoFieldInitializer(;) - endClassFields(null, augment, null, static, null, late, var, 1, augment, ;) + endFields(DeclarationKind.Class, null, augment, null, static, null, late, var, 1, augment, ;) endMember() beginMetadataStar(augment) endMetadataStar(0) @@ -349,7 +349,7 @@ beginCompilationUnit(class) handleNoType(final) handleIdentifier(field, fieldDeclaration) handleNoFieldInitializer(;) - endClassFields(null, augment, null, static, null, late, final, 1, augment, ;) + endFields(DeclarationKind.Class, null, augment, null, static, null, late, final, 1, augment, ;) endMember() beginMetadataStar(augment) endMetadataStar(0) @@ -360,7 +360,7 @@ beginCompilationUnit(class) handleType(int, null) handleIdentifier(field, fieldDeclaration) handleNoFieldInitializer(;) - endClassFields(null, augment, null, static, null, late, null, 1, augment, ;) + endFields(DeclarationKind.Class, null, augment, null, static, null, late, null, 1, augment, ;) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 26, {, }) endClassDeclaration(class, }) @@ -388,7 +388,7 @@ beginCompilationUnit(class) handleAsyncModifier(null, null) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) - endMixinMethod(null, augment, (, null, }) + endMethod(DeclarationKind.Mixin, null, augment, (, null, }) endMember() beginMetadataStar(augment) endMetadataStar(0) @@ -403,7 +403,7 @@ beginCompilationUnit(class) handleAsyncModifier(null, null) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) - endMixinMethod(null, augment, (, null, }) + endMethod(DeclarationKind.Mixin, null, augment, (, null, }) endMember() beginMetadataStar(augment) endMetadataStar(0) @@ -417,7 +417,7 @@ beginCompilationUnit(class) handleAsyncModifier(null, null) handleLiteralNull(null) handleExpressionFunctionBody(=>, ;) - endMixinMethod(get, augment, =>, null, ;) + endMethod(DeclarationKind.Mixin, get, augment, =>, null, ;) endMember() beginMetadataStar(augment) endMetadataStar(0) @@ -433,7 +433,7 @@ beginCompilationUnit(class) handleAsyncModifier(null, null) handleLiteralInt(0) handleExpressionFunctionBody(=>, ;) - endMixinMethod(get, augment, =>, null, ;) + endMethod(DeclarationKind.Mixin, get, augment, =>, null, ;) endMember() beginMetadataStar(augment) endMetadataStar(0) @@ -455,7 +455,7 @@ beginCompilationUnit(class) handleAsyncModifier(null, null) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) - endMixinMethod(set, augment, (, null, }) + endMethod(DeclarationKind.Mixin, set, augment, (, null, }) endMember() beginMetadataStar(augment) endMetadataStar(0) @@ -477,7 +477,7 @@ beginCompilationUnit(class) handleAsyncModifier(null, null) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) - endMixinMethod(set, augment, (, null, }) + endMethod(DeclarationKind.Mixin, set, augment, (, null, }) endMember() beginMetadataStar(augment) endMetadataStar(0) @@ -486,7 +486,7 @@ beginCompilationUnit(class) handleNoType(var) handleIdentifier(field, fieldDeclaration) handleNoFieldInitializer(;) - endMixinFields(null, augment, null, null, null, null, var, 1, augment, ;) + endFields(DeclarationKind.Mixin, null, augment, null, null, null, null, var, 1, augment, ;) endMember() beginMetadataStar(augment) endMetadataStar(0) @@ -497,7 +497,7 @@ beginCompilationUnit(class) beginFieldInitializer(=) handleLiteralInt(0) endFieldInitializer(=, 0) - endMixinFields(null, augment, null, null, null, null, final, 1, augment, ;) + endFields(DeclarationKind.Mixin, null, augment, null, null, null, null, final, 1, augment, ;) endMember() beginMetadataStar(augment) endMetadataStar(0) @@ -508,7 +508,7 @@ beginCompilationUnit(class) beginFieldInitializer(=) handleLiteralInt(0) endFieldInitializer(=, 0) - endMixinFields(null, augment, null, null, null, null, const, 1, augment, ;) + endFields(DeclarationKind.Mixin, null, augment, null, null, null, null, const, 1, augment, ;) endMember() beginMetadataStar(augment) endMetadataStar(0) @@ -519,7 +519,7 @@ beginCompilationUnit(class) handleType(int, null) handleIdentifier(field, fieldDeclaration) handleNoFieldInitializer(;) - endMixinFields(null, augment, null, null, null, null, null, 1, augment, ;) + endFields(DeclarationKind.Mixin, null, augment, null, null, null, null, null, 1, augment, ;) endMember() beginMetadataStar(augment) endMetadataStar(0) @@ -528,7 +528,7 @@ beginCompilationUnit(class) handleNoType(var) handleIdentifier(field, fieldDeclaration) handleNoFieldInitializer(;) - endMixinFields(null, augment, null, null, null, late, var, 1, augment, ;) + endFields(DeclarationKind.Mixin, null, augment, null, null, null, late, var, 1, augment, ;) endMember() beginMetadataStar(augment) endMetadataStar(0) @@ -537,7 +537,7 @@ beginCompilationUnit(class) handleNoType(final) handleIdentifier(field, fieldDeclaration) handleNoFieldInitializer(;) - endMixinFields(null, augment, null, null, null, late, final, 1, augment, ;) + endFields(DeclarationKind.Mixin, null, augment, null, null, null, late, final, 1, augment, ;) endMember() beginMetadataStar(augment) endMetadataStar(0) @@ -548,7 +548,7 @@ beginCompilationUnit(class) handleType(int, null) handleIdentifier(field, fieldDeclaration) handleNoFieldInitializer(;) - endMixinFields(null, augment, null, null, null, late, null, 1, augment, ;) + endFields(DeclarationKind.Mixin, null, augment, null, null, null, late, null, 1, augment, ;) endMember() beginMetadataStar(augment) endMetadataStar(0) @@ -563,7 +563,7 @@ beginCompilationUnit(class) handleAsyncModifier(null, null) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) - endMixinMethod(null, augment, (, null, }) + endMethod(DeclarationKind.Mixin, null, augment, (, null, }) endMember() beginMetadataStar(augment) endMetadataStar(0) @@ -578,7 +578,7 @@ beginCompilationUnit(class) handleAsyncModifier(null, null) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) - endMixinMethod(null, augment, (, null, }) + endMethod(DeclarationKind.Mixin, null, augment, (, null, }) endMember() beginMetadataStar(augment) endMetadataStar(0) @@ -592,7 +592,7 @@ beginCompilationUnit(class) handleAsyncModifier(null, null) handleLiteralNull(null) handleExpressionFunctionBody(=>, ;) - endMixinMethod(get, augment, =>, null, ;) + endMethod(DeclarationKind.Mixin, get, augment, =>, null, ;) endMember() beginMetadataStar(augment) endMetadataStar(0) @@ -608,7 +608,7 @@ beginCompilationUnit(class) handleAsyncModifier(null, null) handleLiteralInt(0) handleExpressionFunctionBody(=>, ;) - endMixinMethod(get, augment, =>, null, ;) + endMethod(DeclarationKind.Mixin, get, augment, =>, null, ;) endMember() beginMetadataStar(augment) endMetadataStar(0) @@ -630,7 +630,7 @@ beginCompilationUnit(class) handleAsyncModifier(null, null) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) - endMixinMethod(set, augment, (, null, }) + endMethod(DeclarationKind.Mixin, set, augment, (, null, }) endMember() beginMetadataStar(augment) endMetadataStar(0) @@ -652,7 +652,7 @@ beginCompilationUnit(class) handleAsyncModifier(null, null) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) - endMixinMethod(set, augment, (, null, }) + endMethod(DeclarationKind.Mixin, set, augment, (, null, }) endMember() beginMetadataStar(augment) endMetadataStar(0) @@ -661,7 +661,7 @@ beginCompilationUnit(class) handleNoType(var) handleIdentifier(field, fieldDeclaration) handleNoFieldInitializer(;) - endMixinFields(null, augment, null, static, null, null, var, 1, augment, ;) + endFields(DeclarationKind.Mixin, null, augment, null, static, null, null, var, 1, augment, ;) endMember() beginMetadataStar(augment) endMetadataStar(0) @@ -672,7 +672,7 @@ beginCompilationUnit(class) beginFieldInitializer(=) handleLiteralInt(0) endFieldInitializer(=, 0) - endMixinFields(null, augment, null, static, null, null, final, 1, augment, ;) + endFields(DeclarationKind.Mixin, null, augment, null, static, null, null, final, 1, augment, ;) endMember() beginMetadataStar(augment) endMetadataStar(0) @@ -683,7 +683,7 @@ beginCompilationUnit(class) beginFieldInitializer(=) handleLiteralInt(0) endFieldInitializer(=, 0) - endMixinFields(null, augment, null, static, null, null, const, 1, augment, ;) + endFields(DeclarationKind.Mixin, null, augment, null, static, null, null, const, 1, augment, ;) endMember() beginMetadataStar(augment) endMetadataStar(0) @@ -694,7 +694,7 @@ beginCompilationUnit(class) handleType(int, null) handleIdentifier(field, fieldDeclaration) handleNoFieldInitializer(;) - endMixinFields(null, augment, null, static, null, null, null, 1, augment, ;) + endFields(DeclarationKind.Mixin, null, augment, null, static, null, null, null, 1, augment, ;) endMember() beginMetadataStar(augment) endMetadataStar(0) @@ -703,7 +703,7 @@ beginCompilationUnit(class) handleNoType(var) handleIdentifier(field, fieldDeclaration) handleNoFieldInitializer(;) - endMixinFields(null, augment, null, static, null, late, var, 1, augment, ;) + endFields(DeclarationKind.Mixin, null, augment, null, static, null, late, var, 1, augment, ;) endMember() beginMetadataStar(augment) endMetadataStar(0) @@ -712,7 +712,7 @@ beginCompilationUnit(class) handleNoType(final) handleIdentifier(field, fieldDeclaration) handleNoFieldInitializer(;) - endMixinFields(null, augment, null, static, null, late, final, 1, augment, ;) + endFields(DeclarationKind.Mixin, null, augment, null, static, null, late, final, 1, augment, ;) endMember() beginMetadataStar(augment) endMetadataStar(0) @@ -723,7 +723,7 @@ beginCompilationUnit(class) handleType(int, null) handleIdentifier(field, fieldDeclaration) handleNoFieldInitializer(;) - endMixinFields(null, augment, null, static, null, late, null, 1, augment, ;) + endFields(DeclarationKind.Mixin, null, augment, null, static, null, late, null, 1, augment, ;) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Mixin, 26, {, }) endMixinDeclaration(mixin, }) diff --git a/pkg/front_end/parser_testcases/augmentation/member_declarations.dart.intertwined.expect b/pkg/front_end/parser_testcases/augmentation/member_declarations.dart.intertwined.expect index 21872bc584b..0f0cf484294 100644 --- a/pkg/front_end/parser_testcases/augmentation/member_declarations.dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/augmentation/member_declarations.dart.intertwined.expect @@ -57,7 +57,7 @@ parseUnit(class) listener: beginBlockFunctionBody({) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(0, {, }) - listener: endClassMethod(null, augment, (, null, }) + listener: endMethod(DeclarationKind.Class, null, augment, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, augment) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Class) @@ -88,7 +88,7 @@ parseUnit(class) listener: beginBlockFunctionBody({) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(0, {, }) - listener: endClassMethod(null, augment, (, null, }) + listener: endMethod(DeclarationKind.Class, null, augment, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, augment) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Class) @@ -125,7 +125,7 @@ parseUnit(class) ensureSemicolon(null) listener: handleExpressionFunctionBody(=>, ;) inGenerator() - listener: endClassMethod(get, augment, =>, null, ;) + listener: endMethod(DeclarationKind.Class, get, augment, =>, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, augment) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Class) @@ -164,7 +164,7 @@ parseUnit(class) ensureSemicolon(0) listener: handleExpressionFunctionBody(=>, ;) inGenerator() - listener: endClassMethod(get, augment, =>, null, ;) + listener: endMethod(DeclarationKind.Class, get, augment, =>, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, augment) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Class) @@ -205,7 +205,7 @@ parseUnit(class) listener: beginBlockFunctionBody({) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(0, {, }) - listener: endClassMethod(set, augment, (, null, }) + listener: endMethod(DeclarationKind.Class, set, augment, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, augment) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Class) @@ -246,7 +246,7 @@ parseUnit(class) listener: beginBlockFunctionBody({) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(0, {, }) - listener: endClassMethod(set, augment, (, null, }) + listener: endMethod(DeclarationKind.Class, set, augment, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, augment) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Class) @@ -263,7 +263,7 @@ parseUnit(class) listener: handleIdentifier(field, fieldDeclaration) parseFieldInitializerOpt(field, field, null, null, augment, null, var, DeclarationKind.Class, Class) listener: handleNoFieldInitializer(;) - listener: endClassFields(null, augment, null, null, null, null, var, 1, augment, ;) + listener: endFields(DeclarationKind.Class, null, augment, null, null, null, null, var, 1, augment, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, augment) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Class) @@ -289,7 +289,7 @@ parseUnit(class) parseLiteralInt(=) listener: handleLiteralInt(0) listener: endFieldInitializer(=, 0) - listener: endClassFields(null, augment, null, null, null, null, final, 1, augment, ;) + listener: endFields(DeclarationKind.Class, null, augment, null, null, null, null, final, 1, augment, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, augment) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Class) @@ -313,7 +313,7 @@ parseUnit(class) parseLiteralInt(=) listener: handleLiteralInt(0) listener: endFieldInitializer(=, 0) - listener: endClassFields(null, augment, null, null, null, null, const, 1, augment, ;) + listener: endFields(DeclarationKind.Class, null, augment, null, null, null, null, const, 1, augment, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, augment) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Class) @@ -330,7 +330,7 @@ parseUnit(class) listener: handleIdentifier(field, fieldDeclaration) parseFieldInitializerOpt(field, field, null, null, augment, null, null, DeclarationKind.Class, Class) listener: handleNoFieldInitializer(;) - listener: endClassFields(null, augment, null, null, null, null, null, 1, augment, ;) + listener: endFields(DeclarationKind.Class, null, augment, null, null, null, null, null, 1, augment, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, augment) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Class) @@ -347,7 +347,7 @@ parseUnit(class) listener: handleIdentifier(field, fieldDeclaration) parseFieldInitializerOpt(field, field, late, null, augment, null, var, DeclarationKind.Class, Class) listener: handleNoFieldInitializer(;) - listener: endClassFields(null, augment, null, null, null, late, var, 1, augment, ;) + listener: endFields(DeclarationKind.Class, null, augment, null, null, null, late, var, 1, augment, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, augment) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Class) @@ -364,7 +364,7 @@ parseUnit(class) listener: handleIdentifier(field, fieldDeclaration) parseFieldInitializerOpt(field, field, late, null, augment, null, final, DeclarationKind.Class, Class) listener: handleNoFieldInitializer(;) - listener: endClassFields(null, augment, null, null, null, late, final, 1, augment, ;) + listener: endFields(DeclarationKind.Class, null, augment, null, null, null, late, final, 1, augment, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, augment) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Class) @@ -381,7 +381,7 @@ parseUnit(class) listener: handleIdentifier(field, fieldDeclaration) parseFieldInitializerOpt(field, field, late, null, augment, null, null, DeclarationKind.Class, Class) listener: handleNoFieldInitializer(;) - listener: endClassFields(null, augment, null, null, null, late, null, 1, augment, ;) + listener: endFields(DeclarationKind.Class, null, augment, null, null, null, late, null, 1, augment, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, augment) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Class) @@ -412,7 +412,7 @@ parseUnit(class) listener: beginBlockFunctionBody({) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(0, {, }) - listener: endClassMethod(null, augment, (, null, }) + listener: endMethod(DeclarationKind.Class, null, augment, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, augment) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Class) @@ -442,7 +442,7 @@ parseUnit(class) listener: beginBlockFunctionBody({) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(0, {, }) - listener: endClassMethod(null, augment, (, null, }) + listener: endMethod(DeclarationKind.Class, null, augment, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, augment) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Class) @@ -478,7 +478,7 @@ parseUnit(class) ensureSemicolon(null) listener: handleExpressionFunctionBody(=>, ;) inGenerator() - listener: endClassMethod(get, augment, =>, null, ;) + listener: endMethod(DeclarationKind.Class, get, augment, =>, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, augment) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Class) @@ -516,7 +516,7 @@ parseUnit(class) ensureSemicolon(0) listener: handleExpressionFunctionBody(=>, ;) inGenerator() - listener: endClassMethod(get, augment, =>, null, ;) + listener: endMethod(DeclarationKind.Class, get, augment, =>, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, augment) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Class) @@ -556,7 +556,7 @@ parseUnit(class) listener: beginBlockFunctionBody({) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(0, {, }) - listener: endClassMethod(set, augment, (, null, }) + listener: endMethod(DeclarationKind.Class, set, augment, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, augment) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Class) @@ -596,7 +596,7 @@ parseUnit(class) listener: beginBlockFunctionBody({) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(0, {, }) - listener: endClassMethod(set, augment, (, null, }) + listener: endMethod(DeclarationKind.Class, set, augment, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, augment) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Class) @@ -613,7 +613,7 @@ parseUnit(class) listener: handleIdentifier(field, fieldDeclaration) parseFieldInitializerOpt(field, field, null, null, augment, null, var, DeclarationKind.Class, Class) listener: handleNoFieldInitializer(;) - listener: endClassFields(null, augment, null, static, null, null, var, 1, augment, ;) + listener: endFields(DeclarationKind.Class, null, augment, null, static, null, null, var, 1, augment, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, augment) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Class) @@ -639,7 +639,7 @@ parseUnit(class) parseLiteralInt(=) listener: handleLiteralInt(0) listener: endFieldInitializer(=, 0) - listener: endClassFields(null, augment, null, static, null, null, final, 1, augment, ;) + listener: endFields(DeclarationKind.Class, null, augment, null, static, null, null, final, 1, augment, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, augment) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Class) @@ -663,7 +663,7 @@ parseUnit(class) parseLiteralInt(=) listener: handleLiteralInt(0) listener: endFieldInitializer(=, 0) - listener: endClassFields(null, augment, null, static, null, null, const, 1, augment, ;) + listener: endFields(DeclarationKind.Class, null, augment, null, static, null, null, const, 1, augment, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, augment) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Class) @@ -680,7 +680,7 @@ parseUnit(class) listener: handleIdentifier(field, fieldDeclaration) parseFieldInitializerOpt(field, field, null, null, augment, null, null, DeclarationKind.Class, Class) listener: handleNoFieldInitializer(;) - listener: endClassFields(null, augment, null, static, null, null, null, 1, augment, ;) + listener: endFields(DeclarationKind.Class, null, augment, null, static, null, null, null, 1, augment, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, augment) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Class) @@ -697,7 +697,7 @@ parseUnit(class) listener: handleIdentifier(field, fieldDeclaration) parseFieldInitializerOpt(field, field, late, null, augment, null, var, DeclarationKind.Class, Class) listener: handleNoFieldInitializer(;) - listener: endClassFields(null, augment, null, static, null, late, var, 1, augment, ;) + listener: endFields(DeclarationKind.Class, null, augment, null, static, null, late, var, 1, augment, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, augment) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Class) @@ -714,7 +714,7 @@ parseUnit(class) listener: handleIdentifier(field, fieldDeclaration) parseFieldInitializerOpt(field, field, late, null, augment, null, final, DeclarationKind.Class, Class) listener: handleNoFieldInitializer(;) - listener: endClassFields(null, augment, null, static, null, late, final, 1, augment, ;) + listener: endFields(DeclarationKind.Class, null, augment, null, static, null, late, final, 1, augment, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, augment) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Class) @@ -731,7 +731,7 @@ parseUnit(class) listener: handleIdentifier(field, fieldDeclaration) parseFieldInitializerOpt(field, field, late, null, augment, null, null, DeclarationKind.Class, Class) listener: handleNoFieldInitializer(;) - listener: endClassFields(null, augment, null, static, null, late, null, 1, augment, ;) + listener: endFields(DeclarationKind.Class, null, augment, null, static, null, late, null, 1, augment, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 26, {, }) @@ -786,7 +786,7 @@ parseUnit(class) listener: beginBlockFunctionBody({) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(0, {, }) - listener: endMixinMethod(null, augment, (, null, }) + listener: endMethod(DeclarationKind.Mixin, null, augment, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, augment) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Mixin, Mixin) @@ -817,7 +817,7 @@ parseUnit(class) listener: beginBlockFunctionBody({) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(0, {, }) - listener: endMixinMethod(null, augment, (, null, }) + listener: endMethod(DeclarationKind.Mixin, null, augment, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, augment) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Mixin, Mixin) @@ -854,7 +854,7 @@ parseUnit(class) ensureSemicolon(null) listener: handleExpressionFunctionBody(=>, ;) inGenerator() - listener: endMixinMethod(get, augment, =>, null, ;) + listener: endMethod(DeclarationKind.Mixin, get, augment, =>, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, augment) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Mixin, Mixin) @@ -893,7 +893,7 @@ parseUnit(class) ensureSemicolon(0) listener: handleExpressionFunctionBody(=>, ;) inGenerator() - listener: endMixinMethod(get, augment, =>, null, ;) + listener: endMethod(DeclarationKind.Mixin, get, augment, =>, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, augment) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Mixin, Mixin) @@ -934,7 +934,7 @@ parseUnit(class) listener: beginBlockFunctionBody({) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(0, {, }) - listener: endMixinMethod(set, augment, (, null, }) + listener: endMethod(DeclarationKind.Mixin, set, augment, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, augment) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Mixin, Mixin) @@ -975,7 +975,7 @@ parseUnit(class) listener: beginBlockFunctionBody({) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(0, {, }) - listener: endMixinMethod(set, augment, (, null, }) + listener: endMethod(DeclarationKind.Mixin, set, augment, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, augment) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Mixin, Mixin) @@ -992,7 +992,7 @@ parseUnit(class) listener: handleIdentifier(field, fieldDeclaration) parseFieldInitializerOpt(field, field, null, null, augment, null, var, DeclarationKind.Mixin, Mixin) listener: handleNoFieldInitializer(;) - listener: endMixinFields(null, augment, null, null, null, null, var, 1, augment, ;) + listener: endFields(DeclarationKind.Mixin, null, augment, null, null, null, null, var, 1, augment, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, augment) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Mixin, Mixin) @@ -1018,7 +1018,7 @@ parseUnit(class) parseLiteralInt(=) listener: handleLiteralInt(0) listener: endFieldInitializer(=, 0) - listener: endMixinFields(null, augment, null, null, null, null, final, 1, augment, ;) + listener: endFields(DeclarationKind.Mixin, null, augment, null, null, null, null, final, 1, augment, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, augment) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Mixin, Mixin) @@ -1042,7 +1042,7 @@ parseUnit(class) parseLiteralInt(=) listener: handleLiteralInt(0) listener: endFieldInitializer(=, 0) - listener: endMixinFields(null, augment, null, null, null, null, const, 1, augment, ;) + listener: endFields(DeclarationKind.Mixin, null, augment, null, null, null, null, const, 1, augment, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, augment) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Mixin, Mixin) @@ -1059,7 +1059,7 @@ parseUnit(class) listener: handleIdentifier(field, fieldDeclaration) parseFieldInitializerOpt(field, field, null, null, augment, null, null, DeclarationKind.Mixin, Mixin) listener: handleNoFieldInitializer(;) - listener: endMixinFields(null, augment, null, null, null, null, null, 1, augment, ;) + listener: endFields(DeclarationKind.Mixin, null, augment, null, null, null, null, null, 1, augment, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, augment) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Mixin, Mixin) @@ -1076,7 +1076,7 @@ parseUnit(class) listener: handleIdentifier(field, fieldDeclaration) parseFieldInitializerOpt(field, field, late, null, augment, null, var, DeclarationKind.Mixin, Mixin) listener: handleNoFieldInitializer(;) - listener: endMixinFields(null, augment, null, null, null, late, var, 1, augment, ;) + listener: endFields(DeclarationKind.Mixin, null, augment, null, null, null, late, var, 1, augment, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, augment) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Mixin, Mixin) @@ -1093,7 +1093,7 @@ parseUnit(class) listener: handleIdentifier(field, fieldDeclaration) parseFieldInitializerOpt(field, field, late, null, augment, null, final, DeclarationKind.Mixin, Mixin) listener: handleNoFieldInitializer(;) - listener: endMixinFields(null, augment, null, null, null, late, final, 1, augment, ;) + listener: endFields(DeclarationKind.Mixin, null, augment, null, null, null, late, final, 1, augment, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, augment) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Mixin, Mixin) @@ -1110,7 +1110,7 @@ parseUnit(class) listener: handleIdentifier(field, fieldDeclaration) parseFieldInitializerOpt(field, field, late, null, augment, null, null, DeclarationKind.Mixin, Mixin) listener: handleNoFieldInitializer(;) - listener: endMixinFields(null, augment, null, null, null, late, null, 1, augment, ;) + listener: endFields(DeclarationKind.Mixin, null, augment, null, null, null, late, null, 1, augment, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, augment) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Mixin, Mixin) @@ -1141,7 +1141,7 @@ parseUnit(class) listener: beginBlockFunctionBody({) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(0, {, }) - listener: endMixinMethod(null, augment, (, null, }) + listener: endMethod(DeclarationKind.Mixin, null, augment, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, augment) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Mixin, Mixin) @@ -1171,7 +1171,7 @@ parseUnit(class) listener: beginBlockFunctionBody({) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(0, {, }) - listener: endMixinMethod(null, augment, (, null, }) + listener: endMethod(DeclarationKind.Mixin, null, augment, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, augment) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Mixin, Mixin) @@ -1207,7 +1207,7 @@ parseUnit(class) ensureSemicolon(null) listener: handleExpressionFunctionBody(=>, ;) inGenerator() - listener: endMixinMethod(get, augment, =>, null, ;) + listener: endMethod(DeclarationKind.Mixin, get, augment, =>, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, augment) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Mixin, Mixin) @@ -1245,7 +1245,7 @@ parseUnit(class) ensureSemicolon(0) listener: handleExpressionFunctionBody(=>, ;) inGenerator() - listener: endMixinMethod(get, augment, =>, null, ;) + listener: endMethod(DeclarationKind.Mixin, get, augment, =>, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, augment) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Mixin, Mixin) @@ -1285,7 +1285,7 @@ parseUnit(class) listener: beginBlockFunctionBody({) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(0, {, }) - listener: endMixinMethod(set, augment, (, null, }) + listener: endMethod(DeclarationKind.Mixin, set, augment, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, augment) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Mixin, Mixin) @@ -1325,7 +1325,7 @@ parseUnit(class) listener: beginBlockFunctionBody({) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(0, {, }) - listener: endMixinMethod(set, augment, (, null, }) + listener: endMethod(DeclarationKind.Mixin, set, augment, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, augment) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Mixin, Mixin) @@ -1342,7 +1342,7 @@ parseUnit(class) listener: handleIdentifier(field, fieldDeclaration) parseFieldInitializerOpt(field, field, null, null, augment, null, var, DeclarationKind.Mixin, Mixin) listener: handleNoFieldInitializer(;) - listener: endMixinFields(null, augment, null, static, null, null, var, 1, augment, ;) + listener: endFields(DeclarationKind.Mixin, null, augment, null, static, null, null, var, 1, augment, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, augment) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Mixin, Mixin) @@ -1368,7 +1368,7 @@ parseUnit(class) parseLiteralInt(=) listener: handleLiteralInt(0) listener: endFieldInitializer(=, 0) - listener: endMixinFields(null, augment, null, static, null, null, final, 1, augment, ;) + listener: endFields(DeclarationKind.Mixin, null, augment, null, static, null, null, final, 1, augment, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, augment) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Mixin, Mixin) @@ -1392,7 +1392,7 @@ parseUnit(class) parseLiteralInt(=) listener: handleLiteralInt(0) listener: endFieldInitializer(=, 0) - listener: endMixinFields(null, augment, null, static, null, null, const, 1, augment, ;) + listener: endFields(DeclarationKind.Mixin, null, augment, null, static, null, null, const, 1, augment, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, augment) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Mixin, Mixin) @@ -1409,7 +1409,7 @@ parseUnit(class) listener: handleIdentifier(field, fieldDeclaration) parseFieldInitializerOpt(field, field, null, null, augment, null, null, DeclarationKind.Mixin, Mixin) listener: handleNoFieldInitializer(;) - listener: endMixinFields(null, augment, null, static, null, null, null, 1, augment, ;) + listener: endFields(DeclarationKind.Mixin, null, augment, null, static, null, null, null, 1, augment, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, augment) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Mixin, Mixin) @@ -1426,7 +1426,7 @@ parseUnit(class) listener: handleIdentifier(field, fieldDeclaration) parseFieldInitializerOpt(field, field, late, null, augment, null, var, DeclarationKind.Mixin, Mixin) listener: handleNoFieldInitializer(;) - listener: endMixinFields(null, augment, null, static, null, late, var, 1, augment, ;) + listener: endFields(DeclarationKind.Mixin, null, augment, null, static, null, late, var, 1, augment, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, augment) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Mixin, Mixin) @@ -1443,7 +1443,7 @@ parseUnit(class) listener: handleIdentifier(field, fieldDeclaration) parseFieldInitializerOpt(field, field, late, null, augment, null, final, DeclarationKind.Mixin, Mixin) listener: handleNoFieldInitializer(;) - listener: endMixinFields(null, augment, null, static, null, late, final, 1, augment, ;) + listener: endFields(DeclarationKind.Mixin, null, augment, null, static, null, late, final, 1, augment, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, augment) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Mixin, Mixin) @@ -1460,7 +1460,7 @@ parseUnit(class) listener: handleIdentifier(field, fieldDeclaration) parseFieldInitializerOpt(field, field, late, null, augment, null, null, DeclarationKind.Mixin, Mixin) listener: handleNoFieldInitializer(;) - listener: endMixinFields(null, augment, null, static, null, late, null, 1, augment, ;) + listener: endFields(DeclarationKind.Mixin, null, augment, null, static, null, late, null, 1, augment, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Mixin, 26, {, }) diff --git a/pkg/front_end/parser_testcases/augmentation/member_errors.dart.expect b/pkg/front_end/parser_testcases/augmentation/member_errors.dart.expect index 69b0dfde626..cfe322d4a1d 100644 --- a/pkg/front_end/parser_testcases/augmentation/member_errors.dart.expect +++ b/pkg/front_end/parser_testcases/augmentation/member_errors.dart.expect @@ -272,7 +272,7 @@ beginCompilationUnit(class) handleAsyncModifier(null, null) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) - endClassMethod(null, augment, (, null, }) + endMethod(DeclarationKind.Class, null, augment, (, null, }) endMember() beginMetadataStar(augment) endMetadataStar(0) @@ -287,7 +287,7 @@ beginCompilationUnit(class) handleNoInitializers() handleAsyncModifier(null, null) handleEmptyFunctionBody(;) - endClassMethod(null, augment, (, null, ;) + endMethod(DeclarationKind.Class, null, augment, (, null, ;) endMember() beginMetadataStar(external) endMetadataStar(0) @@ -302,7 +302,7 @@ beginCompilationUnit(class) handleNoInitializers() handleAsyncModifier(null, null) handleEmptyFunctionBody(;) - endClassMethod(null, external, (, null, ;) + endMethod(DeclarationKind.Class, null, external, (, null, ;) endMember() beginMetadataStar(augment) endMetadataStar(0) @@ -318,7 +318,7 @@ beginCompilationUnit(class) handleAsyncModifier(null, null) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) - endClassMethod(null, augment, (, null, }) + endMethod(DeclarationKind.Class, null, augment, (, null, }) endMember() beginMetadataStar(augment) endMetadataStar(0) @@ -333,7 +333,7 @@ beginCompilationUnit(class) handleNoInitializers() handleAsyncModifier(null, null) handleEmptyFunctionBody(;) - endClassMethod(null, augment, (, null, ;) + endMethod(DeclarationKind.Class, null, augment, (, null, ;) endMember() beginMetadataStar(external) endMetadataStar(0) @@ -348,7 +348,7 @@ beginCompilationUnit(class) handleNoInitializers() handleAsyncModifier(null, null) handleEmptyFunctionBody(;) - endClassMethod(null, external, (, null, ;) + endMethod(DeclarationKind.Class, null, external, (, null, ;) endMember() beginMetadataStar(augment) endMetadataStar(0) @@ -363,7 +363,7 @@ beginCompilationUnit(class) handleAsyncModifier(null, null) handleLiteralNull(null) handleExpressionFunctionBody(=>, ;) - endClassMethod(get, augment, =>, null, ;) + endMethod(DeclarationKind.Class, get, augment, =>, null, ;) endMember() beginMetadataStar(augment) endMetadataStar(0) @@ -377,7 +377,7 @@ beginCompilationUnit(class) handleNoInitializers() handleAsyncModifier(null, null) handleEmptyFunctionBody(;) - endClassMethod(get, augment, ;, null, ;) + endMethod(DeclarationKind.Class, get, augment, ;, null, ;) endMember() beginMetadataStar(external) endMetadataStar(0) @@ -391,7 +391,7 @@ beginCompilationUnit(class) handleNoInitializers() handleAsyncModifier(null, null) handleEmptyFunctionBody(;) - endClassMethod(get, external, ;, null, ;) + endMethod(DeclarationKind.Class, get, external, ;, null, ;) endMember() beginMetadataStar(augment) endMetadataStar(0) @@ -408,7 +408,7 @@ beginCompilationUnit(class) handleAsyncModifier(null, null) handleLiteralInt(0) handleExpressionFunctionBody(=>, ;) - endClassMethod(get, augment, =>, null, ;) + endMethod(DeclarationKind.Class, get, augment, =>, null, ;) endMember() beginMetadataStar(augment) endMetadataStar(0) @@ -424,7 +424,7 @@ beginCompilationUnit(class) handleNoInitializers() handleAsyncModifier(null, null) handleEmptyFunctionBody(;) - endClassMethod(get, augment, ;, null, ;) + endMethod(DeclarationKind.Class, get, augment, ;, null, ;) endMember() beginMetadataStar(external) endMetadataStar(0) @@ -440,7 +440,7 @@ beginCompilationUnit(class) handleNoInitializers() handleAsyncModifier(null, null) handleEmptyFunctionBody(;) - endClassMethod(get, external, ;, null, ;) + endMethod(DeclarationKind.Class, get, external, ;, null, ;) endMember() beginMetadataStar(augment) endMetadataStar(0) @@ -463,7 +463,7 @@ beginCompilationUnit(class) handleAsyncModifier(null, null) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) - endClassMethod(set, augment, (, null, }) + endMethod(DeclarationKind.Class, set, augment, (, null, }) endMember() beginMetadataStar(augment) endMetadataStar(0) @@ -485,7 +485,7 @@ beginCompilationUnit(class) handleNoInitializers() handleAsyncModifier(null, null) handleEmptyFunctionBody(;) - endClassMethod(set, augment, (, null, ;) + endMethod(DeclarationKind.Class, set, augment, (, null, ;) endMember() beginMetadataStar(external) endMetadataStar(0) @@ -507,7 +507,7 @@ beginCompilationUnit(class) handleNoInitializers() handleAsyncModifier(null, null) handleEmptyFunctionBody(;) - endClassMethod(set, external, (, null, ;) + endMethod(DeclarationKind.Class, set, external, (, null, ;) endMember() beginMetadataStar(augment) endMetadataStar(0) @@ -530,7 +530,7 @@ beginCompilationUnit(class) handleAsyncModifier(null, null) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) - endClassMethod(set, augment, (, null, }) + endMethod(DeclarationKind.Class, set, augment, (, null, }) endMember() beginMetadataStar(augment) endMetadataStar(0) @@ -552,7 +552,7 @@ beginCompilationUnit(class) handleNoInitializers() handleAsyncModifier(null, null) handleEmptyFunctionBody(;) - endClassMethod(set, augment, (, null, ;) + endMethod(DeclarationKind.Class, set, augment, (, null, ;) endMember() beginMetadataStar(external) endMetadataStar(0) @@ -574,7 +574,7 @@ beginCompilationUnit(class) handleNoInitializers() handleAsyncModifier(null, null) handleEmptyFunctionBody(;) - endClassMethod(set, external, (, null, ;) + endMethod(DeclarationKind.Class, set, external, (, null, ;) endMember() beginMetadataStar(augment) endMetadataStar(0) @@ -584,7 +584,7 @@ beginCompilationUnit(class) handleNoType(var) handleIdentifier(field, fieldDeclaration) handleNoFieldInitializer(;) - endClassFields(null, augment, null, null, null, null, var, 1, augment, ;) + endFields(DeclarationKind.Class, null, augment, null, null, null, null, var, 1, augment, ;) endMember() beginMetadataStar(augment) endMetadataStar(0) @@ -594,7 +594,7 @@ beginCompilationUnit(class) handleNoType(var) handleIdentifier(field, fieldDeclaration) handleNoFieldInitializer(;) - endClassFields(null, augment, external, null, null, null, var, 1, augment, ;) + endFields(DeclarationKind.Class, null, augment, external, null, null, null, var, 1, augment, ;) endMember() beginMetadataStar(external) endMetadataStar(0) @@ -604,7 +604,7 @@ beginCompilationUnit(class) handleNoType(var) handleIdentifier(field, fieldDeclaration) handleNoFieldInitializer(;) - endClassFields(null, null, external, null, null, null, var, 1, external, ;) + endFields(DeclarationKind.Class, null, null, external, null, null, null, var, 1, external, ;) endMember() beginMetadataStar(augment) endMetadataStar(0) @@ -616,7 +616,7 @@ beginCompilationUnit(class) beginFieldInitializer(=) handleLiteralInt(0) endFieldInitializer(=, 0) - endClassFields(null, augment, null, null, null, null, final, 1, augment, ;) + endFields(DeclarationKind.Class, null, augment, null, null, null, null, final, 1, augment, ;) endMember() beginMetadataStar(augment) endMetadataStar(0) @@ -626,7 +626,7 @@ beginCompilationUnit(class) handleNoType(final) handleIdentifier(field, fieldDeclaration) handleNoFieldInitializer(;) - endClassFields(null, augment, external, null, null, null, final, 1, augment, ;) + endFields(DeclarationKind.Class, null, augment, external, null, null, null, final, 1, augment, ;) endMember() beginMetadataStar(external) endMetadataStar(0) @@ -636,7 +636,7 @@ beginCompilationUnit(class) handleNoType(final) handleIdentifier(field, fieldDeclaration) handleNoFieldInitializer(;) - endClassFields(null, null, external, null, null, null, final, 1, external, ;) + endFields(DeclarationKind.Class, null, null, external, null, null, null, final, 1, external, ;) endMember() beginMetadataStar(augment) endMetadataStar(0) @@ -648,7 +648,7 @@ beginCompilationUnit(class) beginFieldInitializer(=) handleLiteralInt(0) endFieldInitializer(=, 0) - endClassFields(null, augment, null, null, null, null, const, 1, augment, ;) + endFields(DeclarationKind.Class, null, augment, null, null, null, null, const, 1, augment, ;) endMember() beginMetadataStar(augment) endMetadataStar(0) @@ -659,7 +659,7 @@ beginCompilationUnit(class) handleIdentifier(field, fieldDeclaration) handleRecoverableError(Message[Template(ConstFieldWithoutInitializer), The const variable 'field' must be initialized., Try adding an initializer ('= expression') to the declaration., {name: field}], field, field) handleNoFieldInitializer(;) - endClassFields(null, augment, external, null, null, null, const, 1, augment, ;) + endFields(DeclarationKind.Class, null, augment, external, null, null, null, const, 1, augment, ;) endMember() beginMetadataStar(external) endMetadataStar(0) @@ -670,7 +670,7 @@ beginCompilationUnit(class) handleIdentifier(field, fieldDeclaration) handleRecoverableError(Message[Template(ConstFieldWithoutInitializer), The const variable 'field' must be initialized., Try adding an initializer ('= expression') to the declaration., {name: field}], field, field) handleNoFieldInitializer(;) - endClassFields(null, null, external, null, null, null, const, 1, external, ;) + endFields(DeclarationKind.Class, null, null, external, null, null, null, const, 1, external, ;) endMember() beginMetadataStar(augment) endMetadataStar(0) @@ -682,7 +682,7 @@ beginCompilationUnit(class) handleType(int, null) handleIdentifier(field, fieldDeclaration) handleNoFieldInitializer(;) - endClassFields(null, augment, null, null, null, null, null, 1, augment, ;) + endFields(DeclarationKind.Class, null, augment, null, null, null, null, null, 1, augment, ;) endMember() beginMetadataStar(augment) endMetadataStar(0) @@ -694,7 +694,7 @@ beginCompilationUnit(class) handleType(int, null) handleIdentifier(field, fieldDeclaration) handleNoFieldInitializer(;) - endClassFields(null, augment, external, null, null, null, null, 1, augment, ;) + endFields(DeclarationKind.Class, null, augment, external, null, null, null, null, 1, augment, ;) endMember() beginMetadataStar(external) endMetadataStar(0) @@ -706,7 +706,7 @@ beginCompilationUnit(class) handleType(int, null) handleIdentifier(field, fieldDeclaration) handleNoFieldInitializer(;) - endClassFields(null, null, external, null, null, null, null, 1, external, ;) + endFields(DeclarationKind.Class, null, null, external, null, null, null, null, 1, external, ;) endMember() beginMetadataStar(augment) endMetadataStar(0) @@ -716,7 +716,7 @@ beginCompilationUnit(class) handleNoType(var) handleIdentifier(field, fieldDeclaration) handleNoFieldInitializer(;) - endClassFields(null, augment, null, null, null, late, var, 1, augment, ;) + endFields(DeclarationKind.Class, null, augment, null, null, null, late, var, 1, augment, ;) endMember() beginMetadataStar(augment) endMetadataStar(0) @@ -725,7 +725,7 @@ beginCompilationUnit(class) handleNoType(var) handleIdentifier(field, fieldDeclaration) handleNoFieldInitializer(;) - endClassFields(null, augment, null, null, null, late, var, 1, augment, ;) + endFields(DeclarationKind.Class, null, augment, null, null, null, late, var, 1, augment, ;) endMember() beginMetadataStar(augment) endMetadataStar(0) @@ -734,7 +734,7 @@ beginCompilationUnit(class) handleNoType(var) handleIdentifier(field, fieldDeclaration) handleNoFieldInitializer(;) - endClassFields(null, augment, null, null, null, late, var, 1, augment, ;) + endFields(DeclarationKind.Class, null, augment, null, null, null, late, var, 1, augment, ;) endMember() beginMetadataStar(augment) endMetadataStar(0) @@ -744,7 +744,7 @@ beginCompilationUnit(class) handleNoType(final) handleIdentifier(field, fieldDeclaration) handleNoFieldInitializer(;) - endClassFields(null, augment, null, null, null, late, final, 1, augment, ;) + endFields(DeclarationKind.Class, null, augment, null, null, null, late, final, 1, augment, ;) endMember() beginMetadataStar(augment) endMetadataStar(0) @@ -753,7 +753,7 @@ beginCompilationUnit(class) handleNoType(final) handleIdentifier(field, fieldDeclaration) handleNoFieldInitializer(;) - endClassFields(null, augment, null, null, null, late, final, 1, augment, ;) + endFields(DeclarationKind.Class, null, augment, null, null, null, late, final, 1, augment, ;) endMember() beginMetadataStar(augment) endMetadataStar(0) @@ -762,7 +762,7 @@ beginCompilationUnit(class) handleNoType(final) handleIdentifier(field, fieldDeclaration) handleNoFieldInitializer(;) - endClassFields(null, augment, null, null, null, late, final, 1, augment, ;) + endFields(DeclarationKind.Class, null, augment, null, null, null, late, final, 1, augment, ;) endMember() beginMetadataStar(augment) endMetadataStar(0) @@ -774,7 +774,7 @@ beginCompilationUnit(class) handleType(int, null) handleIdentifier(field, fieldDeclaration) handleNoFieldInitializer(;) - endClassFields(null, augment, null, null, null, late, null, 1, augment, ;) + endFields(DeclarationKind.Class, null, augment, null, null, null, late, null, 1, augment, ;) endMember() beginMetadataStar(augment) endMetadataStar(0) @@ -785,7 +785,7 @@ beginCompilationUnit(class) handleType(int, null) handleIdentifier(field, fieldDeclaration) handleNoFieldInitializer(;) - endClassFields(null, augment, null, null, null, late, null, 1, augment, ;) + endFields(DeclarationKind.Class, null, augment, null, null, null, late, null, 1, augment, ;) endMember() beginMetadataStar(augment) endMetadataStar(0) @@ -796,7 +796,7 @@ beginCompilationUnit(class) handleType(int, null) handleIdentifier(field, fieldDeclaration) handleNoFieldInitializer(;) - endClassFields(null, augment, null, null, null, late, null, 1, augment, ;) + endFields(DeclarationKind.Class, null, augment, null, null, null, late, null, 1, augment, ;) endMember() beginMetadataStar(augment) endMetadataStar(0) @@ -812,7 +812,7 @@ beginCompilationUnit(class) handleAsyncModifier(null, null) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) - endClassMethod(null, augment, (, null, }) + endMethod(DeclarationKind.Class, null, augment, (, null, }) endMember() beginMetadataStar(static) endMetadataStar(0) @@ -828,7 +828,7 @@ beginCompilationUnit(class) handleAsyncModifier(null, null) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) - endClassMethod(null, static, (, null, }) + endMethod(DeclarationKind.Class, null, static, (, null, }) endMember() beginMetadataStar(augment) endMetadataStar(0) @@ -844,7 +844,7 @@ beginCompilationUnit(class) handleAsyncModifier(null, null) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) - endClassMethod(null, augment, (, null, }) + endMethod(DeclarationKind.Class, null, augment, (, null, }) endMember() beginMetadataStar(static) endMetadataStar(0) @@ -860,7 +860,7 @@ beginCompilationUnit(class) handleAsyncModifier(null, null) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) - endClassMethod(null, static, (, null, }) + endMethod(DeclarationKind.Class, null, static, (, null, }) endMember() beginMetadataStar(augment) endMetadataStar(0) @@ -875,7 +875,7 @@ beginCompilationUnit(class) handleAsyncModifier(null, null) handleLiteralNull(null) handleExpressionFunctionBody(=>, ;) - endClassMethod(get, augment, =>, null, ;) + endMethod(DeclarationKind.Class, get, augment, =>, null, ;) endMember() beginMetadataStar(static) endMetadataStar(0) @@ -890,7 +890,7 @@ beginCompilationUnit(class) handleAsyncModifier(null, null) handleLiteralNull(null) handleExpressionFunctionBody(=>, ;) - endClassMethod(get, static, =>, null, ;) + endMethod(DeclarationKind.Class, get, static, =>, null, ;) endMember() beginMetadataStar(augment) endMetadataStar(0) @@ -907,7 +907,7 @@ beginCompilationUnit(class) handleAsyncModifier(null, null) handleLiteralInt(0) handleExpressionFunctionBody(=>, ;) - endClassMethod(get, augment, =>, null, ;) + endMethod(DeclarationKind.Class, get, augment, =>, null, ;) endMember() beginMetadataStar(static) endMetadataStar(0) @@ -924,7 +924,7 @@ beginCompilationUnit(class) handleAsyncModifier(null, null) handleLiteralInt(0) handleExpressionFunctionBody(=>, ;) - endClassMethod(get, static, =>, null, ;) + endMethod(DeclarationKind.Class, get, static, =>, null, ;) endMember() beginMetadataStar(augment) endMetadataStar(0) @@ -947,7 +947,7 @@ beginCompilationUnit(class) handleAsyncModifier(null, null) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) - endClassMethod(set, augment, (, null, }) + endMethod(DeclarationKind.Class, set, augment, (, null, }) endMember() beginMetadataStar(static) endMetadataStar(0) @@ -970,7 +970,7 @@ beginCompilationUnit(class) handleAsyncModifier(null, null) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) - endClassMethod(set, static, (, null, }) + endMethod(DeclarationKind.Class, set, static, (, null, }) endMember() beginMetadataStar(augment) endMetadataStar(0) @@ -993,7 +993,7 @@ beginCompilationUnit(class) handleAsyncModifier(null, null) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) - endClassMethod(set, augment, (, null, }) + endMethod(DeclarationKind.Class, set, augment, (, null, }) endMember() beginMetadataStar(static) endMetadataStar(0) @@ -1016,7 +1016,7 @@ beginCompilationUnit(class) handleAsyncModifier(null, null) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) - endClassMethod(set, static, (, null, }) + endMethod(DeclarationKind.Class, set, static, (, null, }) endMember() beginMetadataStar(augment) endMetadataStar(0) @@ -1026,7 +1026,7 @@ beginCompilationUnit(class) handleNoType(var) handleIdentifier(field, fieldDeclaration) handleNoFieldInitializer(;) - endClassFields(null, augment, null, static, null, null, var, 1, augment, ;) + endFields(DeclarationKind.Class, null, augment, null, static, null, null, var, 1, augment, ;) endMember() beginMetadataStar(static) endMetadataStar(0) @@ -1036,7 +1036,7 @@ beginCompilationUnit(class) handleNoType(var) handleIdentifier(field, fieldDeclaration) handleNoFieldInitializer(;) - endClassFields(null, null, null, static, null, null, var, 1, static, ;) + endFields(DeclarationKind.Class, null, null, null, static, null, null, var, 1, static, ;) endMember() beginMetadataStar(augment) endMetadataStar(0) @@ -1048,7 +1048,7 @@ beginCompilationUnit(class) beginFieldInitializer(=) handleLiteralInt(0) endFieldInitializer(=, 0) - endClassFields(null, augment, null, static, null, null, final, 1, augment, ;) + endFields(DeclarationKind.Class, null, augment, null, static, null, null, final, 1, augment, ;) endMember() beginMetadataStar(static) endMetadataStar(0) @@ -1060,7 +1060,7 @@ beginCompilationUnit(class) beginFieldInitializer(=) handleLiteralInt(0) endFieldInitializer(=, 0) - endClassFields(null, null, null, static, null, null, final, 1, static, ;) + endFields(DeclarationKind.Class, null, null, null, static, null, null, final, 1, static, ;) endMember() beginMetadataStar(augment) endMetadataStar(0) @@ -1072,7 +1072,7 @@ beginCompilationUnit(class) beginFieldInitializer(=) handleLiteralInt(0) endFieldInitializer(=, 0) - endClassFields(null, augment, null, static, null, null, const, 1, augment, ;) + endFields(DeclarationKind.Class, null, augment, null, static, null, null, const, 1, augment, ;) endMember() beginMetadataStar(static) endMetadataStar(0) @@ -1084,7 +1084,7 @@ beginCompilationUnit(class) beginFieldInitializer(=) handleLiteralInt(0) endFieldInitializer(=, 0) - endClassFields(null, null, null, static, null, null, const, 1, static, ;) + endFields(DeclarationKind.Class, null, null, null, static, null, null, const, 1, static, ;) endMember() beginMetadataStar(augment) endMetadataStar(0) @@ -1096,7 +1096,7 @@ beginCompilationUnit(class) handleType(int, null) handleIdentifier(field, fieldDeclaration) handleNoFieldInitializer(;) - endClassFields(null, augment, null, static, null, null, null, 1, augment, ;) + endFields(DeclarationKind.Class, null, augment, null, static, null, null, null, 1, augment, ;) endMember() beginMetadataStar(static) endMetadataStar(0) @@ -1108,7 +1108,7 @@ beginCompilationUnit(class) handleType(int, null) handleIdentifier(field, fieldDeclaration) handleNoFieldInitializer(;) - endClassFields(null, null, null, static, null, null, null, 1, static, ;) + endFields(DeclarationKind.Class, null, null, null, static, null, null, null, 1, static, ;) endMember() beginMetadataStar(augment) endMetadataStar(0) @@ -1118,7 +1118,7 @@ beginCompilationUnit(class) handleNoType(var) handleIdentifier(field, fieldDeclaration) handleNoFieldInitializer(;) - endClassFields(null, augment, null, static, null, late, var, 1, augment, ;) + endFields(DeclarationKind.Class, null, augment, null, static, null, late, var, 1, augment, ;) endMember() beginMetadataStar(static) endMetadataStar(0) @@ -1128,7 +1128,7 @@ beginCompilationUnit(class) handleNoType(var) handleIdentifier(field, fieldDeclaration) handleNoFieldInitializer(;) - endClassFields(null, null, null, static, null, late, var, 1, static, ;) + endFields(DeclarationKind.Class, null, null, null, static, null, late, var, 1, static, ;) endMember() beginMetadataStar(augment) endMetadataStar(0) @@ -1138,7 +1138,7 @@ beginCompilationUnit(class) handleNoType(final) handleIdentifier(field, fieldDeclaration) handleNoFieldInitializer(;) - endClassFields(null, augment, null, static, null, late, final, 1, augment, ;) + endFields(DeclarationKind.Class, null, augment, null, static, null, late, final, 1, augment, ;) endMember() beginMetadataStar(static) endMetadataStar(0) @@ -1148,7 +1148,7 @@ beginCompilationUnit(class) handleNoType(final) handleIdentifier(field, fieldDeclaration) handleNoFieldInitializer(;) - endClassFields(null, null, null, static, null, late, final, 1, static, ;) + endFields(DeclarationKind.Class, null, null, null, static, null, late, final, 1, static, ;) endMember() beginMetadataStar(augment) endMetadataStar(0) @@ -1160,7 +1160,7 @@ beginCompilationUnit(class) handleType(int, null) handleIdentifier(field, fieldDeclaration) handleNoFieldInitializer(;) - endClassFields(null, augment, null, static, null, late, null, 1, augment, ;) + endFields(DeclarationKind.Class, null, augment, null, static, null, late, null, 1, augment, ;) endMember() beginMetadataStar(static) endMetadataStar(0) @@ -1172,7 +1172,7 @@ beginCompilationUnit(class) handleType(int, null) handleIdentifier(field, fieldDeclaration) handleNoFieldInitializer(;) - endClassFields(null, null, null, static, null, late, null, 1, static, ;) + endFields(DeclarationKind.Class, null, null, null, static, null, late, null, 1, static, ;) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 65, {, }) endClassDeclaration(class, }) diff --git a/pkg/front_end/parser_testcases/augmentation/member_errors.dart.intertwined.expect b/pkg/front_end/parser_testcases/augmentation/member_errors.dart.intertwined.expect index 3b45fcee05c..41cadd60c91 100644 --- a/pkg/front_end/parser_testcases/augmentation/member_errors.dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/augmentation/member_errors.dart.intertwined.expect @@ -59,7 +59,7 @@ parseUnit(class) listener: beginBlockFunctionBody({) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(0, {, }) - listener: endClassMethod(null, augment, (, null, }) + listener: endMethod(DeclarationKind.Class, null, augment, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, augment) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Class) @@ -91,7 +91,7 @@ parseUnit(class) inPlainSync() parseFunctionBody(), false, true) listener: handleEmptyFunctionBody(;) - listener: endClassMethod(null, augment, (, null, ;) + listener: endMethod(DeclarationKind.Class, null, augment, (, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, external) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Class) @@ -123,7 +123,7 @@ parseUnit(class) inPlainSync() parseFunctionBody(), false, true) listener: handleEmptyFunctionBody(;) - listener: endClassMethod(null, external, (, null, ;) + listener: endMethod(DeclarationKind.Class, null, external, (, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, augment) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Class) @@ -156,7 +156,7 @@ parseUnit(class) listener: beginBlockFunctionBody({) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(0, {, }) - listener: endClassMethod(null, augment, (, null, }) + listener: endMethod(DeclarationKind.Class, null, augment, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, augment) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Class) @@ -187,7 +187,7 @@ parseUnit(class) inPlainSync() parseFunctionBody(), false, true) listener: handleEmptyFunctionBody(;) - listener: endClassMethod(null, augment, (, null, ;) + listener: endMethod(DeclarationKind.Class, null, augment, (, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, external) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Class) @@ -218,7 +218,7 @@ parseUnit(class) inPlainSync() parseFunctionBody(), false, true) listener: handleEmptyFunctionBody(;) - listener: endClassMethod(null, external, (, null, ;) + listener: endMethod(DeclarationKind.Class, null, external, (, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, augment) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Class) @@ -257,7 +257,7 @@ parseUnit(class) ensureSemicolon(null) listener: handleExpressionFunctionBody(=>, ;) inGenerator() - listener: endClassMethod(get, augment, =>, null, ;) + listener: endMethod(DeclarationKind.Class, get, augment, =>, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, augment) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Class) @@ -285,7 +285,7 @@ parseUnit(class) inPlainSync() parseFunctionBody(getter, false, true) listener: handleEmptyFunctionBody(;) - listener: endClassMethod(get, augment, ;, null, ;) + listener: endMethod(DeclarationKind.Class, get, augment, ;, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, external) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Class) @@ -313,7 +313,7 @@ parseUnit(class) inPlainSync() parseFunctionBody(getter, false, true) listener: handleEmptyFunctionBody(;) - listener: endClassMethod(get, external, ;, null, ;) + listener: endMethod(DeclarationKind.Class, get, external, ;, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, augment) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Class) @@ -354,7 +354,7 @@ parseUnit(class) ensureSemicolon(0) listener: handleExpressionFunctionBody(=>, ;) inGenerator() - listener: endClassMethod(get, augment, =>, null, ;) + listener: endMethod(DeclarationKind.Class, get, augment, =>, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, augment) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Class) @@ -384,7 +384,7 @@ parseUnit(class) inPlainSync() parseFunctionBody(getter, false, true) listener: handleEmptyFunctionBody(;) - listener: endClassMethod(get, augment, ;, null, ;) + listener: endMethod(DeclarationKind.Class, get, augment, ;, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, external) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Class) @@ -414,7 +414,7 @@ parseUnit(class) inPlainSync() parseFunctionBody(getter, false, true) listener: handleEmptyFunctionBody(;) - listener: endClassMethod(get, external, ;, null, ;) + listener: endMethod(DeclarationKind.Class, get, external, ;, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, augment) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Class) @@ -457,7 +457,7 @@ parseUnit(class) listener: beginBlockFunctionBody({) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(0, {, }) - listener: endClassMethod(set, augment, (, null, }) + listener: endMethod(DeclarationKind.Class, set, augment, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, augment) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Class) @@ -498,7 +498,7 @@ parseUnit(class) inPlainSync() parseFunctionBody(), false, true) listener: handleEmptyFunctionBody(;) - listener: endClassMethod(set, augment, (, null, ;) + listener: endMethod(DeclarationKind.Class, set, augment, (, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, external) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Class) @@ -539,7 +539,7 @@ parseUnit(class) inPlainSync() parseFunctionBody(), false, true) listener: handleEmptyFunctionBody(;) - listener: endClassMethod(set, external, (, null, ;) + listener: endMethod(DeclarationKind.Class, set, external, (, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, augment) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Class) @@ -582,7 +582,7 @@ parseUnit(class) listener: beginBlockFunctionBody({) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(0, {, }) - listener: endClassMethod(set, augment, (, null, }) + listener: endMethod(DeclarationKind.Class, set, augment, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, augment) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Class) @@ -623,7 +623,7 @@ parseUnit(class) inPlainSync() parseFunctionBody(), false, true) listener: handleEmptyFunctionBody(;) - listener: endClassMethod(set, augment, (, null, ;) + listener: endMethod(DeclarationKind.Class, set, augment, (, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, external) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Class) @@ -664,7 +664,7 @@ parseUnit(class) inPlainSync() parseFunctionBody(), false, true) listener: handleEmptyFunctionBody(;) - listener: endClassMethod(set, external, (, null, ;) + listener: endMethod(DeclarationKind.Class, set, external, (, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, augment) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Class) @@ -683,7 +683,7 @@ parseUnit(class) listener: handleIdentifier(field, fieldDeclaration) parseFieldInitializerOpt(field, field, null, null, augment, null, var, DeclarationKind.Class, Class) listener: handleNoFieldInitializer(;) - listener: endClassFields(null, augment, null, null, null, null, var, 1, augment, ;) + listener: endFields(DeclarationKind.Class, null, augment, null, null, null, null, var, 1, augment, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, augment) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Class) @@ -702,7 +702,7 @@ parseUnit(class) listener: handleIdentifier(field, fieldDeclaration) parseFieldInitializerOpt(field, field, null, null, augment, external, var, DeclarationKind.Class, Class) listener: handleNoFieldInitializer(;) - listener: endClassFields(null, augment, external, null, null, null, var, 1, augment, ;) + listener: endFields(DeclarationKind.Class, null, augment, external, null, null, null, var, 1, augment, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, external) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Class) @@ -721,7 +721,7 @@ parseUnit(class) listener: handleIdentifier(field, fieldDeclaration) parseFieldInitializerOpt(field, field, null, null, null, external, var, DeclarationKind.Class, Class) listener: handleNoFieldInitializer(;) - listener: endClassFields(null, null, external, null, null, null, var, 1, external, ;) + listener: endFields(DeclarationKind.Class, null, null, external, null, null, null, var, 1, external, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, augment) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Class) @@ -749,7 +749,7 @@ parseUnit(class) parseLiteralInt(=) listener: handleLiteralInt(0) listener: endFieldInitializer(=, 0) - listener: endClassFields(null, augment, null, null, null, null, final, 1, augment, ;) + listener: endFields(DeclarationKind.Class, null, augment, null, null, null, null, final, 1, augment, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, augment) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Class) @@ -768,7 +768,7 @@ parseUnit(class) listener: handleIdentifier(field, fieldDeclaration) parseFieldInitializerOpt(field, field, null, null, augment, external, final, DeclarationKind.Class, Class) listener: handleNoFieldInitializer(;) - listener: endClassFields(null, augment, external, null, null, null, final, 1, augment, ;) + listener: endFields(DeclarationKind.Class, null, augment, external, null, null, null, final, 1, augment, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, external) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Class) @@ -787,7 +787,7 @@ parseUnit(class) listener: handleIdentifier(field, fieldDeclaration) parseFieldInitializerOpt(field, field, null, null, null, external, final, DeclarationKind.Class, Class) listener: handleNoFieldInitializer(;) - listener: endClassFields(null, null, external, null, null, null, final, 1, external, ;) + listener: endFields(DeclarationKind.Class, null, null, external, null, null, null, final, 1, external, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, augment) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Class) @@ -813,7 +813,7 @@ parseUnit(class) parseLiteralInt(=) listener: handleLiteralInt(0) listener: endFieldInitializer(=, 0) - listener: endClassFields(null, augment, null, null, null, null, const, 1, augment, ;) + listener: endFields(DeclarationKind.Class, null, augment, null, null, null, null, const, 1, augment, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, augment) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Class) @@ -832,7 +832,7 @@ parseUnit(class) reportRecoverableError(field, Message[Template(ConstFieldWithoutInitializer), The const variable 'field' must be initialized., Try adding an initializer ('= expression') to the declaration., {name: field}]) listener: handleRecoverableError(Message[Template(ConstFieldWithoutInitializer), The const variable 'field' must be initialized., Try adding an initializer ('= expression') to the declaration., {name: field}], field, field) listener: handleNoFieldInitializer(;) - listener: endClassFields(null, augment, external, null, null, null, const, 1, augment, ;) + listener: endFields(DeclarationKind.Class, null, augment, external, null, null, null, const, 1, augment, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, external) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Class) @@ -851,7 +851,7 @@ parseUnit(class) reportRecoverableError(field, Message[Template(ConstFieldWithoutInitializer), The const variable 'field' must be initialized., Try adding an initializer ('= expression') to the declaration., {name: field}]) listener: handleRecoverableError(Message[Template(ConstFieldWithoutInitializer), The const variable 'field' must be initialized., Try adding an initializer ('= expression') to the declaration., {name: field}], field, field) listener: handleNoFieldInitializer(;) - listener: endClassFields(null, null, external, null, null, null, const, 1, external, ;) + listener: endFields(DeclarationKind.Class, null, null, external, null, null, null, const, 1, external, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, augment) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Class) @@ -870,7 +870,7 @@ parseUnit(class) listener: handleIdentifier(field, fieldDeclaration) parseFieldInitializerOpt(field, field, null, null, augment, null, null, DeclarationKind.Class, Class) listener: handleNoFieldInitializer(;) - listener: endClassFields(null, augment, null, null, null, null, null, 1, augment, ;) + listener: endFields(DeclarationKind.Class, null, augment, null, null, null, null, null, 1, augment, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, augment) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Class) @@ -889,7 +889,7 @@ parseUnit(class) listener: handleIdentifier(field, fieldDeclaration) parseFieldInitializerOpt(field, field, null, null, augment, external, null, DeclarationKind.Class, Class) listener: handleNoFieldInitializer(;) - listener: endClassFields(null, augment, external, null, null, null, null, 1, augment, ;) + listener: endFields(DeclarationKind.Class, null, augment, external, null, null, null, null, 1, augment, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, external) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Class) @@ -908,7 +908,7 @@ parseUnit(class) listener: handleIdentifier(field, fieldDeclaration) parseFieldInitializerOpt(field, field, null, null, null, external, null, DeclarationKind.Class, Class) listener: handleNoFieldInitializer(;) - listener: endClassFields(null, null, external, null, null, null, null, 1, external, ;) + listener: endFields(DeclarationKind.Class, null, null, external, null, null, null, null, 1, external, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, augment) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Class) @@ -927,7 +927,7 @@ parseUnit(class) listener: handleIdentifier(field, fieldDeclaration) parseFieldInitializerOpt(field, field, late, null, augment, null, var, DeclarationKind.Class, Class) listener: handleNoFieldInitializer(;) - listener: endClassFields(null, augment, null, null, null, late, var, 1, augment, ;) + listener: endFields(DeclarationKind.Class, null, augment, null, null, null, late, var, 1, augment, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, augment) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Class) @@ -944,7 +944,7 @@ parseUnit(class) listener: handleIdentifier(field, fieldDeclaration) parseFieldInitializerOpt(field, field, late, null, augment, null, var, DeclarationKind.Class, Class) listener: handleNoFieldInitializer(;) - listener: endClassFields(null, augment, null, null, null, late, var, 1, augment, ;) + listener: endFields(DeclarationKind.Class, null, augment, null, null, null, late, var, 1, augment, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, augment) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Class) @@ -961,7 +961,7 @@ parseUnit(class) listener: handleIdentifier(field, fieldDeclaration) parseFieldInitializerOpt(field, field, late, null, augment, null, var, DeclarationKind.Class, Class) listener: handleNoFieldInitializer(;) - listener: endClassFields(null, augment, null, null, null, late, var, 1, augment, ;) + listener: endFields(DeclarationKind.Class, null, augment, null, null, null, late, var, 1, augment, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, augment) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Class) @@ -980,7 +980,7 @@ parseUnit(class) listener: handleIdentifier(field, fieldDeclaration) parseFieldInitializerOpt(field, field, late, null, augment, null, final, DeclarationKind.Class, Class) listener: handleNoFieldInitializer(;) - listener: endClassFields(null, augment, null, null, null, late, final, 1, augment, ;) + listener: endFields(DeclarationKind.Class, null, augment, null, null, null, late, final, 1, augment, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, augment) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Class) @@ -997,7 +997,7 @@ parseUnit(class) listener: handleIdentifier(field, fieldDeclaration) parseFieldInitializerOpt(field, field, late, null, augment, null, final, DeclarationKind.Class, Class) listener: handleNoFieldInitializer(;) - listener: endClassFields(null, augment, null, null, null, late, final, 1, augment, ;) + listener: endFields(DeclarationKind.Class, null, augment, null, null, null, late, final, 1, augment, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, augment) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Class) @@ -1014,7 +1014,7 @@ parseUnit(class) listener: handleIdentifier(field, fieldDeclaration) parseFieldInitializerOpt(field, field, late, null, augment, null, final, DeclarationKind.Class, Class) listener: handleNoFieldInitializer(;) - listener: endClassFields(null, augment, null, null, null, late, final, 1, augment, ;) + listener: endFields(DeclarationKind.Class, null, augment, null, null, null, late, final, 1, augment, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, augment) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Class) @@ -1033,7 +1033,7 @@ parseUnit(class) listener: handleIdentifier(field, fieldDeclaration) parseFieldInitializerOpt(field, field, late, null, augment, null, null, DeclarationKind.Class, Class) listener: handleNoFieldInitializer(;) - listener: endClassFields(null, augment, null, null, null, late, null, 1, augment, ;) + listener: endFields(DeclarationKind.Class, null, augment, null, null, null, late, null, 1, augment, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, augment) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Class) @@ -1050,7 +1050,7 @@ parseUnit(class) listener: handleIdentifier(field, fieldDeclaration) parseFieldInitializerOpt(field, field, late, null, augment, null, null, DeclarationKind.Class, Class) listener: handleNoFieldInitializer(;) - listener: endClassFields(null, augment, null, null, null, late, null, 1, augment, ;) + listener: endFields(DeclarationKind.Class, null, augment, null, null, null, late, null, 1, augment, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, augment) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Class) @@ -1067,7 +1067,7 @@ parseUnit(class) listener: handleIdentifier(field, fieldDeclaration) parseFieldInitializerOpt(field, field, late, null, augment, null, null, DeclarationKind.Class, Class) listener: handleNoFieldInitializer(;) - listener: endClassFields(null, augment, null, null, null, late, null, 1, augment, ;) + listener: endFields(DeclarationKind.Class, null, augment, null, null, null, late, null, 1, augment, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, augment) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Class) @@ -1100,7 +1100,7 @@ parseUnit(class) listener: beginBlockFunctionBody({) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(0, {, }) - listener: endClassMethod(null, augment, (, null, }) + listener: endMethod(DeclarationKind.Class, null, augment, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, static) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Class) @@ -1133,7 +1133,7 @@ parseUnit(class) listener: beginBlockFunctionBody({) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(0, {, }) - listener: endClassMethod(null, static, (, null, }) + listener: endMethod(DeclarationKind.Class, null, static, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, augment) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Class) @@ -1165,7 +1165,7 @@ parseUnit(class) listener: beginBlockFunctionBody({) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(0, {, }) - listener: endClassMethod(null, augment, (, null, }) + listener: endMethod(DeclarationKind.Class, null, augment, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, static) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Class) @@ -1197,7 +1197,7 @@ parseUnit(class) listener: beginBlockFunctionBody({) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(0, {, }) - listener: endClassMethod(null, static, (, null, }) + listener: endMethod(DeclarationKind.Class, null, static, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, augment) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Class) @@ -1235,7 +1235,7 @@ parseUnit(class) ensureSemicolon(null) listener: handleExpressionFunctionBody(=>, ;) inGenerator() - listener: endClassMethod(get, augment, =>, null, ;) + listener: endMethod(DeclarationKind.Class, get, augment, =>, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, static) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Class) @@ -1273,7 +1273,7 @@ parseUnit(class) ensureSemicolon(null) listener: handleExpressionFunctionBody(=>, ;) inGenerator() - listener: endClassMethod(get, static, =>, null, ;) + listener: endMethod(DeclarationKind.Class, get, static, =>, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, augment) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Class) @@ -1313,7 +1313,7 @@ parseUnit(class) ensureSemicolon(0) listener: handleExpressionFunctionBody(=>, ;) inGenerator() - listener: endClassMethod(get, augment, =>, null, ;) + listener: endMethod(DeclarationKind.Class, get, augment, =>, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, static) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Class) @@ -1353,7 +1353,7 @@ parseUnit(class) ensureSemicolon(0) listener: handleExpressionFunctionBody(=>, ;) inGenerator() - listener: endClassMethod(get, static, =>, null, ;) + listener: endMethod(DeclarationKind.Class, get, static, =>, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, augment) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Class) @@ -1395,7 +1395,7 @@ parseUnit(class) listener: beginBlockFunctionBody({) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(0, {, }) - listener: endClassMethod(set, augment, (, null, }) + listener: endMethod(DeclarationKind.Class, set, augment, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, static) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Class) @@ -1437,7 +1437,7 @@ parseUnit(class) listener: beginBlockFunctionBody({) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(0, {, }) - listener: endClassMethod(set, static, (, null, }) + listener: endMethod(DeclarationKind.Class, set, static, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, augment) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Class) @@ -1479,7 +1479,7 @@ parseUnit(class) listener: beginBlockFunctionBody({) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(0, {, }) - listener: endClassMethod(set, augment, (, null, }) + listener: endMethod(DeclarationKind.Class, set, augment, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, static) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Class) @@ -1521,7 +1521,7 @@ parseUnit(class) listener: beginBlockFunctionBody({) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(0, {, }) - listener: endClassMethod(set, static, (, null, }) + listener: endMethod(DeclarationKind.Class, set, static, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, augment) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Class) @@ -1540,7 +1540,7 @@ parseUnit(class) listener: handleIdentifier(field, fieldDeclaration) parseFieldInitializerOpt(field, field, null, null, augment, null, var, DeclarationKind.Class, Class) listener: handleNoFieldInitializer(;) - listener: endClassFields(null, augment, null, static, null, null, var, 1, augment, ;) + listener: endFields(DeclarationKind.Class, null, augment, null, static, null, null, var, 1, augment, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, static) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Class) @@ -1559,7 +1559,7 @@ parseUnit(class) listener: handleIdentifier(field, fieldDeclaration) parseFieldInitializerOpt(field, field, null, null, null, null, var, DeclarationKind.Class, Class) listener: handleNoFieldInitializer(;) - listener: endClassFields(null, null, null, static, null, null, var, 1, static, ;) + listener: endFields(DeclarationKind.Class, null, null, null, static, null, null, var, 1, static, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, augment) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Class) @@ -1587,7 +1587,7 @@ parseUnit(class) parseLiteralInt(=) listener: handleLiteralInt(0) listener: endFieldInitializer(=, 0) - listener: endClassFields(null, augment, null, static, null, null, final, 1, augment, ;) + listener: endFields(DeclarationKind.Class, null, augment, null, static, null, null, final, 1, augment, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, static) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Class) @@ -1615,7 +1615,7 @@ parseUnit(class) parseLiteralInt(=) listener: handleLiteralInt(0) listener: endFieldInitializer(=, 0) - listener: endClassFields(null, null, null, static, null, null, final, 1, static, ;) + listener: endFields(DeclarationKind.Class, null, null, null, static, null, null, final, 1, static, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, augment) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Class) @@ -1641,7 +1641,7 @@ parseUnit(class) parseLiteralInt(=) listener: handleLiteralInt(0) listener: endFieldInitializer(=, 0) - listener: endClassFields(null, augment, null, static, null, null, const, 1, augment, ;) + listener: endFields(DeclarationKind.Class, null, augment, null, static, null, null, const, 1, augment, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, static) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Class) @@ -1667,7 +1667,7 @@ parseUnit(class) parseLiteralInt(=) listener: handleLiteralInt(0) listener: endFieldInitializer(=, 0) - listener: endClassFields(null, null, null, static, null, null, const, 1, static, ;) + listener: endFields(DeclarationKind.Class, null, null, null, static, null, null, const, 1, static, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, augment) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Class) @@ -1686,7 +1686,7 @@ parseUnit(class) listener: handleIdentifier(field, fieldDeclaration) parseFieldInitializerOpt(field, field, null, null, augment, null, null, DeclarationKind.Class, Class) listener: handleNoFieldInitializer(;) - listener: endClassFields(null, augment, null, static, null, null, null, 1, augment, ;) + listener: endFields(DeclarationKind.Class, null, augment, null, static, null, null, null, 1, augment, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, static) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Class) @@ -1705,7 +1705,7 @@ parseUnit(class) listener: handleIdentifier(field, fieldDeclaration) parseFieldInitializerOpt(field, field, null, null, null, null, null, DeclarationKind.Class, Class) listener: handleNoFieldInitializer(;) - listener: endClassFields(null, null, null, static, null, null, null, 1, static, ;) + listener: endFields(DeclarationKind.Class, null, null, null, static, null, null, null, 1, static, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, augment) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Class) @@ -1724,7 +1724,7 @@ parseUnit(class) listener: handleIdentifier(field, fieldDeclaration) parseFieldInitializerOpt(field, field, late, null, augment, null, var, DeclarationKind.Class, Class) listener: handleNoFieldInitializer(;) - listener: endClassFields(null, augment, null, static, null, late, var, 1, augment, ;) + listener: endFields(DeclarationKind.Class, null, augment, null, static, null, late, var, 1, augment, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, static) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Class) @@ -1743,7 +1743,7 @@ parseUnit(class) listener: handleIdentifier(field, fieldDeclaration) parseFieldInitializerOpt(field, field, late, null, null, null, var, DeclarationKind.Class, Class) listener: handleNoFieldInitializer(;) - listener: endClassFields(null, null, null, static, null, late, var, 1, static, ;) + listener: endFields(DeclarationKind.Class, null, null, null, static, null, late, var, 1, static, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, augment) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Class) @@ -1762,7 +1762,7 @@ parseUnit(class) listener: handleIdentifier(field, fieldDeclaration) parseFieldInitializerOpt(field, field, late, null, augment, null, final, DeclarationKind.Class, Class) listener: handleNoFieldInitializer(;) - listener: endClassFields(null, augment, null, static, null, late, final, 1, augment, ;) + listener: endFields(DeclarationKind.Class, null, augment, null, static, null, late, final, 1, augment, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, static) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Class) @@ -1781,7 +1781,7 @@ parseUnit(class) listener: handleIdentifier(field, fieldDeclaration) parseFieldInitializerOpt(field, field, late, null, null, null, final, DeclarationKind.Class, Class) listener: handleNoFieldInitializer(;) - listener: endClassFields(null, null, null, static, null, late, final, 1, static, ;) + listener: endFields(DeclarationKind.Class, null, null, null, static, null, late, final, 1, static, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, augment) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Class) @@ -1800,7 +1800,7 @@ parseUnit(class) listener: handleIdentifier(field, fieldDeclaration) parseFieldInitializerOpt(field, field, late, null, augment, null, null, DeclarationKind.Class, Class) listener: handleNoFieldInitializer(;) - listener: endClassFields(null, augment, null, static, null, late, null, 1, augment, ;) + listener: endFields(DeclarationKind.Class, null, augment, null, static, null, late, null, 1, augment, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, static) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Class) @@ -1819,7 +1819,7 @@ parseUnit(class) listener: handleIdentifier(field, fieldDeclaration) parseFieldInitializerOpt(field, field, late, null, null, null, null, DeclarationKind.Class, Class) listener: handleNoFieldInitializer(;) - listener: endClassFields(null, null, null, static, null, late, null, 1, static, ;) + listener: endFields(DeclarationKind.Class, null, null, null, static, null, late, null, 1, static, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 65, {, }) diff --git a/pkg/front_end/parser_testcases/declaring_constructors/class_primary_constructor_body_error.dart.expect b/pkg/front_end/parser_testcases/declaring_constructors/class_primary_constructor_body_error.dart.expect index dbc1c408bf8..fbd146be686 100644 --- a/pkg/front_end/parser_testcases/declaring_constructors/class_primary_constructor_body_error.dart.expect +++ b/pkg/front_end/parser_testcases/declaring_constructors/class_primary_constructor_body_error.dart.expect @@ -55,7 +55,7 @@ beginCompilationUnit(class) handleAsyncModifier(null, null) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) - endClassMethod(null, this, (, null, }) + endMethod(DeclarationKind.Class, null, this, (, null, }) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 1, {, }) endClassDeclaration(class, }) @@ -109,7 +109,7 @@ beginCompilationUnit(class) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) handleRecoverableError(ConstructorWithWrongName, this, this) - endClassConstructor(this, (, :, }) + endConstructor(DeclarationKind.Class, this, (, :, }) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 1, {, }) endClassDeclaration(class, }) @@ -143,7 +143,7 @@ beginCompilationUnit(class) handleNoInitializers() handleAsyncModifier(null, null) handleEmptyFunctionBody(;) - endClassMethod(null, this, (, null, ;) + endMethod(DeclarationKind.Class, null, this, (, null, ;) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 1, {, }) endClassDeclaration(class, }) @@ -196,7 +196,7 @@ beginCompilationUnit(class) handleAsyncModifier(null, null) handleEmptyFunctionBody(;) handleRecoverableError(ConstructorWithWrongName, this, this) - endClassConstructor(this, (, :, ;) + endConstructor(DeclarationKind.Class, this, (, :, ;) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 1, {, }) endClassDeclaration(class, }) diff --git a/pkg/front_end/parser_testcases/declaring_constructors/class_primary_constructor_body_error.dart.intertwined.expect b/pkg/front_end/parser_testcases/declaring_constructors/class_primary_constructor_body_error.dart.intertwined.expect index 38e434372e3..7a495988fa1 100644 --- a/pkg/front_end/parser_testcases/declaring_constructors/class_primary_constructor_body_error.dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/declaring_constructors/class_primary_constructor_body_error.dart.intertwined.expect @@ -63,7 +63,7 @@ parseUnit(class) listener: beginBlockFunctionBody({) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(0, {, }) - listener: endClassMethod(null, this, (, null, }) + listener: endMethod(DeclarationKind.Class, null, this, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 1, {, }) @@ -167,7 +167,7 @@ parseUnit(class) listener: endBlockFunctionBody(0, {, }) reportRecoverableError(this, ConstructorWithWrongName) listener: handleRecoverableError(ConstructorWithWrongName, this, this) - listener: endClassConstructor(this, (, :, }) + listener: endConstructor(DeclarationKind.Class, this, (, :, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 1, {, }) @@ -232,7 +232,7 @@ parseUnit(class) inPlainSync() parseFunctionBody(), false, true) listener: handleEmptyFunctionBody(;) - listener: endClassMethod(null, this, (, null, ;) + listener: endMethod(DeclarationKind.Class, null, this, (, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 1, {, }) @@ -334,7 +334,7 @@ parseUnit(class) listener: handleEmptyFunctionBody(;) reportRecoverableError(this, ConstructorWithWrongName) listener: handleRecoverableError(ConstructorWithWrongName, this, this) - listener: endClassConstructor(this, (, :, ;) + listener: endConstructor(DeclarationKind.Class, this, (, :, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 1, {, }) diff --git a/pkg/front_end/parser_testcases/declaring_constructors/declaring_parameter_error.dart.expect b/pkg/front_end/parser_testcases/declaring_constructors/declaring_parameter_error.dart.expect index 91975df933a..5c51915a33b 100644 --- a/pkg/front_end/parser_testcases/declaring_constructors/declaring_parameter_error.dart.expect +++ b/pkg/front_end/parser_testcases/declaring_constructors/declaring_parameter_error.dart.expect @@ -193,7 +193,7 @@ beginCompilationUnit(m) handleAsyncModifier(null, null) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) - endClassConstructor(C, (, null, }) + endConstructor(DeclarationKind.Class, C, (, null, }) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 1, {, }) endClassDeclaration(class, }) @@ -855,7 +855,7 @@ beginCompilationUnit(m) handleAsyncModifier(null, null) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) - endExtensionTypeConstructor(ET, (, null, }) + endConstructor(DeclarationKind.ExtensionType, ET, (, null, }) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.ExtensionType, 1, {, }) endExtensionTypeDeclaration(extension, null, extension, type, }) diff --git a/pkg/front_end/parser_testcases/declaring_constructors/declaring_parameter_error.dart.intertwined.expect b/pkg/front_end/parser_testcases/declaring_constructors/declaring_parameter_error.dart.intertwined.expect index ee1a2d7ec91..6535f51b9b8 100644 --- a/pkg/front_end/parser_testcases/declaring_constructors/declaring_parameter_error.dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/declaring_constructors/declaring_parameter_error.dart.intertwined.expect @@ -113,7 +113,7 @@ parseUnit(m) listener: beginBlockFunctionBody({) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(0, {, }) - listener: endClassConstructor(C, (, null, }) + listener: endConstructor(DeclarationKind.Class, C, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 1, {, }) @@ -1166,7 +1166,7 @@ parseUnit(m) listener: beginBlockFunctionBody({) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(0, {, }) - listener: endExtensionTypeConstructor(ET, (, null, }) + listener: endConstructor(DeclarationKind.ExtensionType, ET, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.ExtensionType, 1, {, }) diff --git a/pkg/front_end/parser_testcases/declaring_constructors/extension_type_primary_constructor_body_error.dart.expect b/pkg/front_end/parser_testcases/declaring_constructors/extension_type_primary_constructor_body_error.dart.expect index d10db040224..f4dc99b0007 100644 --- a/pkg/front_end/parser_testcases/declaring_constructors/extension_type_primary_constructor_body_error.dart.expect +++ b/pkg/front_end/parser_testcases/declaring_constructors/extension_type_primary_constructor_body_error.dart.expect @@ -70,7 +70,7 @@ beginCompilationUnit(extension) handleAsyncModifier(null, null) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) - endExtensionTypeMethod(null, this, (, null, }) + endMethod(DeclarationKind.ExtensionType, null, this, (, null, }) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.ExtensionType, 1, {, }) endExtensionTypeDeclaration(extension, null, extension, type, }) @@ -126,7 +126,7 @@ beginCompilationUnit(extension) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) handleRecoverableError(ConstructorWithWrongName, this, this) - endExtensionTypeConstructor(this, (, :, }) + endConstructor(DeclarationKind.ExtensionType, this, (, :, }) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.ExtensionType, 1, {, }) endExtensionTypeDeclaration(extension, null, extension, type, }) @@ -172,7 +172,7 @@ beginCompilationUnit(extension) handleAsyncModifier(null, null) handleEmptyFunctionBody(;) handleRecoverableError(ExtensionTypeDeclaresAbstractMember, this, this) - endExtensionTypeMethod(null, this, (, null, ;) + endMethod(DeclarationKind.ExtensionType, null, this, (, null, ;) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.ExtensionType, 1, {, }) endExtensionTypeDeclaration(extension, null, extension, type, }) @@ -227,7 +227,7 @@ beginCompilationUnit(extension) handleAsyncModifier(null, null) handleEmptyFunctionBody(;) handleRecoverableError(ConstructorWithWrongName, this, this) - endExtensionTypeConstructor(this, (, :, ;) + endConstructor(DeclarationKind.ExtensionType, this, (, :, ;) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.ExtensionType, 1, {, }) endExtensionTypeDeclaration(extension, null, extension, type, }) diff --git a/pkg/front_end/parser_testcases/declaring_constructors/extension_type_primary_constructor_body_error.dart.intertwined.expect b/pkg/front_end/parser_testcases/declaring_constructors/extension_type_primary_constructor_body_error.dart.intertwined.expect index 640a26f8897..cde698f2407 100644 --- a/pkg/front_end/parser_testcases/declaring_constructors/extension_type_primary_constructor_body_error.dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/declaring_constructors/extension_type_primary_constructor_body_error.dart.intertwined.expect @@ -76,7 +76,7 @@ parseUnit(extension) listener: beginBlockFunctionBody({) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(0, {, }) - listener: endExtensionTypeMethod(null, this, (, null, }) + listener: endMethod(DeclarationKind.ExtensionType, null, this, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.ExtensionType, 1, {, }) @@ -181,7 +181,7 @@ parseUnit(extension) listener: endBlockFunctionBody(0, {, }) reportRecoverableError(this, ConstructorWithWrongName) listener: handleRecoverableError(ConstructorWithWrongName, this, this) - listener: endExtensionTypeConstructor(this, (, :, }) + listener: endConstructor(DeclarationKind.ExtensionType, this, (, :, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.ExtensionType, 1, {, }) @@ -261,7 +261,7 @@ parseUnit(extension) listener: handleEmptyFunctionBody(;) reportRecoverableError(this, ExtensionTypeDeclaresAbstractMember) listener: handleRecoverableError(ExtensionTypeDeclaresAbstractMember, this, this) - listener: endExtensionTypeMethod(null, this, (, null, ;) + listener: endMethod(DeclarationKind.ExtensionType, null, this, (, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.ExtensionType, 1, {, }) @@ -364,7 +364,7 @@ parseUnit(extension) listener: handleEmptyFunctionBody(;) reportRecoverableError(this, ConstructorWithWrongName) listener: handleRecoverableError(ConstructorWithWrongName, this, this) - listener: endExtensionTypeConstructor(this, (, :, ;) + listener: endConstructor(DeclarationKind.ExtensionType, this, (, :, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.ExtensionType, 1, {, }) diff --git a/pkg/front_end/parser_testcases/declaring_constructors/factory_constructor_head.dart.expect b/pkg/front_end/parser_testcases/declaring_constructors/factory_constructor_head.dart.expect index cf5b86dba81..9dfcaac8f13 100644 --- a/pkg/front_end/parser_testcases/declaring_constructors/factory_constructor_head.dart.expect +++ b/pkg/front_end/parser_testcases/declaring_constructors/factory_constructor_head.dart.expect @@ -15,43 +15,43 @@ beginCompilationUnit(class) beginMetadataStar(external) endMetadataStar(0) beginMember() - beginFactoryMethod(DeclarationKind.Class, {, external, null) + beginFactory(DeclarationKind.Class, {, external, null) handleNoIdentifier(factory) handleNoTypeVariables(() beginFormalParameters((, MemberKind.Factory) endFormalParameters(0, (, ), MemberKind.Factory) handleAsyncModifier(null, null) handleEmptyFunctionBody(;) - endClassFactoryMethod(external, factory, ;) + endFactory(DeclarationKind.Class, external, factory, ;) endMember() beginMetadataStar(external) endMetadataStar(0) beginMember() - beginFactoryMethod(DeclarationKind.Class, ;, external, null) + beginFactory(DeclarationKind.Class, ;, external, null) handleIdentifier(C, methodDeclaration) handleNoTypeVariables(() beginFormalParameters((, MemberKind.Factory) endFormalParameters(0, (, ), MemberKind.Factory) handleAsyncModifier(null, null) handleEmptyFunctionBody(;) - endClassFactoryMethod(external, factory, ;) + endFactory(DeclarationKind.Class, external, factory, ;) endMember() beginMetadataStar(external) endMetadataStar(0) beginMember() - beginFactoryMethod(DeclarationKind.Class, ;, external, null) + beginFactory(DeclarationKind.Class, ;, external, null) handleIdentifier(name, methodDeclaration) handleNoTypeVariables(() beginFormalParameters((, MemberKind.Factory) endFormalParameters(0, (, ), MemberKind.Factory) handleAsyncModifier(null, null) handleEmptyFunctionBody(;) - endClassFactoryMethod(external, factory, ;) + endFactory(DeclarationKind.Class, external, factory, ;) endMember() beginMetadataStar(external) endMetadataStar(0) beginMember() - beginFactoryMethod(DeclarationKind.Class, ;, external, null) + beginFactory(DeclarationKind.Class, ;, external, null) handleIdentifier(C, methodDeclaration) handleIdentifier(name, methodDeclarationContinuation) handleQualified(.) @@ -60,12 +60,12 @@ beginCompilationUnit(class) endFormalParameters(0, (, ), MemberKind.Factory) handleAsyncModifier(null, null) handleEmptyFunctionBody(;) - endClassFactoryMethod(external, factory, ;) + endFactory(DeclarationKind.Class, external, factory, ;) endMember() beginMetadataStar(factory) endMetadataStar(0) beginMember() - beginFactoryMethod(DeclarationKind.Class, ;, null, null) + beginFactory(DeclarationKind.Class, ;, null, null) handleNoIdentifier(factory) handleNoTypeVariables(() beginFormalParameters((, MemberKind.Factory) @@ -77,12 +77,12 @@ beginCompilationUnit(class) endArguments(0, (, )) handleSend(C, )) handleExpressionFunctionBody(=>, ;) - endClassFactoryMethod(factory, factory, ;) + endFactory(DeclarationKind.Class, factory, factory, ;) endMember() beginMetadataStar(factory) endMetadataStar(0) beginMember() - beginFactoryMethod(DeclarationKind.Class, ;, null, null) + beginFactory(DeclarationKind.Class, ;, null, null) handleIdentifier(C, methodDeclaration) handleNoTypeVariables(() beginFormalParameters((, MemberKind.Factory) @@ -94,12 +94,12 @@ beginCompilationUnit(class) endArguments(0, (, )) handleSend(C, )) handleExpressionFunctionBody(=>, ;) - endClassFactoryMethod(factory, factory, ;) + endFactory(DeclarationKind.Class, factory, factory, ;) endMember() beginMetadataStar(factory) endMetadataStar(0) beginMember() - beginFactoryMethod(DeclarationKind.Class, ;, null, null) + beginFactory(DeclarationKind.Class, ;, null, null) handleIdentifier(name, methodDeclaration) handleNoTypeVariables(() beginFormalParameters((, MemberKind.Factory) @@ -111,12 +111,12 @@ beginCompilationUnit(class) endArguments(0, (, )) handleSend(C, )) handleExpressionFunctionBody(=>, ;) - endClassFactoryMethod(factory, factory, ;) + endFactory(DeclarationKind.Class, factory, factory, ;) endMember() beginMetadataStar(factory) endMetadataStar(0) beginMember() - beginFactoryMethod(DeclarationKind.Class, ;, null, null) + beginFactory(DeclarationKind.Class, ;, null, null) handleIdentifier(C, methodDeclaration) handleIdentifier(name, methodDeclarationContinuation) handleQualified(.) @@ -130,12 +130,12 @@ beginCompilationUnit(class) endArguments(0, (, )) handleSend(C, )) handleExpressionFunctionBody(=>, ;) - endClassFactoryMethod(factory, factory, ;) + endFactory(DeclarationKind.Class, factory, factory, ;) endMember() beginMetadataStar(factory) endMetadataStar(0) beginMember() - beginFactoryMethod(DeclarationKind.Class, ;, null, null) + beginFactory(DeclarationKind.Class, ;, null, null) handleNoIdentifier(factory) handleNoTypeVariables(() beginFormalParameters((, MemberKind.Factory) @@ -143,12 +143,12 @@ beginCompilationUnit(class) handleAsyncModifier(null, null) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) - endClassFactoryMethod(factory, factory, }) + endFactory(DeclarationKind.Class, factory, factory, }) endMember() beginMetadataStar(factory) endMetadataStar(0) beginMember() - beginFactoryMethod(DeclarationKind.Class, }, null, null) + beginFactory(DeclarationKind.Class, }, null, null) handleIdentifier(C, methodDeclaration) handleNoTypeVariables(() beginFormalParameters((, MemberKind.Factory) @@ -156,12 +156,12 @@ beginCompilationUnit(class) handleAsyncModifier(null, null) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) - endClassFactoryMethod(factory, factory, }) + endFactory(DeclarationKind.Class, factory, factory, }) endMember() beginMetadataStar(factory) endMetadataStar(0) beginMember() - beginFactoryMethod(DeclarationKind.Class, }, null, null) + beginFactory(DeclarationKind.Class, }, null, null) handleIdentifier(name, methodDeclaration) handleNoTypeVariables(() beginFormalParameters((, MemberKind.Factory) @@ -169,12 +169,12 @@ beginCompilationUnit(class) handleAsyncModifier(null, null) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) - endClassFactoryMethod(factory, factory, }) + endFactory(DeclarationKind.Class, factory, factory, }) endMember() beginMetadataStar(factory) endMetadataStar(0) beginMember() - beginFactoryMethod(DeclarationKind.Class, }, null, null) + beginFactory(DeclarationKind.Class, }, null, null) handleIdentifier(C, methodDeclaration) handleIdentifier(name, methodDeclarationContinuation) handleQualified(.) @@ -184,12 +184,12 @@ beginCompilationUnit(class) handleAsyncModifier(null, null) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) - endClassFactoryMethod(factory, factory, }) + endFactory(DeclarationKind.Class, factory, factory, }) endMember() beginMetadataStar(factory) endMetadataStar(0) beginMember() - beginFactoryMethod(DeclarationKind.Class, }, null, null) + beginFactory(DeclarationKind.Class, }, null, null) handleNoIdentifier(factory) handleNoTypeVariables(() beginFormalParameters((, MemberKind.Factory) @@ -202,12 +202,12 @@ beginCompilationUnit(class) handleNoConstructorReferenceContinuationAfterTypeArguments(C) endConstructorReference(C, null, C, ConstructorReferenceContext.RedirectingFactory) endRedirectingFactoryBody(=, ;) - endClassFactoryMethod(factory, factory, ;) + endFactory(DeclarationKind.Class, factory, factory, ;) endMember() beginMetadataStar(factory) endMetadataStar(0) beginMember() - beginFactoryMethod(DeclarationKind.Class, ;, null, null) + beginFactory(DeclarationKind.Class, ;, null, null) handleIdentifier(C, methodDeclaration) handleNoTypeVariables(() beginFormalParameters((, MemberKind.Factory) @@ -220,12 +220,12 @@ beginCompilationUnit(class) handleNoConstructorReferenceContinuationAfterTypeArguments(C) endConstructorReference(C, null, C, ConstructorReferenceContext.RedirectingFactory) endRedirectingFactoryBody(=, ;) - endClassFactoryMethod(factory, factory, ;) + endFactory(DeclarationKind.Class, factory, factory, ;) endMember() beginMetadataStar(factory) endMetadataStar(0) beginMember() - beginFactoryMethod(DeclarationKind.Class, ;, null, null) + beginFactory(DeclarationKind.Class, ;, null, null) handleIdentifier(name, methodDeclaration) handleNoTypeVariables(() beginFormalParameters((, MemberKind.Factory) @@ -238,12 +238,12 @@ beginCompilationUnit(class) handleNoConstructorReferenceContinuationAfterTypeArguments(C) endConstructorReference(C, null, C, ConstructorReferenceContext.RedirectingFactory) endRedirectingFactoryBody(=, ;) - endClassFactoryMethod(factory, factory, ;) + endFactory(DeclarationKind.Class, factory, factory, ;) endMember() beginMetadataStar(factory) endMetadataStar(0) beginMember() - beginFactoryMethod(DeclarationKind.Class, ;, null, null) + beginFactory(DeclarationKind.Class, ;, null, null) handleIdentifier(C, methodDeclaration) handleIdentifier(name, methodDeclarationContinuation) handleQualified(.) @@ -258,48 +258,48 @@ beginCompilationUnit(class) handleNoConstructorReferenceContinuationAfterTypeArguments(C) endConstructorReference(C, null, C, ConstructorReferenceContext.RedirectingFactory) endRedirectingFactoryBody(=, ;) - endClassFactoryMethod(factory, factory, ;) + endFactory(DeclarationKind.Class, factory, factory, ;) endMember() beginMetadataStar(external) endMetadataStar(0) beginMember() - beginFactoryMethod(DeclarationKind.Class, ;, external, const) + beginFactory(DeclarationKind.Class, ;, external, const) handleNoIdentifier(factory) handleNoTypeVariables(() beginFormalParameters((, MemberKind.Factory) endFormalParameters(0, (, ), MemberKind.Factory) handleAsyncModifier(null, null) handleEmptyFunctionBody(;) - endClassFactoryMethod(external, factory, ;) + endFactory(DeclarationKind.Class, external, factory, ;) endMember() beginMetadataStar(external) endMetadataStar(0) beginMember() - beginFactoryMethod(DeclarationKind.Class, ;, external, const) + beginFactory(DeclarationKind.Class, ;, external, const) handleIdentifier(C, methodDeclaration) handleNoTypeVariables(() beginFormalParameters((, MemberKind.Factory) endFormalParameters(0, (, ), MemberKind.Factory) handleAsyncModifier(null, null) handleEmptyFunctionBody(;) - endClassFactoryMethod(external, factory, ;) + endFactory(DeclarationKind.Class, external, factory, ;) endMember() beginMetadataStar(external) endMetadataStar(0) beginMember() - beginFactoryMethod(DeclarationKind.Class, ;, external, const) + beginFactory(DeclarationKind.Class, ;, external, const) handleIdentifier(name, methodDeclaration) handleNoTypeVariables(() beginFormalParameters((, MemberKind.Factory) endFormalParameters(0, (, ), MemberKind.Factory) handleAsyncModifier(null, null) handleEmptyFunctionBody(;) - endClassFactoryMethod(external, factory, ;) + endFactory(DeclarationKind.Class, external, factory, ;) endMember() beginMetadataStar(external) endMetadataStar(0) beginMember() - beginFactoryMethod(DeclarationKind.Class, ;, external, const) + beginFactory(DeclarationKind.Class, ;, external, const) handleIdentifier(C, methodDeclaration) handleIdentifier(name, methodDeclarationContinuation) handleQualified(.) @@ -308,12 +308,12 @@ beginCompilationUnit(class) endFormalParameters(0, (, ), MemberKind.Factory) handleAsyncModifier(null, null) handleEmptyFunctionBody(;) - endClassFactoryMethod(external, factory, ;) + endFactory(DeclarationKind.Class, external, factory, ;) endMember() beginMetadataStar(const) endMetadataStar(0) beginMember() - beginFactoryMethod(DeclarationKind.Class, ;, null, const) + beginFactory(DeclarationKind.Class, ;, null, const) handleNoIdentifier(factory) handleNoTypeVariables(() beginFormalParameters((, MemberKind.Factory) @@ -326,12 +326,12 @@ beginCompilationUnit(class) endArguments(0, (, )) handleSend(C, )) handleExpressionFunctionBody(=>, ;) - endClassFactoryMethod(const, factory, ;) + endFactory(DeclarationKind.Class, const, factory, ;) endMember() beginMetadataStar(const) endMetadataStar(0) beginMember() - beginFactoryMethod(DeclarationKind.Class, ;, null, const) + beginFactory(DeclarationKind.Class, ;, null, const) handleIdentifier(C, methodDeclaration) handleNoTypeVariables(() beginFormalParameters((, MemberKind.Factory) @@ -344,12 +344,12 @@ beginCompilationUnit(class) endArguments(0, (, )) handleSend(C, )) handleExpressionFunctionBody(=>, ;) - endClassFactoryMethod(const, factory, ;) + endFactory(DeclarationKind.Class, const, factory, ;) endMember() beginMetadataStar(const) endMetadataStar(0) beginMember() - beginFactoryMethod(DeclarationKind.Class, ;, null, const) + beginFactory(DeclarationKind.Class, ;, null, const) handleIdentifier(name, methodDeclaration) handleNoTypeVariables(() beginFormalParameters((, MemberKind.Factory) @@ -362,12 +362,12 @@ beginCompilationUnit(class) endArguments(0, (, )) handleSend(C, )) handleExpressionFunctionBody(=>, ;) - endClassFactoryMethod(const, factory, ;) + endFactory(DeclarationKind.Class, const, factory, ;) endMember() beginMetadataStar(const) endMetadataStar(0) beginMember() - beginFactoryMethod(DeclarationKind.Class, ;, null, const) + beginFactory(DeclarationKind.Class, ;, null, const) handleIdentifier(C, methodDeclaration) handleIdentifier(name, methodDeclarationContinuation) handleQualified(.) @@ -382,12 +382,12 @@ beginCompilationUnit(class) endArguments(0, (, )) handleSend(C, )) handleExpressionFunctionBody(=>, ;) - endClassFactoryMethod(const, factory, ;) + endFactory(DeclarationKind.Class, const, factory, ;) endMember() beginMetadataStar(const) endMetadataStar(0) beginMember() - beginFactoryMethod(DeclarationKind.Class, ;, null, const) + beginFactory(DeclarationKind.Class, ;, null, const) handleNoIdentifier(factory) handleNoTypeVariables(() beginFormalParameters((, MemberKind.Factory) @@ -396,12 +396,12 @@ beginCompilationUnit(class) handleConstFactory(const) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) - endClassFactoryMethod(const, factory, }) + endFactory(DeclarationKind.Class, const, factory, }) endMember() beginMetadataStar(const) endMetadataStar(0) beginMember() - beginFactoryMethod(DeclarationKind.Class, }, null, const) + beginFactory(DeclarationKind.Class, }, null, const) handleIdentifier(C, methodDeclaration) handleNoTypeVariables(() beginFormalParameters((, MemberKind.Factory) @@ -410,12 +410,12 @@ beginCompilationUnit(class) handleConstFactory(const) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) - endClassFactoryMethod(const, factory, }) + endFactory(DeclarationKind.Class, const, factory, }) endMember() beginMetadataStar(const) endMetadataStar(0) beginMember() - beginFactoryMethod(DeclarationKind.Class, }, null, const) + beginFactory(DeclarationKind.Class, }, null, const) handleIdentifier(name, methodDeclaration) handleNoTypeVariables(() beginFormalParameters((, MemberKind.Factory) @@ -424,12 +424,12 @@ beginCompilationUnit(class) handleConstFactory(const) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) - endClassFactoryMethod(const, factory, }) + endFactory(DeclarationKind.Class, const, factory, }) endMember() beginMetadataStar(const) endMetadataStar(0) beginMember() - beginFactoryMethod(DeclarationKind.Class, }, null, const) + beginFactory(DeclarationKind.Class, }, null, const) handleIdentifier(C, methodDeclaration) handleIdentifier(name, methodDeclarationContinuation) handleQualified(.) @@ -440,12 +440,12 @@ beginCompilationUnit(class) handleConstFactory(const) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) - endClassFactoryMethod(const, factory, }) + endFactory(DeclarationKind.Class, const, factory, }) endMember() beginMetadataStar(const) endMetadataStar(0) beginMember() - beginFactoryMethod(DeclarationKind.Class, }, null, const) + beginFactory(DeclarationKind.Class, }, null, const) handleNoIdentifier(factory) handleNoTypeVariables(() beginFormalParameters((, MemberKind.Factory) @@ -458,12 +458,12 @@ beginCompilationUnit(class) handleNoConstructorReferenceContinuationAfterTypeArguments(C) endConstructorReference(C, null, C, ConstructorReferenceContext.RedirectingFactory) endRedirectingFactoryBody(=, ;) - endClassFactoryMethod(const, factory, ;) + endFactory(DeclarationKind.Class, const, factory, ;) endMember() beginMetadataStar(const) endMetadataStar(0) beginMember() - beginFactoryMethod(DeclarationKind.Class, ;, null, const) + beginFactory(DeclarationKind.Class, ;, null, const) handleIdentifier(C, methodDeclaration) handleNoTypeVariables(() beginFormalParameters((, MemberKind.Factory) @@ -476,12 +476,12 @@ beginCompilationUnit(class) handleNoConstructorReferenceContinuationAfterTypeArguments(C) endConstructorReference(C, null, C, ConstructorReferenceContext.RedirectingFactory) endRedirectingFactoryBody(=, ;) - endClassFactoryMethod(const, factory, ;) + endFactory(DeclarationKind.Class, const, factory, ;) endMember() beginMetadataStar(const) endMetadataStar(0) beginMember() - beginFactoryMethod(DeclarationKind.Class, ;, null, const) + beginFactory(DeclarationKind.Class, ;, null, const) handleIdentifier(name, methodDeclaration) handleNoTypeVariables(() beginFormalParameters((, MemberKind.Factory) @@ -494,12 +494,12 @@ beginCompilationUnit(class) handleNoConstructorReferenceContinuationAfterTypeArguments(C) endConstructorReference(C, null, C, ConstructorReferenceContext.RedirectingFactory) endRedirectingFactoryBody(=, ;) - endClassFactoryMethod(const, factory, ;) + endFactory(DeclarationKind.Class, const, factory, ;) endMember() beginMetadataStar(const) endMetadataStar(0) beginMember() - beginFactoryMethod(DeclarationKind.Class, ;, null, const) + beginFactory(DeclarationKind.Class, ;, null, const) handleIdentifier(C, methodDeclaration) handleIdentifier(name, methodDeclarationContinuation) handleQualified(.) @@ -514,7 +514,7 @@ beginCompilationUnit(class) handleNoConstructorReferenceContinuationAfterTypeArguments(C) endConstructorReference(C, null, C, ConstructorReferenceContext.RedirectingFactory) endRedirectingFactoryBody(=, ;) - endClassFactoryMethod(const, factory, ;) + endFactory(DeclarationKind.Class, const, factory, ;) endMember() beginMetadataStar(void) endMetadataStar(0) @@ -533,7 +533,7 @@ beginCompilationUnit(class) endArguments(0, (, )) handleSend(C, )) handleExpressionFunctionBody(=>, ;) - endClassMethod(null, void, (, null, ;) + endMethod(DeclarationKind.Class, null, void, (, null, ;) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 33, {, }) endClassDeclaration(class, }) diff --git a/pkg/front_end/parser_testcases/declaring_constructors/factory_constructor_head.dart.intertwined.expect b/pkg/front_end/parser_testcases/declaring_constructors/factory_constructor_head.dart.intertwined.expect index 0a5b5cce7ca..7da28af97cf 100644 --- a/pkg/front_end/parser_testcases/declaring_constructors/factory_constructor_head.dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/declaring_constructors/factory_constructor_head.dart.intertwined.expect @@ -34,7 +34,7 @@ parseUnit(class) listener: endMetadataStar(0) listener: beginMember() parseFactoryMethod(external, DeclarationKind.Class, {, external, null, null, false) - listener: beginFactoryMethod(DeclarationKind.Class, {, external, null) + listener: beginFactory(DeclarationKind.Class, {, external, null) listener: handleNoIdentifier(factory) parseMethodTypeVar(factory) listener: handleNoTypeVariables(() @@ -48,7 +48,7 @@ parseUnit(class) inPlainSync() parseFunctionBody(), false, true) listener: handleEmptyFunctionBody(;) - listener: endClassFactoryMethod(external, factory, ;) + listener: endFactory(DeclarationKind.Class, external, factory, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, external) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, C) @@ -57,7 +57,7 @@ parseUnit(class) listener: endMetadataStar(0) listener: beginMember() parseFactoryMethod(external, DeclarationKind.Class, ;, external, null, null, true) - listener: beginFactoryMethod(DeclarationKind.Class, ;, external, null) + listener: beginFactory(DeclarationKind.Class, ;, external, null) ensureIdentifier(factory, methodDeclaration) listener: handleIdentifier(C, methodDeclaration) parseQualifiedRestOpt(C, methodDeclarationContinuation) @@ -73,7 +73,7 @@ parseUnit(class) inPlainSync() parseFunctionBody(), false, true) listener: handleEmptyFunctionBody(;) - listener: endClassFactoryMethod(external, factory, ;) + listener: endFactory(DeclarationKind.Class, external, factory, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, external) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, C) @@ -82,7 +82,7 @@ parseUnit(class) listener: endMetadataStar(0) listener: beginMember() parseFactoryMethod(external, DeclarationKind.Class, ;, external, null, null, true) - listener: beginFactoryMethod(DeclarationKind.Class, ;, external, null) + listener: beginFactory(DeclarationKind.Class, ;, external, null) ensureIdentifier(factory, methodDeclaration) listener: handleIdentifier(name, methodDeclaration) parseQualifiedRestOpt(name, methodDeclarationContinuation) @@ -98,7 +98,7 @@ parseUnit(class) inPlainSync() parseFunctionBody(), false, true) listener: handleEmptyFunctionBody(;) - listener: endClassFactoryMethod(external, factory, ;) + listener: endFactory(DeclarationKind.Class, external, factory, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, external) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, C) @@ -107,7 +107,7 @@ parseUnit(class) listener: endMetadataStar(0) listener: beginMember() parseFactoryMethod(external, DeclarationKind.Class, ;, external, null, null, true) - listener: beginFactoryMethod(DeclarationKind.Class, ;, external, null) + listener: beginFactory(DeclarationKind.Class, ;, external, null) ensureIdentifier(factory, methodDeclaration) listener: handleIdentifier(C, methodDeclaration) parseQualifiedRestOpt(C, methodDeclarationContinuation) @@ -127,7 +127,7 @@ parseUnit(class) inPlainSync() parseFunctionBody(), false, true) listener: handleEmptyFunctionBody(;) - listener: endClassFactoryMethod(external, factory, ;) + listener: endFactory(DeclarationKind.Class, external, factory, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, factory) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, C) @@ -136,7 +136,7 @@ parseUnit(class) listener: endMetadataStar(0) listener: beginMember() parseFactoryMethod(;, DeclarationKind.Class, ;, null, null, null, false) - listener: beginFactoryMethod(DeclarationKind.Class, ;, null, null) + listener: beginFactory(DeclarationKind.Class, ;, null, null) listener: handleNoIdentifier(factory) parseMethodTypeVar(factory) listener: handleNoTypeVariables(() @@ -172,7 +172,7 @@ parseUnit(class) ensureSemicolon()) listener: handleExpressionFunctionBody(=>, ;) inGenerator() - listener: endClassFactoryMethod(factory, factory, ;) + listener: endFactory(DeclarationKind.Class, factory, factory, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, factory) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, C) @@ -181,7 +181,7 @@ parseUnit(class) listener: endMetadataStar(0) listener: beginMember() parseFactoryMethod(;, DeclarationKind.Class, ;, null, null, null, true) - listener: beginFactoryMethod(DeclarationKind.Class, ;, null, null) + listener: beginFactory(DeclarationKind.Class, ;, null, null) ensureIdentifier(factory, methodDeclaration) listener: handleIdentifier(C, methodDeclaration) parseQualifiedRestOpt(C, methodDeclarationContinuation) @@ -219,7 +219,7 @@ parseUnit(class) ensureSemicolon()) listener: handleExpressionFunctionBody(=>, ;) inGenerator() - listener: endClassFactoryMethod(factory, factory, ;) + listener: endFactory(DeclarationKind.Class, factory, factory, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, factory) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, C) @@ -228,7 +228,7 @@ parseUnit(class) listener: endMetadataStar(0) listener: beginMember() parseFactoryMethod(;, DeclarationKind.Class, ;, null, null, null, true) - listener: beginFactoryMethod(DeclarationKind.Class, ;, null, null) + listener: beginFactory(DeclarationKind.Class, ;, null, null) ensureIdentifier(factory, methodDeclaration) listener: handleIdentifier(name, methodDeclaration) parseQualifiedRestOpt(name, methodDeclarationContinuation) @@ -266,7 +266,7 @@ parseUnit(class) ensureSemicolon()) listener: handleExpressionFunctionBody(=>, ;) inGenerator() - listener: endClassFactoryMethod(factory, factory, ;) + listener: endFactory(DeclarationKind.Class, factory, factory, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, factory) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, C) @@ -275,7 +275,7 @@ parseUnit(class) listener: endMetadataStar(0) listener: beginMember() parseFactoryMethod(;, DeclarationKind.Class, ;, null, null, null, true) - listener: beginFactoryMethod(DeclarationKind.Class, ;, null, null) + listener: beginFactory(DeclarationKind.Class, ;, null, null) ensureIdentifier(factory, methodDeclaration) listener: handleIdentifier(C, methodDeclaration) parseQualifiedRestOpt(C, methodDeclarationContinuation) @@ -317,7 +317,7 @@ parseUnit(class) ensureSemicolon()) listener: handleExpressionFunctionBody(=>, ;) inGenerator() - listener: endClassFactoryMethod(factory, factory, ;) + listener: endFactory(DeclarationKind.Class, factory, factory, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, factory) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, C) @@ -326,7 +326,7 @@ parseUnit(class) listener: endMetadataStar(0) listener: beginMember() parseFactoryMethod(;, DeclarationKind.Class, ;, null, null, null, false) - listener: beginFactoryMethod(DeclarationKind.Class, ;, null, null) + listener: beginFactory(DeclarationKind.Class, ;, null, null) listener: handleNoIdentifier(factory) parseMethodTypeVar(factory) listener: handleNoTypeVariables(() @@ -342,7 +342,7 @@ parseUnit(class) listener: beginBlockFunctionBody({) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(0, {, }) - listener: endClassFactoryMethod(factory, factory, }) + listener: endFactory(DeclarationKind.Class, factory, factory, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, factory) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, C) @@ -351,7 +351,7 @@ parseUnit(class) listener: endMetadataStar(0) listener: beginMember() parseFactoryMethod(}, DeclarationKind.Class, }, null, null, null, true) - listener: beginFactoryMethod(DeclarationKind.Class, }, null, null) + listener: beginFactory(DeclarationKind.Class, }, null, null) ensureIdentifier(factory, methodDeclaration) listener: handleIdentifier(C, methodDeclaration) parseQualifiedRestOpt(C, methodDeclarationContinuation) @@ -369,7 +369,7 @@ parseUnit(class) listener: beginBlockFunctionBody({) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(0, {, }) - listener: endClassFactoryMethod(factory, factory, }) + listener: endFactory(DeclarationKind.Class, factory, factory, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, factory) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, C) @@ -378,7 +378,7 @@ parseUnit(class) listener: endMetadataStar(0) listener: beginMember() parseFactoryMethod(}, DeclarationKind.Class, }, null, null, null, true) - listener: beginFactoryMethod(DeclarationKind.Class, }, null, null) + listener: beginFactory(DeclarationKind.Class, }, null, null) ensureIdentifier(factory, methodDeclaration) listener: handleIdentifier(name, methodDeclaration) parseQualifiedRestOpt(name, methodDeclarationContinuation) @@ -396,7 +396,7 @@ parseUnit(class) listener: beginBlockFunctionBody({) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(0, {, }) - listener: endClassFactoryMethod(factory, factory, }) + listener: endFactory(DeclarationKind.Class, factory, factory, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, factory) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, C) @@ -405,7 +405,7 @@ parseUnit(class) listener: endMetadataStar(0) listener: beginMember() parseFactoryMethod(}, DeclarationKind.Class, }, null, null, null, true) - listener: beginFactoryMethod(DeclarationKind.Class, }, null, null) + listener: beginFactory(DeclarationKind.Class, }, null, null) ensureIdentifier(factory, methodDeclaration) listener: handleIdentifier(C, methodDeclaration) parseQualifiedRestOpt(C, methodDeclarationContinuation) @@ -427,7 +427,7 @@ parseUnit(class) listener: beginBlockFunctionBody({) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(0, {, }) - listener: endClassFactoryMethod(factory, factory, }) + listener: endFactory(DeclarationKind.Class, factory, factory, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, factory) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, C) @@ -436,7 +436,7 @@ parseUnit(class) listener: endMetadataStar(0) listener: beginMember() parseFactoryMethod(}, DeclarationKind.Class, }, null, null, null, false) - listener: beginFactoryMethod(DeclarationKind.Class, }, null, null) + listener: beginFactory(DeclarationKind.Class, }, null, null) listener: handleNoIdentifier(factory) parseMethodTypeVar(factory) listener: handleNoTypeVariables(() @@ -460,7 +460,7 @@ parseUnit(class) listener: endConstructorReference(C, null, C, ConstructorReferenceContext.RedirectingFactory) ensureSemicolon(C) listener: endRedirectingFactoryBody(=, ;) - listener: endClassFactoryMethod(factory, factory, ;) + listener: endFactory(DeclarationKind.Class, factory, factory, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, factory) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, C) @@ -469,7 +469,7 @@ parseUnit(class) listener: endMetadataStar(0) listener: beginMember() parseFactoryMethod(;, DeclarationKind.Class, ;, null, null, null, true) - listener: beginFactoryMethod(DeclarationKind.Class, ;, null, null) + listener: beginFactory(DeclarationKind.Class, ;, null, null) ensureIdentifier(factory, methodDeclaration) listener: handleIdentifier(C, methodDeclaration) parseQualifiedRestOpt(C, methodDeclarationContinuation) @@ -495,7 +495,7 @@ parseUnit(class) listener: endConstructorReference(C, null, C, ConstructorReferenceContext.RedirectingFactory) ensureSemicolon(C) listener: endRedirectingFactoryBody(=, ;) - listener: endClassFactoryMethod(factory, factory, ;) + listener: endFactory(DeclarationKind.Class, factory, factory, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, factory) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, C) @@ -504,7 +504,7 @@ parseUnit(class) listener: endMetadataStar(0) listener: beginMember() parseFactoryMethod(;, DeclarationKind.Class, ;, null, null, null, true) - listener: beginFactoryMethod(DeclarationKind.Class, ;, null, null) + listener: beginFactory(DeclarationKind.Class, ;, null, null) ensureIdentifier(factory, methodDeclaration) listener: handleIdentifier(name, methodDeclaration) parseQualifiedRestOpt(name, methodDeclarationContinuation) @@ -530,7 +530,7 @@ parseUnit(class) listener: endConstructorReference(C, null, C, ConstructorReferenceContext.RedirectingFactory) ensureSemicolon(C) listener: endRedirectingFactoryBody(=, ;) - listener: endClassFactoryMethod(factory, factory, ;) + listener: endFactory(DeclarationKind.Class, factory, factory, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, factory) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, C) @@ -539,7 +539,7 @@ parseUnit(class) listener: endMetadataStar(0) listener: beginMember() parseFactoryMethod(;, DeclarationKind.Class, ;, null, null, null, true) - listener: beginFactoryMethod(DeclarationKind.Class, ;, null, null) + listener: beginFactory(DeclarationKind.Class, ;, null, null) ensureIdentifier(factory, methodDeclaration) listener: handleIdentifier(C, methodDeclaration) parseQualifiedRestOpt(C, methodDeclarationContinuation) @@ -569,7 +569,7 @@ parseUnit(class) listener: endConstructorReference(C, null, C, ConstructorReferenceContext.RedirectingFactory) ensureSemicolon(C) listener: endRedirectingFactoryBody(=, ;) - listener: endClassFactoryMethod(factory, factory, ;) + listener: endFactory(DeclarationKind.Class, factory, factory, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, external) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, C) @@ -578,7 +578,7 @@ parseUnit(class) listener: endMetadataStar(0) listener: beginMember() parseFactoryMethod(const, DeclarationKind.Class, ;, external, null, const, false) - listener: beginFactoryMethod(DeclarationKind.Class, ;, external, const) + listener: beginFactory(DeclarationKind.Class, ;, external, const) listener: handleNoIdentifier(factory) parseMethodTypeVar(factory) listener: handleNoTypeVariables(() @@ -592,7 +592,7 @@ parseUnit(class) inPlainSync() parseFunctionBody(), false, true) listener: handleEmptyFunctionBody(;) - listener: endClassFactoryMethod(external, factory, ;) + listener: endFactory(DeclarationKind.Class, external, factory, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, external) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, C) @@ -601,7 +601,7 @@ parseUnit(class) listener: endMetadataStar(0) listener: beginMember() parseFactoryMethod(const, DeclarationKind.Class, ;, external, null, const, true) - listener: beginFactoryMethod(DeclarationKind.Class, ;, external, const) + listener: beginFactory(DeclarationKind.Class, ;, external, const) ensureIdentifier(factory, methodDeclaration) listener: handleIdentifier(C, methodDeclaration) parseQualifiedRestOpt(C, methodDeclarationContinuation) @@ -617,7 +617,7 @@ parseUnit(class) inPlainSync() parseFunctionBody(), false, true) listener: handleEmptyFunctionBody(;) - listener: endClassFactoryMethod(external, factory, ;) + listener: endFactory(DeclarationKind.Class, external, factory, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, external) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, C) @@ -626,7 +626,7 @@ parseUnit(class) listener: endMetadataStar(0) listener: beginMember() parseFactoryMethod(const, DeclarationKind.Class, ;, external, null, const, true) - listener: beginFactoryMethod(DeclarationKind.Class, ;, external, const) + listener: beginFactory(DeclarationKind.Class, ;, external, const) ensureIdentifier(factory, methodDeclaration) listener: handleIdentifier(name, methodDeclaration) parseQualifiedRestOpt(name, methodDeclarationContinuation) @@ -642,7 +642,7 @@ parseUnit(class) inPlainSync() parseFunctionBody(), false, true) listener: handleEmptyFunctionBody(;) - listener: endClassFactoryMethod(external, factory, ;) + listener: endFactory(DeclarationKind.Class, external, factory, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, external) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, C) @@ -651,7 +651,7 @@ parseUnit(class) listener: endMetadataStar(0) listener: beginMember() parseFactoryMethod(const, DeclarationKind.Class, ;, external, null, const, true) - listener: beginFactoryMethod(DeclarationKind.Class, ;, external, const) + listener: beginFactory(DeclarationKind.Class, ;, external, const) ensureIdentifier(factory, methodDeclaration) listener: handleIdentifier(C, methodDeclaration) parseQualifiedRestOpt(C, methodDeclarationContinuation) @@ -671,7 +671,7 @@ parseUnit(class) inPlainSync() parseFunctionBody(), false, true) listener: handleEmptyFunctionBody(;) - listener: endClassFactoryMethod(external, factory, ;) + listener: endFactory(DeclarationKind.Class, external, factory, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, const) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, C) @@ -680,7 +680,7 @@ parseUnit(class) listener: endMetadataStar(0) listener: beginMember() parseFactoryMethod(const, DeclarationKind.Class, ;, null, null, const, false) - listener: beginFactoryMethod(DeclarationKind.Class, ;, null, const) + listener: beginFactory(DeclarationKind.Class, ;, null, const) listener: handleNoIdentifier(factory) parseMethodTypeVar(factory) listener: handleNoTypeVariables(() @@ -717,7 +717,7 @@ parseUnit(class) ensureSemicolon()) listener: handleExpressionFunctionBody(=>, ;) inGenerator() - listener: endClassFactoryMethod(const, factory, ;) + listener: endFactory(DeclarationKind.Class, const, factory, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, const) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, C) @@ -726,7 +726,7 @@ parseUnit(class) listener: endMetadataStar(0) listener: beginMember() parseFactoryMethod(const, DeclarationKind.Class, ;, null, null, const, true) - listener: beginFactoryMethod(DeclarationKind.Class, ;, null, const) + listener: beginFactory(DeclarationKind.Class, ;, null, const) ensureIdentifier(factory, methodDeclaration) listener: handleIdentifier(C, methodDeclaration) parseQualifiedRestOpt(C, methodDeclarationContinuation) @@ -765,7 +765,7 @@ parseUnit(class) ensureSemicolon()) listener: handleExpressionFunctionBody(=>, ;) inGenerator() - listener: endClassFactoryMethod(const, factory, ;) + listener: endFactory(DeclarationKind.Class, const, factory, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, const) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, C) @@ -774,7 +774,7 @@ parseUnit(class) listener: endMetadataStar(0) listener: beginMember() parseFactoryMethod(const, DeclarationKind.Class, ;, null, null, const, true) - listener: beginFactoryMethod(DeclarationKind.Class, ;, null, const) + listener: beginFactory(DeclarationKind.Class, ;, null, const) ensureIdentifier(factory, methodDeclaration) listener: handleIdentifier(name, methodDeclaration) parseQualifiedRestOpt(name, methodDeclarationContinuation) @@ -813,7 +813,7 @@ parseUnit(class) ensureSemicolon()) listener: handleExpressionFunctionBody(=>, ;) inGenerator() - listener: endClassFactoryMethod(const, factory, ;) + listener: endFactory(DeclarationKind.Class, const, factory, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, const) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, C) @@ -822,7 +822,7 @@ parseUnit(class) listener: endMetadataStar(0) listener: beginMember() parseFactoryMethod(const, DeclarationKind.Class, ;, null, null, const, true) - listener: beginFactoryMethod(DeclarationKind.Class, ;, null, const) + listener: beginFactory(DeclarationKind.Class, ;, null, const) ensureIdentifier(factory, methodDeclaration) listener: handleIdentifier(C, methodDeclaration) parseQualifiedRestOpt(C, methodDeclarationContinuation) @@ -865,7 +865,7 @@ parseUnit(class) ensureSemicolon()) listener: handleExpressionFunctionBody(=>, ;) inGenerator() - listener: endClassFactoryMethod(const, factory, ;) + listener: endFactory(DeclarationKind.Class, const, factory, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, const) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, C) @@ -874,7 +874,7 @@ parseUnit(class) listener: endMetadataStar(0) listener: beginMember() parseFactoryMethod(const, DeclarationKind.Class, ;, null, null, const, false) - listener: beginFactoryMethod(DeclarationKind.Class, ;, null, const) + listener: beginFactory(DeclarationKind.Class, ;, null, const) listener: handleNoIdentifier(factory) parseMethodTypeVar(factory) listener: handleNoTypeVariables(() @@ -891,7 +891,7 @@ parseUnit(class) listener: beginBlockFunctionBody({) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(0, {, }) - listener: endClassFactoryMethod(const, factory, }) + listener: endFactory(DeclarationKind.Class, const, factory, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, const) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, C) @@ -900,7 +900,7 @@ parseUnit(class) listener: endMetadataStar(0) listener: beginMember() parseFactoryMethod(const, DeclarationKind.Class, }, null, null, const, true) - listener: beginFactoryMethod(DeclarationKind.Class, }, null, const) + listener: beginFactory(DeclarationKind.Class, }, null, const) ensureIdentifier(factory, methodDeclaration) listener: handleIdentifier(C, methodDeclaration) parseQualifiedRestOpt(C, methodDeclarationContinuation) @@ -919,7 +919,7 @@ parseUnit(class) listener: beginBlockFunctionBody({) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(0, {, }) - listener: endClassFactoryMethod(const, factory, }) + listener: endFactory(DeclarationKind.Class, const, factory, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, const) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, C) @@ -928,7 +928,7 @@ parseUnit(class) listener: endMetadataStar(0) listener: beginMember() parseFactoryMethod(const, DeclarationKind.Class, }, null, null, const, true) - listener: beginFactoryMethod(DeclarationKind.Class, }, null, const) + listener: beginFactory(DeclarationKind.Class, }, null, const) ensureIdentifier(factory, methodDeclaration) listener: handleIdentifier(name, methodDeclaration) parseQualifiedRestOpt(name, methodDeclarationContinuation) @@ -947,7 +947,7 @@ parseUnit(class) listener: beginBlockFunctionBody({) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(0, {, }) - listener: endClassFactoryMethod(const, factory, }) + listener: endFactory(DeclarationKind.Class, const, factory, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, const) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, C) @@ -956,7 +956,7 @@ parseUnit(class) listener: endMetadataStar(0) listener: beginMember() parseFactoryMethod(const, DeclarationKind.Class, }, null, null, const, true) - listener: beginFactoryMethod(DeclarationKind.Class, }, null, const) + listener: beginFactory(DeclarationKind.Class, }, null, const) ensureIdentifier(factory, methodDeclaration) listener: handleIdentifier(C, methodDeclaration) parseQualifiedRestOpt(C, methodDeclarationContinuation) @@ -979,7 +979,7 @@ parseUnit(class) listener: beginBlockFunctionBody({) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(0, {, }) - listener: endClassFactoryMethod(const, factory, }) + listener: endFactory(DeclarationKind.Class, const, factory, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, const) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, C) @@ -988,7 +988,7 @@ parseUnit(class) listener: endMetadataStar(0) listener: beginMember() parseFactoryMethod(const, DeclarationKind.Class, }, null, null, const, false) - listener: beginFactoryMethod(DeclarationKind.Class, }, null, const) + listener: beginFactory(DeclarationKind.Class, }, null, const) listener: handleNoIdentifier(factory) parseMethodTypeVar(factory) listener: handleNoTypeVariables(() @@ -1012,7 +1012,7 @@ parseUnit(class) listener: endConstructorReference(C, null, C, ConstructorReferenceContext.RedirectingFactory) ensureSemicolon(C) listener: endRedirectingFactoryBody(=, ;) - listener: endClassFactoryMethod(const, factory, ;) + listener: endFactory(DeclarationKind.Class, const, factory, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, const) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, C) @@ -1021,7 +1021,7 @@ parseUnit(class) listener: endMetadataStar(0) listener: beginMember() parseFactoryMethod(const, DeclarationKind.Class, ;, null, null, const, true) - listener: beginFactoryMethod(DeclarationKind.Class, ;, null, const) + listener: beginFactory(DeclarationKind.Class, ;, null, const) ensureIdentifier(factory, methodDeclaration) listener: handleIdentifier(C, methodDeclaration) parseQualifiedRestOpt(C, methodDeclarationContinuation) @@ -1047,7 +1047,7 @@ parseUnit(class) listener: endConstructorReference(C, null, C, ConstructorReferenceContext.RedirectingFactory) ensureSemicolon(C) listener: endRedirectingFactoryBody(=, ;) - listener: endClassFactoryMethod(const, factory, ;) + listener: endFactory(DeclarationKind.Class, const, factory, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, const) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, C) @@ -1056,7 +1056,7 @@ parseUnit(class) listener: endMetadataStar(0) listener: beginMember() parseFactoryMethod(const, DeclarationKind.Class, ;, null, null, const, true) - listener: beginFactoryMethod(DeclarationKind.Class, ;, null, const) + listener: beginFactory(DeclarationKind.Class, ;, null, const) ensureIdentifier(factory, methodDeclaration) listener: handleIdentifier(name, methodDeclaration) parseQualifiedRestOpt(name, methodDeclarationContinuation) @@ -1082,7 +1082,7 @@ parseUnit(class) listener: endConstructorReference(C, null, C, ConstructorReferenceContext.RedirectingFactory) ensureSemicolon(C) listener: endRedirectingFactoryBody(=, ;) - listener: endClassFactoryMethod(const, factory, ;) + listener: endFactory(DeclarationKind.Class, const, factory, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, const) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, C) @@ -1091,7 +1091,7 @@ parseUnit(class) listener: endMetadataStar(0) listener: beginMember() parseFactoryMethod(const, DeclarationKind.Class, ;, null, null, const, true) - listener: beginFactoryMethod(DeclarationKind.Class, ;, null, const) + listener: beginFactory(DeclarationKind.Class, ;, null, const) ensureIdentifier(factory, methodDeclaration) listener: handleIdentifier(C, methodDeclaration) parseQualifiedRestOpt(C, methodDeclarationContinuation) @@ -1121,7 +1121,7 @@ parseUnit(class) listener: endConstructorReference(C, null, C, ConstructorReferenceContext.RedirectingFactory) ensureSemicolon(C) listener: endRedirectingFactoryBody(=, ;) - listener: endClassFactoryMethod(const, factory, ;) + listener: endFactory(DeclarationKind.Class, const, factory, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, void) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, C) @@ -1172,7 +1172,7 @@ parseUnit(class) ensureSemicolon()) listener: handleExpressionFunctionBody(=>, ;) inGenerator() - listener: endClassMethod(null, void, (, null, ;) + listener: endMethod(DeclarationKind.Class, null, void, (, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 33, {, }) diff --git a/pkg/front_end/parser_testcases/dot_shorthands/const_no_identifier_recovery.dart.expect b/pkg/front_end/parser_testcases/dot_shorthands/const_no_identifier_recovery.dart.expect index 7055b0f124c..dfaa4c1afa5 100644 --- a/pkg/front_end/parser_testcases/dot_shorthands/const_no_identifier_recovery.dart.expect +++ b/pkg/front_end/parser_testcases/dot_shorthands/const_no_identifier_recovery.dart.expect @@ -27,7 +27,7 @@ beginCompilationUnit(class) handleType(int, null) handleIdentifier(x, fieldDeclaration) handleNoFieldInitializer(;) - endClassFields(null, null, null, null, null, null, final, 1, final, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) endMember() beginMetadataStar(const) endMetadataStar(0) @@ -50,7 +50,7 @@ beginCompilationUnit(class) handleNoInitializers() handleAsyncModifier(null, null) handleEmptyFunctionBody(;) - endClassConstructor(const, (, null, ;) + endConstructor(DeclarationKind.Class, const, (, null, ;) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 2, {, }) endClassDeclaration(class, }) diff --git a/pkg/front_end/parser_testcases/dot_shorthands/const_no_identifier_recovery.dart.intertwined.expect b/pkg/front_end/parser_testcases/dot_shorthands/const_no_identifier_recovery.dart.intertwined.expect index 50233d6e1f2..cdc31839b56 100644 --- a/pkg/front_end/parser_testcases/dot_shorthands/const_no_identifier_recovery.dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/dot_shorthands/const_no_identifier_recovery.dart.intertwined.expect @@ -44,7 +44,7 @@ parseUnit(class) listener: handleIdentifier(x, fieldDeclaration) parseFieldInitializerOpt(x, x, null, null, null, null, final, DeclarationKind.Class, Color) listener: handleNoFieldInitializer(;) - listener: endClassFields(null, null, null, null, null, null, final, 1, final, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, const) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Color) @@ -87,7 +87,7 @@ parseUnit(class) inPlainSync() parseFunctionBody(), false, true) listener: handleEmptyFunctionBody(;) - listener: endClassConstructor(const, (, null, ;) + listener: endConstructor(DeclarationKind.Class, const, (, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 2, {, }) diff --git a/pkg/front_end/parser_testcases/dot_shorthands/const_property_recovery.dart.expect b/pkg/front_end/parser_testcases/dot_shorthands/const_property_recovery.dart.expect index 509e19a91bc..603b8d174c0 100644 --- a/pkg/front_end/parser_testcases/dot_shorthands/const_property_recovery.dart.expect +++ b/pkg/front_end/parser_testcases/dot_shorthands/const_property_recovery.dart.expect @@ -27,7 +27,7 @@ beginCompilationUnit(class) handleType(int, null) handleIdentifier(x, fieldDeclaration) handleNoFieldInitializer(;) - endClassFields(null, null, null, null, null, null, final, 1, final, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) endMember() beginMetadataStar(const) endMetadataStar(0) @@ -50,7 +50,7 @@ beginCompilationUnit(class) handleNoInitializers() handleAsyncModifier(null, null) handleEmptyFunctionBody(;) - endClassConstructor(const, (, null, ;) + endConstructor(DeclarationKind.Class, const, (, null, ;) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 2, {, }) endClassDeclaration(class, }) diff --git a/pkg/front_end/parser_testcases/dot_shorthands/const_property_recovery.dart.intertwined.expect b/pkg/front_end/parser_testcases/dot_shorthands/const_property_recovery.dart.intertwined.expect index c98f88a0278..48e8898742e 100644 --- a/pkg/front_end/parser_testcases/dot_shorthands/const_property_recovery.dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/dot_shorthands/const_property_recovery.dart.intertwined.expect @@ -44,7 +44,7 @@ parseUnit(class) listener: handleIdentifier(x, fieldDeclaration) parseFieldInitializerOpt(x, x, null, null, null, null, final, DeclarationKind.Class, Color) listener: handleNoFieldInitializer(;) - listener: endClassFields(null, null, null, null, null, null, final, 1, final, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, const) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Color) @@ -87,7 +87,7 @@ parseUnit(class) inPlainSync() parseFunctionBody(), false, true) listener: handleEmptyFunctionBody(;) - listener: endClassConstructor(const, (, null, ;) + listener: endConstructor(DeclarationKind.Class, const, (, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 2, {, }) diff --git a/pkg/front_end/parser_testcases/enhanced_enums/entries_with_type_arguments.dart.expect b/pkg/front_end/parser_testcases/enhanced_enums/entries_with_type_arguments.dart.expect index bf8d1524fb5..29148bf72f4 100644 --- a/pkg/front_end/parser_testcases/enhanced_enums/entries_with_type_arguments.dart.expect +++ b/pkg/front_end/parser_testcases/enhanced_enums/entries_with_type_arguments.dart.expect @@ -92,7 +92,7 @@ beginCompilationUnit(enum) handleNoInitializers() handleAsyncModifier(null, null) handleEmptyFunctionBody(;) - endEnumConstructor(const, (, null, ;) + endConstructor(DeclarationKind.Enum, const, (, null, ;) endMember() beginMetadataStar(const) endMetadataStar(0) @@ -117,7 +117,7 @@ beginCompilationUnit(enum) handleNoInitializers() handleAsyncModifier(null, null) handleEmptyFunctionBody(;) - endEnumConstructor(const, (, null, ;) + endConstructor(DeclarationKind.Enum, const, (, null, ;) endMember() endEnumBody({, }) endEnumDeclaration(enum, enum, {, 2, }) diff --git a/pkg/front_end/parser_testcases/enhanced_enums/entries_with_type_arguments.dart.intertwined.expect b/pkg/front_end/parser_testcases/enhanced_enums/entries_with_type_arguments.dart.intertwined.expect index d1ceb5ecfae..f2d93698e47 100644 --- a/pkg/front_end/parser_testcases/enhanced_enums/entries_with_type_arguments.dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/enhanced_enums/entries_with_type_arguments.dart.intertwined.expect @@ -147,7 +147,7 @@ parseUnit(enum) inPlainSync() parseFunctionBody(), false, true) listener: handleEmptyFunctionBody(;) - listener: endEnumConstructor(const, (, null, ;) + listener: endConstructor(DeclarationKind.Enum, const, (, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, const) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Enum, E) @@ -192,7 +192,7 @@ parseUnit(enum) inPlainSync() parseFunctionBody(), false, true) listener: handleEmptyFunctionBody(;) - listener: endEnumConstructor(const, (, null, ;) + listener: endConstructor(DeclarationKind.Enum, const, (, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endEnumBody({, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/bracket_mismatch_01.dart.expect b/pkg/front_end/parser_testcases/error_recovery/bracket_mismatch_01.dart.expect index b7e53704200..70c396a0234 100644 --- a/pkg/front_end/parser_testcases/error_recovery/bracket_mismatch_01.dart.expect +++ b/pkg/front_end/parser_testcases/error_recovery/bracket_mismatch_01.dart.expect @@ -43,7 +43,7 @@ beginCompilationUnit(class) handleNoInitializers() handleAsyncModifier(null, null) handleEmptyFunctionBody(;) - endClassConstructor(C, (, null, ;) + endConstructor(DeclarationKind.Class, C, (, null, ;) endMember() beginMetadataStar(C) endMetadataStar(0) @@ -105,7 +105,7 @@ beginCompilationUnit(class) handleSend(C, )) endReturnStatement(true, return, ;) endBlockFunctionBody(1, {, }) - endClassMethod(null, C, (, null, }) + endMethod(DeclarationKind.Class, null, C, (, null, }) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 2, {, }) endClassDeclaration(class, }) @@ -144,7 +144,7 @@ beginCompilationUnit(class) handleNoInitializers() handleAsyncModifier(null, null) handleEmptyFunctionBody(;) - endClassConstructor(D, (, null, ;) + endConstructor(DeclarationKind.Class, D, (, null, ;) endMember() beginMetadataStar(D) endMetadataStar(0) @@ -210,7 +210,7 @@ beginCompilationUnit(class) handleSend(D, )) endReturnStatement(true, return, ;) endBlockFunctionBody(1, {, }) - endClassMethod(null, D, (, null, }) + endMethod(DeclarationKind.Class, null, D, (, null, }) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 2, {, }) endClassDeclaration(class, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/bracket_mismatch_01.dart.intertwined.expect b/pkg/front_end/parser_testcases/error_recovery/bracket_mismatch_01.dart.intertwined.expect index ecb21261cf5..944f27dc771 100644 --- a/pkg/front_end/parser_testcases/error_recovery/bracket_mismatch_01.dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/error_recovery/bracket_mismatch_01.dart.intertwined.expect @@ -69,7 +69,7 @@ parseUnit(class) inPlainSync() parseFunctionBody(), false, true) listener: handleEmptyFunctionBody(;) - listener: endClassConstructor(C, (, null, ;) + listener: endConstructor(DeclarationKind.Class, C, (, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, C) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, C) @@ -269,7 +269,7 @@ parseUnit(class) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(1, {, }) - listener: endClassMethod(null, C, (, null, }) + listener: endMethod(DeclarationKind.Class, null, C, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 2, {, }) @@ -342,7 +342,7 @@ parseUnit(class) inPlainSync() parseFunctionBody(), false, true) listener: handleEmptyFunctionBody(;) - listener: endClassConstructor(D, (, null, ;) + listener: endConstructor(DeclarationKind.Class, D, (, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, D) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, D) @@ -555,7 +555,7 @@ parseUnit(class) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(1, {, }) - listener: endClassMethod(null, D, (, null, }) + listener: endMethod(DeclarationKind.Class, null, D, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 2, {, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/constructor_recovery_bad_name_general.crash_dart.expect b/pkg/front_end/parser_testcases/error_recovery/constructor_recovery_bad_name_general.crash_dart.expect index 2f80b9fe8bc..df419005be3 100644 --- a/pkg/front_end/parser_testcases/error_recovery/constructor_recovery_bad_name_general.crash_dart.expect +++ b/pkg/front_end/parser_testcases/error_recovery/constructor_recovery_bad_name_general.crash_dart.expect @@ -150,7 +150,7 @@ beginCompilationUnit(class) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) handleRecoverableError(ConstructorWithWrongName, foo, foo) - endClassConstructor(foo, (, null, }) + endConstructor(DeclarationKind.Class, foo, (, null, }) endMember() beginMetadataStar(foo) endMetadataStar(0) @@ -177,7 +177,7 @@ beginCompilationUnit(class) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) handleRecoverableError(ConstructorWithWrongName, foo, foo) - endClassConstructor(foo, (, :, }) + endConstructor(DeclarationKind.Class, foo, (, :, }) endMember() beginMetadataStar(foo) endMetadataStar(0) @@ -202,7 +202,7 @@ beginCompilationUnit(class) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) handleRecoverableError(ConstructorWithWrongName, foo, foo) - endClassConstructor(foo, (, :, }) + endConstructor(DeclarationKind.Class, foo, (, :, }) endMember() beginMetadataStar(get) endMetadataStar(0) @@ -217,7 +217,7 @@ beginCompilationUnit(class) handleLiteralInt(0) handleExpressionFunctionBody(=>, ;) handleRecoverableError(MemberWithSameNameAsClass, Foo, Foo) - endClassMethod(get, get, =>, null, ;) + endMethod(DeclarationKind.Class, get, get, =>, null, ;) endMember() beginMetadataStar(get) endMetadataStar(0) @@ -235,7 +235,7 @@ beginCompilationUnit(class) endReturnStatement(true, return, ;) endBlockFunctionBody(1, {, }) handleRecoverableError(MemberWithSameNameAsClass, Foo, Foo) - endClassMethod(get, get, {, null, }) + endMethod(DeclarationKind.Class, get, get, {, null, }) endMember() beginMetadataStar(get) endMetadataStar(0) @@ -254,7 +254,7 @@ beginCompilationUnit(class) handleLiteralInt(0) handleExpressionFunctionBody(=>, ;) handleRecoverableError(GetterConstructor, get, get) - endClassConstructor(get, (, null, ;) + endConstructor(DeclarationKind.Class, get, (, null, ;) endMember() beginMetadataStar(get) endMetadataStar(0) @@ -276,7 +276,7 @@ beginCompilationUnit(class) endReturnStatement(true, return, ;) endBlockFunctionBody(1, {, }) handleRecoverableError(GetterConstructor, get, get) - endClassConstructor(get, (, null, }) + endConstructor(DeclarationKind.Class, get, (, null, }) endMember() beginMetadataStar(get) endMetadataStar(0) @@ -302,7 +302,7 @@ beginCompilationUnit(class) handleLiteralInt(0) handleExpressionFunctionBody(=>, ;) handleRecoverableError(GetterConstructor, get, get) - endClassConstructor(get, (, :, ;) + endConstructor(DeclarationKind.Class, get, (, :, ;) endMember() beginMetadataStar(get) endMetadataStar(0) @@ -333,7 +333,7 @@ beginCompilationUnit(class) endReturnStatement(true, return, ;) endBlockFunctionBody(1, {, }) handleRecoverableError(GetterConstructor, get, get) - endClassConstructor(get, (, :, }) + endConstructor(DeclarationKind.Class, get, (, :, }) endMember() beginMetadataStar(set) endMetadataStar(0) @@ -350,7 +350,7 @@ beginCompilationUnit(class) handleLiteralInt(0) handleExpressionFunctionBody(=>, ;) handleRecoverableError(MemberWithSameNameAsClass, Foo, Foo) - endClassMethod(set, set, (, null, ;) + endMethod(DeclarationKind.Class, set, set, (, null, ;) endMember() beginMetadataStar(set) endMetadataStar(0) @@ -370,7 +370,7 @@ beginCompilationUnit(class) endReturnStatement(true, return, ;) endBlockFunctionBody(1, {, }) handleRecoverableError(MemberWithSameNameAsClass, Foo, Foo) - endClassMethod(set, set, (, null, }) + endMethod(DeclarationKind.Class, set, set, (, null, }) endMember() beginMetadataStar(set) endMetadataStar(0) @@ -389,7 +389,7 @@ beginCompilationUnit(class) handleLiteralInt(0) handleExpressionFunctionBody(=>, ;) handleRecoverableError(SetterConstructor, set, set) - endClassConstructor(set, (, null, ;) + endConstructor(DeclarationKind.Class, set, (, null, ;) endMember() beginMetadataStar(set) endMetadataStar(0) @@ -411,7 +411,7 @@ beginCompilationUnit(class) endReturnStatement(true, return, ;) endBlockFunctionBody(1, {, }) handleRecoverableError(SetterConstructor, set, set) - endClassConstructor(set, (, null, }) + endConstructor(DeclarationKind.Class, set, (, null, }) endMember() beginMetadataStar(set) endMetadataStar(0) @@ -437,7 +437,7 @@ beginCompilationUnit(class) handleLiteralInt(0) handleExpressionFunctionBody(=>, ;) handleRecoverableError(SetterConstructor, set, set) - endClassConstructor(set, (, :, ;) + endConstructor(DeclarationKind.Class, set, (, :, ;) endMember() beginMetadataStar(set) endMetadataStar(0) @@ -468,7 +468,7 @@ beginCompilationUnit(class) endReturnStatement(true, return, ;) endBlockFunctionBody(1, {, }) handleRecoverableError(SetterConstructor, set, set) - endClassConstructor(set, (, :, }) + endConstructor(DeclarationKind.Class, set, (, :, }) endMember() beginMetadataStar(external) endMetadataStar(0) @@ -492,7 +492,7 @@ beginCompilationUnit(class) handleAsyncModifier(null, null) handleEmptyFunctionBody(;) handleRecoverableError(ExternalConstructorWithInitializer, :, :) - endClassConstructor(external, (, :, ;) + endConstructor(DeclarationKind.Class, external, (, :, ;) endMember() beginMetadataStar(external) endMetadataStar(0) @@ -523,7 +523,7 @@ beginCompilationUnit(class) endReturnStatement(true, return, ;) endBlockFunctionBody(1, {, }) handleRecoverableError(ExternalConstructorWithInitializer, :, :) - endClassConstructor(external, (, :, }) + endConstructor(DeclarationKind.Class, external, (, :, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -535,7 +535,7 @@ beginCompilationUnit(class) handleIdentifier(Foo, fieldDeclaration) handleRecoverableError(MemberWithSameNameAsClass, Foo, Foo) handleNoFieldInitializer(;) - endClassFields(null, null, null, null, null, null, null, 1, int, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -551,7 +551,7 @@ beginCompilationUnit(class) handleNoFieldInitializer(,) handleIdentifier(B, fieldDeclaration) handleNoFieldInitializer(;) - endClassFields(null, null, null, null, null, null, null, 3, int, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 3, int, ;) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 19, {, }) endClassDeclaration(class, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/constructor_recovery_bad_name_general.crash_dart.intertwined.expect b/pkg/front_end/parser_testcases/error_recovery/constructor_recovery_bad_name_general.crash_dart.intertwined.expect index 3c8de1bbb86..83184dd2f5b 100644 --- a/pkg/front_end/parser_testcases/error_recovery/constructor_recovery_bad_name_general.crash_dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/error_recovery/constructor_recovery_bad_name_general.crash_dart.intertwined.expect @@ -63,7 +63,7 @@ parseUnit(class) listener: endBlockFunctionBody(0, {, }) reportRecoverableError(foo, ConstructorWithWrongName) listener: handleRecoverableError(ConstructorWithWrongName, foo, foo) - listener: endClassConstructor(foo, (, null, }) + listener: endConstructor(DeclarationKind.Class, foo, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, foo) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Foo) @@ -128,7 +128,7 @@ parseUnit(class) listener: endBlockFunctionBody(0, {, }) reportRecoverableError(foo, ConstructorWithWrongName) listener: handleRecoverableError(ConstructorWithWrongName, foo, foo) - listener: endClassConstructor(foo, (, :, }) + listener: endConstructor(DeclarationKind.Class, foo, (, :, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, foo) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Foo) @@ -189,7 +189,7 @@ parseUnit(class) listener: endBlockFunctionBody(0, {, }) reportRecoverableError(foo, ConstructorWithWrongName) listener: handleRecoverableError(ConstructorWithWrongName, foo, foo) - listener: endClassConstructor(foo, (, :, }) + listener: endConstructor(DeclarationKind.Class, foo, (, :, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, get) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Foo) @@ -228,7 +228,7 @@ parseUnit(class) inGenerator() reportRecoverableError(Foo, MemberWithSameNameAsClass) listener: handleRecoverableError(MemberWithSameNameAsClass, Foo, Foo) - listener: endClassMethod(get, get, =>, null, ;) + listener: endMethod(DeclarationKind.Class, get, get, =>, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, get) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Foo) @@ -274,7 +274,7 @@ parseUnit(class) listener: endBlockFunctionBody(1, {, }) reportRecoverableError(Foo, MemberWithSameNameAsClass) listener: handleRecoverableError(MemberWithSameNameAsClass, Foo, Foo) - listener: endClassMethod(get, get, {, null, }) + listener: endMethod(DeclarationKind.Class, get, get, {, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, get) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Foo) @@ -323,7 +323,7 @@ parseUnit(class) inGenerator() reportRecoverableError(get, GetterConstructor) listener: handleRecoverableError(GetterConstructor, get, get) - listener: endClassConstructor(get, (, null, ;) + listener: endConstructor(DeclarationKind.Class, get, (, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, get) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Foo) @@ -379,7 +379,7 @@ parseUnit(class) listener: endBlockFunctionBody(1, {, }) reportRecoverableError(get, GetterConstructor) listener: handleRecoverableError(GetterConstructor, get, get) - listener: endClassConstructor(get, (, null, }) + listener: endConstructor(DeclarationKind.Class, get, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, get) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Foo) @@ -451,7 +451,7 @@ parseUnit(class) inGenerator() reportRecoverableError(get, GetterConstructor) listener: handleRecoverableError(GetterConstructor, get, get) - listener: endClassConstructor(get, (, :, ;) + listener: endConstructor(DeclarationKind.Class, get, (, :, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, get) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Foo) @@ -534,7 +534,7 @@ parseUnit(class) listener: endBlockFunctionBody(1, {, }) reportRecoverableError(get, GetterConstructor) listener: handleRecoverableError(GetterConstructor, get, get) - listener: endClassConstructor(get, (, :, }) + listener: endConstructor(DeclarationKind.Class, get, (, :, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, set) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Foo) @@ -579,7 +579,7 @@ parseUnit(class) inGenerator() reportRecoverableError(Foo, MemberWithSameNameAsClass) listener: handleRecoverableError(MemberWithSameNameAsClass, Foo, Foo) - listener: endClassMethod(set, set, (, null, ;) + listener: endMethod(DeclarationKind.Class, set, set, (, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, set) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Foo) @@ -631,7 +631,7 @@ parseUnit(class) listener: endBlockFunctionBody(1, {, }) reportRecoverableError(Foo, MemberWithSameNameAsClass) listener: handleRecoverableError(MemberWithSameNameAsClass, Foo, Foo) - listener: endClassMethod(set, set, (, null, }) + listener: endMethod(DeclarationKind.Class, set, set, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, set) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Foo) @@ -680,7 +680,7 @@ parseUnit(class) inGenerator() reportRecoverableError(set, SetterConstructor) listener: handleRecoverableError(SetterConstructor, set, set) - listener: endClassConstructor(set, (, null, ;) + listener: endConstructor(DeclarationKind.Class, set, (, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, set) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Foo) @@ -736,7 +736,7 @@ parseUnit(class) listener: endBlockFunctionBody(1, {, }) reportRecoverableError(set, SetterConstructor) listener: handleRecoverableError(SetterConstructor, set, set) - listener: endClassConstructor(set, (, null, }) + listener: endConstructor(DeclarationKind.Class, set, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, set) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Foo) @@ -808,7 +808,7 @@ parseUnit(class) inGenerator() reportRecoverableError(set, SetterConstructor) listener: handleRecoverableError(SetterConstructor, set, set) - listener: endClassConstructor(set, (, :, ;) + listener: endConstructor(DeclarationKind.Class, set, (, :, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, set) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Foo) @@ -891,7 +891,7 @@ parseUnit(class) listener: endBlockFunctionBody(1, {, }) reportRecoverableError(set, SetterConstructor) listener: handleRecoverableError(SetterConstructor, set, set) - listener: endClassConstructor(set, (, :, }) + listener: endConstructor(DeclarationKind.Class, set, (, :, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, external) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Foo) @@ -950,7 +950,7 @@ parseUnit(class) listener: handleEmptyFunctionBody(;) reportRecoverableError(:, ExternalConstructorWithInitializer) listener: handleRecoverableError(ExternalConstructorWithInitializer, :, :) - listener: endClassConstructor(external, (, :, ;) + listener: endConstructor(DeclarationKind.Class, external, (, :, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, external) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Foo) @@ -1033,7 +1033,7 @@ parseUnit(class) listener: endBlockFunctionBody(1, {, }) reportRecoverableError(:, ExternalConstructorWithInitializer) listener: handleRecoverableError(ExternalConstructorWithInitializer, :, :) - listener: endClassConstructor(external, (, :, }) + listener: endConstructor(DeclarationKind.Class, external, (, :, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Foo) @@ -1052,7 +1052,7 @@ parseUnit(class) reportRecoverableError(Foo, MemberWithSameNameAsClass) listener: handleRecoverableError(MemberWithSameNameAsClass, Foo, Foo) listener: handleNoFieldInitializer(;) - listener: endClassFields(null, null, null, null, null, null, null, 1, int, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Foo) @@ -1079,7 +1079,7 @@ parseUnit(class) listener: handleIdentifier(B, fieldDeclaration) parseFieldInitializerOpt(B, B, null, null, null, null, null, DeclarationKind.Class, Foo) listener: handleNoFieldInitializer(;) - listener: endClassFields(null, null, null, null, null, null, null, 3, int, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 3, int, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 19, {, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/constructor_recovery_bad_name_get.crash_dart.expect b/pkg/front_end/parser_testcases/error_recovery/constructor_recovery_bad_name_get.crash_dart.expect index e356d81f297..c31b7c40824 100644 --- a/pkg/front_end/parser_testcases/error_recovery/constructor_recovery_bad_name_get.crash_dart.expect +++ b/pkg/front_end/parser_testcases/error_recovery/constructor_recovery_bad_name_get.crash_dart.expect @@ -59,7 +59,7 @@ beginCompilationUnit(class) endBlockFunctionBody(0, {, }) handleRecoverableError(ConstructorWithWrongName, foo, foo) handleRecoverableError(GetterConstructor, get, get) - endClassConstructor(get, (, null, }) + endConstructor(DeclarationKind.Class, get, (, null, }) endMember() beginMetadataStar(get) endMetadataStar(0) @@ -87,7 +87,7 @@ beginCompilationUnit(class) endBlockFunctionBody(0, {, }) handleRecoverableError(ConstructorWithWrongName, foo, foo) handleRecoverableError(GetterConstructor, get, get) - endClassConstructor(get, (, :, }) + endConstructor(DeclarationKind.Class, get, (, :, }) endMember() beginMetadataStar(get) endMetadataStar(0) @@ -114,7 +114,7 @@ beginCompilationUnit(class) endBlockFunctionBody(0, {, }) handleRecoverableError(ConstructorWithWrongName, foo, foo) handleRecoverableError(GetterConstructor, get, get) - endClassConstructor(get, (, :, }) + endConstructor(DeclarationKind.Class, get, (, :, }) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 3, {, }) endClassDeclaration(class, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/constructor_recovery_bad_name_get.crash_dart.intertwined.expect b/pkg/front_end/parser_testcases/error_recovery/constructor_recovery_bad_name_get.crash_dart.intertwined.expect index 946e6e61826..f4a7e67e532 100644 --- a/pkg/front_end/parser_testcases/error_recovery/constructor_recovery_bad_name_get.crash_dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/error_recovery/constructor_recovery_bad_name_get.crash_dart.intertwined.expect @@ -64,7 +64,7 @@ parseUnit(class) listener: handleRecoverableError(ConstructorWithWrongName, foo, foo) reportRecoverableError(get, GetterConstructor) listener: handleRecoverableError(GetterConstructor, get, get) - listener: endClassConstructor(get, (, null, }) + listener: endConstructor(DeclarationKind.Class, get, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, get) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Foo) @@ -130,7 +130,7 @@ parseUnit(class) listener: handleRecoverableError(ConstructorWithWrongName, foo, foo) reportRecoverableError(get, GetterConstructor) listener: handleRecoverableError(GetterConstructor, get, get) - listener: endClassConstructor(get, (, :, }) + listener: endConstructor(DeclarationKind.Class, get, (, :, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, get) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Foo) @@ -194,7 +194,7 @@ parseUnit(class) listener: handleRecoverableError(ConstructorWithWrongName, foo, foo) reportRecoverableError(get, GetterConstructor) listener: handleRecoverableError(GetterConstructor, get, get) - listener: endClassConstructor(get, (, :, }) + listener: endConstructor(DeclarationKind.Class, get, (, :, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 3, {, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/constructor_recovery_bad_name_return_type.crash_dart.expect b/pkg/front_end/parser_testcases/error_recovery/constructor_recovery_bad_name_return_type.crash_dart.expect index cec8d9c2301..7e79e158d8b 100644 --- a/pkg/front_end/parser_testcases/error_recovery/constructor_recovery_bad_name_return_type.crash_dart.expect +++ b/pkg/front_end/parser_testcases/error_recovery/constructor_recovery_bad_name_return_type.crash_dart.expect @@ -55,7 +55,7 @@ beginCompilationUnit(class) endBlockFunctionBody(0, {, }) handleRecoverableError(ConstructorWithWrongName, foo, foo) handleRecoverableError(ConstructorWithReturnType, void, void) - endClassConstructor(void, (, null, }) + endConstructor(DeclarationKind.Class, void, (, null, }) endMember() beginMetadataStar(void) endMetadataStar(0) @@ -83,7 +83,7 @@ beginCompilationUnit(class) endBlockFunctionBody(0, {, }) handleRecoverableError(ConstructorWithWrongName, foo, foo) handleRecoverableError(ConstructorWithReturnType, void, void) - endClassConstructor(void, (, :, }) + endConstructor(DeclarationKind.Class, void, (, :, }) endMember() beginMetadataStar(void) endMetadataStar(0) @@ -109,7 +109,7 @@ beginCompilationUnit(class) endBlockFunctionBody(0, {, }) handleRecoverableError(ConstructorWithWrongName, foo, foo) handleRecoverableError(ConstructorWithReturnType, void, void) - endClassConstructor(void, (, :, }) + endConstructor(DeclarationKind.Class, void, (, :, }) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 3, {, }) endClassDeclaration(class, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/constructor_recovery_bad_name_return_type.crash_dart.intertwined.expect b/pkg/front_end/parser_testcases/error_recovery/constructor_recovery_bad_name_return_type.crash_dart.intertwined.expect index 11e3cdbef0c..d07101d2860 100644 --- a/pkg/front_end/parser_testcases/error_recovery/constructor_recovery_bad_name_return_type.crash_dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/error_recovery/constructor_recovery_bad_name_return_type.crash_dart.intertwined.expect @@ -64,7 +64,7 @@ parseUnit(class) listener: handleRecoverableError(ConstructorWithWrongName, foo, foo) reportRecoverableError(void, ConstructorWithReturnType) listener: handleRecoverableError(ConstructorWithReturnType, void, void) - listener: endClassConstructor(void, (, null, }) + listener: endConstructor(DeclarationKind.Class, void, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, void) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Foo) @@ -130,7 +130,7 @@ parseUnit(class) listener: handleRecoverableError(ConstructorWithWrongName, foo, foo) reportRecoverableError(void, ConstructorWithReturnType) listener: handleRecoverableError(ConstructorWithReturnType, void, void) - listener: endClassConstructor(void, (, :, }) + listener: endConstructor(DeclarationKind.Class, void, (, :, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, void) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Foo) @@ -192,7 +192,7 @@ parseUnit(class) listener: handleRecoverableError(ConstructorWithWrongName, foo, foo) reportRecoverableError(void, ConstructorWithReturnType) listener: handleRecoverableError(ConstructorWithReturnType, void, void) - listener: endClassConstructor(void, (, :, }) + listener: endConstructor(DeclarationKind.Class, void, (, :, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 3, {, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/constructor_recovery_bad_name_set.crash_dart.expect b/pkg/front_end/parser_testcases/error_recovery/constructor_recovery_bad_name_set.crash_dart.expect index 2169e6da064..d5a5f0d24e8 100644 --- a/pkg/front_end/parser_testcases/error_recovery/constructor_recovery_bad_name_set.crash_dart.expect +++ b/pkg/front_end/parser_testcases/error_recovery/constructor_recovery_bad_name_set.crash_dart.expect @@ -55,7 +55,7 @@ beginCompilationUnit(class) endBlockFunctionBody(0, {, }) handleRecoverableError(ConstructorWithWrongName, foo, foo) handleRecoverableError(SetterConstructor, set, set) - endClassConstructor(set, (, null, }) + endConstructor(DeclarationKind.Class, set, (, null, }) endMember() beginMetadataStar(set) endMetadataStar(0) @@ -83,7 +83,7 @@ beginCompilationUnit(class) endBlockFunctionBody(0, {, }) handleRecoverableError(ConstructorWithWrongName, foo, foo) handleRecoverableError(SetterConstructor, set, set) - endClassConstructor(set, (, :, }) + endConstructor(DeclarationKind.Class, set, (, :, }) endMember() beginMetadataStar(set) endMetadataStar(0) @@ -109,7 +109,7 @@ beginCompilationUnit(class) endBlockFunctionBody(0, {, }) handleRecoverableError(ConstructorWithWrongName, foo, foo) handleRecoverableError(SetterConstructor, set, set) - endClassConstructor(set, (, :, }) + endConstructor(DeclarationKind.Class, set, (, :, }) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 3, {, }) endClassDeclaration(class, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/constructor_recovery_bad_name_set.crash_dart.intertwined.expect b/pkg/front_end/parser_testcases/error_recovery/constructor_recovery_bad_name_set.crash_dart.intertwined.expect index a6b8e50cbbf..23c0627fd56 100644 --- a/pkg/front_end/parser_testcases/error_recovery/constructor_recovery_bad_name_set.crash_dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/error_recovery/constructor_recovery_bad_name_set.crash_dart.intertwined.expect @@ -64,7 +64,7 @@ parseUnit(class) listener: handleRecoverableError(ConstructorWithWrongName, foo, foo) reportRecoverableError(set, SetterConstructor) listener: handleRecoverableError(SetterConstructor, set, set) - listener: endClassConstructor(set, (, null, }) + listener: endConstructor(DeclarationKind.Class, set, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, set) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Foo) @@ -130,7 +130,7 @@ parseUnit(class) listener: handleRecoverableError(ConstructorWithWrongName, foo, foo) reportRecoverableError(set, SetterConstructor) listener: handleRecoverableError(SetterConstructor, set, set) - listener: endClassConstructor(set, (, :, }) + listener: endConstructor(DeclarationKind.Class, set, (, :, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, set) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Foo) @@ -192,7 +192,7 @@ parseUnit(class) listener: handleRecoverableError(ConstructorWithWrongName, foo, foo) reportRecoverableError(set, SetterConstructor) listener: handleRecoverableError(SetterConstructor, set, set) - listener: endClassConstructor(set, (, :, }) + listener: endConstructor(DeclarationKind.Class, set, (, :, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 3, {, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/constructor_recovery_get.dart.expect b/pkg/front_end/parser_testcases/error_recovery/constructor_recovery_get.dart.expect index 418102914d0..ad4bd5dec42 100644 --- a/pkg/front_end/parser_testcases/error_recovery/constructor_recovery_get.dart.expect +++ b/pkg/front_end/parser_testcases/error_recovery/constructor_recovery_get.dart.expect @@ -53,7 +53,7 @@ beginCompilationUnit(class) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) handleRecoverableError(MemberWithSameNameAsClass, Foo, Foo) - endClassMethod(get, get, (, null, }) + endMethod(DeclarationKind.Class, get, get, (, null, }) endMember() beginMetadataStar(get) endMetadataStar(0) @@ -79,7 +79,7 @@ beginCompilationUnit(class) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) handleRecoverableError(GetterConstructor, get, get) - endClassConstructor(get, (, :, }) + endConstructor(DeclarationKind.Class, get, (, :, }) endMember() beginMetadataStar(get) endMetadataStar(0) @@ -97,7 +97,7 @@ beginCompilationUnit(class) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) handleRecoverableError(GetterConstructor, get, get) - endClassConstructor(get, (, null, }) + endConstructor(DeclarationKind.Class, get, (, null, }) endMember() beginMetadataStar(get) endMetadataStar(0) @@ -124,7 +124,7 @@ beginCompilationUnit(class) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) handleRecoverableError(GetterConstructor, get, get) - endClassConstructor(get, (, :, }) + endConstructor(DeclarationKind.Class, get, (, :, }) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 4, {, }) endClassDeclaration(class, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/constructor_recovery_get.dart.intertwined.expect b/pkg/front_end/parser_testcases/error_recovery/constructor_recovery_get.dart.intertwined.expect index 0f11b7b5302..f6a9261fd91 100644 --- a/pkg/front_end/parser_testcases/error_recovery/constructor_recovery_get.dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/error_recovery/constructor_recovery_get.dart.intertwined.expect @@ -60,7 +60,7 @@ parseUnit(class) listener: endBlockFunctionBody(0, {, }) reportRecoverableError(Foo, MemberWithSameNameAsClass) listener: handleRecoverableError(MemberWithSameNameAsClass, Foo, Foo) - listener: endClassMethod(get, get, (, null, }) + listener: endMethod(DeclarationKind.Class, get, get, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, get) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Foo) @@ -122,7 +122,7 @@ parseUnit(class) listener: endBlockFunctionBody(0, {, }) reportRecoverableError(get, GetterConstructor) listener: handleRecoverableError(GetterConstructor, get, get) - listener: endClassConstructor(get, (, :, }) + listener: endConstructor(DeclarationKind.Class, get, (, :, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, get) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Foo) @@ -159,7 +159,7 @@ parseUnit(class) listener: endBlockFunctionBody(0, {, }) reportRecoverableError(get, GetterConstructor) listener: handleRecoverableError(GetterConstructor, get, get) - listener: endClassConstructor(get, (, null, }) + listener: endConstructor(DeclarationKind.Class, get, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, get) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Foo) @@ -223,7 +223,7 @@ parseUnit(class) listener: endBlockFunctionBody(0, {, }) reportRecoverableError(get, GetterConstructor) listener: handleRecoverableError(GetterConstructor, get, get) - listener: endClassConstructor(get, (, :, }) + listener: endConstructor(DeclarationKind.Class, get, (, :, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 4, {, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/constructor_recovery_ok.dart.expect b/pkg/front_end/parser_testcases/error_recovery/constructor_recovery_ok.dart.expect index 61a4aa94cff..2e5d6465886 100644 --- a/pkg/front_end/parser_testcases/error_recovery/constructor_recovery_ok.dart.expect +++ b/pkg/front_end/parser_testcases/error_recovery/constructor_recovery_ok.dart.expect @@ -25,7 +25,7 @@ beginCompilationUnit(class) handleAsyncModifier(null, null) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) - endClassConstructor(Foo, (, null, }) + endConstructor(DeclarationKind.Class, Foo, (, null, }) endMember() beginMetadataStar(Foo) endMetadataStar(0) @@ -49,7 +49,7 @@ beginCompilationUnit(class) handleAsyncModifier(null, null) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) - endClassConstructor(Foo, (, :, }) + endConstructor(DeclarationKind.Class, Foo, (, :, }) endMember() beginMetadataStar(Foo) endMetadataStar(0) @@ -66,7 +66,7 @@ beginCompilationUnit(class) handleAsyncModifier(null, null) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) - endClassConstructor(Foo, (, null, }) + endConstructor(DeclarationKind.Class, Foo, (, null, }) endMember() beginMetadataStar(Foo) endMetadataStar(0) @@ -92,7 +92,7 @@ beginCompilationUnit(class) handleAsyncModifier(null, null) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) - endClassConstructor(Foo, (, :, }) + endConstructor(DeclarationKind.Class, Foo, (, :, }) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 4, {, }) endClassDeclaration(class, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/constructor_recovery_ok.dart.intertwined.expect b/pkg/front_end/parser_testcases/error_recovery/constructor_recovery_ok.dart.intertwined.expect index 6e2e5ebcb94..8636c8ea73d 100644 --- a/pkg/front_end/parser_testcases/error_recovery/constructor_recovery_ok.dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/error_recovery/constructor_recovery_ok.dart.intertwined.expect @@ -57,7 +57,7 @@ parseUnit(class) listener: beginBlockFunctionBody({) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(0, {, }) - listener: endClassConstructor(Foo, (, null, }) + listener: endConstructor(DeclarationKind.Class, Foo, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, Foo) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Foo) @@ -116,7 +116,7 @@ parseUnit(class) listener: beginBlockFunctionBody({) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(0, {, }) - listener: endClassConstructor(Foo, (, :, }) + listener: endConstructor(DeclarationKind.Class, Foo, (, :, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, Foo) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Foo) @@ -152,7 +152,7 @@ parseUnit(class) listener: beginBlockFunctionBody({) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(0, {, }) - listener: endClassConstructor(Foo, (, null, }) + listener: endConstructor(DeclarationKind.Class, Foo, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, Foo) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Foo) @@ -215,7 +215,7 @@ parseUnit(class) listener: beginBlockFunctionBody({) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(0, {, }) - listener: endClassConstructor(Foo, (, :, }) + listener: endConstructor(DeclarationKind.Class, Foo, (, :, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 4, {, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/constructor_recovery_operator.crash_dart.expect b/pkg/front_end/parser_testcases/error_recovery/constructor_recovery_operator.crash_dart.expect index 7596b14a748..93a829f79c5 100644 --- a/pkg/front_end/parser_testcases/error_recovery/constructor_recovery_operator.crash_dart.expect +++ b/pkg/front_end/parser_testcases/error_recovery/constructor_recovery_operator.crash_dart.expect @@ -99,7 +99,7 @@ beginCompilationUnit(class) handleAsyncModifier(null, null) handleRecoverableError(Message[Template(ExpectedFunctionBody), Expected a function body, but got '/'., null, {lexeme: /}], /, /) handleInvalidFunctionBody({) - endClassConstructor(Foo, (, null, }) + endConstructor(DeclarationKind.Class, Foo, (, null, }) endMember() beginMetadataStar(/) endMetadataStar(0) @@ -125,7 +125,7 @@ beginCompilationUnit(class) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) handleRecoverableError(ConstructorWithWrongName, /, /) - endClassConstructor(operator, (, :, }) + endConstructor(DeclarationKind.Class, operator, (, :, }) endMember() beginMetadataStar(Foo) endMetadataStar(0) @@ -140,7 +140,7 @@ beginCompilationUnit(class) handleAsyncModifier(null, null) handleRecoverableError(Message[Template(ExpectedFunctionBody), Expected a function body, but got '.'., null, {lexeme: .}], ., .) handleInvalidFunctionBody({) - endClassConstructor(Foo, (, null, }) + endConstructor(DeclarationKind.Class, Foo, (, null, }) endMember() beginMetadataStar(.) endMetadataStar(0) @@ -172,7 +172,7 @@ beginCompilationUnit(class) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) handleRecoverableError(ConstructorWithWrongName, /, /) - endClassConstructor(operator, (, :, }) + endConstructor(DeclarationKind.Class, operator, (, :, }) endMember() beginMetadataStar(foo) endMetadataStar(0) @@ -187,7 +187,7 @@ beginCompilationUnit(class) handleAsyncModifier(null, null) handleRecoverableError(Message[Template(ExpectedFunctionBody), Expected a function body, but got '/'., null, {lexeme: /}], /, /) handleInvalidFunctionBody({) - endClassMethod(null, foo, (, null, }) + endMethod(DeclarationKind.Class, null, foo, (, null, }) endMember() beginMetadataStar(/) endMetadataStar(0) @@ -213,7 +213,7 @@ beginCompilationUnit(class) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) handleRecoverableError(ConstructorWithWrongName, /, /) - endClassConstructor(operator, (, :, }) + endConstructor(DeclarationKind.Class, operator, (, :, }) endMember() beginMetadataStar(foo) endMetadataStar(0) @@ -228,7 +228,7 @@ beginCompilationUnit(class) handleAsyncModifier(null, null) handleRecoverableError(Message[Template(ExpectedFunctionBody), Expected a function body, but got '.'., null, {lexeme: .}], ., .) handleInvalidFunctionBody({) - endClassMethod(null, foo, (, null, }) + endMethod(DeclarationKind.Class, null, foo, (, null, }) endMember() beginMetadataStar(.) endMetadataStar(0) @@ -260,7 +260,7 @@ beginCompilationUnit(class) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) handleRecoverableError(ConstructorWithWrongName, /, /) - endClassConstructor(operator, (, :, }) + endConstructor(DeclarationKind.Class, operator, (, :, }) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 10, {, }) endClassDeclaration(class, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/constructor_recovery_operator.crash_dart.intertwined.expect b/pkg/front_end/parser_testcases/error_recovery/constructor_recovery_operator.crash_dart.intertwined.expect index b7a4ef09a4d..3ca02faf460 100644 --- a/pkg/front_end/parser_testcases/error_recovery/constructor_recovery_operator.crash_dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/error_recovery/constructor_recovery_operator.crash_dart.intertwined.expect @@ -61,7 +61,7 @@ parseUnit(class) rewriter() rewriter() listener: handleInvalidFunctionBody({) - listener: endClassConstructor(Foo, (, null, }) + listener: endConstructor(DeclarationKind.Class, Foo, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, /) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Foo) @@ -122,7 +122,7 @@ parseUnit(class) listener: endBlockFunctionBody(0, {, }) reportRecoverableError(operator, ConstructorWithWrongName) listener: handleRecoverableError(ConstructorWithWrongName, /, /) - listener: endClassConstructor(operator, (, :, }) + listener: endConstructor(DeclarationKind.Class, operator, (, :, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, Foo) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Foo) @@ -158,7 +158,7 @@ parseUnit(class) rewriter() rewriter() listener: handleInvalidFunctionBody({) - listener: endClassConstructor(Foo, (, null, }) + listener: endConstructor(DeclarationKind.Class, Foo, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, .) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Foo) @@ -230,7 +230,7 @@ parseUnit(class) listener: endBlockFunctionBody(0, {, }) reportRecoverableError(operator, ConstructorWithWrongName) listener: handleRecoverableError(ConstructorWithWrongName, /, /) - listener: endClassConstructor(operator, (, :, }) + listener: endConstructor(DeclarationKind.Class, operator, (, :, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, foo) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Foo) @@ -266,7 +266,7 @@ parseUnit(class) rewriter() rewriter() listener: handleInvalidFunctionBody({) - listener: endClassMethod(null, foo, (, null, }) + listener: endMethod(DeclarationKind.Class, null, foo, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, /) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Foo) @@ -327,7 +327,7 @@ parseUnit(class) listener: endBlockFunctionBody(0, {, }) reportRecoverableError(operator, ConstructorWithWrongName) listener: handleRecoverableError(ConstructorWithWrongName, /, /) - listener: endClassConstructor(operator, (, :, }) + listener: endConstructor(DeclarationKind.Class, operator, (, :, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, foo) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Foo) @@ -363,7 +363,7 @@ parseUnit(class) rewriter() rewriter() listener: handleInvalidFunctionBody({) - listener: endClassMethod(null, foo, (, null, }) + listener: endMethod(DeclarationKind.Class, null, foo, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, .) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Foo) @@ -435,7 +435,7 @@ parseUnit(class) listener: endBlockFunctionBody(0, {, }) reportRecoverableError(operator, ConstructorWithWrongName) listener: handleRecoverableError(ConstructorWithWrongName, /, /) - listener: endClassConstructor(operator, (, :, }) + listener: endConstructor(DeclarationKind.Class, operator, (, :, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 10, {, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/constructor_recovery_return_type.dart.expect b/pkg/front_end/parser_testcases/error_recovery/constructor_recovery_return_type.dart.expect index ccc587f1d8d..66811e2aaed 100644 --- a/pkg/front_end/parser_testcases/error_recovery/constructor_recovery_return_type.dart.expect +++ b/pkg/front_end/parser_testcases/error_recovery/constructor_recovery_return_type.dart.expect @@ -44,7 +44,7 @@ beginCompilationUnit(class) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) handleRecoverableError(ConstructorWithReturnType, void, void) - endClassConstructor(void, (, null, }) + endConstructor(DeclarationKind.Class, void, (, null, }) endMember() beginMetadataStar(void) endMetadataStar(0) @@ -69,7 +69,7 @@ beginCompilationUnit(class) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) handleRecoverableError(ConstructorWithReturnType, void, void) - endClassConstructor(void, (, :, }) + endConstructor(DeclarationKind.Class, void, (, :, }) endMember() beginMetadataStar(void) endMetadataStar(0) @@ -87,7 +87,7 @@ beginCompilationUnit(class) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) handleRecoverableError(ConstructorWithReturnType, void, void) - endClassConstructor(void, (, null, }) + endConstructor(DeclarationKind.Class, void, (, null, }) endMember() beginMetadataStar(void) endMetadataStar(0) @@ -114,7 +114,7 @@ beginCompilationUnit(class) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) handleRecoverableError(ConstructorWithReturnType, void, void) - endClassConstructor(void, (, :, }) + endConstructor(DeclarationKind.Class, void, (, :, }) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 4, {, }) endClassDeclaration(class, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/constructor_recovery_return_type.dart.intertwined.expect b/pkg/front_end/parser_testcases/error_recovery/constructor_recovery_return_type.dart.intertwined.expect index 712ada2646e..185e537ffdb 100644 --- a/pkg/front_end/parser_testcases/error_recovery/constructor_recovery_return_type.dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/error_recovery/constructor_recovery_return_type.dart.intertwined.expect @@ -58,7 +58,7 @@ parseUnit(class) listener: endBlockFunctionBody(0, {, }) reportRecoverableError(void, ConstructorWithReturnType) listener: handleRecoverableError(ConstructorWithReturnType, void, void) - listener: endClassConstructor(void, (, null, }) + listener: endConstructor(DeclarationKind.Class, void, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, void) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Foo) @@ -118,7 +118,7 @@ parseUnit(class) listener: endBlockFunctionBody(0, {, }) reportRecoverableError(void, ConstructorWithReturnType) listener: handleRecoverableError(ConstructorWithReturnType, void, void) - listener: endClassConstructor(void, (, :, }) + listener: endConstructor(DeclarationKind.Class, void, (, :, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, void) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Foo) @@ -155,7 +155,7 @@ parseUnit(class) listener: endBlockFunctionBody(0, {, }) reportRecoverableError(void, ConstructorWithReturnType) listener: handleRecoverableError(ConstructorWithReturnType, void, void) - listener: endClassConstructor(void, (, null, }) + listener: endConstructor(DeclarationKind.Class, void, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, void) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Foo) @@ -219,7 +219,7 @@ parseUnit(class) listener: endBlockFunctionBody(0, {, }) reportRecoverableError(void, ConstructorWithReturnType) listener: handleRecoverableError(ConstructorWithReturnType, void, void) - listener: endClassConstructor(void, (, :, }) + listener: endConstructor(DeclarationKind.Class, void, (, :, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 4, {, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/constructor_recovery_set.dart.expect b/pkg/front_end/parser_testcases/error_recovery/constructor_recovery_set.dart.expect index 9f900d1c103..aa5bc995506 100644 --- a/pkg/front_end/parser_testcases/error_recovery/constructor_recovery_set.dart.expect +++ b/pkg/front_end/parser_testcases/error_recovery/constructor_recovery_set.dart.expect @@ -44,7 +44,7 @@ beginCompilationUnit(class) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) handleRecoverableError(MemberWithSameNameAsClass, Foo, Foo) - endClassMethod(set, set, (, null, }) + endMethod(DeclarationKind.Class, set, set, (, null, }) endMember() beginMetadataStar(set) endMetadataStar(0) @@ -69,7 +69,7 @@ beginCompilationUnit(class) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) handleRecoverableError(SetterConstructor, set, set) - endClassConstructor(set, (, :, }) + endConstructor(DeclarationKind.Class, set, (, :, }) endMember() beginMetadataStar(set) endMetadataStar(0) @@ -87,7 +87,7 @@ beginCompilationUnit(class) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) handleRecoverableError(SetterConstructor, set, set) - endClassConstructor(set, (, null, }) + endConstructor(DeclarationKind.Class, set, (, null, }) endMember() beginMetadataStar(set) endMetadataStar(0) @@ -114,7 +114,7 @@ beginCompilationUnit(class) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) handleRecoverableError(SetterConstructor, set, set) - endClassConstructor(set, (, :, }) + endConstructor(DeclarationKind.Class, set, (, :, }) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 4, {, }) endClassDeclaration(class, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/constructor_recovery_set.dart.intertwined.expect b/pkg/front_end/parser_testcases/error_recovery/constructor_recovery_set.dart.intertwined.expect index dbe08c68cff..d1cbfdf4b22 100644 --- a/pkg/front_end/parser_testcases/error_recovery/constructor_recovery_set.dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/error_recovery/constructor_recovery_set.dart.intertwined.expect @@ -58,7 +58,7 @@ parseUnit(class) listener: endBlockFunctionBody(0, {, }) reportRecoverableError(Foo, MemberWithSameNameAsClass) listener: handleRecoverableError(MemberWithSameNameAsClass, Foo, Foo) - listener: endClassMethod(set, set, (, null, }) + listener: endMethod(DeclarationKind.Class, set, set, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, set) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Foo) @@ -118,7 +118,7 @@ parseUnit(class) listener: endBlockFunctionBody(0, {, }) reportRecoverableError(set, SetterConstructor) listener: handleRecoverableError(SetterConstructor, set, set) - listener: endClassConstructor(set, (, :, }) + listener: endConstructor(DeclarationKind.Class, set, (, :, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, set) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Foo) @@ -155,7 +155,7 @@ parseUnit(class) listener: endBlockFunctionBody(0, {, }) reportRecoverableError(set, SetterConstructor) listener: handleRecoverableError(SetterConstructor, set, set) - listener: endClassConstructor(set, (, null, }) + listener: endConstructor(DeclarationKind.Class, set, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, set) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Foo) @@ -219,7 +219,7 @@ parseUnit(class) listener: endBlockFunctionBody(0, {, }) reportRecoverableError(set, SetterConstructor) listener: handleRecoverableError(SetterConstructor, set, set) - listener: endClassConstructor(set, (, :, }) + listener: endConstructor(DeclarationKind.Class, set, (, :, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 4, {, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/extension_member_contributor_test_completion.dart.expect b/pkg/front_end/parser_testcases/error_recovery/extension_member_contributor_test_completion.dart.expect index 12fac45d0df..c166efbc51c 100644 --- a/pkg/front_end/parser_testcases/error_recovery/extension_member_contributor_test_completion.dart.expect +++ b/pkg/front_end/parser_testcases/error_recovery/extension_member_contributor_test_completion.dart.expect @@ -65,7 +65,7 @@ beginCompilationUnit(extension) handleAsyncModifier(null, null) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) - endExtensionMethod(null, bool, (, null, }) + endMethod(DeclarationKind.Extension, null, bool, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -81,7 +81,7 @@ beginCompilationUnit(extension) handleAsyncModifier(null, null) handleLiteralInt(0) handleExpressionFunctionBody(=>, ;) - endExtensionMethod(get, int, =>, null, ;) + endMethod(DeclarationKind.Extension, get, int, =>, null, ;) endMember() beginMetadataStar(set) endMetadataStar(0) @@ -105,7 +105,7 @@ beginCompilationUnit(extension) handleAsyncModifier(null, null) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) - endExtensionMethod(set, set, (, null, }) + endMethod(DeclarationKind.Extension, set, set, (, null, }) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Extension, 3, {, }) endExtensionDeclaration(extension, extension, on, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/extension_member_contributor_test_completion.dart.intertwined.expect b/pkg/front_end/parser_testcases/error_recovery/extension_member_contributor_test_completion.dart.intertwined.expect index ae4b61537ec..47a7ef6306b 100644 --- a/pkg/front_end/parser_testcases/error_recovery/extension_member_contributor_test_completion.dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/error_recovery/extension_member_contributor_test_completion.dart.intertwined.expect @@ -88,7 +88,7 @@ parseUnit(extension) listener: beginBlockFunctionBody({) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(0, {, }) - listener: endExtensionMethod(null, bool, (, null, }) + listener: endMethod(DeclarationKind.Extension, null, bool, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Extension, E) @@ -127,7 +127,7 @@ parseUnit(extension) ensureSemicolon(0) listener: handleExpressionFunctionBody(=>, ;) inGenerator() - listener: endExtensionMethod(get, int, =>, null, ;) + listener: endMethod(DeclarationKind.Extension, get, int, =>, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, set) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Extension, E) @@ -170,7 +170,7 @@ parseUnit(extension) listener: beginBlockFunctionBody({) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(0, {, }) - listener: endExtensionMethod(set, set, (, null, }) + listener: endMethod(DeclarationKind.Extension, set, set, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Extension, 3, {, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/issue_000032.dart.expect b/pkg/front_end/parser_testcases/error_recovery/issue_000032.dart.expect index 818c20af310..e4063f911ce 100644 --- a/pkg/front_end/parser_testcases/error_recovery/issue_000032.dart.expect +++ b/pkg/front_end/parser_testcases/error_recovery/issue_000032.dart.expect @@ -50,7 +50,7 @@ beginCompilationUnit(class) handleIdentifier(, fieldDeclaration) handleNoFieldInitializer(}) handleRecoverableError(Message[Template(ExpectedAfterButGot), Expected ';' after this., null, {string: ;}], <, <) - endClassFields(null, null, null, null, null, null, null, 1, C, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, C, ;) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 1, {, }) endClassDeclaration(class, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/issue_000032.dart.intertwined.expect b/pkg/front_end/parser_testcases/error_recovery/issue_000032.dart.intertwined.expect index 1ff6e41ad7b..f3a45ed3c70 100644 --- a/pkg/front_end/parser_testcases/error_recovery/issue_000032.dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/error_recovery/issue_000032.dart.intertwined.expect @@ -59,7 +59,7 @@ parseUnit(class) reportRecoverableError(<, Message[Template(ExpectedAfterButGot), Expected ';' after this., null, {string: ;}]) listener: handleRecoverableError(Message[Template(ExpectedAfterButGot), Expected ';' after this., null, {string: ;}], <, <) rewriter() - listener: endClassFields(null, null, null, null, null, null, null, 1, C, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, C, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 1, {, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/issue_22313.dart.expect b/pkg/front_end/parser_testcases/error_recovery/issue_22313.dart.expect index c459a4fac0f..09b30647ffa 100644 --- a/pkg/front_end/parser_testcases/error_recovery/issue_22313.dart.expect +++ b/pkg/front_end/parser_testcases/error_recovery/issue_22313.dart.expect @@ -85,7 +85,7 @@ beginCompilationUnit(class) handleAsyncModifier(null, null) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) - endClassConstructor(Foo, (, null, }) + endConstructor(DeclarationKind.Class, Foo, (, null, }) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 1, {, }) endClassDeclaration(class, }) @@ -128,7 +128,7 @@ beginCompilationUnit(class) handleAsyncModifier(null, null) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) - endClassConstructor(Bar, (, null, }) + endConstructor(DeclarationKind.Class, Bar, (, null, }) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 1, {, }) endClassDeclaration(class, }) @@ -171,7 +171,7 @@ beginCompilationUnit(class) handleAsyncModifier(null, null) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) - endClassConstructor(Baz, (, null, }) + endConstructor(DeclarationKind.Class, Baz, (, null, }) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 1, {, }) endClassDeclaration(class, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/issue_22313.dart.intertwined.expect b/pkg/front_end/parser_testcases/error_recovery/issue_22313.dart.intertwined.expect index a66b7418eb9..e60d1d0700e 100644 --- a/pkg/front_end/parser_testcases/error_recovery/issue_22313.dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/error_recovery/issue_22313.dart.intertwined.expect @@ -123,7 +123,7 @@ parseUnit(class) listener: beginBlockFunctionBody({) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(0, {, }) - listener: endClassConstructor(Foo, (, null, }) + listener: endConstructor(DeclarationKind.Class, Foo, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 1, {, }) @@ -209,7 +209,7 @@ parseUnit(class) listener: beginBlockFunctionBody({) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(0, {, }) - listener: endClassConstructor(Bar, (, null, }) + listener: endConstructor(DeclarationKind.Class, Bar, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 1, {, }) @@ -295,7 +295,7 @@ parseUnit(class) listener: beginBlockFunctionBody({) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(0, {, }) - listener: endClassConstructor(Baz, (, null, }) + listener: endConstructor(DeclarationKind.Class, Baz, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 1, {, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/issue_22314.dart.expect b/pkg/front_end/parser_testcases/error_recovery/issue_22314.dart.expect index adb4a61b59d..6ad3eeff463 100644 --- a/pkg/front_end/parser_testcases/error_recovery/issue_22314.dart.expect +++ b/pkg/front_end/parser_testcases/error_recovery/issue_22314.dart.expect @@ -42,7 +42,7 @@ beginCompilationUnit(const) handleType(String, null) handleIdentifier(message, fieldDeclaration) handleNoFieldInitializer(;) - endClassFields(null, null, null, null, null, null, final, 1, final, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) endMember() beginMetadataStar(const) endMetadataStar(0) @@ -63,7 +63,7 @@ beginCompilationUnit(const) handleNoInitializers() handleAsyncModifier(null, null) handleEmptyFunctionBody(;) - endClassConstructor(const, (, null, ;) + endConstructor(DeclarationKind.Class, const, (, null, ;) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 2, {, }) endClassDeclaration(class, }) @@ -132,7 +132,7 @@ beginCompilationUnit(const) endArguments(0, (, )) endNewExpression(new) handleExpressionFunctionBody(=>, ;) - endClassMethod(null, m, (, null, ;) + endMethod(DeclarationKind.Class, null, m, (, null, ;) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 1, {, }) endClassDeclaration(class, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/issue_22314.dart.intertwined.expect b/pkg/front_end/parser_testcases/error_recovery/issue_22314.dart.intertwined.expect index 82927c9a620..9f009325ea9 100644 --- a/pkg/front_end/parser_testcases/error_recovery/issue_22314.dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/error_recovery/issue_22314.dart.intertwined.expect @@ -68,7 +68,7 @@ parseUnit(const) listener: handleIdentifier(message, fieldDeclaration) parseFieldInitializerOpt(message, message, null, null, null, null, final, DeclarationKind.Class, Annotation) listener: handleNoFieldInitializer(;) - listener: endClassFields(null, null, null, null, null, null, final, 1, final, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, const) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Annotation) @@ -107,7 +107,7 @@ parseUnit(const) inPlainSync() parseFunctionBody(), false, true) listener: handleEmptyFunctionBody(;) - listener: endClassConstructor(const, (, null, ;) + listener: endConstructor(DeclarationKind.Class, const, (, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 2, {, }) @@ -235,7 +235,7 @@ parseUnit(const) ensureSemicolon()) listener: handleExpressionFunctionBody(=>, ;) inGenerator() - listener: endClassMethod(null, m, (, null, ;) + listener: endMethod(DeclarationKind.Class, null, m, (, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 1, {, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/issue_26810.dart.expect b/pkg/front_end/parser_testcases/error_recovery/issue_26810.dart.expect index 06a4bb55a89..0afdad28d3d 100644 --- a/pkg/front_end/parser_testcases/error_recovery/issue_26810.dart.expect +++ b/pkg/front_end/parser_testcases/error_recovery/issue_26810.dart.expect @@ -105,7 +105,7 @@ beginCompilationUnit(abstract) handleDotAccess(., hashCode, false) endBinaryExpression(^, hashCode) handleExpressionFunctionBody(=>, ;) - endClassMethod(get, int, =>, null, ;) + endMethod(DeclarationKind.Class, get, int, =>, null, ;) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -137,7 +137,7 @@ beginCompilationUnit(abstract) handleDotAccess(., hashCode, false) endBinaryExpression(^, hashCode) handleExpressionFunctionBody(=>, ;) - endClassMethod(get, int, =>, null, ;) + endMethod(DeclarationKind.Class, get, int, =>, null, ;) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -173,7 +173,7 @@ beginCompilationUnit(abstract) endBinaryExpression(^, hashCode) endReturnStatement(true, return, ;) endBlockFunctionBody(1, {, }) - endClassMethod(get, int, {, null, }) + endMethod(DeclarationKind.Class, get, int, {, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -208,7 +208,7 @@ beginCompilationUnit(abstract) endBinaryExpression(^, hashCode) endReturnStatement(true, return, ;) endBlockFunctionBody(1, {, }) - endClassMethod(get, int, {, null, }) + endMethod(DeclarationKind.Class, get, int, {, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -247,7 +247,7 @@ beginCompilationUnit(abstract) endBinaryExpression(+, 3) endBinaryExpression(^, 3) handleExpressionFunctionBody(=>, ;) - endClassMethod(get, int, =>, null, ;) + endMethod(DeclarationKind.Class, get, int, =>, null, ;) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -285,7 +285,7 @@ beginCompilationUnit(abstract) endBinaryExpression(+, 3) endBinaryExpression(^, 3) handleExpressionFunctionBody(=>, ;) - endClassMethod(get, int, =>, null, ;) + endMethod(DeclarationKind.Class, get, int, =>, null, ;) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -327,7 +327,7 @@ beginCompilationUnit(abstract) endBinaryExpression(^, 3) endReturnStatement(true, return, ;) endBlockFunctionBody(1, {, }) - endClassMethod(get, int, {, null, }) + endMethod(DeclarationKind.Class, get, int, {, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -368,7 +368,7 @@ beginCompilationUnit(abstract) endBinaryExpression(^, 3) endReturnStatement(true, return, ;) endBlockFunctionBody(1, {, }) - endClassMethod(get, int, {, null, }) + endMethod(DeclarationKind.Class, get, int, {, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -413,7 +413,7 @@ beginCompilationUnit(abstract) handleSend(y, y) endBinaryExpression(^, y) handleExpressionFunctionBody(=>, ;) - endClassMethod(null, int, (, null, ;) + endMethod(DeclarationKind.Class, null, int, (, null, ;) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -457,7 +457,7 @@ beginCompilationUnit(abstract) handleSend(y, y) endBinaryExpression(^, y) handleExpressionFunctionBody(=>, ;) - endClassMethod(null, int, (, null, ;) + endMethod(DeclarationKind.Class, null, int, (, null, ;) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -505,7 +505,7 @@ beginCompilationUnit(abstract) endBinaryExpression(^, y) endReturnStatement(true, return, ;) endBlockFunctionBody(1, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -552,7 +552,7 @@ beginCompilationUnit(abstract) endBinaryExpression(^, y) endReturnStatement(true, return, ;) endBlockFunctionBody(1, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -616,7 +616,7 @@ beginCompilationUnit(abstract) handleSend(z, z) endReturnStatement(true, return, ;) endBlockFunctionBody(2, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -679,7 +679,7 @@ beginCompilationUnit(abstract) handleSend(z, z) endReturnStatement(true, return, ;) endBlockFunctionBody(2, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -730,7 +730,7 @@ beginCompilationUnit(abstract) endBinaryExpression(+, 3) endBinaryExpression(^, 3) handleExpressionFunctionBody(=>, ;) - endClassMethod(null, int, (, null, ;) + endMethod(DeclarationKind.Class, null, int, (, null, ;) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -780,7 +780,7 @@ beginCompilationUnit(abstract) endBinaryExpression(+, 3) endBinaryExpression(^, 3) handleExpressionFunctionBody(=>, ;) - endClassMethod(null, int, (, null, ;) + endMethod(DeclarationKind.Class, null, int, (, null, ;) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -834,7 +834,7 @@ beginCompilationUnit(abstract) endBinaryExpression(^, 3) endReturnStatement(true, return, ;) endBlockFunctionBody(1, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -887,7 +887,7 @@ beginCompilationUnit(abstract) endBinaryExpression(^, 3) endReturnStatement(true, return, ;) endBlockFunctionBody(1, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(s) endMetadataStar(0) @@ -974,7 +974,7 @@ beginCompilationUnit(abstract) handleSend(s, )) handleExpressionStatement(s, ;) endBlockFunctionBody(2, {, }) - endClassMethod(null, s, (, null, }) + endMethod(DeclarationKind.Class, null, s, (, null, }) endMember() beginMetadataStar(Key) endMetadataStar(0) @@ -1065,7 +1065,7 @@ beginCompilationUnit(abstract) handleSend(print, )) handleExpressionStatement(print, ;) endBlockFunctionBody(1, {, }) - endClassConstructor(Key, (, :, }) + endConstructor(DeclarationKind.Class, Key, (, :, }) endMember() beginMetadataStar(Key) endMetadataStar(0) @@ -1153,7 +1153,7 @@ beginCompilationUnit(abstract) handleSend(print, )) handleExpressionStatement(print, ;) endBlockFunctionBody(1, {, }) - endClassConstructor(Key, (, :, }) + endConstructor(DeclarationKind.Class, Key, (, :, }) endMember() beginMetadataStar(not_currently_working) endMetadataStar(0) @@ -1214,7 +1214,7 @@ beginCompilationUnit(abstract) endBinaryExpression(^, y) handleExpressionStatement(x, ;) endBlockFunctionBody(3, {, }) - endClassMethod(null, not_currently_working, (, null, }) + endMethod(DeclarationKind.Class, null, not_currently_working, (, null, }) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 22, {, }) endClassDeclaration(abstract, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/issue_26810.dart.intertwined.expect b/pkg/front_end/parser_testcases/error_recovery/issue_26810.dart.intertwined.expect index cba63d7fdb4..c00ad4e9ae5 100644 --- a/pkg/front_end/parser_testcases/error_recovery/issue_26810.dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/error_recovery/issue_26810.dart.intertwined.expect @@ -111,7 +111,7 @@ parseUnit(abstract) ensureSemicolon(hashCode) listener: handleExpressionFunctionBody(=>, ;) inGenerator() - listener: endClassMethod(get, int, =>, null, ;) + listener: endMethod(DeclarationKind.Class, get, int, =>, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Key) @@ -184,7 +184,7 @@ parseUnit(abstract) ensureSemicolon(hashCode) listener: handleExpressionFunctionBody(=>, ;) inGenerator() - listener: endClassMethod(get, int, =>, null, ;) + listener: endMethod(DeclarationKind.Class, get, int, =>, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Key) @@ -277,7 +277,7 @@ parseUnit(abstract) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(1, {, }) - listener: endClassMethod(get, int, {, null, }) + listener: endMethod(DeclarationKind.Class, get, int, {, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Key) @@ -357,7 +357,7 @@ parseUnit(abstract) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(1, {, }) - listener: endClassMethod(get, int, {, null, }) + listener: endMethod(DeclarationKind.Class, get, int, {, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Key) @@ -461,7 +461,7 @@ parseUnit(abstract) ensureSemicolon(3) listener: handleExpressionFunctionBody(=>, ;) inGenerator() - listener: endClassMethod(get, int, =>, null, ;) + listener: endMethod(DeclarationKind.Class, get, int, =>, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Key) @@ -547,7 +547,7 @@ parseUnit(abstract) ensureSemicolon(3) listener: handleExpressionFunctionBody(=>, ;) inGenerator() - listener: endClassMethod(get, int, =>, null, ;) + listener: endMethod(DeclarationKind.Class, get, int, =>, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Key) @@ -658,7 +658,7 @@ parseUnit(abstract) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(1, {, }) - listener: endClassMethod(get, int, {, null, }) + listener: endMethod(DeclarationKind.Class, get, int, {, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Key) @@ -751,7 +751,7 @@ parseUnit(abstract) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(1, {, }) - listener: endClassMethod(get, int, {, null, }) + listener: endMethod(DeclarationKind.Class, get, int, {, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Key) @@ -848,7 +848,7 @@ parseUnit(abstract) ensureSemicolon(y) listener: handleExpressionFunctionBody(=>, ;) inGenerator() - listener: endClassMethod(null, int, (, null, ;) + listener: endMethod(DeclarationKind.Class, null, int, (, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Key) @@ -934,7 +934,7 @@ parseUnit(abstract) ensureSemicolon(y) listener: handleExpressionFunctionBody(=>, ;) inGenerator() - listener: endClassMethod(null, int, (, null, ;) + listener: endMethod(DeclarationKind.Class, null, int, (, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Key) @@ -1038,7 +1038,7 @@ parseUnit(abstract) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(1, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Key) @@ -1131,7 +1131,7 @@ parseUnit(abstract) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(1, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Key) @@ -1272,7 +1272,7 @@ parseUnit(abstract) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(2, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Key) @@ -1402,7 +1402,7 @@ parseUnit(abstract) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(2, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Key) @@ -1517,7 +1517,7 @@ parseUnit(abstract) ensureSemicolon(3) listener: handleExpressionFunctionBody(=>, ;) inGenerator() - listener: endClassMethod(null, int, (, null, ;) + listener: endMethod(DeclarationKind.Class, null, int, (, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Key) @@ -1616,7 +1616,7 @@ parseUnit(abstract) ensureSemicolon(3) listener: handleExpressionFunctionBody(=>, ;) inGenerator() - listener: endClassMethod(null, int, (, null, ;) + listener: endMethod(DeclarationKind.Class, null, int, (, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Key) @@ -1738,7 +1738,7 @@ parseUnit(abstract) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(1, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Key) @@ -1844,7 +1844,7 @@ parseUnit(abstract) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(1, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, s) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Key) @@ -2092,7 +2092,7 @@ parseUnit(abstract) listener: handleExpressionStatement(s, ;) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(2, {, }) - listener: endClassMethod(null, s, (, null, }) + listener: endMethod(DeclarationKind.Class, null, s, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, Key) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Key) @@ -2340,7 +2340,7 @@ parseUnit(abstract) listener: handleExpressionStatement(print, ;) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(1, {, }) - listener: endClassConstructor(Key, (, :, }) + listener: endConstructor(DeclarationKind.Class, Key, (, :, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, Key) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Key) @@ -2555,7 +2555,7 @@ parseUnit(abstract) listener: handleExpressionStatement(print, ;) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(1, {, }) - listener: endClassConstructor(Key, (, :, }) + listener: endConstructor(DeclarationKind.Class, Key, (, :, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, not_currently_working) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Key) @@ -2694,7 +2694,7 @@ parseUnit(abstract) listener: handleExpressionStatement(x, ;) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(3, {, }) - listener: endClassMethod(null, not_currently_working, (, null, }) + listener: endMethod(DeclarationKind.Class, null, not_currently_working, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 22, {, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/issue_26810_and.dart.expect b/pkg/front_end/parser_testcases/error_recovery/issue_26810_and.dart.expect index 118d88ce864..ee8ce0adedb 100644 --- a/pkg/front_end/parser_testcases/error_recovery/issue_26810_and.dart.expect +++ b/pkg/front_end/parser_testcases/error_recovery/issue_26810_and.dart.expect @@ -105,7 +105,7 @@ beginCompilationUnit(abstract) handleDotAccess(., hashCode, false) endBinaryExpression(&, hashCode) handleExpressionFunctionBody(=>, ;) - endClassMethod(get, int, =>, null, ;) + endMethod(DeclarationKind.Class, get, int, =>, null, ;) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -137,7 +137,7 @@ beginCompilationUnit(abstract) handleDotAccess(., hashCode, false) endBinaryExpression(&, hashCode) handleExpressionFunctionBody(=>, ;) - endClassMethod(get, int, =>, null, ;) + endMethod(DeclarationKind.Class, get, int, =>, null, ;) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -173,7 +173,7 @@ beginCompilationUnit(abstract) endBinaryExpression(&, hashCode) endReturnStatement(true, return, ;) endBlockFunctionBody(1, {, }) - endClassMethod(get, int, {, null, }) + endMethod(DeclarationKind.Class, get, int, {, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -208,7 +208,7 @@ beginCompilationUnit(abstract) endBinaryExpression(&, hashCode) endReturnStatement(true, return, ;) endBlockFunctionBody(1, {, }) - endClassMethod(get, int, {, null, }) + endMethod(DeclarationKind.Class, get, int, {, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -247,7 +247,7 @@ beginCompilationUnit(abstract) endBinaryExpression(+, 3) endBinaryExpression(&, 3) handleExpressionFunctionBody(=>, ;) - endClassMethod(get, int, =>, null, ;) + endMethod(DeclarationKind.Class, get, int, =>, null, ;) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -285,7 +285,7 @@ beginCompilationUnit(abstract) endBinaryExpression(+, 3) endBinaryExpression(&, 3) handleExpressionFunctionBody(=>, ;) - endClassMethod(get, int, =>, null, ;) + endMethod(DeclarationKind.Class, get, int, =>, null, ;) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -327,7 +327,7 @@ beginCompilationUnit(abstract) endBinaryExpression(&, 3) endReturnStatement(true, return, ;) endBlockFunctionBody(1, {, }) - endClassMethod(get, int, {, null, }) + endMethod(DeclarationKind.Class, get, int, {, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -368,7 +368,7 @@ beginCompilationUnit(abstract) endBinaryExpression(&, 3) endReturnStatement(true, return, ;) endBlockFunctionBody(1, {, }) - endClassMethod(get, int, {, null, }) + endMethod(DeclarationKind.Class, get, int, {, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -413,7 +413,7 @@ beginCompilationUnit(abstract) handleSend(y, y) endBinaryExpression(&, y) handleExpressionFunctionBody(=>, ;) - endClassMethod(null, int, (, null, ;) + endMethod(DeclarationKind.Class, null, int, (, null, ;) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -457,7 +457,7 @@ beginCompilationUnit(abstract) handleSend(y, y) endBinaryExpression(&, y) handleExpressionFunctionBody(=>, ;) - endClassMethod(null, int, (, null, ;) + endMethod(DeclarationKind.Class, null, int, (, null, ;) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -505,7 +505,7 @@ beginCompilationUnit(abstract) endBinaryExpression(&, y) endReturnStatement(true, return, ;) endBlockFunctionBody(1, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -552,7 +552,7 @@ beginCompilationUnit(abstract) endBinaryExpression(&, y) endReturnStatement(true, return, ;) endBlockFunctionBody(1, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -616,7 +616,7 @@ beginCompilationUnit(abstract) handleSend(z, z) endReturnStatement(true, return, ;) endBlockFunctionBody(2, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -679,7 +679,7 @@ beginCompilationUnit(abstract) handleSend(z, z) endReturnStatement(true, return, ;) endBlockFunctionBody(2, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -730,7 +730,7 @@ beginCompilationUnit(abstract) endBinaryExpression(+, 3) endBinaryExpression(&, 3) handleExpressionFunctionBody(=>, ;) - endClassMethod(null, int, (, null, ;) + endMethod(DeclarationKind.Class, null, int, (, null, ;) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -780,7 +780,7 @@ beginCompilationUnit(abstract) endBinaryExpression(+, 3) endBinaryExpression(&, 3) handleExpressionFunctionBody(=>, ;) - endClassMethod(null, int, (, null, ;) + endMethod(DeclarationKind.Class, null, int, (, null, ;) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -834,7 +834,7 @@ beginCompilationUnit(abstract) endBinaryExpression(&, 3) endReturnStatement(true, return, ;) endBlockFunctionBody(1, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -887,7 +887,7 @@ beginCompilationUnit(abstract) endBinaryExpression(&, 3) endReturnStatement(true, return, ;) endBlockFunctionBody(1, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(s) endMetadataStar(0) @@ -974,7 +974,7 @@ beginCompilationUnit(abstract) handleSend(s, )) handleExpressionStatement(s, ;) endBlockFunctionBody(2, {, }) - endClassMethod(null, s, (, null, }) + endMethod(DeclarationKind.Class, null, s, (, null, }) endMember() beginMetadataStar(Key) endMetadataStar(0) @@ -1065,7 +1065,7 @@ beginCompilationUnit(abstract) handleSend(print, )) handleExpressionStatement(print, ;) endBlockFunctionBody(1, {, }) - endClassConstructor(Key, (, :, }) + endConstructor(DeclarationKind.Class, Key, (, :, }) endMember() beginMetadataStar(Key) endMetadataStar(0) @@ -1153,7 +1153,7 @@ beginCompilationUnit(abstract) handleSend(print, )) handleExpressionStatement(print, ;) endBlockFunctionBody(1, {, }) - endClassConstructor(Key, (, :, }) + endConstructor(DeclarationKind.Class, Key, (, :, }) endMember() beginMetadataStar(not_currently_working) endMetadataStar(0) @@ -1214,7 +1214,7 @@ beginCompilationUnit(abstract) endBinaryExpression(&, y) handleExpressionStatement(x, ;) endBlockFunctionBody(3, {, }) - endClassMethod(null, not_currently_working, (, null, }) + endMethod(DeclarationKind.Class, null, not_currently_working, (, null, }) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 22, {, }) endClassDeclaration(abstract, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/issue_26810_and.dart.intertwined.expect b/pkg/front_end/parser_testcases/error_recovery/issue_26810_and.dart.intertwined.expect index f30b77362aa..7d454811532 100644 --- a/pkg/front_end/parser_testcases/error_recovery/issue_26810_and.dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/error_recovery/issue_26810_and.dart.intertwined.expect @@ -111,7 +111,7 @@ parseUnit(abstract) ensureSemicolon(hashCode) listener: handleExpressionFunctionBody(=>, ;) inGenerator() - listener: endClassMethod(get, int, =>, null, ;) + listener: endMethod(DeclarationKind.Class, get, int, =>, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Key) @@ -184,7 +184,7 @@ parseUnit(abstract) ensureSemicolon(hashCode) listener: handleExpressionFunctionBody(=>, ;) inGenerator() - listener: endClassMethod(get, int, =>, null, ;) + listener: endMethod(DeclarationKind.Class, get, int, =>, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Key) @@ -277,7 +277,7 @@ parseUnit(abstract) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(1, {, }) - listener: endClassMethod(get, int, {, null, }) + listener: endMethod(DeclarationKind.Class, get, int, {, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Key) @@ -357,7 +357,7 @@ parseUnit(abstract) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(1, {, }) - listener: endClassMethod(get, int, {, null, }) + listener: endMethod(DeclarationKind.Class, get, int, {, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Key) @@ -462,7 +462,7 @@ parseUnit(abstract) ensureSemicolon(3) listener: handleExpressionFunctionBody(=>, ;) inGenerator() - listener: endClassMethod(get, int, =>, null, ;) + listener: endMethod(DeclarationKind.Class, get, int, =>, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Key) @@ -548,7 +548,7 @@ parseUnit(abstract) ensureSemicolon(3) listener: handleExpressionFunctionBody(=>, ;) inGenerator() - listener: endClassMethod(get, int, =>, null, ;) + listener: endMethod(DeclarationKind.Class, get, int, =>, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Key) @@ -660,7 +660,7 @@ parseUnit(abstract) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(1, {, }) - listener: endClassMethod(get, int, {, null, }) + listener: endMethod(DeclarationKind.Class, get, int, {, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Key) @@ -753,7 +753,7 @@ parseUnit(abstract) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(1, {, }) - listener: endClassMethod(get, int, {, null, }) + listener: endMethod(DeclarationKind.Class, get, int, {, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Key) @@ -850,7 +850,7 @@ parseUnit(abstract) ensureSemicolon(y) listener: handleExpressionFunctionBody(=>, ;) inGenerator() - listener: endClassMethod(null, int, (, null, ;) + listener: endMethod(DeclarationKind.Class, null, int, (, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Key) @@ -936,7 +936,7 @@ parseUnit(abstract) ensureSemicolon(y) listener: handleExpressionFunctionBody(=>, ;) inGenerator() - listener: endClassMethod(null, int, (, null, ;) + listener: endMethod(DeclarationKind.Class, null, int, (, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Key) @@ -1040,7 +1040,7 @@ parseUnit(abstract) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(1, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Key) @@ -1133,7 +1133,7 @@ parseUnit(abstract) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(1, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Key) @@ -1274,7 +1274,7 @@ parseUnit(abstract) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(2, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Key) @@ -1404,7 +1404,7 @@ parseUnit(abstract) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(2, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Key) @@ -1520,7 +1520,7 @@ parseUnit(abstract) ensureSemicolon(3) listener: handleExpressionFunctionBody(=>, ;) inGenerator() - listener: endClassMethod(null, int, (, null, ;) + listener: endMethod(DeclarationKind.Class, null, int, (, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Key) @@ -1619,7 +1619,7 @@ parseUnit(abstract) ensureSemicolon(3) listener: handleExpressionFunctionBody(=>, ;) inGenerator() - listener: endClassMethod(null, int, (, null, ;) + listener: endMethod(DeclarationKind.Class, null, int, (, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Key) @@ -1742,7 +1742,7 @@ parseUnit(abstract) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(1, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Key) @@ -1848,7 +1848,7 @@ parseUnit(abstract) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(1, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, s) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Key) @@ -2096,7 +2096,7 @@ parseUnit(abstract) listener: handleExpressionStatement(s, ;) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(2, {, }) - listener: endClassMethod(null, s, (, null, }) + listener: endMethod(DeclarationKind.Class, null, s, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, Key) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Key) @@ -2344,7 +2344,7 @@ parseUnit(abstract) listener: handleExpressionStatement(print, ;) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(1, {, }) - listener: endClassConstructor(Key, (, :, }) + listener: endConstructor(DeclarationKind.Class, Key, (, :, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, Key) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Key) @@ -2559,7 +2559,7 @@ parseUnit(abstract) listener: handleExpressionStatement(print, ;) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(1, {, }) - listener: endClassConstructor(Key, (, :, }) + listener: endConstructor(DeclarationKind.Class, Key, (, :, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, not_currently_working) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Key) @@ -2698,7 +2698,7 @@ parseUnit(abstract) listener: handleExpressionStatement(x, ;) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(3, {, }) - listener: endClassMethod(null, not_currently_working, (, null, }) + listener: endMethod(DeclarationKind.Class, null, not_currently_working, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 22, {, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/issue_26810_or.dart.expect b/pkg/front_end/parser_testcases/error_recovery/issue_26810_or.dart.expect index 432b02fcc81..37bc72aa9cb 100644 --- a/pkg/front_end/parser_testcases/error_recovery/issue_26810_or.dart.expect +++ b/pkg/front_end/parser_testcases/error_recovery/issue_26810_or.dart.expect @@ -105,7 +105,7 @@ beginCompilationUnit(abstract) handleDotAccess(., hashCode, false) endBinaryExpression(|, hashCode) handleExpressionFunctionBody(=>, ;) - endClassMethod(get, int, =>, null, ;) + endMethod(DeclarationKind.Class, get, int, =>, null, ;) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -137,7 +137,7 @@ beginCompilationUnit(abstract) handleDotAccess(., hashCode, false) endBinaryExpression(|, hashCode) handleExpressionFunctionBody(=>, ;) - endClassMethod(get, int, =>, null, ;) + endMethod(DeclarationKind.Class, get, int, =>, null, ;) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -173,7 +173,7 @@ beginCompilationUnit(abstract) endBinaryExpression(|, hashCode) endReturnStatement(true, return, ;) endBlockFunctionBody(1, {, }) - endClassMethod(get, int, {, null, }) + endMethod(DeclarationKind.Class, get, int, {, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -208,7 +208,7 @@ beginCompilationUnit(abstract) endBinaryExpression(|, hashCode) endReturnStatement(true, return, ;) endBlockFunctionBody(1, {, }) - endClassMethod(get, int, {, null, }) + endMethod(DeclarationKind.Class, get, int, {, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -247,7 +247,7 @@ beginCompilationUnit(abstract) endBinaryExpression(+, 3) endBinaryExpression(|, 3) handleExpressionFunctionBody(=>, ;) - endClassMethod(get, int, =>, null, ;) + endMethod(DeclarationKind.Class, get, int, =>, null, ;) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -285,7 +285,7 @@ beginCompilationUnit(abstract) endBinaryExpression(+, 3) endBinaryExpression(|, 3) handleExpressionFunctionBody(=>, ;) - endClassMethod(get, int, =>, null, ;) + endMethod(DeclarationKind.Class, get, int, =>, null, ;) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -327,7 +327,7 @@ beginCompilationUnit(abstract) endBinaryExpression(|, 3) endReturnStatement(true, return, ;) endBlockFunctionBody(1, {, }) - endClassMethod(get, int, {, null, }) + endMethod(DeclarationKind.Class, get, int, {, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -368,7 +368,7 @@ beginCompilationUnit(abstract) endBinaryExpression(|, 3) endReturnStatement(true, return, ;) endBlockFunctionBody(1, {, }) - endClassMethod(get, int, {, null, }) + endMethod(DeclarationKind.Class, get, int, {, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -413,7 +413,7 @@ beginCompilationUnit(abstract) handleSend(y, y) endBinaryExpression(|, y) handleExpressionFunctionBody(=>, ;) - endClassMethod(null, int, (, null, ;) + endMethod(DeclarationKind.Class, null, int, (, null, ;) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -457,7 +457,7 @@ beginCompilationUnit(abstract) handleSend(y, y) endBinaryExpression(|, y) handleExpressionFunctionBody(=>, ;) - endClassMethod(null, int, (, null, ;) + endMethod(DeclarationKind.Class, null, int, (, null, ;) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -505,7 +505,7 @@ beginCompilationUnit(abstract) endBinaryExpression(|, y) endReturnStatement(true, return, ;) endBlockFunctionBody(1, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -552,7 +552,7 @@ beginCompilationUnit(abstract) endBinaryExpression(|, y) endReturnStatement(true, return, ;) endBlockFunctionBody(1, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -616,7 +616,7 @@ beginCompilationUnit(abstract) handleSend(z, z) endReturnStatement(true, return, ;) endBlockFunctionBody(2, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -679,7 +679,7 @@ beginCompilationUnit(abstract) handleSend(z, z) endReturnStatement(true, return, ;) endBlockFunctionBody(2, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -730,7 +730,7 @@ beginCompilationUnit(abstract) endBinaryExpression(+, 3) endBinaryExpression(|, 3) handleExpressionFunctionBody(=>, ;) - endClassMethod(null, int, (, null, ;) + endMethod(DeclarationKind.Class, null, int, (, null, ;) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -780,7 +780,7 @@ beginCompilationUnit(abstract) endBinaryExpression(+, 3) endBinaryExpression(|, 3) handleExpressionFunctionBody(=>, ;) - endClassMethod(null, int, (, null, ;) + endMethod(DeclarationKind.Class, null, int, (, null, ;) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -834,7 +834,7 @@ beginCompilationUnit(abstract) endBinaryExpression(|, 3) endReturnStatement(true, return, ;) endBlockFunctionBody(1, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -887,7 +887,7 @@ beginCompilationUnit(abstract) endBinaryExpression(|, 3) endReturnStatement(true, return, ;) endBlockFunctionBody(1, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(s) endMetadataStar(0) @@ -974,7 +974,7 @@ beginCompilationUnit(abstract) handleSend(s, )) handleExpressionStatement(s, ;) endBlockFunctionBody(2, {, }) - endClassMethod(null, s, (, null, }) + endMethod(DeclarationKind.Class, null, s, (, null, }) endMember() beginMetadataStar(Key) endMetadataStar(0) @@ -1065,7 +1065,7 @@ beginCompilationUnit(abstract) handleSend(print, )) handleExpressionStatement(print, ;) endBlockFunctionBody(1, {, }) - endClassConstructor(Key, (, :, }) + endConstructor(DeclarationKind.Class, Key, (, :, }) endMember() beginMetadataStar(Key) endMetadataStar(0) @@ -1153,7 +1153,7 @@ beginCompilationUnit(abstract) handleSend(print, )) handleExpressionStatement(print, ;) endBlockFunctionBody(1, {, }) - endClassConstructor(Key, (, :, }) + endConstructor(DeclarationKind.Class, Key, (, :, }) endMember() beginMetadataStar(not_currently_working) endMetadataStar(0) @@ -1214,7 +1214,7 @@ beginCompilationUnit(abstract) endBinaryExpression(|, y) handleExpressionStatement(x, ;) endBlockFunctionBody(3, {, }) - endClassMethod(null, not_currently_working, (, null, }) + endMethod(DeclarationKind.Class, null, not_currently_working, (, null, }) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 22, {, }) endClassDeclaration(abstract, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/issue_26810_or.dart.intertwined.expect b/pkg/front_end/parser_testcases/error_recovery/issue_26810_or.dart.intertwined.expect index aca5982f448..799d9f4d8f6 100644 --- a/pkg/front_end/parser_testcases/error_recovery/issue_26810_or.dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/error_recovery/issue_26810_or.dart.intertwined.expect @@ -111,7 +111,7 @@ parseUnit(abstract) ensureSemicolon(hashCode) listener: handleExpressionFunctionBody(=>, ;) inGenerator() - listener: endClassMethod(get, int, =>, null, ;) + listener: endMethod(DeclarationKind.Class, get, int, =>, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Key) @@ -184,7 +184,7 @@ parseUnit(abstract) ensureSemicolon(hashCode) listener: handleExpressionFunctionBody(=>, ;) inGenerator() - listener: endClassMethod(get, int, =>, null, ;) + listener: endMethod(DeclarationKind.Class, get, int, =>, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Key) @@ -277,7 +277,7 @@ parseUnit(abstract) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(1, {, }) - listener: endClassMethod(get, int, {, null, }) + listener: endMethod(DeclarationKind.Class, get, int, {, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Key) @@ -357,7 +357,7 @@ parseUnit(abstract) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(1, {, }) - listener: endClassMethod(get, int, {, null, }) + listener: endMethod(DeclarationKind.Class, get, int, {, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Key) @@ -462,7 +462,7 @@ parseUnit(abstract) ensureSemicolon(3) listener: handleExpressionFunctionBody(=>, ;) inGenerator() - listener: endClassMethod(get, int, =>, null, ;) + listener: endMethod(DeclarationKind.Class, get, int, =>, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Key) @@ -548,7 +548,7 @@ parseUnit(abstract) ensureSemicolon(3) listener: handleExpressionFunctionBody(=>, ;) inGenerator() - listener: endClassMethod(get, int, =>, null, ;) + listener: endMethod(DeclarationKind.Class, get, int, =>, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Key) @@ -660,7 +660,7 @@ parseUnit(abstract) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(1, {, }) - listener: endClassMethod(get, int, {, null, }) + listener: endMethod(DeclarationKind.Class, get, int, {, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Key) @@ -753,7 +753,7 @@ parseUnit(abstract) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(1, {, }) - listener: endClassMethod(get, int, {, null, }) + listener: endMethod(DeclarationKind.Class, get, int, {, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Key) @@ -850,7 +850,7 @@ parseUnit(abstract) ensureSemicolon(y) listener: handleExpressionFunctionBody(=>, ;) inGenerator() - listener: endClassMethod(null, int, (, null, ;) + listener: endMethod(DeclarationKind.Class, null, int, (, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Key) @@ -936,7 +936,7 @@ parseUnit(abstract) ensureSemicolon(y) listener: handleExpressionFunctionBody(=>, ;) inGenerator() - listener: endClassMethod(null, int, (, null, ;) + listener: endMethod(DeclarationKind.Class, null, int, (, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Key) @@ -1040,7 +1040,7 @@ parseUnit(abstract) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(1, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Key) @@ -1133,7 +1133,7 @@ parseUnit(abstract) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(1, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Key) @@ -1274,7 +1274,7 @@ parseUnit(abstract) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(2, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Key) @@ -1404,7 +1404,7 @@ parseUnit(abstract) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(2, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Key) @@ -1520,7 +1520,7 @@ parseUnit(abstract) ensureSemicolon(3) listener: handleExpressionFunctionBody(=>, ;) inGenerator() - listener: endClassMethod(null, int, (, null, ;) + listener: endMethod(DeclarationKind.Class, null, int, (, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Key) @@ -1619,7 +1619,7 @@ parseUnit(abstract) ensureSemicolon(3) listener: handleExpressionFunctionBody(=>, ;) inGenerator() - listener: endClassMethod(null, int, (, null, ;) + listener: endMethod(DeclarationKind.Class, null, int, (, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Key) @@ -1742,7 +1742,7 @@ parseUnit(abstract) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(1, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Key) @@ -1848,7 +1848,7 @@ parseUnit(abstract) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(1, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, s) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Key) @@ -2096,7 +2096,7 @@ parseUnit(abstract) listener: handleExpressionStatement(s, ;) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(2, {, }) - listener: endClassMethod(null, s, (, null, }) + listener: endMethod(DeclarationKind.Class, null, s, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, Key) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Key) @@ -2344,7 +2344,7 @@ parseUnit(abstract) listener: handleExpressionStatement(print, ;) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(1, {, }) - listener: endClassConstructor(Key, (, :, }) + listener: endConstructor(DeclarationKind.Class, Key, (, :, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, Key) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Key) @@ -2559,7 +2559,7 @@ parseUnit(abstract) listener: handleExpressionStatement(print, ;) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(1, {, }) - listener: endClassConstructor(Key, (, :, }) + listener: endConstructor(DeclarationKind.Class, Key, (, :, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, not_currently_working) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Key) @@ -2698,7 +2698,7 @@ parseUnit(abstract) listener: handleExpressionStatement(x, ;) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(3, {, }) - listener: endClassMethod(null, not_currently_working, (, null, }) + listener: endMethod(DeclarationKind.Class, null, not_currently_working, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 22, {, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/issue_39026.crash_dart.expect b/pkg/front_end/parser_testcases/error_recovery/issue_39026.crash_dart.expect index 07bcc02f5e4..0ab03cca553 100644 --- a/pkg/front_end/parser_testcases/error_recovery/issue_39026.crash_dart.expect +++ b/pkg/front_end/parser_testcases/error_recovery/issue_39026.crash_dart.expect @@ -39,7 +39,7 @@ beginCompilationUnit(class) handleAsyncModifier(null, null) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) - endClassMethod(null, co, (, null, }) + endMethod(DeclarationKind.Class, null, co, (, null, }) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 1, {, }) endClassDeclaration(class, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/issue_39026.crash_dart.intertwined.expect b/pkg/front_end/parser_testcases/error_recovery/issue_39026.crash_dart.intertwined.expect index 5af5ccbc84d..98cb8b7df91 100644 --- a/pkg/front_end/parser_testcases/error_recovery/issue_39026.crash_dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/error_recovery/issue_39026.crash_dart.intertwined.expect @@ -64,7 +64,7 @@ parseUnit(class) listener: beginBlockFunctionBody({) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(0, {, }) - listener: endClassMethod(null, co, (, null, }) + listener: endMethod(DeclarationKind.Class, null, co, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 1, {, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/issue_39026_prime.crash_dart.expect b/pkg/front_end/parser_testcases/error_recovery/issue_39026_prime.crash_dart.expect index ac3e36bd259..41c7fe90d65 100644 --- a/pkg/front_end/parser_testcases/error_recovery/issue_39026_prime.crash_dart.expect +++ b/pkg/front_end/parser_testcases/error_recovery/issue_39026_prime.crash_dart.expect @@ -34,7 +34,7 @@ beginCompilationUnit(class) handleAsyncModifier(null, null) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) - endClassMethod(null, co, (, null, }) + endMethod(DeclarationKind.Class, null, co, (, null, }) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 1, {, }) endClassDeclaration(class, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/issue_39026_prime.crash_dart.intertwined.expect b/pkg/front_end/parser_testcases/error_recovery/issue_39026_prime.crash_dart.intertwined.expect index d656479658a..f31991ea3d0 100644 --- a/pkg/front_end/parser_testcases/error_recovery/issue_39026_prime.crash_dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/error_recovery/issue_39026_prime.crash_dart.intertwined.expect @@ -60,7 +60,7 @@ parseUnit(class) listener: beginBlockFunctionBody({) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(0, {, }) - listener: endClassMethod(null, co, (, null, }) + listener: endMethod(DeclarationKind.Class, null, co, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 1, {, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/issue_39230.crash_dart.expect b/pkg/front_end/parser_testcases/error_recovery/issue_39230.crash_dart.expect index 921983f717b..b8b0db54b09 100644 --- a/pkg/front_end/parser_testcases/error_recovery/issue_39230.crash_dart.expect +++ b/pkg/front_end/parser_testcases/error_recovery/issue_39230.crash_dart.expect @@ -43,7 +43,7 @@ beginCompilationUnit(class) handleAsyncModifier(null, null) handleRecoverableError(Message[Template(ExpectedFunctionBody), Expected a function body, but got '/'., null, {lexeme: /}], /, /) handleInvalidFunctionBody({) - endClassConstructor(C, (, null, }) + endConstructor(DeclarationKind.Class, C, (, null, }) endMember() beginMetadataStar(/) endMetadataStar(0) @@ -68,7 +68,7 @@ beginCompilationUnit(class) handleAsyncModifier(null, null) handleEmptyFunctionBody(;) handleRecoverableError(ConstructorWithWrongName, /, /) - endClassConstructor(operator, (, :, ;) + endConstructor(DeclarationKind.Class, operator, (, :, ;) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 2, {, }) endClassDeclaration(class, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/issue_39230.crash_dart.intertwined.expect b/pkg/front_end/parser_testcases/error_recovery/issue_39230.crash_dart.intertwined.expect index b4456ea00ba..08dc724e957 100644 --- a/pkg/front_end/parser_testcases/error_recovery/issue_39230.crash_dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/error_recovery/issue_39230.crash_dart.intertwined.expect @@ -61,7 +61,7 @@ parseUnit(class) rewriter() rewriter() listener: handleInvalidFunctionBody({) - listener: endClassConstructor(C, (, null, }) + listener: endConstructor(DeclarationKind.Class, C, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, /) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, C) @@ -120,7 +120,7 @@ parseUnit(class) listener: handleEmptyFunctionBody(;) reportRecoverableError(operator, ConstructorWithWrongName) listener: handleRecoverableError(ConstructorWithWrongName, /, /) - listener: endClassConstructor(operator, (, :, ;) + listener: endConstructor(DeclarationKind.Class, operator, (, :, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 2, {, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/issue_45251.dart.expect b/pkg/front_end/parser_testcases/error_recovery/issue_45251.dart.expect index 59658f73b63..dd90ccabb9d 100644 --- a/pkg/front_end/parser_testcases/error_recovery/issue_45251.dart.expect +++ b/pkg/front_end/parser_testcases/error_recovery/issue_45251.dart.expect @@ -61,7 +61,7 @@ beginCompilationUnit(class) endTypeArguments(2, <, >) handleLiteralSetOrMap(0, {, null, }, false) endFieldInitializer(=, }) - endClassFields(null, null, null, null, null, null, final, 1, final, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) endMember() beginMetadataStar(final) endMetadataStar(0) @@ -93,7 +93,7 @@ beginCompilationUnit(class) endTypeArguments(2, <, >) handleLiteralSetOrMap(0, {, null, }, false) endFieldInitializer(=, }) - endClassFields(null, null, null, null, null, null, final, 1, final, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) endMember() beginMetadataStar(final) endMetadataStar(0) @@ -115,7 +115,7 @@ beginCompilationUnit(class) handleNoTypeArguments({) handleLiteralSetOrMap(0, {, null, }, false) endFieldInitializer(=, }) - endClassFields(null, null, null, null, null, null, final, 1, final, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) endMember() beginMetadataStar(final) endMetadataStar(0) @@ -150,7 +150,7 @@ beginCompilationUnit(class) endArguments(0, (, )) handleSend(Map, )) endFieldInitializer(=, )) - endClassFields(null, null, null, null, null, null, final, 1, final, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) endMember() beginMetadataStar(final) endMetadataStar(0) @@ -174,7 +174,7 @@ beginCompilationUnit(class) endArguments(0, (, )) handleSend(Map, )) endFieldInitializer(=, )) - endClassFields(null, null, null, null, null, null, final, 1, final, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) endMember() beginMetadataStar(final) endMetadataStar(0) @@ -211,7 +211,7 @@ beginCompilationUnit(class) handleLiteralMapEntry(:, }, null, null) handleLiteralSetOrMap(1, {, null, }, false) endFieldInitializer(=, }) - endClassFields(null, null, null, null, null, null, final, 1, final, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) endMember() beginMetadataStar(final) endMetadataStar(0) @@ -237,7 +237,7 @@ beginCompilationUnit(class) handleLiteralMapEntry(:, }, null, null) handleLiteralSetOrMap(1, {, null, }, false) endFieldInitializer(=, }) - endClassFields(null, null, null, null, null, null, final, 1, final, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) endMember() beginMetadataStar(final) endMetadataStar(0) @@ -273,7 +273,7 @@ beginCompilationUnit(class) handleLiteralMapEntry(:, }, null, null) handleLiteralSetOrMap(1, {, null, }, false) endFieldInitializer(=, }) - endClassFields(null, null, null, null, null, null, final, 1, final, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) endMember() beginMetadataStar(final) endMetadataStar(0) @@ -298,7 +298,7 @@ beginCompilationUnit(class) handleLiteralMapEntry(:, }, null, null) handleLiteralSetOrMap(1, {, null, }, false) endFieldInitializer(=, }) - endClassFields(null, null, null, null, null, null, final, 1, final, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 9, {, }) endClassDeclaration(class, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/issue_45251.dart.intertwined.expect b/pkg/front_end/parser_testcases/error_recovery/issue_45251.dart.intertwined.expect index 3c4a39c01e5..9c2936c28d4 100644 --- a/pkg/front_end/parser_testcases/error_recovery/issue_45251.dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/error_recovery/issue_45251.dart.intertwined.expect @@ -80,7 +80,7 @@ parseUnit(class) parseLiteralSetOrMapSuffix(>, null) listener: handleLiteralSetOrMap(0, {, null, }, false) listener: endFieldInitializer(=, }) - listener: endClassFields(null, null, null, null, null, null, final, 1, final, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, final) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, F) @@ -129,7 +129,7 @@ parseUnit(class) parseLiteralSetOrMapSuffix(>, null) listener: handleLiteralSetOrMap(0, {, null, }, false) listener: endFieldInitializer(=, }) - listener: endClassFields(null, null, null, null, null, null, final, 1, final, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, final) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, F) @@ -172,7 +172,7 @@ parseUnit(class) parseLiteralSetOrMapSuffix(Map, null) listener: handleLiteralSetOrMap(0, {, null, }, false) listener: endFieldInitializer(=, }) - listener: endClassFields(null, null, null, null, null, null, final, 1, final, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, final) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, F) @@ -230,7 +230,7 @@ parseUnit(class) listener: endArguments(0, (, )) listener: handleSend(Map, )) listener: endFieldInitializer(=, )) - listener: endClassFields(null, null, null, null, null, null, final, 1, final, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, final) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, F) @@ -277,7 +277,7 @@ parseUnit(class) listener: endArguments(0, (, )) listener: handleSend(Map, )) listener: endFieldInitializer(=, )) - listener: endClassFields(null, null, null, null, null, null, final, 1, final, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, final) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, F) @@ -351,7 +351,7 @@ parseUnit(class) listener: handleLiteralMapEntry(:, }, null, null) listener: handleLiteralSetOrMap(1, {, null, }, false) listener: endFieldInitializer(=, }) - listener: endClassFields(null, null, null, null, null, null, final, 1, final, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, final) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, F) @@ -413,7 +413,7 @@ parseUnit(class) listener: handleLiteralMapEntry(:, }, null, null) listener: handleLiteralSetOrMap(1, {, null, }, false) listener: endFieldInitializer(=, }) - listener: endClassFields(null, null, null, null, null, null, final, 1, final, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, final) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, F) @@ -481,7 +481,7 @@ parseUnit(class) listener: handleLiteralMapEntry(:, }, null, null) listener: handleLiteralSetOrMap(1, {, null, }, false) listener: endFieldInitializer(=, }) - listener: endClassFields(null, null, null, null, null, null, final, 1, final, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, final) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, F) @@ -537,7 +537,7 @@ parseUnit(class) listener: handleLiteralMapEntry(:, }, null, null) listener: handleLiteralSetOrMap(1, {, null, }, false) listener: endFieldInitializer(=, }) - listener: endClassFields(null, null, null, null, null, null, final, 1, final, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 9, {, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/issue_45251_const.dart.expect b/pkg/front_end/parser_testcases/error_recovery/issue_45251_const.dart.expect index 834208d7c9d..48b8d509e00 100644 --- a/pkg/front_end/parser_testcases/error_recovery/issue_45251_const.dart.expect +++ b/pkg/front_end/parser_testcases/error_recovery/issue_45251_const.dart.expect @@ -63,7 +63,7 @@ beginCompilationUnit(class) handleLiteralSetOrMap(0, {, const, }, false) endConstLiteral(}) endFieldInitializer(=, }) - endClassFields(null, null, null, null, null, null, final, 1, final, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) endMember() beginMetadataStar(final) endMetadataStar(0) @@ -97,7 +97,7 @@ beginCompilationUnit(class) handleLiteralSetOrMap(0, {, const, }, false) endConstLiteral(}) endFieldInitializer(=, }) - endClassFields(null, null, null, null, null, null, final, 1, final, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) endMember() beginMetadataStar(final) endMetadataStar(0) @@ -121,7 +121,7 @@ beginCompilationUnit(class) handleLiteralSetOrMap(0, {, const, }, false) endConstLiteral(}) endFieldInitializer(=, }) - endClassFields(null, null, null, null, null, null, final, 1, final, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) endMember() beginMetadataStar(final) endMetadataStar(0) @@ -160,7 +160,7 @@ beginCompilationUnit(class) endArguments(0, (, )) endConstExpression(const) endFieldInitializer(=, )) - endClassFields(null, null, null, null, null, null, final, 1, final, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) endMember() beginMetadataStar(final) endMetadataStar(0) @@ -188,7 +188,7 @@ beginCompilationUnit(class) endArguments(0, (, )) endConstExpression(const) endFieldInitializer(=, )) - endClassFields(null, null, null, null, null, null, final, 1, final, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) endMember() beginMetadataStar(final) endMetadataStar(0) @@ -227,7 +227,7 @@ beginCompilationUnit(class) handleLiteralSetOrMap(1, {, const, }, false) endConstLiteral(}) endFieldInitializer(=, }) - endClassFields(null, null, null, null, null, null, final, 1, final, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) endMember() beginMetadataStar(final) endMetadataStar(0) @@ -255,7 +255,7 @@ beginCompilationUnit(class) handleLiteralSetOrMap(1, {, const, }, false) endConstLiteral(}) endFieldInitializer(=, }) - endClassFields(null, null, null, null, null, null, final, 1, final, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) endMember() beginMetadataStar(final) endMetadataStar(0) @@ -293,7 +293,7 @@ beginCompilationUnit(class) handleLiteralSetOrMap(1, {, const, }, false) endConstLiteral(}) endFieldInitializer(=, }) - endClassFields(null, null, null, null, null, null, final, 1, final, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) endMember() beginMetadataStar(final) endMetadataStar(0) @@ -320,7 +320,7 @@ beginCompilationUnit(class) handleLiteralSetOrMap(1, {, const, }, false) endConstLiteral(}) endFieldInitializer(=, }) - endClassFields(null, null, null, null, null, null, final, 1, final, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 9, {, }) endClassDeclaration(class, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/issue_45251_const.dart.intertwined.expect b/pkg/front_end/parser_testcases/error_recovery/issue_45251_const.dart.intertwined.expect index 679e1cfc2c2..761ed8a506a 100644 --- a/pkg/front_end/parser_testcases/error_recovery/issue_45251_const.dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/error_recovery/issue_45251_const.dart.intertwined.expect @@ -79,7 +79,7 @@ parseUnit(class) listener: handleLiteralSetOrMap(0, {, const, }, false) listener: endConstLiteral(}) listener: endFieldInitializer(=, }) - listener: endClassFields(null, null, null, null, null, null, final, 1, final, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, final) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, F) @@ -131,7 +131,7 @@ parseUnit(class) listener: handleLiteralSetOrMap(0, {, const, }, false) listener: endConstLiteral(}) listener: endFieldInitializer(=, }) - listener: endClassFields(null, null, null, null, null, null, final, 1, final, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, final) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, F) @@ -173,7 +173,7 @@ parseUnit(class) listener: handleLiteralSetOrMap(0, {, const, }, false) listener: endConstLiteral(}) listener: endFieldInitializer(=, }) - listener: endClassFields(null, null, null, null, null, null, final, 1, final, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, final) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, F) @@ -233,7 +233,7 @@ parseUnit(class) listener: endArguments(0, (, )) listener: endConstExpression(const) listener: endFieldInitializer(=, )) - listener: endClassFields(null, null, null, null, null, null, final, 1, final, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, final) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, F) @@ -282,7 +282,7 @@ parseUnit(class) listener: endArguments(0, (, )) listener: endConstExpression(const) listener: endFieldInitializer(=, )) - listener: endClassFields(null, null, null, null, null, null, final, 1, final, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, final) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, F) @@ -355,7 +355,7 @@ parseUnit(class) listener: handleLiteralSetOrMap(1, {, const, }, false) listener: endConstLiteral(}) listener: endFieldInitializer(=, }) - listener: endClassFields(null, null, null, null, null, null, final, 1, final, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, final) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, F) @@ -416,7 +416,7 @@ parseUnit(class) listener: handleLiteralSetOrMap(1, {, const, }, false) listener: endConstLiteral(}) listener: endFieldInitializer(=, }) - listener: endClassFields(null, null, null, null, null, null, final, 1, final, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, final) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, F) @@ -487,7 +487,7 @@ parseUnit(class) listener: handleLiteralSetOrMap(1, {, const, }, false) listener: endConstLiteral(}) listener: endFieldInitializer(=, }) - listener: endClassFields(null, null, null, null, null, null, final, 1, final, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, final) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, F) @@ -546,7 +546,7 @@ parseUnit(class) listener: handleLiteralSetOrMap(1, {, const, }, false) listener: endConstLiteral(}) listener: endFieldInitializer(=, }) - listener: endClassFields(null, null, null, null, null, null, final, 1, final, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 9, {, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/issue_45251_list.dart.expect b/pkg/front_end/parser_testcases/error_recovery/issue_45251_list.dart.expect index 7f3dcbf399a..fd677a77726 100644 --- a/pkg/front_end/parser_testcases/error_recovery/issue_45251_list.dart.expect +++ b/pkg/front_end/parser_testcases/error_recovery/issue_45251_list.dart.expect @@ -51,7 +51,7 @@ beginCompilationUnit(class) endTypeArguments(1, <, >) handleLiteralList(0, [, null, ]) endFieldInitializer(=, ]) - endClassFields(null, null, null, null, null, null, final, 1, final, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) endMember() beginMetadataStar(final) endMetadataStar(0) @@ -77,7 +77,7 @@ beginCompilationUnit(class) endTypeArguments(1, <, >) handleLiteralList(0, [, null, ]) endFieldInitializer(=, ]) - endClassFields(null, null, null, null, null, null, final, 1, final, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) endMember() beginMetadataStar(final) endMetadataStar(0) @@ -96,7 +96,7 @@ beginCompilationUnit(class) handleNoTypeArguments([]) handleLiteralList(0, [, null, ]) endFieldInitializer(=, ]) - endClassFields(null, null, null, null, null, null, final, 1, final, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) endMember() beginMetadataStar(final) endMetadataStar(0) @@ -125,7 +125,7 @@ beginCompilationUnit(class) endArguments(0, (, )) handleSend(List, )) endFieldInitializer(=, )) - endClassFields(null, null, null, null, null, null, final, 1, final, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) endMember() beginMetadataStar(final) endMetadataStar(0) @@ -146,7 +146,7 @@ beginCompilationUnit(class) endArguments(0, (, )) handleSend(List, )) endFieldInitializer(=, )) - endClassFields(null, null, null, null, null, null, final, 1, final, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) endMember() beginMetadataStar(final) endMetadataStar(0) @@ -174,7 +174,7 @@ beginCompilationUnit(class) handleLiteralNull(null) handleLiteralList(1, [, null, ]) endFieldInitializer(=, ]) - endClassFields(null, null, null, null, null, null, final, 1, final, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) endMember() beginMetadataStar(final) endMetadataStar(0) @@ -196,7 +196,7 @@ beginCompilationUnit(class) handleLiteralNull(null) handleIndexedExpression(null, [, ]) endFieldInitializer(=, ]) - endClassFields(null, null, null, null, null, null, final, 1, final, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) endMember() beginMetadataStar(final) endMetadataStar(0) @@ -223,7 +223,7 @@ beginCompilationUnit(class) handleLiteralNull(null) handleLiteralList(1, [, null, ]) endFieldInitializer(=, ]) - endClassFields(null, null, null, null, null, null, final, 1, final, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) endMember() beginMetadataStar(final) endMetadataStar(0) @@ -242,7 +242,7 @@ beginCompilationUnit(class) handleLiteralNull(null) handleLiteralList(1, [, null, ]) endFieldInitializer(=, ]) - endClassFields(null, null, null, null, null, null, final, 1, final, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 9, {, }) endClassDeclaration(class, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/issue_45251_list.dart.intertwined.expect b/pkg/front_end/parser_testcases/error_recovery/issue_45251_list.dart.intertwined.expect index ae9d838feb4..65b3120b0a8 100644 --- a/pkg/front_end/parser_testcases/error_recovery/issue_45251_list.dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/error_recovery/issue_45251_list.dart.intertwined.expect @@ -76,7 +76,7 @@ parseUnit(class) rewriter() listener: handleLiteralList(0, [, null, ]) listener: endFieldInitializer(=, ]) - listener: endClassFields(null, null, null, null, null, null, final, 1, final, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, final) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, F) @@ -121,7 +121,7 @@ parseUnit(class) rewriter() listener: handleLiteralList(0, [, null, ]) listener: endFieldInitializer(=, ]) - listener: endClassFields(null, null, null, null, null, null, final, 1, final, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, final) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, F) @@ -163,7 +163,7 @@ parseUnit(class) rewriter() listener: handleLiteralList(0, [, null, ]) listener: endFieldInitializer(=, ]) - listener: endClassFields(null, null, null, null, null, null, final, 1, final, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, final) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, F) @@ -214,7 +214,7 @@ parseUnit(class) listener: endArguments(0, (, )) listener: handleSend(List, )) listener: endFieldInitializer(=, )) - listener: endClassFields(null, null, null, null, null, null, final, 1, final, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, final) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, F) @@ -257,7 +257,7 @@ parseUnit(class) listener: endArguments(0, (, )) listener: handleSend(List, )) listener: endFieldInitializer(=, )) - listener: endClassFields(null, null, null, null, null, null, final, 1, final, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, final) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, F) @@ -313,7 +313,7 @@ parseUnit(class) listener: handleLiteralNull(null) listener: handleLiteralList(1, [, null, ]) listener: endFieldInitializer(=, ]) - listener: endClassFields(null, null, null, null, null, null, final, 1, final, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, final) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, F) @@ -362,7 +362,7 @@ parseUnit(class) listener: handleLiteralNull(null) listener: handleIndexedExpression(null, [, ]) listener: endFieldInitializer(=, ]) - listener: endClassFields(null, null, null, null, null, null, final, 1, final, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, final) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, F) @@ -412,7 +412,7 @@ parseUnit(class) listener: handleLiteralNull(null) listener: handleLiteralList(1, [, null, ]) listener: endFieldInitializer(=, ]) - listener: endClassFields(null, null, null, null, null, null, final, 1, final, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, final) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, F) @@ -453,7 +453,7 @@ parseUnit(class) listener: handleLiteralNull(null) listener: handleLiteralList(1, [, null, ]) listener: endFieldInitializer(=, ]) - listener: endClassFields(null, null, null, null, null, null, final, 1, final, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 9, {, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/issue_45251_list_const.dart.expect b/pkg/front_end/parser_testcases/error_recovery/issue_45251_list_const.dart.expect index d94081c13b4..fdbb1f9a032 100644 --- a/pkg/front_end/parser_testcases/error_recovery/issue_45251_list_const.dart.expect +++ b/pkg/front_end/parser_testcases/error_recovery/issue_45251_list_const.dart.expect @@ -57,7 +57,7 @@ beginCompilationUnit(class) handleLiteralList(0, [, const, ]) endConstLiteral(]) endFieldInitializer(=, ]) - endClassFields(null, null, null, null, null, null, final, 1, final, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) endMember() beginMetadataStar(final) endMetadataStar(0) @@ -85,7 +85,7 @@ beginCompilationUnit(class) handleLiteralList(0, [, const, ]) endConstLiteral(]) endFieldInitializer(=, ]) - endClassFields(null, null, null, null, null, null, final, 1, final, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) endMember() beginMetadataStar(final) endMetadataStar(0) @@ -106,7 +106,7 @@ beginCompilationUnit(class) handleLiteralList(0, [, const, ]) endConstLiteral(]) endFieldInitializer(=, ]) - endClassFields(null, null, null, null, null, null, final, 1, final, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) endMember() beginMetadataStar(final) endMetadataStar(0) @@ -139,7 +139,7 @@ beginCompilationUnit(class) endArguments(0, (, )) endConstExpression(const) endFieldInitializer(=, )) - endClassFields(null, null, null, null, null, null, final, 1, final, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) endMember() beginMetadataStar(final) endMetadataStar(0) @@ -164,7 +164,7 @@ beginCompilationUnit(class) endArguments(0, (, )) endConstExpression(const) endFieldInitializer(=, )) - endClassFields(null, null, null, null, null, null, final, 1, final, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) endMember() beginMetadataStar(final) endMetadataStar(0) @@ -194,7 +194,7 @@ beginCompilationUnit(class) handleLiteralList(1, [, const, ]) endConstLiteral(]) endFieldInitializer(=, ]) - endClassFields(null, null, null, null, null, null, final, 1, final, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) endMember() beginMetadataStar(final) endMetadataStar(0) @@ -216,7 +216,7 @@ beginCompilationUnit(class) handleLiteralList(1, [, const, ]) endConstLiteral(]) endFieldInitializer(=, ]) - endClassFields(null, null, null, null, null, null, final, 1, final, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) endMember() beginMetadataStar(final) endMetadataStar(0) @@ -245,7 +245,7 @@ beginCompilationUnit(class) handleLiteralList(1, [, const, ]) endConstLiteral(]) endFieldInitializer(=, ]) - endClassFields(null, null, null, null, null, null, final, 1, final, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) endMember() beginMetadataStar(final) endMetadataStar(0) @@ -266,7 +266,7 @@ beginCompilationUnit(class) handleLiteralList(1, [, const, ]) endConstLiteral(]) endFieldInitializer(=, ]) - endClassFields(null, null, null, null, null, null, final, 1, final, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 9, {, }) endClassDeclaration(class, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/issue_45251_list_const.dart.intertwined.expect b/pkg/front_end/parser_testcases/error_recovery/issue_45251_list_const.dart.intertwined.expect index 78af44737c1..1e4391a1db4 100644 --- a/pkg/front_end/parser_testcases/error_recovery/issue_45251_list_const.dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/error_recovery/issue_45251_list_const.dart.intertwined.expect @@ -75,7 +75,7 @@ parseUnit(class) listener: handleLiteralList(0, [, const, ]) listener: endConstLiteral(]) listener: endFieldInitializer(=, ]) - listener: endClassFields(null, null, null, null, null, null, final, 1, final, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, final) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, F) @@ -123,7 +123,7 @@ parseUnit(class) listener: handleLiteralList(0, [, const, ]) listener: endConstLiteral(]) listener: endFieldInitializer(=, ]) - listener: endClassFields(null, null, null, null, null, null, final, 1, final, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, final) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, F) @@ -164,7 +164,7 @@ parseUnit(class) listener: handleLiteralList(0, [, const, ]) listener: endConstLiteral(]) listener: endFieldInitializer(=, ]) - listener: endClassFields(null, null, null, null, null, null, final, 1, final, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, final) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, F) @@ -217,7 +217,7 @@ parseUnit(class) listener: endArguments(0, (, )) listener: endConstExpression(const) listener: endFieldInitializer(=, )) - listener: endClassFields(null, null, null, null, null, null, final, 1, final, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, final) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, F) @@ -262,7 +262,7 @@ parseUnit(class) listener: endArguments(0, (, )) listener: endConstExpression(const) listener: endFieldInitializer(=, )) - listener: endClassFields(null, null, null, null, null, null, final, 1, final, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, final) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, F) @@ -317,7 +317,7 @@ parseUnit(class) listener: handleLiteralList(1, [, const, ]) listener: endConstLiteral(]) listener: endFieldInitializer(=, ]) - listener: endClassFields(null, null, null, null, null, null, final, 1, final, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, final) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, F) @@ -363,7 +363,7 @@ parseUnit(class) listener: handleLiteralList(1, [, const, ]) listener: endConstLiteral(]) listener: endFieldInitializer(=, ]) - listener: endClassFields(null, null, null, null, null, null, final, 1, final, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, final) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, F) @@ -416,7 +416,7 @@ parseUnit(class) listener: handleLiteralList(1, [, const, ]) listener: endConstLiteral(]) listener: endFieldInitializer(=, ]) - listener: endClassFields(null, null, null, null, null, null, final, 1, final, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, final) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, F) @@ -460,7 +460,7 @@ parseUnit(class) listener: handleLiteralList(1, [, const, ]) listener: endConstLiteral(]) listener: endFieldInitializer(=, ]) - listener: endClassFields(null, null, null, null, null, null, final, 1, final, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 9, {, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/issue_45251_list_new.dart.expect b/pkg/front_end/parser_testcases/error_recovery/issue_45251_list_new.dart.expect index 6545ff91cc6..05d4ba06df7 100644 --- a/pkg/front_end/parser_testcases/error_recovery/issue_45251_list_new.dart.expect +++ b/pkg/front_end/parser_testcases/error_recovery/issue_45251_list_new.dart.expect @@ -67,7 +67,7 @@ beginCompilationUnit(class) endTypeArguments(1, <, >) handleLiteralList(0, [, null, ]) endFieldInitializer(=, ]) - endClassFields(null, null, null, null, null, null, final, 1, final, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) endMember() beginMetadataStar(final) endMetadataStar(0) @@ -94,7 +94,7 @@ beginCompilationUnit(class) endTypeArguments(1, <, >) handleLiteralList(0, [, null, ]) endFieldInitializer(=, ]) - endClassFields(null, null, null, null, null, null, final, 1, final, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) endMember() beginMetadataStar(final) endMetadataStar(0) @@ -113,7 +113,7 @@ beginCompilationUnit(class) handleNoTypeArguments([]) handleLiteralList(0, [, null, ]) endFieldInitializer(=, ]) - endClassFields(null, null, null, null, null, null, final, 1, final, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) endMember() beginMetadataStar(final) endMetadataStar(0) @@ -146,7 +146,7 @@ beginCompilationUnit(class) endArguments(0, (, )) endNewExpression(new) endFieldInitializer(=, )) - endClassFields(null, null, null, null, null, null, final, 1, final, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) endMember() beginMetadataStar(final) endMetadataStar(0) @@ -171,7 +171,7 @@ beginCompilationUnit(class) endArguments(0, (, )) endNewExpression(new) endFieldInitializer(=, )) - endClassFields(null, null, null, null, null, null, final, 1, final, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) endMember() beginMetadataStar(final) endMetadataStar(0) @@ -199,7 +199,7 @@ beginCompilationUnit(class) handleLiteralNull(null) handleLiteralList(1, [, null, ]) endFieldInitializer(=, ]) - endClassFields(null, null, null, null, null, null, final, 1, final, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) endMember() beginMetadataStar(final) endMetadataStar(0) @@ -219,7 +219,7 @@ beginCompilationUnit(class) handleLiteralNull(null) handleLiteralList(1, [, null, ]) endFieldInitializer(=, ]) - endClassFields(null, null, null, null, null, null, final, 1, final, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) endMember() beginMetadataStar(final) endMetadataStar(0) @@ -247,7 +247,7 @@ beginCompilationUnit(class) handleLiteralNull(null) handleLiteralList(1, [, null, ]) endFieldInitializer(=, ]) - endClassFields(null, null, null, null, null, null, final, 1, final, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) endMember() beginMetadataStar(final) endMetadataStar(0) @@ -267,7 +267,7 @@ beginCompilationUnit(class) handleLiteralNull(null) handleLiteralList(1, [, null, ]) endFieldInitializer(=, ]) - endClassFields(null, null, null, null, null, null, final, 1, final, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 9, {, }) endClassDeclaration(class, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/issue_45251_list_new.dart.intertwined.expect b/pkg/front_end/parser_testcases/error_recovery/issue_45251_list_new.dart.intertwined.expect index 4bc91c8e1b6..bf58da54562 100644 --- a/pkg/front_end/parser_testcases/error_recovery/issue_45251_list_new.dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/error_recovery/issue_45251_list_new.dart.intertwined.expect @@ -74,7 +74,7 @@ parseUnit(class) rewriter() listener: handleLiteralList(0, [, null, ]) listener: endFieldInitializer(=, ]) - listener: endClassFields(null, null, null, null, null, null, final, 1, final, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, final) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, F) @@ -123,7 +123,7 @@ parseUnit(class) rewriter() listener: handleLiteralList(0, [, null, ]) listener: endFieldInitializer(=, ]) - listener: endClassFields(null, null, null, null, null, null, final, 1, final, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, final) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, F) @@ -163,7 +163,7 @@ parseUnit(class) rewriter() listener: handleLiteralList(0, [, null, ]) listener: endFieldInitializer(=, ]) - listener: endClassFields(null, null, null, null, null, null, final, 1, final, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, final) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, F) @@ -216,7 +216,7 @@ parseUnit(class) listener: endArguments(0, (, )) listener: endNewExpression(new) listener: endFieldInitializer(=, )) - listener: endClassFields(null, null, null, null, null, null, final, 1, final, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, final) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, F) @@ -261,7 +261,7 @@ parseUnit(class) listener: endArguments(0, (, )) listener: endNewExpression(new) listener: endFieldInitializer(=, )) - listener: endClassFields(null, null, null, null, null, null, final, 1, final, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, final) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, F) @@ -315,7 +315,7 @@ parseUnit(class) listener: handleLiteralNull(null) listener: handleLiteralList(1, [, null, ]) listener: endFieldInitializer(=, ]) - listener: endClassFields(null, null, null, null, null, null, final, 1, final, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, final) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, F) @@ -360,7 +360,7 @@ parseUnit(class) listener: handleLiteralNull(null) listener: handleLiteralList(1, [, null, ]) listener: endFieldInitializer(=, ]) - listener: endClassFields(null, null, null, null, null, null, final, 1, final, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, final) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, F) @@ -414,7 +414,7 @@ parseUnit(class) listener: handleLiteralNull(null) listener: handleLiteralList(1, [, null, ]) listener: endFieldInitializer(=, ]) - listener: endClassFields(null, null, null, null, null, null, final, 1, final, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, final) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, F) @@ -459,7 +459,7 @@ parseUnit(class) listener: handleLiteralNull(null) listener: handleLiteralList(1, [, null, ]) listener: endFieldInitializer(=, ]) - listener: endClassFields(null, null, null, null, null, null, final, 1, final, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 9, {, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/issue_45251_new.dart.expect b/pkg/front_end/parser_testcases/error_recovery/issue_45251_new.dart.expect index f463392e90c..eb1a6ecf347 100644 --- a/pkg/front_end/parser_testcases/error_recovery/issue_45251_new.dart.expect +++ b/pkg/front_end/parser_testcases/error_recovery/issue_45251_new.dart.expect @@ -73,7 +73,7 @@ beginCompilationUnit(class) endTypeArguments(2, <, >) handleLiteralSetOrMap(0, {, null, }, false) endFieldInitializer(=, }) - endClassFields(null, null, null, null, null, null, final, 1, final, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) endMember() beginMetadataStar(final) endMetadataStar(0) @@ -106,7 +106,7 @@ beginCompilationUnit(class) endTypeArguments(2, <, >) handleLiteralSetOrMap(0, {, null, }, false) endFieldInitializer(=, }) - endClassFields(null, null, null, null, null, null, final, 1, final, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) endMember() beginMetadataStar(final) endMetadataStar(0) @@ -128,7 +128,7 @@ beginCompilationUnit(class) handleNoTypeArguments({) handleLiteralSetOrMap(0, {, null, }, false) endFieldInitializer(=, }) - endClassFields(null, null, null, null, null, null, final, 1, final, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) endMember() beginMetadataStar(final) endMetadataStar(0) @@ -167,7 +167,7 @@ beginCompilationUnit(class) endArguments(0, (, )) endNewExpression(new) endFieldInitializer(=, )) - endClassFields(null, null, null, null, null, null, final, 1, final, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) endMember() beginMetadataStar(final) endMetadataStar(0) @@ -195,7 +195,7 @@ beginCompilationUnit(class) endArguments(0, (, )) endNewExpression(new) endFieldInitializer(=, )) - endClassFields(null, null, null, null, null, null, final, 1, final, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) endMember() beginMetadataStar(final) endMetadataStar(0) @@ -232,7 +232,7 @@ beginCompilationUnit(class) handleLiteralMapEntry(:, }, null, null) handleLiteralSetOrMap(1, {, null, }, false) endFieldInitializer(=, }) - endClassFields(null, null, null, null, null, null, final, 1, final, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) endMember() beginMetadataStar(final) endMetadataStar(0) @@ -258,7 +258,7 @@ beginCompilationUnit(class) handleLiteralMapEntry(:, }, null, null) handleLiteralSetOrMap(1, {, null, }, false) endFieldInitializer(=, }) - endClassFields(null, null, null, null, null, null, final, 1, final, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) endMember() beginMetadataStar(final) endMetadataStar(0) @@ -295,7 +295,7 @@ beginCompilationUnit(class) handleLiteralMapEntry(:, }, null, null) handleLiteralSetOrMap(1, {, null, }, false) endFieldInitializer(=, }) - endClassFields(null, null, null, null, null, null, final, 1, final, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) endMember() beginMetadataStar(final) endMetadataStar(0) @@ -321,7 +321,7 @@ beginCompilationUnit(class) handleLiteralMapEntry(:, }, null, null) handleLiteralSetOrMap(1, {, null, }, false) endFieldInitializer(=, }) - endClassFields(null, null, null, null, null, null, final, 1, final, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 9, {, }) endClassDeclaration(class, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/issue_45251_new.dart.intertwined.expect b/pkg/front_end/parser_testcases/error_recovery/issue_45251_new.dart.intertwined.expect index e8a20a7b082..c9e1d58e180 100644 --- a/pkg/front_end/parser_testcases/error_recovery/issue_45251_new.dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/error_recovery/issue_45251_new.dart.intertwined.expect @@ -78,7 +78,7 @@ parseUnit(class) parseLiteralSetOrMapSuffix(>, null) listener: handleLiteralSetOrMap(0, {, null, }, false) listener: endFieldInitializer(=, }) - listener: endClassFields(null, null, null, null, null, null, final, 1, final, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, final) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, F) @@ -131,7 +131,7 @@ parseUnit(class) parseLiteralSetOrMapSuffix(>, null) listener: handleLiteralSetOrMap(0, {, null, }, false) listener: endFieldInitializer(=, }) - listener: endClassFields(null, null, null, null, null, null, final, 1, final, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, final) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, F) @@ -172,7 +172,7 @@ parseUnit(class) parseLiteralSetOrMapSuffix(Map, null) listener: handleLiteralSetOrMap(0, {, null, }, false) listener: endFieldInitializer(=, }) - listener: endClassFields(null, null, null, null, null, null, final, 1, final, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, final) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, F) @@ -232,7 +232,7 @@ parseUnit(class) listener: endArguments(0, (, )) listener: endNewExpression(new) listener: endFieldInitializer(=, )) - listener: endClassFields(null, null, null, null, null, null, final, 1, final, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, final) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, F) @@ -281,7 +281,7 @@ parseUnit(class) listener: endArguments(0, (, )) listener: endNewExpression(new) listener: endFieldInitializer(=, )) - listener: endClassFields(null, null, null, null, null, null, final, 1, final, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, final) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, F) @@ -353,7 +353,7 @@ parseUnit(class) listener: handleLiteralMapEntry(:, }, null, null) listener: handleLiteralSetOrMap(1, {, null, }, false) listener: endFieldInitializer(=, }) - listener: endClassFields(null, null, null, null, null, null, final, 1, final, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, final) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, F) @@ -413,7 +413,7 @@ parseUnit(class) listener: handleLiteralMapEntry(:, }, null, null) listener: handleLiteralSetOrMap(1, {, null, }, false) listener: endFieldInitializer(=, }) - listener: endClassFields(null, null, null, null, null, null, final, 1, final, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, final) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, F) @@ -485,7 +485,7 @@ parseUnit(class) listener: handleLiteralMapEntry(:, }, null, null) listener: handleLiteralSetOrMap(1, {, null, }, false) listener: endFieldInitializer(=, }) - listener: endClassFields(null, null, null, null, null, null, final, 1, final, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, final) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, F) @@ -545,7 +545,7 @@ parseUnit(class) listener: handleLiteralMapEntry(:, }, null, null) listener: handleLiteralSetOrMap(1, {, null, }, false) listener: endFieldInitializer(=, }) - listener: endClassFields(null, null, null, null, null, null, final, 1, final, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 9, {, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/issue_45251_set.dart.expect b/pkg/front_end/parser_testcases/error_recovery/issue_45251_set.dart.expect index 1a5f959040e..a5c6aa90497 100644 --- a/pkg/front_end/parser_testcases/error_recovery/issue_45251_set.dart.expect +++ b/pkg/front_end/parser_testcases/error_recovery/issue_45251_set.dart.expect @@ -55,7 +55,7 @@ beginCompilationUnit(class) endTypeArguments(1, <, >) handleLiteralSetOrMap(0, {, null, }, false) endFieldInitializer(=, }) - endClassFields(null, null, null, null, null, null, final, 1, final, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) endMember() beginMetadataStar(final) endMetadataStar(0) @@ -81,7 +81,7 @@ beginCompilationUnit(class) endTypeArguments(1, <, >) handleLiteralSetOrMap(0, {, null, }, false) endFieldInitializer(=, }) - endClassFields(null, null, null, null, null, null, final, 1, final, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) endMember() beginMetadataStar(final) endMetadataStar(0) @@ -100,7 +100,7 @@ beginCompilationUnit(class) handleNoTypeArguments({) handleLiteralSetOrMap(0, {, null, }, false) endFieldInitializer(=, }) - endClassFields(null, null, null, null, null, null, final, 1, final, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) endMember() beginMetadataStar(final) endMetadataStar(0) @@ -129,7 +129,7 @@ beginCompilationUnit(class) endArguments(0, (, )) handleSend(Set, )) endFieldInitializer(=, )) - endClassFields(null, null, null, null, null, null, final, 1, final, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) endMember() beginMetadataStar(final) endMetadataStar(0) @@ -150,7 +150,7 @@ beginCompilationUnit(class) endArguments(0, (, )) handleSend(Set, )) endFieldInitializer(=, )) - endClassFields(null, null, null, null, null, null, final, 1, final, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) endMember() beginMetadataStar(final) endMetadataStar(0) @@ -178,7 +178,7 @@ beginCompilationUnit(class) handleLiteralNull(null) handleLiteralSetOrMap(1, {, null, }, true) endFieldInitializer(=, }) - endClassFields(null, null, null, null, null, null, final, 1, final, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) endMember() beginMetadataStar(final) endMetadataStar(0) @@ -198,7 +198,7 @@ beginCompilationUnit(class) handleLiteralNull(null) handleLiteralSetOrMap(1, {, null, }, true) endFieldInitializer(=, }) - endClassFields(null, null, null, null, null, null, final, 1, final, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) endMember() beginMetadataStar(final) endMetadataStar(0) @@ -225,7 +225,7 @@ beginCompilationUnit(class) handleLiteralNull(null) handleLiteralSetOrMap(1, {, null, }, true) endFieldInitializer(=, }) - endClassFields(null, null, null, null, null, null, final, 1, final, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) endMember() beginMetadataStar(final) endMetadataStar(0) @@ -244,7 +244,7 @@ beginCompilationUnit(class) handleLiteralNull(null) handleLiteralSetOrMap(1, {, null, }, true) endFieldInitializer(=, }) - endClassFields(null, null, null, null, null, null, final, 1, final, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 9, {, }) endClassDeclaration(class, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/issue_45251_set.dart.intertwined.expect b/pkg/front_end/parser_testcases/error_recovery/issue_45251_set.dart.intertwined.expect index d70e729d8c5..de5a448a709 100644 --- a/pkg/front_end/parser_testcases/error_recovery/issue_45251_set.dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/error_recovery/issue_45251_set.dart.intertwined.expect @@ -73,7 +73,7 @@ parseUnit(class) parseLiteralSetOrMapSuffix(>, null) listener: handleLiteralSetOrMap(0, {, null, }, false) listener: endFieldInitializer(=, }) - listener: endClassFields(null, null, null, null, null, null, final, 1, final, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, final) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, F) @@ -115,7 +115,7 @@ parseUnit(class) parseLiteralSetOrMapSuffix(>, null) listener: handleLiteralSetOrMap(0, {, null, }, false) listener: endFieldInitializer(=, }) - listener: endClassFields(null, null, null, null, null, null, final, 1, final, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, final) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, F) @@ -154,7 +154,7 @@ parseUnit(class) parseLiteralSetOrMapSuffix(Set, null) listener: handleLiteralSetOrMap(0, {, null, }, false) listener: endFieldInitializer(=, }) - listener: endClassFields(null, null, null, null, null, null, final, 1, final, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, final) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, F) @@ -205,7 +205,7 @@ parseUnit(class) listener: endArguments(0, (, )) listener: handleSend(Set, )) listener: endFieldInitializer(=, )) - listener: endClassFields(null, null, null, null, null, null, final, 1, final, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, final) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, F) @@ -248,7 +248,7 @@ parseUnit(class) listener: endArguments(0, (, )) listener: handleSend(Set, )) listener: endFieldInitializer(=, )) - listener: endClassFields(null, null, null, null, null, null, final, 1, final, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, final) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, F) @@ -304,7 +304,7 @@ parseUnit(class) listener: handleLiteralNull(null) listener: handleLiteralSetOrMap(1, {, null, }, true) listener: endFieldInitializer(=, }) - listener: endClassFields(null, null, null, null, null, null, final, 1, final, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, final) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, F) @@ -351,7 +351,7 @@ parseUnit(class) listener: handleLiteralNull(null) listener: handleLiteralSetOrMap(1, {, null, }, true) listener: endFieldInitializer(=, }) - listener: endClassFields(null, null, null, null, null, null, final, 1, final, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, final) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, F) @@ -401,7 +401,7 @@ parseUnit(class) listener: handleLiteralNull(null) listener: handleLiteralSetOrMap(1, {, null, }, true) listener: endFieldInitializer(=, }) - listener: endClassFields(null, null, null, null, null, null, final, 1, final, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, final) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, F) @@ -442,7 +442,7 @@ parseUnit(class) listener: handleLiteralNull(null) listener: handleLiteralSetOrMap(1, {, null, }, true) listener: endFieldInitializer(=, }) - listener: endClassFields(null, null, null, null, null, null, final, 1, final, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 9, {, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/issue_45251_set_const.dart.expect b/pkg/front_end/parser_testcases/error_recovery/issue_45251_set_const.dart.expect index b9f5f9d2286..37358c5f1f0 100644 --- a/pkg/front_end/parser_testcases/error_recovery/issue_45251_set_const.dart.expect +++ b/pkg/front_end/parser_testcases/error_recovery/issue_45251_set_const.dart.expect @@ -57,7 +57,7 @@ beginCompilationUnit(class) handleLiteralSetOrMap(0, {, const, }, false) endConstLiteral(}) endFieldInitializer(=, }) - endClassFields(null, null, null, null, null, null, final, 1, final, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) endMember() beginMetadataStar(final) endMetadataStar(0) @@ -85,7 +85,7 @@ beginCompilationUnit(class) handleLiteralSetOrMap(0, {, const, }, false) endConstLiteral(}) endFieldInitializer(=, }) - endClassFields(null, null, null, null, null, null, final, 1, final, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) endMember() beginMetadataStar(final) endMetadataStar(0) @@ -106,7 +106,7 @@ beginCompilationUnit(class) handleLiteralSetOrMap(0, {, const, }, false) endConstLiteral(}) endFieldInitializer(=, }) - endClassFields(null, null, null, null, null, null, final, 1, final, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) endMember() beginMetadataStar(final) endMetadataStar(0) @@ -139,7 +139,7 @@ beginCompilationUnit(class) endArguments(0, (, )) endConstExpression(const) endFieldInitializer(=, )) - endClassFields(null, null, null, null, null, null, final, 1, final, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) endMember() beginMetadataStar(final) endMetadataStar(0) @@ -164,7 +164,7 @@ beginCompilationUnit(class) endArguments(0, (, )) endConstExpression(const) endFieldInitializer(=, )) - endClassFields(null, null, null, null, null, null, final, 1, final, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) endMember() beginMetadataStar(final) endMetadataStar(0) @@ -194,7 +194,7 @@ beginCompilationUnit(class) handleLiteralSetOrMap(1, {, const, }, true) endConstLiteral(}) endFieldInitializer(=, }) - endClassFields(null, null, null, null, null, null, final, 1, final, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) endMember() beginMetadataStar(final) endMetadataStar(0) @@ -216,7 +216,7 @@ beginCompilationUnit(class) handleLiteralSetOrMap(1, {, const, }, true) endConstLiteral(}) endFieldInitializer(=, }) - endClassFields(null, null, null, null, null, null, final, 1, final, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) endMember() beginMetadataStar(final) endMetadataStar(0) @@ -245,7 +245,7 @@ beginCompilationUnit(class) handleLiteralSetOrMap(1, {, const, }, true) endConstLiteral(}) endFieldInitializer(=, }) - endClassFields(null, null, null, null, null, null, final, 1, final, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) endMember() beginMetadataStar(final) endMetadataStar(0) @@ -266,7 +266,7 @@ beginCompilationUnit(class) handleLiteralSetOrMap(1, {, const, }, true) endConstLiteral(}) endFieldInitializer(=, }) - endClassFields(null, null, null, null, null, null, final, 1, final, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 9, {, }) endClassDeclaration(class, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/issue_45251_set_const.dart.intertwined.expect b/pkg/front_end/parser_testcases/error_recovery/issue_45251_set_const.dart.intertwined.expect index e64e0313194..674561d78ab 100644 --- a/pkg/front_end/parser_testcases/error_recovery/issue_45251_set_const.dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/error_recovery/issue_45251_set_const.dart.intertwined.expect @@ -72,7 +72,7 @@ parseUnit(class) listener: handleLiteralSetOrMap(0, {, const, }, false) listener: endConstLiteral(}) listener: endFieldInitializer(=, }) - listener: endClassFields(null, null, null, null, null, null, final, 1, final, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, final) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, F) @@ -117,7 +117,7 @@ parseUnit(class) listener: handleLiteralSetOrMap(0, {, const, }, false) listener: endConstLiteral(}) listener: endFieldInitializer(=, }) - listener: endClassFields(null, null, null, null, null, null, final, 1, final, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, final) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, F) @@ -155,7 +155,7 @@ parseUnit(class) listener: handleLiteralSetOrMap(0, {, const, }, false) listener: endConstLiteral(}) listener: endFieldInitializer(=, }) - listener: endClassFields(null, null, null, null, null, null, final, 1, final, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, final) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, F) @@ -208,7 +208,7 @@ parseUnit(class) listener: endArguments(0, (, )) listener: endConstExpression(const) listener: endFieldInitializer(=, )) - listener: endClassFields(null, null, null, null, null, null, final, 1, final, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, final) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, F) @@ -253,7 +253,7 @@ parseUnit(class) listener: endArguments(0, (, )) listener: endConstExpression(const) listener: endFieldInitializer(=, )) - listener: endClassFields(null, null, null, null, null, null, final, 1, final, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, final) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, F) @@ -308,7 +308,7 @@ parseUnit(class) listener: handleLiteralSetOrMap(1, {, const, }, true) listener: endConstLiteral(}) listener: endFieldInitializer(=, }) - listener: endClassFields(null, null, null, null, null, null, final, 1, final, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, final) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, F) @@ -354,7 +354,7 @@ parseUnit(class) listener: handleLiteralSetOrMap(1, {, const, }, true) listener: endConstLiteral(}) listener: endFieldInitializer(=, }) - listener: endClassFields(null, null, null, null, null, null, final, 1, final, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, final) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, F) @@ -407,7 +407,7 @@ parseUnit(class) listener: handleLiteralSetOrMap(1, {, const, }, true) listener: endConstLiteral(}) listener: endFieldInitializer(=, }) - listener: endClassFields(null, null, null, null, null, null, final, 1, final, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, final) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, F) @@ -451,7 +451,7 @@ parseUnit(class) listener: handleLiteralSetOrMap(1, {, const, }, true) listener: endConstLiteral(}) listener: endFieldInitializer(=, }) - listener: endClassFields(null, null, null, null, null, null, final, 1, final, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 9, {, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/issue_45251_set_new.dart.expect b/pkg/front_end/parser_testcases/error_recovery/issue_45251_set_new.dart.expect index cf38ddf440e..3632858a37c 100644 --- a/pkg/front_end/parser_testcases/error_recovery/issue_45251_set_new.dart.expect +++ b/pkg/front_end/parser_testcases/error_recovery/issue_45251_set_new.dart.expect @@ -67,7 +67,7 @@ beginCompilationUnit(class) endTypeArguments(1, <, >) handleLiteralSetOrMap(0, {, null, }, false) endFieldInitializer(=, }) - endClassFields(null, null, null, null, null, null, final, 1, final, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) endMember() beginMetadataStar(final) endMetadataStar(0) @@ -94,7 +94,7 @@ beginCompilationUnit(class) endTypeArguments(1, <, >) handleLiteralSetOrMap(0, {, null, }, false) endFieldInitializer(=, }) - endClassFields(null, null, null, null, null, null, final, 1, final, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) endMember() beginMetadataStar(final) endMetadataStar(0) @@ -113,7 +113,7 @@ beginCompilationUnit(class) handleNoTypeArguments({) handleLiteralSetOrMap(0, {, null, }, false) endFieldInitializer(=, }) - endClassFields(null, null, null, null, null, null, final, 1, final, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) endMember() beginMetadataStar(final) endMetadataStar(0) @@ -146,7 +146,7 @@ beginCompilationUnit(class) endArguments(0, (, )) endNewExpression(new) endFieldInitializer(=, )) - endClassFields(null, null, null, null, null, null, final, 1, final, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) endMember() beginMetadataStar(final) endMetadataStar(0) @@ -171,7 +171,7 @@ beginCompilationUnit(class) endArguments(0, (, )) endNewExpression(new) endFieldInitializer(=, )) - endClassFields(null, null, null, null, null, null, final, 1, final, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) endMember() beginMetadataStar(final) endMetadataStar(0) @@ -199,7 +199,7 @@ beginCompilationUnit(class) handleLiteralNull(null) handleLiteralSetOrMap(1, {, null, }, true) endFieldInitializer(=, }) - endClassFields(null, null, null, null, null, null, final, 1, final, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) endMember() beginMetadataStar(final) endMetadataStar(0) @@ -219,7 +219,7 @@ beginCompilationUnit(class) handleLiteralNull(null) handleLiteralSetOrMap(1, {, null, }, true) endFieldInitializer(=, }) - endClassFields(null, null, null, null, null, null, final, 1, final, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) endMember() beginMetadataStar(final) endMetadataStar(0) @@ -247,7 +247,7 @@ beginCompilationUnit(class) handleLiteralNull(null) handleLiteralSetOrMap(1, {, null, }, true) endFieldInitializer(=, }) - endClassFields(null, null, null, null, null, null, final, 1, final, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) endMember() beginMetadataStar(final) endMetadataStar(0) @@ -267,7 +267,7 @@ beginCompilationUnit(class) handleLiteralNull(null) handleLiteralSetOrMap(1, {, null, }, true) endFieldInitializer(=, }) - endClassFields(null, null, null, null, null, null, final, 1, final, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 9, {, }) endClassDeclaration(class, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/issue_45251_set_new.dart.intertwined.expect b/pkg/front_end/parser_testcases/error_recovery/issue_45251_set_new.dart.intertwined.expect index 6637fd8fa82..225fc853a08 100644 --- a/pkg/front_end/parser_testcases/error_recovery/issue_45251_set_new.dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/error_recovery/issue_45251_set_new.dart.intertwined.expect @@ -71,7 +71,7 @@ parseUnit(class) parseLiteralSetOrMapSuffix(>, null) listener: handleLiteralSetOrMap(0, {, null, }, false) listener: endFieldInitializer(=, }) - listener: endClassFields(null, null, null, null, null, null, final, 1, final, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, final) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, F) @@ -117,7 +117,7 @@ parseUnit(class) parseLiteralSetOrMapSuffix(>, null) listener: handleLiteralSetOrMap(0, {, null, }, false) listener: endFieldInitializer(=, }) - listener: endClassFields(null, null, null, null, null, null, final, 1, final, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, final) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, F) @@ -154,7 +154,7 @@ parseUnit(class) parseLiteralSetOrMapSuffix(Set, null) listener: handleLiteralSetOrMap(0, {, null, }, false) listener: endFieldInitializer(=, }) - listener: endClassFields(null, null, null, null, null, null, final, 1, final, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, final) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, F) @@ -207,7 +207,7 @@ parseUnit(class) listener: endArguments(0, (, )) listener: endNewExpression(new) listener: endFieldInitializer(=, )) - listener: endClassFields(null, null, null, null, null, null, final, 1, final, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, final) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, F) @@ -252,7 +252,7 @@ parseUnit(class) listener: endArguments(0, (, )) listener: endNewExpression(new) listener: endFieldInitializer(=, )) - listener: endClassFields(null, null, null, null, null, null, final, 1, final, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, final) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, F) @@ -306,7 +306,7 @@ parseUnit(class) listener: handleLiteralNull(null) listener: handleLiteralSetOrMap(1, {, null, }, true) listener: endFieldInitializer(=, }) - listener: endClassFields(null, null, null, null, null, null, final, 1, final, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, final) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, F) @@ -351,7 +351,7 @@ parseUnit(class) listener: handleLiteralNull(null) listener: handleLiteralSetOrMap(1, {, null, }, true) listener: endFieldInitializer(=, }) - listener: endClassFields(null, null, null, null, null, null, final, 1, final, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, final) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, F) @@ -405,7 +405,7 @@ parseUnit(class) listener: handleLiteralNull(null) listener: handleLiteralSetOrMap(1, {, null, }, true) listener: endFieldInitializer(=, }) - listener: endClassFields(null, null, null, null, null, null, final, 1, final, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, final) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, F) @@ -450,7 +450,7 @@ parseUnit(class) listener: handleLiteralNull(null) listener: handleLiteralSetOrMap(1, {, null, }, true) listener: endFieldInitializer(=, }) - listener: endClassFields(null, null, null, null, null, null, final, 1, final, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 9, {, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/issue_45327_prime_1.crash_dart.expect b/pkg/front_end/parser_testcases/error_recovery/issue_45327_prime_1.crash_dart.expect index e91c876199d..102b38ff5d7 100644 --- a/pkg/front_end/parser_testcases/error_recovery/issue_45327_prime_1.crash_dart.expect +++ b/pkg/front_end/parser_testcases/error_recovery/issue_45327_prime_1.crash_dart.expect @@ -73,7 +73,7 @@ beginCompilationUnit(class) endThenStatement(or, ;) endIfStatement(if, null, ;) endBlockFunctionBody(1, {, }) - endClassMethod(null, foo, (, null, }) + endMethod(DeclarationKind.Class, null, foo, (, null, }) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 1, {, }) endClassDeclaration(class, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/issue_45327_prime_1.crash_dart.intertwined.expect b/pkg/front_end/parser_testcases/error_recovery/issue_45327_prime_1.crash_dart.intertwined.expect index 846d2dd4139..b360c2135dd 100644 --- a/pkg/front_end/parser_testcases/error_recovery/issue_45327_prime_1.crash_dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/error_recovery/issue_45327_prime_1.crash_dart.intertwined.expect @@ -148,7 +148,7 @@ parseUnit(UnmatchedToken(()) listener: endIfStatement(if, null, ;) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(1, {, }) - listener: endClassMethod(null, foo, (, null, }) + listener: endMethod(DeclarationKind.Class, null, foo, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 1, {, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/issue_45662.crash_dart.expect b/pkg/front_end/parser_testcases/error_recovery/issue_45662.crash_dart.expect index 92c2f5bd0b3..12515d2e3f4 100644 --- a/pkg/front_end/parser_testcases/error_recovery/issue_45662.crash_dart.expect +++ b/pkg/front_end/parser_testcases/error_recovery/issue_45662.crash_dart.expect @@ -42,7 +42,7 @@ beginCompilationUnit(class) handleType(List, null) handleIdentifier(p, fieldDeclaration) handleNoFieldInitializer(;) - endClassFields(null, null, null, null, null, null, null, 1, List, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, List, ;) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 1, {, }) endClassDeclaration(class, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/issue_45662.crash_dart.intertwined.expect b/pkg/front_end/parser_testcases/error_recovery/issue_45662.crash_dart.intertwined.expect index f53726dd722..abc43f24cf5 100644 --- a/pkg/front_end/parser_testcases/error_recovery/issue_45662.crash_dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/error_recovery/issue_45662.crash_dart.intertwined.expect @@ -65,7 +65,7 @@ parseUnit(class) listener: handleIdentifier(p, fieldDeclaration) parseFieldInitializerOpt(p, p, null, null, null, null, null, DeclarationKind.Class, A) listener: handleNoFieldInitializer(;) - listener: endClassFields(null, null, null, null, null, null, null, 1, List, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, List, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 1, {, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/issue_45662_gt_gt.crash_dart.expect b/pkg/front_end/parser_testcases/error_recovery/issue_45662_gt_gt.crash_dart.expect index 69f0c813246..15a5ad34735 100644 --- a/pkg/front_end/parser_testcases/error_recovery/issue_45662_gt_gt.crash_dart.expect +++ b/pkg/front_end/parser_testcases/error_recovery/issue_45662_gt_gt.crash_dart.expect @@ -38,7 +38,7 @@ beginCompilationUnit(class) handleType(List, null) handleIdentifier(p, fieldDeclaration) handleNoFieldInitializer(;) - endClassFields(null, null, null, null, null, null, null, 1, List, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, List, ;) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 1, {, }) endClassDeclaration(class, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/issue_45662_gt_gt.crash_dart.intertwined.expect b/pkg/front_end/parser_testcases/error_recovery/issue_45662_gt_gt.crash_dart.intertwined.expect index 4529d3f8744..ef93f712c35 100644 --- a/pkg/front_end/parser_testcases/error_recovery/issue_45662_gt_gt.crash_dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/error_recovery/issue_45662_gt_gt.crash_dart.intertwined.expect @@ -60,7 +60,7 @@ parseUnit(class) listener: handleIdentifier(p, fieldDeclaration) parseFieldInitializerOpt(p, p, null, null, null, null, null, DeclarationKind.Class, A) listener: handleNoFieldInitializer(;) - listener: endClassFields(null, null, null, null, null, null, null, 1, List, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, List, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 1, {, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/issue_45662_gt_gt_prime.crash_dart.expect b/pkg/front_end/parser_testcases/error_recovery/issue_45662_gt_gt_prime.crash_dart.expect index 973c237b067..f4e43ec9103 100644 --- a/pkg/front_end/parser_testcases/error_recovery/issue_45662_gt_gt_prime.crash_dart.expect +++ b/pkg/front_end/parser_testcases/error_recovery/issue_45662_gt_gt_prime.crash_dart.expect @@ -38,7 +38,7 @@ beginCompilationUnit(class) handleType(List, null) handleIdentifier(p, fieldDeclaration) handleNoFieldInitializer(;) - endClassFields(null, null, null, null, null, null, null, 1, List, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, List, ;) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 1, {, }) endClassDeclaration(class, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/issue_45662_gt_gt_prime.crash_dart.intertwined.expect b/pkg/front_end/parser_testcases/error_recovery/issue_45662_gt_gt_prime.crash_dart.intertwined.expect index 107ee3da5bf..a9e369898b3 100644 --- a/pkg/front_end/parser_testcases/error_recovery/issue_45662_gt_gt_prime.crash_dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/error_recovery/issue_45662_gt_gt_prime.crash_dart.intertwined.expect @@ -60,7 +60,7 @@ parseUnit(class) listener: handleIdentifier(p, fieldDeclaration) parseFieldInitializerOpt(p, p, null, null, null, null, null, DeclarationKind.Class, A) listener: handleNoFieldInitializer(;) - listener: endClassFields(null, null, null, null, null, null, null, 1, List, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, List, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 1, {, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/issue_45662_prime.crash_dart.expect b/pkg/front_end/parser_testcases/error_recovery/issue_45662_prime.crash_dart.expect index a4ab7cfddaa..d42f0342fbf 100644 --- a/pkg/front_end/parser_testcases/error_recovery/issue_45662_prime.crash_dart.expect +++ b/pkg/front_end/parser_testcases/error_recovery/issue_45662_prime.crash_dart.expect @@ -42,7 +42,7 @@ beginCompilationUnit(class) handleType(List, null) handleIdentifier(p, fieldDeclaration) handleNoFieldInitializer(;) - endClassFields(null, null, null, null, null, null, null, 1, List, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, List, ;) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 1, {, }) endClassDeclaration(class, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/issue_45662_prime.crash_dart.intertwined.expect b/pkg/front_end/parser_testcases/error_recovery/issue_45662_prime.crash_dart.intertwined.expect index 34bf9f8f28f..3db1dde733a 100644 --- a/pkg/front_end/parser_testcases/error_recovery/issue_45662_prime.crash_dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/error_recovery/issue_45662_prime.crash_dart.intertwined.expect @@ -65,7 +65,7 @@ parseUnit(class) listener: handleIdentifier(p, fieldDeclaration) parseFieldInitializerOpt(p, p, null, null, null, null, null, DeclarationKind.Class, A) listener: handleNoFieldInitializer(;) - listener: endClassFields(null, null, null, null, null, null, null, 1, List, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, List, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 1, {, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/issue_46505.crash_dart.expect b/pkg/front_end/parser_testcases/error_recovery/issue_46505.crash_dart.expect index a71f8a04903..392a9cdf3db 100644 --- a/pkg/front_end/parser_testcases/error_recovery/issue_46505.crash_dart.expect +++ b/pkg/front_end/parser_testcases/error_recovery/issue_46505.crash_dart.expect @@ -58,7 +58,7 @@ beginCompilationUnit(class) handleIdentifier(, fieldDeclaration) handleNoFieldInitializer(}) handleRecoverableError(Message[Template(ExpectedAfterButGot), Expected ';' after this., null, {string: ;}], >, >) - endClassFields(null, null, null, null, null, null, null, 1, Stream, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, Stream, ;) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 1, {, }) endClassDeclaration(class, }) @@ -92,7 +92,7 @@ beginCompilationUnit(class) handleIdentifier(, fieldDeclaration) handleNoFieldInitializer(}) handleRecoverableError(Message[Template(ExpectedAfterButGot), Expected ';' after this., null, {string: ;}], >, >) - endClassFields(null, null, null, null, null, null, null, 1, List, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, List, ;) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 1, {, }) endClassDeclaration(class, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/issue_46505.crash_dart.intertwined.expect b/pkg/front_end/parser_testcases/error_recovery/issue_46505.crash_dart.intertwined.expect index f3e112bea2e..6772333ef2c 100644 --- a/pkg/front_end/parser_testcases/error_recovery/issue_46505.crash_dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/error_recovery/issue_46505.crash_dart.intertwined.expect @@ -64,7 +64,7 @@ parseUnit(class) reportRecoverableError(>, Message[Template(ExpectedAfterButGot), Expected ';' after this., null, {string: ;}]) listener: handleRecoverableError(Message[Template(ExpectedAfterButGot), Expected ';' after this., null, {string: ;}], >, >) rewriter() - listener: endClassFields(null, null, null, null, null, null, null, 1, Stream, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, Stream, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 1, {, }) @@ -127,7 +127,7 @@ parseUnit(class) reportRecoverableError(>, Message[Template(ExpectedAfterButGot), Expected ';' after this., null, {string: ;}]) listener: handleRecoverableError(Message[Template(ExpectedAfterButGot), Expected ';' after this., null, {string: ;}], >, >) rewriter() - listener: endClassFields(null, null, null, null, null, null, null, 1, List, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, List, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 1, {, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/issue_46505_prime_1.crash_dart.expect b/pkg/front_end/parser_testcases/error_recovery/issue_46505_prime_1.crash_dart.expect index 24b29e9263b..7a6c611202a 100644 --- a/pkg/front_end/parser_testcases/error_recovery/issue_46505_prime_1.crash_dart.expect +++ b/pkg/front_end/parser_testcases/error_recovery/issue_46505_prime_1.crash_dart.expect @@ -42,7 +42,7 @@ beginCompilationUnit(class) handleAsyncModifier(null, null) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) - endClassMethod(null, Stream, (, null, }) + endMethod(DeclarationKind.Class, null, Stream, (, null, }) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 1, {, }) endClassDeclaration(class, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/issue_46505_prime_1.crash_dart.intertwined.expect b/pkg/front_end/parser_testcases/error_recovery/issue_46505_prime_1.crash_dart.intertwined.expect index ec08f04a42a..2edcbd9dc2a 100644 --- a/pkg/front_end/parser_testcases/error_recovery/issue_46505_prime_1.crash_dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/error_recovery/issue_46505_prime_1.crash_dart.intertwined.expect @@ -71,7 +71,7 @@ parseUnit(class) listener: beginBlockFunctionBody({) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(0, {, }) - listener: endClassMethod(null, Stream, (, null, }) + listener: endMethod(DeclarationKind.Class, null, Stream, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 1, {, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/issue_46505_prime_2.crash_dart.expect b/pkg/front_end/parser_testcases/error_recovery/issue_46505_prime_2.crash_dart.expect index 97fd1746ebb..7026c3a6a90 100644 --- a/pkg/front_end/parser_testcases/error_recovery/issue_46505_prime_2.crash_dart.expect +++ b/pkg/front_end/parser_testcases/error_recovery/issue_46505_prime_2.crash_dart.expect @@ -35,7 +35,7 @@ beginCompilationUnit(class) handleAsyncModifier(null, null) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) - endClassMethod(null, Stream, (, null, }) + endMethod(DeclarationKind.Class, null, Stream, (, null, }) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 1, {, }) endClassDeclaration(class, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/issue_46505_prime_2.crash_dart.intertwined.expect b/pkg/front_end/parser_testcases/error_recovery/issue_46505_prime_2.crash_dart.intertwined.expect index 4963779ffbb..ae81018657c 100644 --- a/pkg/front_end/parser_testcases/error_recovery/issue_46505_prime_2.crash_dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/error_recovery/issue_46505_prime_2.crash_dart.intertwined.expect @@ -67,7 +67,7 @@ parseUnit(class) listener: beginBlockFunctionBody({) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(0, {, }) - listener: endClassMethod(null, Stream, (, null, }) + listener: endMethod(DeclarationKind.Class, null, Stream, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 1, {, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/issue_46505_prime_3.crash_dart.expect b/pkg/front_end/parser_testcases/error_recovery/issue_46505_prime_3.crash_dart.expect index 21ce2127c75..5e9f5b1c20f 100644 --- a/pkg/front_end/parser_testcases/error_recovery/issue_46505_prime_3.crash_dart.expect +++ b/pkg/front_end/parser_testcases/error_recovery/issue_46505_prime_3.crash_dart.expect @@ -50,7 +50,7 @@ beginCompilationUnit(class) handleIdentifier(, fieldDeclaration) handleNoFieldInitializer(}) handleRecoverableError(Message[Template(ExpectedAfterButGot), Expected ';' after this., null, {string: ;}], >, >) - endClassFields(null, null, null, null, null, null, null, 1, Stream, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, Stream, ;) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 1, {, }) endClassDeclaration(class, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/issue_46505_prime_3.crash_dart.intertwined.expect b/pkg/front_end/parser_testcases/error_recovery/issue_46505_prime_3.crash_dart.intertwined.expect index 0c4737a6de6..53ec14a6dd4 100644 --- a/pkg/front_end/parser_testcases/error_recovery/issue_46505_prime_3.crash_dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/error_recovery/issue_46505_prime_3.crash_dart.intertwined.expect @@ -69,7 +69,7 @@ parseUnit(class) reportRecoverableError(>, Message[Template(ExpectedAfterButGot), Expected ';' after this., null, {string: ;}]) listener: handleRecoverableError(Message[Template(ExpectedAfterButGot), Expected ';' after this., null, {string: ;}], >, >) rewriter() - listener: endClassFields(null, null, null, null, null, null, null, 1, Stream, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, Stream, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 1, {, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/issue_46505_prime_4.crash_dart.expect b/pkg/front_end/parser_testcases/error_recovery/issue_46505_prime_4.crash_dart.expect index 747052392a4..8e026c10154 100644 --- a/pkg/front_end/parser_testcases/error_recovery/issue_46505_prime_4.crash_dart.expect +++ b/pkg/front_end/parser_testcases/error_recovery/issue_46505_prime_4.crash_dart.expect @@ -54,7 +54,7 @@ beginCompilationUnit(class) handleIdentifier(, fieldDeclaration) handleNoFieldInitializer(}) handleRecoverableError(Message[Template(ExpectedAfterButGot), Expected ';' after this., null, {string: ;}], >, >) - endClassFields(null, null, null, null, null, null, null, 1, Stream, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, Stream, ;) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 1, {, }) endClassDeclaration(class, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/issue_46505_prime_4.crash_dart.intertwined.expect b/pkg/front_end/parser_testcases/error_recovery/issue_46505_prime_4.crash_dart.intertwined.expect index 90a4dba5de4..56181ff5deb 100644 --- a/pkg/front_end/parser_testcases/error_recovery/issue_46505_prime_4.crash_dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/error_recovery/issue_46505_prime_4.crash_dart.intertwined.expect @@ -74,7 +74,7 @@ parseUnit(class) reportRecoverableError(>, Message[Template(ExpectedAfterButGot), Expected ';' after this., null, {string: ;}]) listener: handleRecoverableError(Message[Template(ExpectedAfterButGot), Expected ';' after this., null, {string: ;}], >, >) rewriter() - listener: endClassFields(null, null, null, null, null, null, null, 1, Stream, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, Stream, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 1, {, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/issue_46505_prime_5.crash_dart.expect b/pkg/front_end/parser_testcases/error_recovery/issue_46505_prime_5.crash_dart.expect index 6c23c645d55..5d352090b7e 100644 --- a/pkg/front_end/parser_testcases/error_recovery/issue_46505_prime_5.crash_dart.expect +++ b/pkg/front_end/parser_testcases/error_recovery/issue_46505_prime_5.crash_dart.expect @@ -118,7 +118,7 @@ beginCompilationUnit(class) handleIdentifier(, fieldDeclaration) handleNoFieldInitializer(}) handleRecoverableError(Message[Template(ExpectedAfterButGot), Expected ';' after this., null, {string: ;}], >, >) - endClassFields(null, null, null, null, null, null, null, 1, Stream, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, Stream, ;) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 1, {, }) endClassDeclaration(class, }) @@ -161,7 +161,7 @@ beginCompilationUnit(class) handleType(Stream, null) handleIdentifier(foo, fieldDeclaration) handleNoFieldInitializer(;) - endClassFields(null, null, null, null, null, null, null, 1, Stream, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, Stream, ;) endMember() beginMetadataStar(Stream) endMetadataStar(0) @@ -191,7 +191,7 @@ beginCompilationUnit(class) handleIdentifier(, fieldDeclaration) handleNoFieldInitializer(}) handleRecoverableError(Message[Template(ExpectedAfterButGot), Expected ';' after this., null, {string: ;}], >, >) - endClassFields(null, null, null, null, null, null, null, 1, Stream, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, Stream, ;) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 2, {, }) endClassDeclaration(class, }) @@ -234,7 +234,7 @@ beginCompilationUnit(class) handleType(Stream, null) handleIdentifier(foo, fieldDeclaration) handleNoFieldInitializer(;) - endClassFields(null, null, null, null, null, null, null, 1, Stream, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, Stream, ;) endMember() beginMetadataStar(Stream) endMetadataStar(0) @@ -278,7 +278,7 @@ beginCompilationUnit(class) handleAsyncModifier(null, null) handleRecoverableError(Message[Template(ExpectedFunctionBody), Expected a function body, but got 'baz'., null, {lexeme: baz}], baz, baz) handleInvalidFunctionBody({) - endClassMethod(null, Stream, (, null, }) + endMethod(DeclarationKind.Class, null, Stream, (, null, }) endMember() beginMetadataStar(baz) endMetadataStar(0) @@ -288,7 +288,7 @@ beginCompilationUnit(class) handleNoType(}) handleIdentifier(baz, fieldDeclaration) handleNoFieldInitializer(;) - endClassFields(null, null, null, null, null, null, null, 1, baz, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, baz, ;) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 3, {, }) endClassDeclaration(class, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/issue_46505_prime_5.crash_dart.intertwined.expect b/pkg/front_end/parser_testcases/error_recovery/issue_46505_prime_5.crash_dart.intertwined.expect index 3a942851418..c0a61c2913d 100644 --- a/pkg/front_end/parser_testcases/error_recovery/issue_46505_prime_5.crash_dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/error_recovery/issue_46505_prime_5.crash_dart.intertwined.expect @@ -74,7 +74,7 @@ parseUnit(class) reportRecoverableError(>, Message[Template(ExpectedAfterButGot), Expected ';' after this., null, {string: ;}]) listener: handleRecoverableError(Message[Template(ExpectedAfterButGot), Expected ';' after this., null, {string: ;}], >, >) rewriter() - listener: endClassFields(null, null, null, null, null, null, null, 1, Stream, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, Stream, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 1, {, }) @@ -140,7 +140,7 @@ parseUnit(class) listener: handleIdentifier(foo, fieldDeclaration) parseFieldInitializerOpt(foo, foo, null, null, null, null, null, DeclarationKind.Class, B) listener: handleNoFieldInitializer(;) - listener: endClassFields(null, null, null, null, null, null, null, 1, Stream, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, Stream, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, Stream) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, B) @@ -189,7 +189,7 @@ parseUnit(class) reportRecoverableError(>, Message[Template(ExpectedAfterButGot), Expected ';' after this., null, {string: ;}]) listener: handleRecoverableError(Message[Template(ExpectedAfterButGot), Expected ';' after this., null, {string: ;}], >, >) rewriter() - listener: endClassFields(null, null, null, null, null, null, null, 1, Stream, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, Stream, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 2, {, }) @@ -255,7 +255,7 @@ parseUnit(class) listener: handleIdentifier(foo, fieldDeclaration) parseFieldInitializerOpt(foo, foo, null, null, null, null, null, DeclarationKind.Class, C) listener: handleNoFieldInitializer(;) - listener: endClassFields(null, null, null, null, null, null, null, 1, Stream, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, Stream, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, Stream) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, C) @@ -338,7 +338,7 @@ parseUnit(class) rewriter() rewriter() listener: handleInvalidFunctionBody({) - listener: endClassMethod(null, Stream, (, null, }) + listener: endMethod(DeclarationKind.Class, null, Stream, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, baz) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, C) @@ -356,7 +356,7 @@ parseUnit(class) listener: handleIdentifier(baz, fieldDeclaration) parseFieldInitializerOpt(baz, baz, null, null, null, null, null, DeclarationKind.Class, C) listener: handleNoFieldInitializer(;) - listener: endClassFields(null, null, null, null, null, null, null, 1, baz, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, baz, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 3, {, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/issue_46505_prime_6.crash_dart.expect b/pkg/front_end/parser_testcases/error_recovery/issue_46505_prime_6.crash_dart.expect index 89218d9e69c..b62d23e36f5 100644 --- a/pkg/front_end/parser_testcases/error_recovery/issue_46505_prime_6.crash_dart.expect +++ b/pkg/front_end/parser_testcases/error_recovery/issue_46505_prime_6.crash_dart.expect @@ -54,7 +54,7 @@ beginCompilationUnit(class) handleAsyncModifier(null, null) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) - endClassMethod(null, stream, (, null, }) + endMethod(DeclarationKind.Class, null, stream, (, null, }) endMember() beginMetadataStar(stream2) endMetadataStar(0) @@ -93,7 +93,7 @@ beginCompilationUnit(class) handleAsyncModifier(null, null) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) - endClassMethod(null, stream2, (, null, }) + endMethod(DeclarationKind.Class, null, stream2, (, null, }) endMember() beginMetadataStar(stream3) endMetadataStar(0) @@ -125,7 +125,7 @@ beginCompilationUnit(class) handleAsyncModifier(null, null) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) - endClassMethod(null, stream3, (, null, }) + endMethod(DeclarationKind.Class, null, stream3, (, null, }) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 3, {, }) endClassDeclaration(class, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/issue_46505_prime_6.crash_dart.intertwined.expect b/pkg/front_end/parser_testcases/error_recovery/issue_46505_prime_6.crash_dart.intertwined.expect index 5a0af91828b..2c9f65aee16 100644 --- a/pkg/front_end/parser_testcases/error_recovery/issue_46505_prime_6.crash_dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/error_recovery/issue_46505_prime_6.crash_dart.intertwined.expect @@ -85,7 +85,7 @@ parseUnit(class) listener: beginBlockFunctionBody({) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(0, {, }) - listener: endClassMethod(null, stream, (, null, }) + listener: endMethod(DeclarationKind.Class, null, stream, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, stream2) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, A) @@ -149,7 +149,7 @@ parseUnit(class) listener: beginBlockFunctionBody({) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(0, {, }) - listener: endClassMethod(null, stream2, (, null, }) + listener: endMethod(DeclarationKind.Class, null, stream2, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, stream3) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, A) @@ -201,7 +201,7 @@ parseUnit(class) listener: beginBlockFunctionBody({) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(0, {, }) - listener: endClassMethod(null, stream3, (, null, }) + listener: endMethod(DeclarationKind.Class, null, stream3, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 3, {, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/issue_48371_prime3.dart.expect b/pkg/front_end/parser_testcases/error_recovery/issue_48371_prime3.dart.expect index 9c2e5a3a7d8..683e54f6cdc 100644 --- a/pkg/front_end/parser_testcases/error_recovery/issue_48371_prime3.dart.expect +++ b/pkg/front_end/parser_testcases/error_recovery/issue_48371_prime3.dart.expect @@ -78,7 +78,7 @@ beginCompilationUnit(enum) handleSend(print, )) handleExpressionStatement(print, ;) endBlockFunctionBody(1, {, }) - endClassMethod(null, void, (, null, }) + endMethod(DeclarationKind.Class, null, void, (, null, }) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 1, {, }) endClassDeclaration(class, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/issue_48371_prime3.dart.intertwined.expect b/pkg/front_end/parser_testcases/error_recovery/issue_48371_prime3.dart.intertwined.expect index 079ced93ade..8a4e949b543 100644 --- a/pkg/front_end/parser_testcases/error_recovery/issue_48371_prime3.dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/error_recovery/issue_48371_prime3.dart.intertwined.expect @@ -158,7 +158,7 @@ parseUnit(enum) listener: handleExpressionStatement(print, ;) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(1, {, }) - listener: endClassMethod(null, void, (, null, }) + listener: endMethod(DeclarationKind.Class, null, void, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 1, {, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/issue_48380_1.dart.expect b/pkg/front_end/parser_testcases/error_recovery/issue_48380_1.dart.expect index 5559aa7525f..78cf9c4f227 100644 --- a/pkg/front_end/parser_testcases/error_recovery/issue_48380_1.dart.expect +++ b/pkg/front_end/parser_testcases/error_recovery/issue_48380_1.dart.expect @@ -58,7 +58,7 @@ beginCompilationUnit(enum) handleNoInitializers() handleAsyncModifier(null, null) handleEmptyFunctionBody(;) - endEnumConstructor(const, (, null, ;) + endConstructor(DeclarationKind.Enum, const, (, null, ;) endMember() beginMetadataStar(const) endMetadataStar(0) @@ -74,7 +74,7 @@ beginCompilationUnit(enum) handleNoInitializers() handleAsyncModifier(null, null) handleEmptyFunctionBody(;) - endEnumConstructor(const, (, null, ;) + endConstructor(DeclarationKind.Enum, const, (, null, ;) endMember() endEnumBody({, }) endEnumDeclaration(enum, enum, {, 2, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/issue_48380_1.dart.intertwined.expect b/pkg/front_end/parser_testcases/error_recovery/issue_48380_1.dart.intertwined.expect index 8eb64a3ecba..2592250641a 100644 --- a/pkg/front_end/parser_testcases/error_recovery/issue_48380_1.dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/error_recovery/issue_48380_1.dart.intertwined.expect @@ -86,7 +86,7 @@ parseUnit(enum) inPlainSync() parseFunctionBody(), false, true) listener: handleEmptyFunctionBody(;) - listener: endEnumConstructor(const, (, null, ;) + listener: endConstructor(DeclarationKind.Enum, const, (, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, const) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Enum, E) @@ -119,7 +119,7 @@ parseUnit(enum) inPlainSync() parseFunctionBody(), false, true) listener: handleEmptyFunctionBody(;) - listener: endEnumConstructor(const, (, null, ;) + listener: endConstructor(DeclarationKind.Enum, const, (, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endEnumBody({, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/issue_48380_1_comma.dart.expect b/pkg/front_end/parser_testcases/error_recovery/issue_48380_1_comma.dart.expect index 843afd3eda2..80c68976a6f 100644 --- a/pkg/front_end/parser_testcases/error_recovery/issue_48380_1_comma.dart.expect +++ b/pkg/front_end/parser_testcases/error_recovery/issue_48380_1_comma.dart.expect @@ -73,7 +73,7 @@ beginCompilationUnit(enum) handleNoInitializers() handleAsyncModifier(null, null) handleEmptyFunctionBody(;) - endEnumConstructor(const, (, null, ;) + endConstructor(DeclarationKind.Enum, const, (, null, ;) endMember() beginMetadataStar(const) endMetadataStar(0) @@ -89,7 +89,7 @@ beginCompilationUnit(enum) handleNoInitializers() handleAsyncModifier(null, null) handleEmptyFunctionBody(;) - endEnumConstructor(const, (, null, ;) + endConstructor(DeclarationKind.Enum, const, (, null, ;) endMember() endEnumBody({, }) endEnumDeclaration(enum, enum, {, 2, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/issue_48380_1_comma.dart.intertwined.expect b/pkg/front_end/parser_testcases/error_recovery/issue_48380_1_comma.dart.intertwined.expect index 299385f7466..b77dc96d245 100644 --- a/pkg/front_end/parser_testcases/error_recovery/issue_48380_1_comma.dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/error_recovery/issue_48380_1_comma.dart.intertwined.expect @@ -107,7 +107,7 @@ parseUnit(enum) inPlainSync() parseFunctionBody(), false, true) listener: handleEmptyFunctionBody(;) - listener: endEnumConstructor(const, (, null, ;) + listener: endConstructor(DeclarationKind.Enum, const, (, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, const) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Enum, E) @@ -140,7 +140,7 @@ parseUnit(enum) inPlainSync() parseFunctionBody(), false, true) listener: handleEmptyFunctionBody(;) - listener: endEnumConstructor(const, (, null, ;) + listener: endConstructor(DeclarationKind.Enum, const, (, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endEnumBody({, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/issue_48380_1_comma_ok.dart.expect b/pkg/front_end/parser_testcases/error_recovery/issue_48380_1_comma_ok.dart.expect index 3d05a2d4480..e2f2230699a 100644 --- a/pkg/front_end/parser_testcases/error_recovery/issue_48380_1_comma_ok.dart.expect +++ b/pkg/front_end/parser_testcases/error_recovery/issue_48380_1_comma_ok.dart.expect @@ -61,7 +61,7 @@ beginCompilationUnit(enum) handleNoInitializers() handleAsyncModifier(null, null) handleEmptyFunctionBody(;) - endEnumConstructor(const, (, null, ;) + endConstructor(DeclarationKind.Enum, const, (, null, ;) endMember() beginMetadataStar(const) endMetadataStar(0) @@ -77,7 +77,7 @@ beginCompilationUnit(enum) handleNoInitializers() handleAsyncModifier(null, null) handleEmptyFunctionBody(;) - endEnumConstructor(const, (, null, ;) + endConstructor(DeclarationKind.Enum, const, (, null, ;) endMember() endEnumBody({, }) endEnumDeclaration(enum, enum, {, 2, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/issue_48380_1_comma_ok.dart.intertwined.expect b/pkg/front_end/parser_testcases/error_recovery/issue_48380_1_comma_ok.dart.intertwined.expect index 66c2189e39e..05234a65f8b 100644 --- a/pkg/front_end/parser_testcases/error_recovery/issue_48380_1_comma_ok.dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/error_recovery/issue_48380_1_comma_ok.dart.intertwined.expect @@ -100,7 +100,7 @@ parseUnit(enum) inPlainSync() parseFunctionBody(), false, true) listener: handleEmptyFunctionBody(;) - listener: endEnumConstructor(const, (, null, ;) + listener: endConstructor(DeclarationKind.Enum, const, (, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, const) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Enum, E) @@ -133,7 +133,7 @@ parseUnit(enum) inPlainSync() parseFunctionBody(), false, true) listener: handleEmptyFunctionBody(;) - listener: endEnumConstructor(const, (, null, ;) + listener: endConstructor(DeclarationKind.Enum, const, (, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endEnumBody({, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/issue_48380_1_ok.dart.expect b/pkg/front_end/parser_testcases/error_recovery/issue_48380_1_ok.dart.expect index 61923248ebb..0747a1754d1 100644 --- a/pkg/front_end/parser_testcases/error_recovery/issue_48380_1_ok.dart.expect +++ b/pkg/front_end/parser_testcases/error_recovery/issue_48380_1_ok.dart.expect @@ -46,7 +46,7 @@ beginCompilationUnit(enum) handleNoInitializers() handleAsyncModifier(null, null) handleEmptyFunctionBody(;) - endEnumConstructor(const, (, null, ;) + endConstructor(DeclarationKind.Enum, const, (, null, ;) endMember() beginMetadataStar(const) endMetadataStar(0) @@ -62,7 +62,7 @@ beginCompilationUnit(enum) handleNoInitializers() handleAsyncModifier(null, null) handleEmptyFunctionBody(;) - endEnumConstructor(const, (, null, ;) + endConstructor(DeclarationKind.Enum, const, (, null, ;) endMember() endEnumBody({, }) endEnumDeclaration(enum, enum, {, 2, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/issue_48380_1_ok.dart.intertwined.expect b/pkg/front_end/parser_testcases/error_recovery/issue_48380_1_ok.dart.intertwined.expect index 0bbccf4ccba..a2f9951881f 100644 --- a/pkg/front_end/parser_testcases/error_recovery/issue_48380_1_ok.dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/error_recovery/issue_48380_1_ok.dart.intertwined.expect @@ -79,7 +79,7 @@ parseUnit(enum) inPlainSync() parseFunctionBody(), false, true) listener: handleEmptyFunctionBody(;) - listener: endEnumConstructor(const, (, null, ;) + listener: endConstructor(DeclarationKind.Enum, const, (, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, const) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Enum, E) @@ -112,7 +112,7 @@ parseUnit(enum) inPlainSync() parseFunctionBody(), false, true) listener: handleEmptyFunctionBody(;) - listener: endEnumConstructor(const, (, null, ;) + listener: endConstructor(DeclarationKind.Enum, const, (, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endEnumBody({, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/issue_48380_2.dart.expect b/pkg/front_end/parser_testcases/error_recovery/issue_48380_2.dart.expect index 18128e64398..4ff37f4210c 100644 --- a/pkg/front_end/parser_testcases/error_recovery/issue_48380_2.dart.expect +++ b/pkg/front_end/parser_testcases/error_recovery/issue_48380_2.dart.expect @@ -53,7 +53,7 @@ beginCompilationUnit(enum) handleNoInitializers() handleAsyncModifier(null, null) handleEmptyFunctionBody(;) - endEnumConstructor(const, (, null, ;) + endConstructor(DeclarationKind.Enum, const, (, null, ;) endMember() beginMetadataStar(const) endMetadataStar(0) @@ -69,7 +69,7 @@ beginCompilationUnit(enum) handleNoInitializers() handleAsyncModifier(null, null) handleEmptyFunctionBody(;) - endEnumConstructor(const, (, null, ;) + endConstructor(DeclarationKind.Enum, const, (, null, ;) endMember() endEnumBody({, }) endEnumDeclaration(enum, enum, {, 2, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/issue_48380_2.dart.intertwined.expect b/pkg/front_end/parser_testcases/error_recovery/issue_48380_2.dart.intertwined.expect index 97d001e9cd6..883f17eacf2 100644 --- a/pkg/front_end/parser_testcases/error_recovery/issue_48380_2.dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/error_recovery/issue_48380_2.dart.intertwined.expect @@ -81,7 +81,7 @@ parseUnit(enum) inPlainSync() parseFunctionBody(), false, true) listener: handleEmptyFunctionBody(;) - listener: endEnumConstructor(const, (, null, ;) + listener: endConstructor(DeclarationKind.Enum, const, (, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, const) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Enum, E) @@ -114,7 +114,7 @@ parseUnit(enum) inPlainSync() parseFunctionBody(), false, true) listener: handleEmptyFunctionBody(;) - listener: endEnumConstructor(const, (, null, ;) + listener: endConstructor(DeclarationKind.Enum, const, (, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endEnumBody({, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/issue_48380_2_comma.dart.expect b/pkg/front_end/parser_testcases/error_recovery/issue_48380_2_comma.dart.expect index 814fc9f13ba..9704986e5c6 100644 --- a/pkg/front_end/parser_testcases/error_recovery/issue_48380_2_comma.dart.expect +++ b/pkg/front_end/parser_testcases/error_recovery/issue_48380_2_comma.dart.expect @@ -68,7 +68,7 @@ beginCompilationUnit(enum) handleNoInitializers() handleAsyncModifier(null, null) handleEmptyFunctionBody(;) - endEnumConstructor(const, (, null, ;) + endConstructor(DeclarationKind.Enum, const, (, null, ;) endMember() beginMetadataStar(const) endMetadataStar(0) @@ -84,7 +84,7 @@ beginCompilationUnit(enum) handleNoInitializers() handleAsyncModifier(null, null) handleEmptyFunctionBody(;) - endEnumConstructor(const, (, null, ;) + endConstructor(DeclarationKind.Enum, const, (, null, ;) endMember() endEnumBody({, }) endEnumDeclaration(enum, enum, {, 2, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/issue_48380_2_comma.dart.intertwined.expect b/pkg/front_end/parser_testcases/error_recovery/issue_48380_2_comma.dart.intertwined.expect index c198bf58bbf..6aa12ed1a2e 100644 --- a/pkg/front_end/parser_testcases/error_recovery/issue_48380_2_comma.dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/error_recovery/issue_48380_2_comma.dart.intertwined.expect @@ -102,7 +102,7 @@ parseUnit(enum) inPlainSync() parseFunctionBody(), false, true) listener: handleEmptyFunctionBody(;) - listener: endEnumConstructor(const, (, null, ;) + listener: endConstructor(DeclarationKind.Enum, const, (, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, const) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Enum, E) @@ -135,7 +135,7 @@ parseUnit(enum) inPlainSync() parseFunctionBody(), false, true) listener: handleEmptyFunctionBody(;) - listener: endEnumConstructor(const, (, null, ;) + listener: endConstructor(DeclarationKind.Enum, const, (, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endEnumBody({, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/issue_48380_2_comma_ok.dart.expect b/pkg/front_end/parser_testcases/error_recovery/issue_48380_2_comma_ok.dart.expect index c4deb974621..e3bc3ada16e 100644 --- a/pkg/front_end/parser_testcases/error_recovery/issue_48380_2_comma_ok.dart.expect +++ b/pkg/front_end/parser_testcases/error_recovery/issue_48380_2_comma_ok.dart.expect @@ -61,7 +61,7 @@ beginCompilationUnit(enum) handleNoInitializers() handleAsyncModifier(null, null) handleEmptyFunctionBody(;) - endEnumConstructor(const, (, null, ;) + endConstructor(DeclarationKind.Enum, const, (, null, ;) endMember() beginMetadataStar(const) endMetadataStar(0) @@ -77,7 +77,7 @@ beginCompilationUnit(enum) handleNoInitializers() handleAsyncModifier(null, null) handleEmptyFunctionBody(;) - endEnumConstructor(const, (, null, ;) + endConstructor(DeclarationKind.Enum, const, (, null, ;) endMember() endEnumBody({, }) endEnumDeclaration(enum, enum, {, 2, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/issue_48380_2_comma_ok.dart.intertwined.expect b/pkg/front_end/parser_testcases/error_recovery/issue_48380_2_comma_ok.dart.intertwined.expect index 7a22c00506a..a0e7140811a 100644 --- a/pkg/front_end/parser_testcases/error_recovery/issue_48380_2_comma_ok.dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/error_recovery/issue_48380_2_comma_ok.dart.intertwined.expect @@ -99,7 +99,7 @@ parseUnit(enum) inPlainSync() parseFunctionBody(), false, true) listener: handleEmptyFunctionBody(;) - listener: endEnumConstructor(const, (, null, ;) + listener: endConstructor(DeclarationKind.Enum, const, (, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, const) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Enum, E) @@ -132,7 +132,7 @@ parseUnit(enum) inPlainSync() parseFunctionBody(), false, true) listener: handleEmptyFunctionBody(;) - listener: endEnumConstructor(const, (, null, ;) + listener: endConstructor(DeclarationKind.Enum, const, (, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endEnumBody({, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/issue_48380_2_ok.dart.expect b/pkg/front_end/parser_testcases/error_recovery/issue_48380_2_ok.dart.expect index 15c897bbb41..e90967201fd 100644 --- a/pkg/front_end/parser_testcases/error_recovery/issue_48380_2_ok.dart.expect +++ b/pkg/front_end/parser_testcases/error_recovery/issue_48380_2_ok.dart.expect @@ -46,7 +46,7 @@ beginCompilationUnit(enum) handleNoInitializers() handleAsyncModifier(null, null) handleEmptyFunctionBody(;) - endEnumConstructor(const, (, null, ;) + endConstructor(DeclarationKind.Enum, const, (, null, ;) endMember() beginMetadataStar(const) endMetadataStar(0) @@ -62,7 +62,7 @@ beginCompilationUnit(enum) handleNoInitializers() handleAsyncModifier(null, null) handleEmptyFunctionBody(;) - endEnumConstructor(const, (, null, ;) + endConstructor(DeclarationKind.Enum, const, (, null, ;) endMember() endEnumBody({, }) endEnumDeclaration(enum, enum, {, 2, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/issue_48380_2_ok.dart.intertwined.expect b/pkg/front_end/parser_testcases/error_recovery/issue_48380_2_ok.dart.intertwined.expect index 8e7fd12501f..dd4f11b4558 100644 --- a/pkg/front_end/parser_testcases/error_recovery/issue_48380_2_ok.dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/error_recovery/issue_48380_2_ok.dart.intertwined.expect @@ -78,7 +78,7 @@ parseUnit(enum) inPlainSync() parseFunctionBody(), false, true) listener: handleEmptyFunctionBody(;) - listener: endEnumConstructor(const, (, null, ;) + listener: endConstructor(DeclarationKind.Enum, const, (, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, const) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Enum, E) @@ -111,7 +111,7 @@ parseUnit(enum) inPlainSync() parseFunctionBody(), false, true) listener: handleEmptyFunctionBody(;) - listener: endEnumConstructor(const, (, null, ;) + listener: endConstructor(DeclarationKind.Enum, const, (, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endEnumBody({, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/issue_48380_3.dart.expect b/pkg/front_end/parser_testcases/error_recovery/issue_48380_3.dart.expect index d719b5e2676..b63245f42e2 100644 --- a/pkg/front_end/parser_testcases/error_recovery/issue_48380_3.dart.expect +++ b/pkg/front_end/parser_testcases/error_recovery/issue_48380_3.dart.expect @@ -46,7 +46,7 @@ beginCompilationUnit(enum) handleNoInitializers() handleAsyncModifier(null, null) handleEmptyFunctionBody(;) - endEnumConstructor(const, (, null, ;) + endConstructor(DeclarationKind.Enum, const, (, null, ;) endMember() beginMetadataStar(const) endMetadataStar(0) @@ -62,7 +62,7 @@ beginCompilationUnit(enum) handleNoInitializers() handleAsyncModifier(null, null) handleEmptyFunctionBody(;) - endEnumConstructor(const, (, null, ;) + endConstructor(DeclarationKind.Enum, const, (, null, ;) endMember() endEnumBody({, }) endEnumDeclaration(enum, enum, {, 2, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/issue_48380_3.dart.intertwined.expect b/pkg/front_end/parser_testcases/error_recovery/issue_48380_3.dart.intertwined.expect index 36d64453ebe..a2d5cb8718a 100644 --- a/pkg/front_end/parser_testcases/error_recovery/issue_48380_3.dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/error_recovery/issue_48380_3.dart.intertwined.expect @@ -74,7 +74,7 @@ parseUnit(enum) inPlainSync() parseFunctionBody(), false, true) listener: handleEmptyFunctionBody(;) - listener: endEnumConstructor(const, (, null, ;) + listener: endConstructor(DeclarationKind.Enum, const, (, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, const) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Enum, E) @@ -107,7 +107,7 @@ parseUnit(enum) inPlainSync() parseFunctionBody(), false, true) listener: handleEmptyFunctionBody(;) - listener: endEnumConstructor(const, (, null, ;) + listener: endConstructor(DeclarationKind.Enum, const, (, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endEnumBody({, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/issue_48380_3_comma.dart.expect b/pkg/front_end/parser_testcases/error_recovery/issue_48380_3_comma.dart.expect index 7d6a84972ec..a4ecf8e95ae 100644 --- a/pkg/front_end/parser_testcases/error_recovery/issue_48380_3_comma.dart.expect +++ b/pkg/front_end/parser_testcases/error_recovery/issue_48380_3_comma.dart.expect @@ -57,7 +57,7 @@ beginCompilationUnit(enum) handleNoInitializers() handleAsyncModifier(null, null) handleEmptyFunctionBody(;) - endEnumConstructor(const, (, null, ;) + endConstructor(DeclarationKind.Enum, const, (, null, ;) endMember() beginMetadataStar(const) endMetadataStar(0) @@ -73,7 +73,7 @@ beginCompilationUnit(enum) handleNoInitializers() handleAsyncModifier(null, null) handleEmptyFunctionBody(;) - endEnumConstructor(const, (, null, ;) + endConstructor(DeclarationKind.Enum, const, (, null, ;) endMember() endEnumBody({, }) endEnumDeclaration(enum, enum, {, 2, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/issue_48380_3_comma.dart.intertwined.expect b/pkg/front_end/parser_testcases/error_recovery/issue_48380_3_comma.dart.intertwined.expect index a0a29564b45..665bbc535c2 100644 --- a/pkg/front_end/parser_testcases/error_recovery/issue_48380_3_comma.dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/error_recovery/issue_48380_3_comma.dart.intertwined.expect @@ -91,7 +91,7 @@ parseUnit(enum) inPlainSync() parseFunctionBody(), false, true) listener: handleEmptyFunctionBody(;) - listener: endEnumConstructor(const, (, null, ;) + listener: endConstructor(DeclarationKind.Enum, const, (, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, const) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Enum, E) @@ -124,7 +124,7 @@ parseUnit(enum) inPlainSync() parseFunctionBody(), false, true) listener: handleEmptyFunctionBody(;) - listener: endEnumConstructor(const, (, null, ;) + listener: endConstructor(DeclarationKind.Enum, const, (, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endEnumBody({, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/issue_48380_3_comma_ok.dart.expect b/pkg/front_end/parser_testcases/error_recovery/issue_48380_3_comma_ok.dart.expect index 5dd7024cc92..6279f79cb59 100644 --- a/pkg/front_end/parser_testcases/error_recovery/issue_48380_3_comma_ok.dart.expect +++ b/pkg/front_end/parser_testcases/error_recovery/issue_48380_3_comma_ok.dart.expect @@ -45,7 +45,7 @@ beginCompilationUnit(enum) handleNoInitializers() handleAsyncModifier(null, null) handleEmptyFunctionBody(;) - endEnumConstructor(const, (, null, ;) + endConstructor(DeclarationKind.Enum, const, (, null, ;) endMember() beginMetadataStar(const) endMetadataStar(0) @@ -61,7 +61,7 @@ beginCompilationUnit(enum) handleNoInitializers() handleAsyncModifier(null, null) handleEmptyFunctionBody(;) - endEnumConstructor(const, (, null, ;) + endConstructor(DeclarationKind.Enum, const, (, null, ;) endMember() endEnumBody({, }) endEnumDeclaration(enum, enum, {, 2, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/issue_48380_3_comma_ok.dart.intertwined.expect b/pkg/front_end/parser_testcases/error_recovery/issue_48380_3_comma_ok.dart.intertwined.expect index 444473fd297..6fe0eaa399f 100644 --- a/pkg/front_end/parser_testcases/error_recovery/issue_48380_3_comma_ok.dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/error_recovery/issue_48380_3_comma_ok.dart.intertwined.expect @@ -84,7 +84,7 @@ parseUnit(enum) inPlainSync() parseFunctionBody(), false, true) listener: handleEmptyFunctionBody(;) - listener: endEnumConstructor(const, (, null, ;) + listener: endConstructor(DeclarationKind.Enum, const, (, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, const) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Enum, E) @@ -117,7 +117,7 @@ parseUnit(enum) inPlainSync() parseFunctionBody(), false, true) listener: handleEmptyFunctionBody(;) - listener: endEnumConstructor(const, (, null, ;) + listener: endConstructor(DeclarationKind.Enum, const, (, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endEnumBody({, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/issue_48380_3_ok.dart.expect b/pkg/front_end/parser_testcases/error_recovery/issue_48380_3_ok.dart.expect index 10b32fdcfc4..83f6273f096 100644 --- a/pkg/front_end/parser_testcases/error_recovery/issue_48380_3_ok.dart.expect +++ b/pkg/front_end/parser_testcases/error_recovery/issue_48380_3_ok.dart.expect @@ -34,7 +34,7 @@ beginCompilationUnit(enum) handleNoInitializers() handleAsyncModifier(null, null) handleEmptyFunctionBody(;) - endEnumConstructor(const, (, null, ;) + endConstructor(DeclarationKind.Enum, const, (, null, ;) endMember() beginMetadataStar(const) endMetadataStar(0) @@ -50,7 +50,7 @@ beginCompilationUnit(enum) handleNoInitializers() handleAsyncModifier(null, null) handleEmptyFunctionBody(;) - endEnumConstructor(const, (, null, ;) + endConstructor(DeclarationKind.Enum, const, (, null, ;) endMember() endEnumBody({, }) endEnumDeclaration(enum, enum, {, 2, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/issue_48380_3_ok.dart.intertwined.expect b/pkg/front_end/parser_testcases/error_recovery/issue_48380_3_ok.dart.intertwined.expect index 3e860b06afb..26e38944c68 100644 --- a/pkg/front_end/parser_testcases/error_recovery/issue_48380_3_ok.dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/error_recovery/issue_48380_3_ok.dart.intertwined.expect @@ -67,7 +67,7 @@ parseUnit(enum) inPlainSync() parseFunctionBody(), false, true) listener: handleEmptyFunctionBody(;) - listener: endEnumConstructor(const, (, null, ;) + listener: endConstructor(DeclarationKind.Enum, const, (, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, const) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Enum, E) @@ -100,7 +100,7 @@ parseUnit(enum) inPlainSync() parseFunctionBody(), false, true) listener: handleEmptyFunctionBody(;) - listener: endEnumConstructor(const, (, null, ;) + listener: endConstructor(DeclarationKind.Enum, const, (, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endEnumBody({, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/issue_48380_4.dart.expect b/pkg/front_end/parser_testcases/error_recovery/issue_48380_4.dart.expect index 9437e61d8e9..50cfa788c97 100644 --- a/pkg/front_end/parser_testcases/error_recovery/issue_48380_4.dart.expect +++ b/pkg/front_end/parser_testcases/error_recovery/issue_48380_4.dart.expect @@ -48,7 +48,7 @@ beginCompilationUnit(enum) endLiteralString(0, ;) endReturnStatement(true, return, ;) endBlockFunctionBody(2, {, }) - endEnumMethod(null, String, (, null, }) + endMethod(DeclarationKind.Enum, null, String, (, null, }) endMember() endEnumBody({, }) endEnumDeclaration(enum, enum, {, 1, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/issue_48380_4.dart.intertwined.expect b/pkg/front_end/parser_testcases/error_recovery/issue_48380_4.dart.intertwined.expect index 5d2e6e99838..2398782a67d 100644 --- a/pkg/front_end/parser_testcases/error_recovery/issue_48380_4.dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/error_recovery/issue_48380_4.dart.intertwined.expect @@ -115,7 +115,7 @@ parseUnit(enum) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(2, {, }) - listener: endEnumMethod(null, String, (, null, }) + listener: endMethod(DeclarationKind.Enum, null, String, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endEnumBody({, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/issue_48411.dart.expect b/pkg/front_end/parser_testcases/error_recovery/issue_48411.dart.expect index 1f2a76d1c64..318d750efef 100644 --- a/pkg/front_end/parser_testcases/error_recovery/issue_48411.dart.expect +++ b/pkg/front_end/parser_testcases/error_recovery/issue_48411.dart.expect @@ -59,7 +59,7 @@ beginCompilationUnit(class) handleNoInitializers() handleAsyncModifier(null, null) handleEmptyFunctionBody(;) - endClassConstructor(A, (, null, ;) + endConstructor(DeclarationKind.Class, A, (, null, ;) endMember() beginMetadataStar(A) endMetadataStar(0) @@ -84,7 +84,7 @@ beginCompilationUnit(class) handleNoInitializers() handleAsyncModifier(null, null) handleEmptyFunctionBody(;) - endClassConstructor(A, (, null, ;) + endConstructor(DeclarationKind.Class, A, (, null, ;) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 2, {, }) endClassDeclaration(class, }) @@ -149,7 +149,7 @@ beginCompilationUnit(class) endInitializers(2, :, )) handleAsyncModifier(null, null) handleEmptyFunctionBody(;) - endClassConstructor(B, (, :, ;) + endConstructor(DeclarationKind.Class, B, (, :, ;) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 1, {, }) endClassDeclaration(class, }) @@ -216,7 +216,7 @@ beginCompilationUnit(class) endInitializers(2, :, )) handleAsyncModifier(null, null) handleEmptyFunctionBody(;) - endClassConstructor(B2, (, :, ;) + endConstructor(DeclarationKind.Class, B2, (, :, ;) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 1, {, }) endClassDeclaration(class, }) @@ -283,7 +283,7 @@ beginCompilationUnit(class) endInitializers(2, :, )) handleAsyncModifier(null, null) handleEmptyFunctionBody(;) - endClassConstructor(B3, (, :, ;) + endConstructor(DeclarationKind.Class, B3, (, :, ;) endMember() beginMetadataStar(B3) endMetadataStar(0) @@ -308,7 +308,7 @@ beginCompilationUnit(class) handleNoInitializers() handleAsyncModifier(null, null) handleEmptyFunctionBody(;) - endClassConstructor(B3, (, null, ;) + endConstructor(DeclarationKind.Class, B3, (, null, ;) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 2, {, }) endClassDeclaration(class, }) @@ -337,7 +337,7 @@ beginCompilationUnit(class) handleType(int, null) handleIdentifier(y, fieldDeclaration) handleNoFieldInitializer(;) - endClassFields(null, null, null, null, null, null, null, 1, int, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) endMember() beginMetadataStar(C) endMetadataStar(0) @@ -384,7 +384,7 @@ beginCompilationUnit(class) endInitializers(2, :, 21) handleAsyncModifier(null, null) handleEmptyFunctionBody(;) - endClassConstructor(C, (, :, ;) + endConstructor(DeclarationKind.Class, C, (, :, ;) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 2, {, }) endClassDeclaration(class, }) @@ -452,7 +452,7 @@ beginCompilationUnit(class) endInitializers(2, :, )) handleAsyncModifier(null, null) handleEmptyFunctionBody(;) - endClassConstructor(D, (, :, ;) + endConstructor(DeclarationKind.Class, D, (, :, ;) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 1, {, }) endClassDeclaration(class, }) @@ -481,7 +481,7 @@ beginCompilationUnit(class) handleType(int, null) handleIdentifier(y, fieldDeclaration) handleNoFieldInitializer(;) - endClassFields(null, null, null, null, null, null, final, 1, final, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) endMember() beginMetadataStar(E) endMetadataStar(0) @@ -533,7 +533,7 @@ beginCompilationUnit(class) endInitializers(2, :, 2) handleAsyncModifier(null, null) handleEmptyFunctionBody(;) - endClassConstructor(E, (, :, ;) + endConstructor(DeclarationKind.Class, E, (, :, ;) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 2, {, }) endClassDeclaration(class, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/issue_48411.dart.intertwined.expect b/pkg/front_end/parser_testcases/error_recovery/issue_48411.dart.intertwined.expect index cd50f11c7f1..50c941096a8 100644 --- a/pkg/front_end/parser_testcases/error_recovery/issue_48411.dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/error_recovery/issue_48411.dart.intertwined.expect @@ -67,7 +67,7 @@ parseUnit(class) inPlainSync() parseFunctionBody(), false, true) listener: handleEmptyFunctionBody(;) - listener: endClassConstructor(A, (, null, ;) + listener: endConstructor(DeclarationKind.Class, A, (, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, A) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, A) @@ -113,7 +113,7 @@ parseUnit(class) inPlainSync() parseFunctionBody(), false, true) listener: handleEmptyFunctionBody(;) - listener: endClassConstructor(A, (, null, ;) + listener: endConstructor(DeclarationKind.Class, A, (, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 2, {, }) @@ -244,7 +244,7 @@ parseUnit(class) inPlainSync() parseFunctionBody(), false, true) listener: handleEmptyFunctionBody(;) - listener: endClassConstructor(B, (, :, ;) + listener: endConstructor(DeclarationKind.Class, B, (, :, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 1, {, }) @@ -382,7 +382,7 @@ parseUnit(class) inPlainSync() parseFunctionBody(), false, true) listener: handleEmptyFunctionBody(;) - listener: endClassConstructor(B2, (, :, ;) + listener: endConstructor(DeclarationKind.Class, B2, (, :, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 1, {, }) @@ -519,7 +519,7 @@ parseUnit(class) inPlainSync() parseFunctionBody(), false, true) listener: handleEmptyFunctionBody(;) - listener: endClassConstructor(B3, (, :, ;) + listener: endConstructor(DeclarationKind.Class, B3, (, :, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, B3) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, B3) @@ -565,7 +565,7 @@ parseUnit(class) inPlainSync() parseFunctionBody(), false, true) listener: handleEmptyFunctionBody(;) - listener: endClassConstructor(B3, (, null, ;) + listener: endConstructor(DeclarationKind.Class, B3, (, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 2, {, }) @@ -614,7 +614,7 @@ parseUnit(class) listener: handleIdentifier(y, fieldDeclaration) parseFieldInitializerOpt(y, y, null, null, null, null, null, DeclarationKind.Class, C) listener: handleNoFieldInitializer(;) - listener: endClassFields(null, null, null, null, null, null, null, 1, int, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, C) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, C) @@ -721,7 +721,7 @@ parseUnit(class) inPlainSync() parseFunctionBody(21, false, true) listener: handleEmptyFunctionBody(;) - listener: endClassConstructor(C, (, :, ;) + listener: endConstructor(DeclarationKind.Class, C, (, :, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 2, {, }) @@ -863,7 +863,7 @@ parseUnit(class) inPlainSync() parseFunctionBody(), false, true) listener: handleEmptyFunctionBody(;) - listener: endClassConstructor(D, (, :, ;) + listener: endConstructor(DeclarationKind.Class, D, (, :, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 1, {, }) @@ -914,7 +914,7 @@ parseUnit(class) listener: handleIdentifier(y, fieldDeclaration) parseFieldInitializerOpt(y, y, null, null, null, null, final, DeclarationKind.Class, E) listener: handleNoFieldInitializer(;) - listener: endClassFields(null, null, null, null, null, null, final, 1, final, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, E) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, E) @@ -1030,7 +1030,7 @@ parseUnit(class) inPlainSync() parseFunctionBody(2, false, true) listener: handleEmptyFunctionBody(;) - listener: endClassConstructor(E, (, :, ;) + listener: endConstructor(DeclarationKind.Class, E, (, :, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 2, {, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/issue_48411_prime.dart.expect b/pkg/front_end/parser_testcases/error_recovery/issue_48411_prime.dart.expect index d797c999bd9..691213d88b3 100644 --- a/pkg/front_end/parser_testcases/error_recovery/issue_48411_prime.dart.expect +++ b/pkg/front_end/parser_testcases/error_recovery/issue_48411_prime.dart.expect @@ -33,7 +33,7 @@ beginCompilationUnit(class) handleNoInitializers() handleAsyncModifier(null, null) handleEmptyFunctionBody(;) - endClassConstructor(A, (, null, ;) + endConstructor(DeclarationKind.Class, A, (, null, ;) endMember() beginMetadataStar(A) endMetadataStar(0) @@ -58,7 +58,7 @@ beginCompilationUnit(class) handleNoInitializers() handleAsyncModifier(null, null) handleEmptyFunctionBody(;) - endClassConstructor(A, (, null, ;) + endConstructor(DeclarationKind.Class, A, (, null, ;) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 2, {, }) endClassDeclaration(class, }) @@ -122,7 +122,7 @@ beginCompilationUnit(class) endInitializers(2, :, )) handleAsyncModifier(null, null) handleEmptyFunctionBody(;) - endClassConstructor(B, (, :, ;) + endConstructor(DeclarationKind.Class, B, (, :, ;) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 1, {, }) endClassDeclaration(class, }) @@ -188,7 +188,7 @@ beginCompilationUnit(class) endInitializers(2, :, )) handleAsyncModifier(null, null) handleEmptyFunctionBody(;) - endClassConstructor(B2, (, :, ;) + endConstructor(DeclarationKind.Class, B2, (, :, ;) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 1, {, }) endClassDeclaration(class, }) @@ -254,7 +254,7 @@ beginCompilationUnit(class) endInitializers(2, :, )) handleAsyncModifier(null, null) handleEmptyFunctionBody(;) - endClassConstructor(B3, (, :, ;) + endConstructor(DeclarationKind.Class, B3, (, :, ;) endMember() beginMetadataStar(B3) endMetadataStar(0) @@ -279,7 +279,7 @@ beginCompilationUnit(class) handleNoInitializers() handleAsyncModifier(null, null) handleEmptyFunctionBody(;) - endClassConstructor(B3, (, null, ;) + endConstructor(DeclarationKind.Class, B3, (, null, ;) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 2, {, }) endClassDeclaration(class, }) @@ -308,7 +308,7 @@ beginCompilationUnit(class) handleType(int, null) handleIdentifier(y, fieldDeclaration) handleNoFieldInitializer(;) - endClassFields(null, null, null, null, null, null, null, 1, int, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) endMember() beginMetadataStar(C) endMetadataStar(0) @@ -354,7 +354,7 @@ beginCompilationUnit(class) endInitializers(2, :, 21) handleAsyncModifier(null, null) handleEmptyFunctionBody(;) - endClassConstructor(C, (, :, ;) + endConstructor(DeclarationKind.Class, C, (, :, ;) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 2, {, }) endClassDeclaration(class, }) @@ -421,7 +421,7 @@ beginCompilationUnit(class) endInitializers(2, :, )) handleAsyncModifier(null, null) handleEmptyFunctionBody(;) - endClassConstructor(D, (, :, ;) + endConstructor(DeclarationKind.Class, D, (, :, ;) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 1, {, }) endClassDeclaration(class, }) @@ -450,7 +450,7 @@ beginCompilationUnit(class) handleType(int, null) handleIdentifier(y, fieldDeclaration) handleNoFieldInitializer(;) - endClassFields(null, null, null, null, null, null, final, 1, final, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) endMember() beginMetadataStar(E) endMetadataStar(0) @@ -501,7 +501,7 @@ beginCompilationUnit(class) endInitializers(2, :, 2) handleAsyncModifier(null, null) handleEmptyFunctionBody(;) - endClassConstructor(E, (, :, ;) + endConstructor(DeclarationKind.Class, E, (, :, ;) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 2, {, }) endClassDeclaration(class, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/issue_48411_prime.dart.intertwined.expect b/pkg/front_end/parser_testcases/error_recovery/issue_48411_prime.dart.intertwined.expect index 91212b53ebd..1e24cd9cef4 100644 --- a/pkg/front_end/parser_testcases/error_recovery/issue_48411_prime.dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/error_recovery/issue_48411_prime.dart.intertwined.expect @@ -67,7 +67,7 @@ parseUnit(class) inPlainSync() parseFunctionBody(), false, true) listener: handleEmptyFunctionBody(;) - listener: endClassConstructor(A, (, null, ;) + listener: endConstructor(DeclarationKind.Class, A, (, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, A) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, A) @@ -113,7 +113,7 @@ parseUnit(class) inPlainSync() parseFunctionBody(), false, true) listener: handleEmptyFunctionBody(;) - listener: endClassConstructor(A, (, null, ;) + listener: endConstructor(DeclarationKind.Class, A, (, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 2, {, }) @@ -241,7 +241,7 @@ parseUnit(class) inPlainSync() parseFunctionBody(), false, true) listener: handleEmptyFunctionBody(;) - listener: endClassConstructor(B, (, :, ;) + listener: endConstructor(DeclarationKind.Class, B, (, :, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 1, {, }) @@ -376,7 +376,7 @@ parseUnit(class) inPlainSync() parseFunctionBody(), false, true) listener: handleEmptyFunctionBody(;) - listener: endClassConstructor(B2, (, :, ;) + listener: endConstructor(DeclarationKind.Class, B2, (, :, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 1, {, }) @@ -510,7 +510,7 @@ parseUnit(class) inPlainSync() parseFunctionBody(), false, true) listener: handleEmptyFunctionBody(;) - listener: endClassConstructor(B3, (, :, ;) + listener: endConstructor(DeclarationKind.Class, B3, (, :, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, B3) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, B3) @@ -556,7 +556,7 @@ parseUnit(class) inPlainSync() parseFunctionBody(), false, true) listener: handleEmptyFunctionBody(;) - listener: endClassConstructor(B3, (, null, ;) + listener: endConstructor(DeclarationKind.Class, B3, (, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 2, {, }) @@ -605,7 +605,7 @@ parseUnit(class) listener: handleIdentifier(y, fieldDeclaration) parseFieldInitializerOpt(y, y, null, null, null, null, null, DeclarationKind.Class, C) listener: handleNoFieldInitializer(;) - listener: endClassFields(null, null, null, null, null, null, null, 1, int, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, C) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, C) @@ -709,7 +709,7 @@ parseUnit(class) inPlainSync() parseFunctionBody(21, false, true) listener: handleEmptyFunctionBody(;) - listener: endClassConstructor(C, (, :, ;) + listener: endConstructor(DeclarationKind.Class, C, (, :, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 2, {, }) @@ -848,7 +848,7 @@ parseUnit(class) inPlainSync() parseFunctionBody(), false, true) listener: handleEmptyFunctionBody(;) - listener: endClassConstructor(D, (, :, ;) + listener: endConstructor(DeclarationKind.Class, D, (, :, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 1, {, }) @@ -899,7 +899,7 @@ parseUnit(class) listener: handleIdentifier(y, fieldDeclaration) parseFieldInitializerOpt(y, y, null, null, null, null, final, DeclarationKind.Class, E) listener: handleNoFieldInitializer(;) - listener: endClassFields(null, null, null, null, null, null, final, 1, final, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, E) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, E) @@ -1012,7 +1012,7 @@ parseUnit(class) inPlainSync() parseFunctionBody(2, false, true) listener: handleEmptyFunctionBody(;) - listener: endClassConstructor(E, (, :, ;) + listener: endConstructor(DeclarationKind.Class, E, (, :, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 2, {, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/issue_48411_prime_1.dart.expect b/pkg/front_end/parser_testcases/error_recovery/issue_48411_prime_1.dart.expect index 4ba1c392c72..dd19b20320f 100644 --- a/pkg/front_end/parser_testcases/error_recovery/issue_48411_prime_1.dart.expect +++ b/pkg/front_end/parser_testcases/error_recovery/issue_48411_prime_1.dart.expect @@ -113,7 +113,7 @@ beginCompilationUnit(class) endConstructorReference(, null, , ConstructorReferenceContext.RedirectingFactory) handleRecoverableError(Message[Template(ExpectedAfterButGot), Expected ';' after this., null, {string: ;}], =, =) endRedirectingFactoryBody(=, ;) - endClassConstructor(C, (, :, ;) + endConstructor(DeclarationKind.Class, C, (, :, ;) endMember() beginMetadataStar(0) endMetadataStar(0) @@ -169,7 +169,7 @@ beginCompilationUnit(class) handleAsyncModifier(null, null) handleRecoverableError(Message[Template(ExpectedFunctionBody), Expected a function body, but got 'null'., null, {lexeme: null}], null, null) handleInvalidFunctionBody({) - endClassConstructor(C, (, :, }) + endConstructor(DeclarationKind.Class, C, (, :, }) endMember() beginMetadataStar(null) endMetadataStar(0) @@ -193,7 +193,7 @@ beginCompilationUnit(class) handleAsyncModifier(null, null) handleRecoverableError(Message[Template(ExpectedFunctionBody), Expected a function body, but got '0'., null, {lexeme: 0}], 0, 0) handleInvalidFunctionBody({) - endClassMethod(null, operator, (, null, }) + endMethod(DeclarationKind.Class, null, operator, (, null, }) endMember() beginMetadataStar(0) endMetadataStar(0) @@ -241,7 +241,7 @@ beginCompilationUnit(class) endInitializers(1, :, 0) handleAsyncModifier(null, null) handleEmptyFunctionBody(;) - endClassConstructor(C, (, :, ;) + endConstructor(DeclarationKind.Class, C, (, :, ;) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 1, {, }) endClassDeclaration(class, }) @@ -289,7 +289,7 @@ beginCompilationUnit(class) endInitializers(1, :, 0) handleAsyncModifier(null, null) handleEmptyFunctionBody(;) - endClassConstructor(C, (, :, ;) + endConstructor(DeclarationKind.Class, C, (, :, ;) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 1, {, }) endClassDeclaration(class, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/issue_48411_prime_1.dart.intertwined.expect b/pkg/front_end/parser_testcases/error_recovery/issue_48411_prime_1.dart.intertwined.expect index 1b7f43bf82d..5f44148c878 100644 --- a/pkg/front_end/parser_testcases/error_recovery/issue_48411_prime_1.dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/error_recovery/issue_48411_prime_1.dart.intertwined.expect @@ -99,7 +99,7 @@ parseUnit(class) listener: handleRecoverableError(Message[Template(ExpectedAfterButGot), Expected ';' after this., null, {string: ;}], =, =) rewriter() listener: endRedirectingFactoryBody(=, ;) - listener: endClassConstructor(C, (, :, ;) + listener: endConstructor(DeclarationKind.Class, C, (, :, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, 0) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, C) @@ -225,7 +225,7 @@ parseUnit(class) rewriter() rewriter() listener: handleInvalidFunctionBody({) - listener: endClassConstructor(C, (, :, }) + listener: endConstructor(DeclarationKind.Class, C, (, :, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, null) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, C) @@ -281,7 +281,7 @@ parseUnit(class) rewriter() rewriter() listener: handleInvalidFunctionBody({) - listener: endClassMethod(null, operator, (, null, }) + listener: endMethod(DeclarationKind.Class, null, operator, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, 0) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, C) @@ -383,7 +383,7 @@ parseUnit(class) inPlainSync() parseFunctionBody(0, false, true) listener: handleEmptyFunctionBody(;) - listener: endClassConstructor(C, (, :, ;) + listener: endConstructor(DeclarationKind.Class, C, (, :, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 1, {, }) @@ -494,7 +494,7 @@ parseUnit(class) inPlainSync() parseFunctionBody(0, false, true) listener: handleEmptyFunctionBody(;) - listener: endClassConstructor(C, (, :, ;) + listener: endConstructor(DeclarationKind.Class, C, (, :, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 1, {, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/issue_54284.dart.expect b/pkg/front_end/parser_testcases/error_recovery/issue_54284.dart.expect index 1308f1238ac..ff38df76c44 100644 --- a/pkg/front_end/parser_testcases/error_recovery/issue_54284.dart.expect +++ b/pkg/front_end/parser_testcases/error_recovery/issue_54284.dart.expect @@ -81,7 +81,7 @@ beginCompilationUnit(var) handleNoType(var) handleIdentifier(x, fieldDeclaration) handleNoFieldInitializer(;) - endClassFields(null, null, null, null, null, null, var, 1, var, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, var, 1, var, ;) endMember() beginMetadataStar(A) endMetadataStar(0) @@ -110,7 +110,7 @@ beginCompilationUnit(var) endInitializers(1, :, isEven) handleAsyncModifier(null, null) handleEmptyFunctionBody(;) - endClassConstructor(A, (, :, ;) + endConstructor(DeclarationKind.Class, A, (, :, ;) endMember() beginMetadataStar(A) endMetadataStar(0) @@ -141,7 +141,7 @@ beginCompilationUnit(var) endInitializers(1, :, isEven) handleAsyncModifier(null, null) handleEmptyFunctionBody(;) - endClassConstructor(A, (, :, ;) + endConstructor(DeclarationKind.Class, A, (, :, ;) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 3, {, }) endClassDeclaration(class, }) @@ -166,7 +166,7 @@ beginCompilationUnit(var) handleNoType(var) handleIdentifier(x, fieldDeclaration) handleNoFieldInitializer(;) - endClassFields(null, null, null, null, null, null, var, 1, var, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, var, 1, var, ;) endMember() beginMetadataStar(A) endMetadataStar(0) @@ -199,7 +199,7 @@ beginCompilationUnit(var) endInitializers(1, :, )) handleAsyncModifier(null, null) handleEmptyFunctionBody(;) - endClassConstructor(A, (, :, ;) + endConstructor(DeclarationKind.Class, A, (, :, ;) endMember() beginMetadataStar(A) endMetadataStar(0) @@ -234,7 +234,7 @@ beginCompilationUnit(var) endInitializers(1, :, )) handleAsyncModifier(null, null) handleEmptyFunctionBody(;) - endClassConstructor(A, (, :, ;) + endConstructor(DeclarationKind.Class, A, (, :, ;) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 3, {, }) endClassDeclaration(class, }) @@ -259,7 +259,7 @@ beginCompilationUnit(var) handleNoType(var) handleIdentifier(x, fieldDeclaration) handleNoFieldInitializer(;) - endClassFields(null, null, null, null, null, null, var, 1, var, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, var, 1, var, ;) endMember() beginMetadataStar(A) endMetadataStar(0) @@ -290,7 +290,7 @@ beginCompilationUnit(var) endInitializers(1, :, isEven) handleAsyncModifier(null, null) handleEmptyFunctionBody(;) - endClassConstructor(A, (, :, ;) + endConstructor(DeclarationKind.Class, A, (, :, ;) endMember() beginMetadataStar(A) endMetadataStar(0) @@ -323,7 +323,7 @@ beginCompilationUnit(var) endInitializers(1, :, isEven) handleAsyncModifier(null, null) handleEmptyFunctionBody(;) - endClassConstructor(A, (, :, ;) + endConstructor(DeclarationKind.Class, A, (, :, ;) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 3, {, }) endClassDeclaration(class, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/issue_54284.dart.intertwined.expect b/pkg/front_end/parser_testcases/error_recovery/issue_54284.dart.intertwined.expect index 48e577944f2..e7297bde72a 100644 --- a/pkg/front_end/parser_testcases/error_recovery/issue_54284.dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/error_recovery/issue_54284.dart.intertwined.expect @@ -199,7 +199,7 @@ parseUnit(var) listener: handleIdentifier(x, fieldDeclaration) parseFieldInitializerOpt(x, x, null, null, null, null, var, DeclarationKind.Class, A) listener: handleNoFieldInitializer(;) - listener: endClassFields(null, null, null, null, null, null, var, 1, var, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, var, 1, var, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, A) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, A) @@ -271,7 +271,7 @@ parseUnit(var) inPlainSync() parseFunctionBody(isEven, false, true) listener: handleEmptyFunctionBody(;) - listener: endClassConstructor(A, (, :, ;) + listener: endConstructor(DeclarationKind.Class, A, (, :, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, A) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, A) @@ -346,7 +346,7 @@ parseUnit(var) inPlainSync() parseFunctionBody(isEven, false, true) listener: handleEmptyFunctionBody(;) - listener: endClassConstructor(A, (, :, ;) + listener: endConstructor(DeclarationKind.Class, A, (, :, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 3, {, }) @@ -392,7 +392,7 @@ parseUnit(var) listener: handleIdentifier(x, fieldDeclaration) parseFieldInitializerOpt(x, x, null, null, null, null, var, DeclarationKind.Class, A) listener: handleNoFieldInitializer(;) - listener: endClassFields(null, null, null, null, null, null, var, 1, var, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, var, 1, var, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, A) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, A) @@ -477,7 +477,7 @@ parseUnit(var) inPlainSync() parseFunctionBody(), false, true) listener: handleEmptyFunctionBody(;) - listener: endClassConstructor(A, (, :, ;) + listener: endConstructor(DeclarationKind.Class, A, (, :, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, A) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, A) @@ -565,7 +565,7 @@ parseUnit(var) inPlainSync() parseFunctionBody(), false, true) listener: handleEmptyFunctionBody(;) - listener: endClassConstructor(A, (, :, ;) + listener: endConstructor(DeclarationKind.Class, A, (, :, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 3, {, }) @@ -611,7 +611,7 @@ parseUnit(var) listener: handleIdentifier(x, fieldDeclaration) parseFieldInitializerOpt(x, x, null, null, null, null, var, DeclarationKind.Class, A) listener: handleNoFieldInitializer(;) - listener: endClassFields(null, null, null, null, null, null, var, 1, var, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, var, 1, var, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, A) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, A) @@ -685,7 +685,7 @@ parseUnit(var) inPlainSync() parseFunctionBody(isEven, false, true) listener: handleEmptyFunctionBody(;) - listener: endClassConstructor(A, (, :, ;) + listener: endConstructor(DeclarationKind.Class, A, (, :, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, A) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, A) @@ -762,7 +762,7 @@ parseUnit(var) inPlainSync() parseFunctionBody(isEven, false, true) listener: handleEmptyFunctionBody(;) - listener: endClassConstructor(A, (, :, ;) + listener: endConstructor(DeclarationKind.Class, A, (, :, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 3, {, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/keyword_named_class_fields.dart.expect b/pkg/front_end/parser_testcases/error_recovery/keyword_named_class_fields.dart.expect index 89126bfb237..6f63b3dab20 100644 --- a/pkg/front_end/parser_testcases/error_recovery/keyword_named_class_fields.dart.expect +++ b/pkg/front_end/parser_testcases/error_recovery/keyword_named_class_fields.dart.expect @@ -157,7 +157,7 @@ beginCompilationUnit(class) beginFieldInitializer(=) handleLiteralInt(42) endFieldInitializer(=, 42) - endClassFields(null, null, null, null, null, null, null, 1, int, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -170,7 +170,7 @@ beginCompilationUnit(class) beginFieldInitializer(=) handleLiteralInt(42) endFieldInitializer(=, 42) - endClassFields(null, null, null, null, null, null, null, 1, int, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -184,7 +184,7 @@ beginCompilationUnit(class) beginFieldInitializer(=) handleLiteralInt(42) endFieldInitializer(=, 42) - endClassFields(null, null, null, null, null, null, null, 1, int, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -197,7 +197,7 @@ beginCompilationUnit(class) beginFieldInitializer(=) handleLiteralInt(42) endFieldInitializer(=, 42) - endClassFields(null, null, null, null, null, null, null, 1, int, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -210,7 +210,7 @@ beginCompilationUnit(class) beginFieldInitializer(=) handleLiteralInt(42) endFieldInitializer(=, 42) - endClassFields(null, null, null, null, null, null, null, 1, int, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -224,7 +224,7 @@ beginCompilationUnit(class) beginFieldInitializer(=) handleLiteralInt(42) endFieldInitializer(=, 42) - endClassFields(null, null, null, null, null, null, null, 1, int, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -238,7 +238,7 @@ beginCompilationUnit(class) beginFieldInitializer(=) handleLiteralInt(42) endFieldInitializer(=, 42) - endClassFields(null, null, null, null, null, null, null, 1, int, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -252,7 +252,7 @@ beginCompilationUnit(class) beginFieldInitializer(=) handleLiteralInt(42) endFieldInitializer(=, 42) - endClassFields(null, null, null, null, null, null, null, 1, int, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -266,7 +266,7 @@ beginCompilationUnit(class) beginFieldInitializer(=) handleLiteralInt(42) endFieldInitializer(=, 42) - endClassFields(null, null, null, null, null, null, null, 1, int, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -280,7 +280,7 @@ beginCompilationUnit(class) beginFieldInitializer(=) handleLiteralInt(42) endFieldInitializer(=, 42) - endClassFields(null, null, null, null, null, null, null, 1, int, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -294,7 +294,7 @@ beginCompilationUnit(class) beginFieldInitializer(=) handleLiteralInt(42) endFieldInitializer(=, 42) - endClassFields(null, null, null, null, null, null, null, 1, int, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -307,7 +307,7 @@ beginCompilationUnit(class) beginFieldInitializer(=) handleLiteralInt(42) endFieldInitializer(=, 42) - endClassFields(null, null, null, null, null, null, null, 1, int, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -321,7 +321,7 @@ beginCompilationUnit(class) beginFieldInitializer(=) handleLiteralInt(42) endFieldInitializer(=, 42) - endClassFields(null, null, null, null, null, null, null, 1, int, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -334,7 +334,7 @@ beginCompilationUnit(class) beginFieldInitializer(=) handleLiteralInt(42) endFieldInitializer(=, 42) - endClassFields(null, null, null, null, null, null, null, 1, int, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -348,7 +348,7 @@ beginCompilationUnit(class) beginFieldInitializer(=) handleLiteralInt(42) endFieldInitializer(=, 42) - endClassFields(null, null, null, null, null, null, null, 1, int, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -361,7 +361,7 @@ beginCompilationUnit(class) beginFieldInitializer(=) handleLiteralInt(42) endFieldInitializer(=, 42) - endClassFields(null, null, null, null, null, null, null, 1, int, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -375,7 +375,7 @@ beginCompilationUnit(class) beginFieldInitializer(=) handleLiteralInt(42) endFieldInitializer(=, 42) - endClassFields(null, null, null, null, null, null, null, 1, int, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -389,7 +389,7 @@ beginCompilationUnit(class) beginFieldInitializer(=) handleLiteralInt(42) endFieldInitializer(=, 42) - endClassFields(null, null, null, null, null, null, null, 1, int, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -402,7 +402,7 @@ beginCompilationUnit(class) beginFieldInitializer(=) handleLiteralInt(42) endFieldInitializer(=, 42) - endClassFields(null, null, null, null, null, null, null, 1, int, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -416,7 +416,7 @@ beginCompilationUnit(class) beginFieldInitializer(=) handleLiteralInt(42) endFieldInitializer(=, 42) - endClassFields(null, null, null, null, null, null, null, 1, int, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -429,7 +429,7 @@ beginCompilationUnit(class) beginFieldInitializer(=) handleLiteralInt(42) endFieldInitializer(=, 42) - endClassFields(null, null, null, null, null, null, null, 1, int, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -442,7 +442,7 @@ beginCompilationUnit(class) beginFieldInitializer(=) handleLiteralInt(42) endFieldInitializer(=, 42) - endClassFields(null, null, null, null, null, null, null, 1, int, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -455,7 +455,7 @@ beginCompilationUnit(class) beginFieldInitializer(=) handleLiteralInt(42) endFieldInitializer(=, 42) - endClassFields(null, null, null, null, null, null, null, 1, int, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -469,7 +469,7 @@ beginCompilationUnit(class) beginFieldInitializer(=) handleLiteralInt(42) endFieldInitializer(=, 42) - endClassFields(null, null, null, null, null, null, null, 1, int, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -483,7 +483,7 @@ beginCompilationUnit(class) beginFieldInitializer(=) handleLiteralInt(42) endFieldInitializer(=, 42) - endClassFields(null, null, null, null, null, null, null, 1, int, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -497,7 +497,7 @@ beginCompilationUnit(class) beginFieldInitializer(=) handleLiteralInt(42) endFieldInitializer(=, 42) - endClassFields(null, null, null, null, null, null, null, 1, int, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -511,7 +511,7 @@ beginCompilationUnit(class) beginFieldInitializer(=) handleLiteralInt(42) endFieldInitializer(=, 42) - endClassFields(null, null, null, null, null, null, null, 1, int, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -524,7 +524,7 @@ beginCompilationUnit(class) beginFieldInitializer(=) handleLiteralInt(42) endFieldInitializer(=, 42) - endClassFields(null, null, null, null, null, null, null, 1, int, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -537,7 +537,7 @@ beginCompilationUnit(class) beginFieldInitializer(=) handleLiteralInt(42) endFieldInitializer(=, 42) - endClassFields(null, null, null, null, null, null, null, 1, int, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -550,7 +550,7 @@ beginCompilationUnit(class) beginFieldInitializer(=) handleLiteralInt(42) endFieldInitializer(=, 42) - endClassFields(null, null, null, null, null, null, null, 1, int, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -564,7 +564,7 @@ beginCompilationUnit(class) beginFieldInitializer(=) handleLiteralInt(42) endFieldInitializer(=, 42) - endClassFields(null, null, null, null, null, null, null, 1, int, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -577,7 +577,7 @@ beginCompilationUnit(class) beginFieldInitializer(=) handleLiteralInt(42) endFieldInitializer(=, 42) - endClassFields(null, null, null, null, null, null, null, 1, int, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -590,7 +590,7 @@ beginCompilationUnit(class) beginFieldInitializer(=) handleLiteralInt(42) endFieldInitializer(=, 42) - endClassFields(null, null, null, null, null, null, null, 1, int, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -604,7 +604,7 @@ beginCompilationUnit(class) beginFieldInitializer(=) handleLiteralInt(42) endFieldInitializer(=, 42) - endClassFields(null, null, null, null, null, null, null, 1, int, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -617,7 +617,7 @@ beginCompilationUnit(class) beginFieldInitializer(=) handleLiteralInt(42) endFieldInitializer(=, 42) - endClassFields(null, null, null, null, null, null, null, 1, int, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -630,7 +630,7 @@ beginCompilationUnit(class) beginFieldInitializer(=) handleLiteralInt(42) endFieldInitializer(=, 42) - endClassFields(null, null, null, null, null, null, null, 1, int, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -644,7 +644,7 @@ beginCompilationUnit(class) beginFieldInitializer(=) handleLiteralInt(42) endFieldInitializer(=, 42) - endClassFields(null, null, null, null, null, null, null, 1, int, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -657,7 +657,7 @@ beginCompilationUnit(class) beginFieldInitializer(=) handleLiteralInt(42) endFieldInitializer(=, 42) - endClassFields(null, null, null, null, null, null, null, 1, int, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -670,7 +670,7 @@ beginCompilationUnit(class) beginFieldInitializer(=) handleLiteralInt(42) endFieldInitializer(=, 42) - endClassFields(null, null, null, null, null, null, null, 1, int, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -683,7 +683,7 @@ beginCompilationUnit(class) beginFieldInitializer(=) handleLiteralInt(42) endFieldInitializer(=, 42) - endClassFields(null, null, null, null, null, null, null, 1, int, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -696,7 +696,7 @@ beginCompilationUnit(class) beginFieldInitializer(=) handleLiteralInt(42) endFieldInitializer(=, 42) - endClassFields(null, null, null, null, null, null, null, 1, int, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -710,7 +710,7 @@ beginCompilationUnit(class) beginFieldInitializer(=) handleLiteralInt(42) endFieldInitializer(=, 42) - endClassFields(null, null, null, null, null, null, null, 1, int, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -724,7 +724,7 @@ beginCompilationUnit(class) beginFieldInitializer(=) handleLiteralInt(42) endFieldInitializer(=, 42) - endClassFields(null, null, null, null, null, null, null, 1, int, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -737,7 +737,7 @@ beginCompilationUnit(class) beginFieldInitializer(=) handleLiteralInt(42) endFieldInitializer(=, 42) - endClassFields(null, null, null, null, null, null, null, 1, int, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -750,7 +750,7 @@ beginCompilationUnit(class) beginFieldInitializer(=) handleLiteralInt(42) endFieldInitializer(=, 42) - endClassFields(null, null, null, null, null, null, null, 1, int, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -763,7 +763,7 @@ beginCompilationUnit(class) beginFieldInitializer(=) handleLiteralInt(42) endFieldInitializer(=, 42) - endClassFields(null, null, null, null, null, null, null, 1, int, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -776,7 +776,7 @@ beginCompilationUnit(class) beginFieldInitializer(=) handleLiteralInt(42) endFieldInitializer(=, 42) - endClassFields(null, null, null, null, null, null, null, 1, int, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -789,7 +789,7 @@ beginCompilationUnit(class) beginFieldInitializer(=) handleLiteralInt(42) endFieldInitializer(=, 42) - endClassFields(null, null, null, null, null, null, null, 1, int, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -802,7 +802,7 @@ beginCompilationUnit(class) beginFieldInitializer(=) handleLiteralInt(42) endFieldInitializer(=, 42) - endClassFields(null, null, null, null, null, null, null, 1, int, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -815,7 +815,7 @@ beginCompilationUnit(class) beginFieldInitializer(=) handleLiteralInt(42) endFieldInitializer(=, 42) - endClassFields(null, null, null, null, null, null, null, 1, int, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -829,7 +829,7 @@ beginCompilationUnit(class) beginFieldInitializer(=) handleLiteralInt(42) endFieldInitializer(=, 42) - endClassFields(null, null, null, null, null, null, null, 1, int, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -843,7 +843,7 @@ beginCompilationUnit(class) beginFieldInitializer(=) handleLiteralInt(42) endFieldInitializer(=, 42) - endClassFields(null, null, null, null, null, null, null, 1, int, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -856,7 +856,7 @@ beginCompilationUnit(class) beginFieldInitializer(=) handleLiteralInt(42) endFieldInitializer(=, 42) - endClassFields(null, null, null, null, null, null, null, 1, int, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -869,7 +869,7 @@ beginCompilationUnit(class) beginFieldInitializer(=) handleLiteralInt(42) endFieldInitializer(=, 42) - endClassFields(null, null, null, null, null, null, null, 1, int, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -882,7 +882,7 @@ beginCompilationUnit(class) beginFieldInitializer(=) handleLiteralInt(42) endFieldInitializer(=, 42) - endClassFields(null, null, null, null, null, null, null, 1, int, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -895,7 +895,7 @@ beginCompilationUnit(class) beginFieldInitializer(=) handleLiteralInt(42) endFieldInitializer(=, 42) - endClassFields(null, null, null, null, null, null, null, 1, int, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -909,7 +909,7 @@ beginCompilationUnit(class) beginFieldInitializer(=) handleLiteralInt(42) endFieldInitializer(=, 42) - endClassFields(null, null, null, null, null, null, null, 1, int, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -923,7 +923,7 @@ beginCompilationUnit(class) beginFieldInitializer(=) handleLiteralInt(42) endFieldInitializer(=, 42) - endClassFields(null, null, null, null, null, null, null, 1, int, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -936,7 +936,7 @@ beginCompilationUnit(class) beginFieldInitializer(=) handleLiteralInt(42) endFieldInitializer(=, 42) - endClassFields(null, null, null, null, null, null, null, 1, int, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -950,7 +950,7 @@ beginCompilationUnit(class) beginFieldInitializer(=) handleLiteralInt(42) endFieldInitializer(=, 42) - endClassFields(null, null, null, null, null, null, null, 1, int, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -964,7 +964,7 @@ beginCompilationUnit(class) beginFieldInitializer(=) handleLiteralInt(42) endFieldInitializer(=, 42) - endClassFields(null, null, null, null, null, null, null, 1, int, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -978,7 +978,7 @@ beginCompilationUnit(class) beginFieldInitializer(=) handleLiteralInt(42) endFieldInitializer(=, 42) - endClassFields(null, null, null, null, null, null, null, 1, int, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -992,7 +992,7 @@ beginCompilationUnit(class) beginFieldInitializer(=) handleLiteralInt(42) endFieldInitializer(=, 42) - endClassFields(null, null, null, null, null, null, null, 1, int, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -1005,7 +1005,7 @@ beginCompilationUnit(class) beginFieldInitializer(=) handleLiteralInt(42) endFieldInitializer(=, 42) - endClassFields(null, null, null, null, null, null, null, 1, int, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -1019,7 +1019,7 @@ beginCompilationUnit(class) beginFieldInitializer(=) handleLiteralInt(42) endFieldInitializer(=, 42) - endClassFields(null, null, null, null, null, null, null, 1, int, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -1033,7 +1033,7 @@ beginCompilationUnit(class) beginFieldInitializer(=) handleLiteralInt(42) endFieldInitializer(=, 42) - endClassFields(null, null, null, null, null, null, null, 1, int, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -1047,7 +1047,7 @@ beginCompilationUnit(class) beginFieldInitializer(=) handleLiteralInt(42) endFieldInitializer(=, 42) - endClassFields(null, null, null, null, null, null, null, 1, int, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -1061,7 +1061,7 @@ beginCompilationUnit(class) beginFieldInitializer(=) handleLiteralInt(42) endFieldInitializer(=, 42) - endClassFields(null, null, null, null, null, null, null, 1, int, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -1074,7 +1074,7 @@ beginCompilationUnit(class) beginFieldInitializer(=) handleLiteralInt(42) endFieldInitializer(=, 42) - endClassFields(null, null, null, null, null, null, null, 1, int, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 69, {, }) endClassDeclaration(class, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/keyword_named_class_fields.dart.intertwined.expect b/pkg/front_end/parser_testcases/error_recovery/keyword_named_class_fields.dart.intertwined.expect index e0fa28e905e..9119f83c119 100644 --- a/pkg/front_end/parser_testcases/error_recovery/keyword_named_class_fields.dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/error_recovery/keyword_named_class_fields.dart.intertwined.expect @@ -51,7 +51,7 @@ parseUnit(class) parseLiteralInt(=) listener: handleLiteralInt(42) listener: endFieldInitializer(=, 42) - listener: endClassFields(null, null, null, null, null, null, null, 1, int, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, WrapperClass) @@ -77,7 +77,7 @@ parseUnit(class) parseLiteralInt(=) listener: handleLiteralInt(42) listener: endFieldInitializer(=, 42) - listener: endClassFields(null, null, null, null, null, null, null, 1, int, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, WrapperClass) @@ -107,7 +107,7 @@ parseUnit(class) parseLiteralInt(=) listener: handleLiteralInt(42) listener: endFieldInitializer(=, 42) - listener: endClassFields(null, null, null, null, null, null, null, 1, int, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, WrapperClass) @@ -133,7 +133,7 @@ parseUnit(class) parseLiteralInt(=) listener: handleLiteralInt(42) listener: endFieldInitializer(=, 42) - listener: endClassFields(null, null, null, null, null, null, null, 1, int, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, WrapperClass) @@ -159,7 +159,7 @@ parseUnit(class) parseLiteralInt(=) listener: handleLiteralInt(42) listener: endFieldInitializer(=, 42) - listener: endClassFields(null, null, null, null, null, null, null, 1, int, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, WrapperClass) @@ -189,7 +189,7 @@ parseUnit(class) parseLiteralInt(=) listener: handleLiteralInt(42) listener: endFieldInitializer(=, 42) - listener: endClassFields(null, null, null, null, null, null, null, 1, int, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, WrapperClass) @@ -219,7 +219,7 @@ parseUnit(class) parseLiteralInt(=) listener: handleLiteralInt(42) listener: endFieldInitializer(=, 42) - listener: endClassFields(null, null, null, null, null, null, null, 1, int, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, WrapperClass) @@ -249,7 +249,7 @@ parseUnit(class) parseLiteralInt(=) listener: handleLiteralInt(42) listener: endFieldInitializer(=, 42) - listener: endClassFields(null, null, null, null, null, null, null, 1, int, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, WrapperClass) @@ -279,7 +279,7 @@ parseUnit(class) parseLiteralInt(=) listener: handleLiteralInt(42) listener: endFieldInitializer(=, 42) - listener: endClassFields(null, null, null, null, null, null, null, 1, int, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, WrapperClass) @@ -309,7 +309,7 @@ parseUnit(class) parseLiteralInt(=) listener: handleLiteralInt(42) listener: endFieldInitializer(=, 42) - listener: endClassFields(null, null, null, null, null, null, null, 1, int, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, WrapperClass) @@ -339,7 +339,7 @@ parseUnit(class) parseLiteralInt(=) listener: handleLiteralInt(42) listener: endFieldInitializer(=, 42) - listener: endClassFields(null, null, null, null, null, null, null, 1, int, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, WrapperClass) @@ -365,7 +365,7 @@ parseUnit(class) parseLiteralInt(=) listener: handleLiteralInt(42) listener: endFieldInitializer(=, 42) - listener: endClassFields(null, null, null, null, null, null, null, 1, int, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, WrapperClass) @@ -395,7 +395,7 @@ parseUnit(class) parseLiteralInt(=) listener: handleLiteralInt(42) listener: endFieldInitializer(=, 42) - listener: endClassFields(null, null, null, null, null, null, null, 1, int, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, WrapperClass) @@ -421,7 +421,7 @@ parseUnit(class) parseLiteralInt(=) listener: handleLiteralInt(42) listener: endFieldInitializer(=, 42) - listener: endClassFields(null, null, null, null, null, null, null, 1, int, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, WrapperClass) @@ -451,7 +451,7 @@ parseUnit(class) parseLiteralInt(=) listener: handleLiteralInt(42) listener: endFieldInitializer(=, 42) - listener: endClassFields(null, null, null, null, null, null, null, 1, int, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, WrapperClass) @@ -477,7 +477,7 @@ parseUnit(class) parseLiteralInt(=) listener: handleLiteralInt(42) listener: endFieldInitializer(=, 42) - listener: endClassFields(null, null, null, null, null, null, null, 1, int, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, WrapperClass) @@ -507,7 +507,7 @@ parseUnit(class) parseLiteralInt(=) listener: handleLiteralInt(42) listener: endFieldInitializer(=, 42) - listener: endClassFields(null, null, null, null, null, null, null, 1, int, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, WrapperClass) @@ -537,7 +537,7 @@ parseUnit(class) parseLiteralInt(=) listener: handleLiteralInt(42) listener: endFieldInitializer(=, 42) - listener: endClassFields(null, null, null, null, null, null, null, 1, int, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, WrapperClass) @@ -563,7 +563,7 @@ parseUnit(class) parseLiteralInt(=) listener: handleLiteralInt(42) listener: endFieldInitializer(=, 42) - listener: endClassFields(null, null, null, null, null, null, null, 1, int, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, WrapperClass) @@ -593,7 +593,7 @@ parseUnit(class) parseLiteralInt(=) listener: handleLiteralInt(42) listener: endFieldInitializer(=, 42) - listener: endClassFields(null, null, null, null, null, null, null, 1, int, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, WrapperClass) @@ -619,7 +619,7 @@ parseUnit(class) parseLiteralInt(=) listener: handleLiteralInt(42) listener: endFieldInitializer(=, 42) - listener: endClassFields(null, null, null, null, null, null, null, 1, int, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, WrapperClass) @@ -645,7 +645,7 @@ parseUnit(class) parseLiteralInt(=) listener: handleLiteralInt(42) listener: endFieldInitializer(=, 42) - listener: endClassFields(null, null, null, null, null, null, null, 1, int, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, WrapperClass) @@ -671,7 +671,7 @@ parseUnit(class) parseLiteralInt(=) listener: handleLiteralInt(42) listener: endFieldInitializer(=, 42) - listener: endClassFields(null, null, null, null, null, null, null, 1, int, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, WrapperClass) @@ -701,7 +701,7 @@ parseUnit(class) parseLiteralInt(=) listener: handleLiteralInt(42) listener: endFieldInitializer(=, 42) - listener: endClassFields(null, null, null, null, null, null, null, 1, int, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, WrapperClass) @@ -731,7 +731,7 @@ parseUnit(class) parseLiteralInt(=) listener: handleLiteralInt(42) listener: endFieldInitializer(=, 42) - listener: endClassFields(null, null, null, null, null, null, null, 1, int, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, WrapperClass) @@ -761,7 +761,7 @@ parseUnit(class) parseLiteralInt(=) listener: handleLiteralInt(42) listener: endFieldInitializer(=, 42) - listener: endClassFields(null, null, null, null, null, null, null, 1, int, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, WrapperClass) @@ -791,7 +791,7 @@ parseUnit(class) parseLiteralInt(=) listener: handleLiteralInt(42) listener: endFieldInitializer(=, 42) - listener: endClassFields(null, null, null, null, null, null, null, 1, int, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, WrapperClass) @@ -817,7 +817,7 @@ parseUnit(class) parseLiteralInt(=) listener: handleLiteralInt(42) listener: endFieldInitializer(=, 42) - listener: endClassFields(null, null, null, null, null, null, null, 1, int, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, WrapperClass) @@ -844,7 +844,7 @@ parseUnit(class) parseLiteralInt(=) listener: handleLiteralInt(42) listener: endFieldInitializer(=, 42) - listener: endClassFields(null, null, null, null, null, null, null, 1, int, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, WrapperClass) @@ -870,7 +870,7 @@ parseUnit(class) parseLiteralInt(=) listener: handleLiteralInt(42) listener: endFieldInitializer(=, 42) - listener: endClassFields(null, null, null, null, null, null, null, 1, int, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, WrapperClass) @@ -900,7 +900,7 @@ parseUnit(class) parseLiteralInt(=) listener: handleLiteralInt(42) listener: endFieldInitializer(=, 42) - listener: endClassFields(null, null, null, null, null, null, null, 1, int, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, WrapperClass) @@ -926,7 +926,7 @@ parseUnit(class) parseLiteralInt(=) listener: handleLiteralInt(42) listener: endFieldInitializer(=, 42) - listener: endClassFields(null, null, null, null, null, null, null, 1, int, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, WrapperClass) @@ -952,7 +952,7 @@ parseUnit(class) parseLiteralInt(=) listener: handleLiteralInt(42) listener: endFieldInitializer(=, 42) - listener: endClassFields(null, null, null, null, null, null, null, 1, int, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, WrapperClass) @@ -982,7 +982,7 @@ parseUnit(class) parseLiteralInt(=) listener: handleLiteralInt(42) listener: endFieldInitializer(=, 42) - listener: endClassFields(null, null, null, null, null, null, null, 1, int, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, WrapperClass) @@ -1008,7 +1008,7 @@ parseUnit(class) parseLiteralInt(=) listener: handleLiteralInt(42) listener: endFieldInitializer(=, 42) - listener: endClassFields(null, null, null, null, null, null, null, 1, int, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, WrapperClass) @@ -1034,7 +1034,7 @@ parseUnit(class) parseLiteralInt(=) listener: handleLiteralInt(42) listener: endFieldInitializer(=, 42) - listener: endClassFields(null, null, null, null, null, null, null, 1, int, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, WrapperClass) @@ -1064,7 +1064,7 @@ parseUnit(class) parseLiteralInt(=) listener: handleLiteralInt(42) listener: endFieldInitializer(=, 42) - listener: endClassFields(null, null, null, null, null, null, null, 1, int, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, WrapperClass) @@ -1090,7 +1090,7 @@ parseUnit(class) parseLiteralInt(=) listener: handleLiteralInt(42) listener: endFieldInitializer(=, 42) - listener: endClassFields(null, null, null, null, null, null, null, 1, int, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, WrapperClass) @@ -1116,7 +1116,7 @@ parseUnit(class) parseLiteralInt(=) listener: handleLiteralInt(42) listener: endFieldInitializer(=, 42) - listener: endClassFields(null, null, null, null, null, null, null, 1, int, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, WrapperClass) @@ -1142,7 +1142,7 @@ parseUnit(class) parseLiteralInt(=) listener: handleLiteralInt(42) listener: endFieldInitializer(=, 42) - listener: endClassFields(null, null, null, null, null, null, null, 1, int, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, WrapperClass) @@ -1168,7 +1168,7 @@ parseUnit(class) parseLiteralInt(=) listener: handleLiteralInt(42) listener: endFieldInitializer(=, 42) - listener: endClassFields(null, null, null, null, null, null, null, 1, int, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, WrapperClass) @@ -1198,7 +1198,7 @@ parseUnit(class) parseLiteralInt(=) listener: handleLiteralInt(42) listener: endFieldInitializer(=, 42) - listener: endClassFields(null, null, null, null, null, null, null, 1, int, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, WrapperClass) @@ -1228,7 +1228,7 @@ parseUnit(class) parseLiteralInt(=) listener: handleLiteralInt(42) listener: endFieldInitializer(=, 42) - listener: endClassFields(null, null, null, null, null, null, null, 1, int, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, WrapperClass) @@ -1254,7 +1254,7 @@ parseUnit(class) parseLiteralInt(=) listener: handleLiteralInt(42) listener: endFieldInitializer(=, 42) - listener: endClassFields(null, null, null, null, null, null, null, 1, int, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, WrapperClass) @@ -1280,7 +1280,7 @@ parseUnit(class) parseLiteralInt(=) listener: handleLiteralInt(42) listener: endFieldInitializer(=, 42) - listener: endClassFields(null, null, null, null, null, null, null, 1, int, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, WrapperClass) @@ -1307,7 +1307,7 @@ parseUnit(class) parseLiteralInt(=) listener: handleLiteralInt(42) listener: endFieldInitializer(=, 42) - listener: endClassFields(null, null, null, null, null, null, null, 1, int, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, WrapperClass) @@ -1333,7 +1333,7 @@ parseUnit(class) parseLiteralInt(=) listener: handleLiteralInt(42) listener: endFieldInitializer(=, 42) - listener: endClassFields(null, null, null, null, null, null, null, 1, int, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, WrapperClass) @@ -1359,7 +1359,7 @@ parseUnit(class) parseLiteralInt(=) listener: handleLiteralInt(42) listener: endFieldInitializer(=, 42) - listener: endClassFields(null, null, null, null, null, null, null, 1, int, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, WrapperClass) @@ -1385,7 +1385,7 @@ parseUnit(class) parseLiteralInt(=) listener: handleLiteralInt(42) listener: endFieldInitializer(=, 42) - listener: endClassFields(null, null, null, null, null, null, null, 1, int, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, WrapperClass) @@ -1411,7 +1411,7 @@ parseUnit(class) parseLiteralInt(=) listener: handleLiteralInt(42) listener: endFieldInitializer(=, 42) - listener: endClassFields(null, null, null, null, null, null, null, 1, int, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, WrapperClass) @@ -1441,7 +1441,7 @@ parseUnit(class) parseLiteralInt(=) listener: handleLiteralInt(42) listener: endFieldInitializer(=, 42) - listener: endClassFields(null, null, null, null, null, null, null, 1, int, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, WrapperClass) @@ -1471,7 +1471,7 @@ parseUnit(class) parseLiteralInt(=) listener: handleLiteralInt(42) listener: endFieldInitializer(=, 42) - listener: endClassFields(null, null, null, null, null, null, null, 1, int, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, WrapperClass) @@ -1498,7 +1498,7 @@ parseUnit(class) parseLiteralInt(=) listener: handleLiteralInt(42) listener: endFieldInitializer(=, 42) - listener: endClassFields(null, null, null, null, null, null, null, 1, int, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, WrapperClass) @@ -1524,7 +1524,7 @@ parseUnit(class) parseLiteralInt(=) listener: handleLiteralInt(42) listener: endFieldInitializer(=, 42) - listener: endClassFields(null, null, null, null, null, null, null, 1, int, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, WrapperClass) @@ -1550,7 +1550,7 @@ parseUnit(class) parseLiteralInt(=) listener: handleLiteralInt(42) listener: endFieldInitializer(=, 42) - listener: endClassFields(null, null, null, null, null, null, null, 1, int, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, WrapperClass) @@ -1576,7 +1576,7 @@ parseUnit(class) parseLiteralInt(=) listener: handleLiteralInt(42) listener: endFieldInitializer(=, 42) - listener: endClassFields(null, null, null, null, null, null, null, 1, int, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, WrapperClass) @@ -1605,7 +1605,7 @@ parseUnit(class) parseLiteralInt(=) listener: handleLiteralInt(42) listener: endFieldInitializer(=, 42) - listener: endClassFields(null, null, null, null, null, null, null, 1, int, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, WrapperClass) @@ -1635,7 +1635,7 @@ parseUnit(class) parseLiteralInt(=) listener: handleLiteralInt(42) listener: endFieldInitializer(=, 42) - listener: endClassFields(null, null, null, null, null, null, null, 1, int, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, WrapperClass) @@ -1661,7 +1661,7 @@ parseUnit(class) parseLiteralInt(=) listener: handleLiteralInt(42) listener: endFieldInitializer(=, 42) - listener: endClassFields(null, null, null, null, null, null, null, 1, int, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, WrapperClass) @@ -1689,7 +1689,7 @@ parseUnit(class) parseLiteralInt(=) listener: handleLiteralInt(42) listener: endFieldInitializer(=, 42) - listener: endClassFields(null, null, null, null, null, null, null, 1, int, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, WrapperClass) @@ -1719,7 +1719,7 @@ parseUnit(class) parseLiteralInt(=) listener: handleLiteralInt(42) listener: endFieldInitializer(=, 42) - listener: endClassFields(null, null, null, null, null, null, null, 1, int, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, WrapperClass) @@ -1749,7 +1749,7 @@ parseUnit(class) parseLiteralInt(=) listener: handleLiteralInt(42) listener: endFieldInitializer(=, 42) - listener: endClassFields(null, null, null, null, null, null, null, 1, int, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, WrapperClass) @@ -1779,7 +1779,7 @@ parseUnit(class) parseLiteralInt(=) listener: handleLiteralInt(42) listener: endFieldInitializer(=, 42) - listener: endClassFields(null, null, null, null, null, null, null, 1, int, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, WrapperClass) @@ -1805,7 +1805,7 @@ parseUnit(class) parseLiteralInt(=) listener: handleLiteralInt(42) listener: endFieldInitializer(=, 42) - listener: endClassFields(null, null, null, null, null, null, null, 1, int, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, WrapperClass) @@ -1835,7 +1835,7 @@ parseUnit(class) parseLiteralInt(=) listener: handleLiteralInt(42) listener: endFieldInitializer(=, 42) - listener: endClassFields(null, null, null, null, null, null, null, 1, int, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, WrapperClass) @@ -1865,7 +1865,7 @@ parseUnit(class) parseLiteralInt(=) listener: handleLiteralInt(42) listener: endFieldInitializer(=, 42) - listener: endClassFields(null, null, null, null, null, null, null, 1, int, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, WrapperClass) @@ -1895,7 +1895,7 @@ parseUnit(class) parseLiteralInt(=) listener: handleLiteralInt(42) listener: endFieldInitializer(=, 42) - listener: endClassFields(null, null, null, null, null, null, null, 1, int, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, WrapperClass) @@ -1925,7 +1925,7 @@ parseUnit(class) parseLiteralInt(=) listener: handleLiteralInt(42) listener: endFieldInitializer(=, 42) - listener: endClassFields(null, null, null, null, null, null, null, 1, int, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, WrapperClass) @@ -1951,7 +1951,7 @@ parseUnit(class) parseLiteralInt(=) listener: handleLiteralInt(42) listener: endFieldInitializer(=, 42) - listener: endClassFields(null, null, null, null, null, null, null, 1, int, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 69, {, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/keyword_named_class_methods.dart.expect b/pkg/front_end/parser_testcases/error_recovery/keyword_named_class_methods.dart.expect index 0fff1e69440..c5a998f6542 100644 --- a/pkg/front_end/parser_testcases/error_recovery/keyword_named_class_methods.dart.expect +++ b/pkg/front_end/parser_testcases/error_recovery/keyword_named_class_methods.dart.expect @@ -550,7 +550,7 @@ beginCompilationUnit(class) endBinaryExpression(+, 1) endReturnStatement(true, return, ;) endBlockFunctionBody(2, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -608,7 +608,7 @@ beginCompilationUnit(class) endBinaryExpression(+, 1) endReturnStatement(true, return, ;) endBlockFunctionBody(2, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -665,7 +665,7 @@ beginCompilationUnit(class) endBinaryExpression(+, 1) endReturnStatement(true, return, ;) endBlockFunctionBody(2, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -723,7 +723,7 @@ beginCompilationUnit(class) endBinaryExpression(+, 1) endReturnStatement(true, return, ;) endBlockFunctionBody(2, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -781,7 +781,7 @@ beginCompilationUnit(class) endBinaryExpression(+, 1) endReturnStatement(true, return, ;) endBlockFunctionBody(2, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -847,7 +847,7 @@ beginCompilationUnit(class) endBinaryExpression(+, 1) handleExpressionStatement((, ;) endBlockFunctionBody(4, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -907,7 +907,7 @@ beginCompilationUnit(class) endBinaryExpression(+, 1) endReturnStatement(true, return, ;) endBlockFunctionBody(2, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -967,7 +967,7 @@ beginCompilationUnit(class) endBinaryExpression(+, 1) endReturnStatement(true, return, ;) endBlockFunctionBody(2, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -1027,7 +1027,7 @@ beginCompilationUnit(class) endBinaryExpression(+, 1) endReturnStatement(true, return, ;) endBlockFunctionBody(2, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -1086,7 +1086,7 @@ beginCompilationUnit(class) endBinaryExpression(+, 1) endReturnStatement(true, return, ;) endBlockFunctionBody(2, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -1152,7 +1152,7 @@ beginCompilationUnit(class) endBinaryExpression(+, 1) handleExpressionStatement((, ;) endBlockFunctionBody(4, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -1210,7 +1210,7 @@ beginCompilationUnit(class) endBinaryExpression(+, 1) endReturnStatement(true, return, ;) endBlockFunctionBody(2, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -1270,7 +1270,7 @@ beginCompilationUnit(class) endBinaryExpression(+, 1) endReturnStatement(true, return, ;) endBlockFunctionBody(2, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -1328,7 +1328,7 @@ beginCompilationUnit(class) endBinaryExpression(+, 1) endReturnStatement(true, return, ;) endBlockFunctionBody(2, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -1404,7 +1404,7 @@ beginCompilationUnit(class) handleRecoverableError(Message[Template(ExpectedAfterButGot), Expected ';' after this., null, {string: ;}], ;, ;) endDoWhileStatement(do, while, ;) endBlockFunctionBody(3, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -1462,7 +1462,7 @@ beginCompilationUnit(class) endBinaryExpression(+, 1) endReturnStatement(true, return, ;) endBlockFunctionBody(2, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -1533,7 +1533,7 @@ beginCompilationUnit(class) endBinaryExpression(+, 1) handleExpressionStatement((, ;) endBlockFunctionBody(4, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -1593,7 +1593,7 @@ beginCompilationUnit(class) endBinaryExpression(+, 1) endReturnStatement(true, return, ;) endBlockFunctionBody(2, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -1651,7 +1651,7 @@ beginCompilationUnit(class) endBinaryExpression(+, 1) endReturnStatement(true, return, ;) endBlockFunctionBody(2, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -1711,7 +1711,7 @@ beginCompilationUnit(class) endBinaryExpression(+, 1) endReturnStatement(true, return, ;) endBlockFunctionBody(2, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -1769,7 +1769,7 @@ beginCompilationUnit(class) endBinaryExpression(+, 1) endReturnStatement(true, return, ;) endBlockFunctionBody(2, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -1827,7 +1827,7 @@ beginCompilationUnit(class) endBinaryExpression(+, 1) endReturnStatement(true, return, ;) endBlockFunctionBody(2, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -1885,7 +1885,7 @@ beginCompilationUnit(class) endBinaryExpression(+, 1) endReturnStatement(true, return, ;) endBlockFunctionBody(2, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -1944,7 +1944,7 @@ beginCompilationUnit(class) endBinaryExpression(+, 1) endReturnStatement(true, return, ;) endBlockFunctionBody(2, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -2031,7 +2031,7 @@ beginCompilationUnit(class) endBinaryExpression(+, 1) handleExpressionStatement(+, ;) endBlockFunctionBody(6, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -2091,7 +2091,7 @@ beginCompilationUnit(class) endBinaryExpression(+, 1) endReturnStatement(true, return, ;) endBlockFunctionBody(2, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -2171,7 +2171,7 @@ beginCompilationUnit(class) endForStatementBody(;) endForStatement(;) endBlockFunctionBody(3, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -2229,7 +2229,7 @@ beginCompilationUnit(class) endBinaryExpression(+, 1) endReturnStatement(true, return, ;) endBlockFunctionBody(2, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -2287,7 +2287,7 @@ beginCompilationUnit(class) endBinaryExpression(+, 1) endReturnStatement(true, return, ;) endBlockFunctionBody(2, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -2345,7 +2345,7 @@ beginCompilationUnit(class) endBinaryExpression(+, 1) endReturnStatement(true, return, ;) endBlockFunctionBody(2, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -2416,7 +2416,7 @@ beginCompilationUnit(class) endThenStatement(+, ;) endIfStatement(if, null, ;) endBlockFunctionBody(3, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -2474,7 +2474,7 @@ beginCompilationUnit(class) endBinaryExpression(+, 1) endReturnStatement(true, return, ;) endBlockFunctionBody(2, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -2532,7 +2532,7 @@ beginCompilationUnit(class) endBinaryExpression(+, 1) endReturnStatement(true, return, ;) endBlockFunctionBody(2, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -2592,7 +2592,7 @@ beginCompilationUnit(class) endBinaryExpression(+, 1) endReturnStatement(true, return, ;) endBlockFunctionBody(2, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -2650,7 +2650,7 @@ beginCompilationUnit(class) endBinaryExpression(+, 1) endReturnStatement(true, return, ;) endBlockFunctionBody(2, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -2708,7 +2708,7 @@ beginCompilationUnit(class) endBinaryExpression(+, 1) endReturnStatement(true, return, ;) endBlockFunctionBody(2, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -2782,7 +2782,7 @@ beginCompilationUnit(class) endBinaryExpression(+, 1) handleExpressionStatement(+, ;) endBlockFunctionBody(3, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -2840,7 +2840,7 @@ beginCompilationUnit(class) endBinaryExpression(+, 1) endReturnStatement(true, return, ;) endBlockFunctionBody(2, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -2898,7 +2898,7 @@ beginCompilationUnit(class) endBinaryExpression(+, 1) endReturnStatement(true, return, ;) endBlockFunctionBody(2, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -2956,7 +2956,7 @@ beginCompilationUnit(class) endBinaryExpression(+, 1) endReturnStatement(true, return, ;) endBlockFunctionBody(2, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -3014,7 +3014,7 @@ beginCompilationUnit(class) endBinaryExpression(+, 1) endReturnStatement(true, return, ;) endBlockFunctionBody(2, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -3078,7 +3078,7 @@ beginCompilationUnit(class) endBinaryExpression(+, 1) endReturnStatement(true, return, ;) endBlockFunctionBody(2, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -3137,7 +3137,7 @@ beginCompilationUnit(class) endBinaryExpression(+, 1) endReturnStatement(true, return, ;) endBlockFunctionBody(2, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -3195,7 +3195,7 @@ beginCompilationUnit(class) endBinaryExpression(+, 1) endReturnStatement(true, return, ;) endBlockFunctionBody(2, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -3253,7 +3253,7 @@ beginCompilationUnit(class) endBinaryExpression(+, 1) endReturnStatement(true, return, ;) endBlockFunctionBody(2, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -3311,7 +3311,7 @@ beginCompilationUnit(class) endBinaryExpression(+, 1) endReturnStatement(true, return, ;) endBlockFunctionBody(2, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -3369,7 +3369,7 @@ beginCompilationUnit(class) endBinaryExpression(+, 1) endReturnStatement(true, return, ;) endBlockFunctionBody(2, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -3427,7 +3427,7 @@ beginCompilationUnit(class) endBinaryExpression(+, 1) endReturnStatement(true, return, ;) endBlockFunctionBody(2, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -3485,7 +3485,7 @@ beginCompilationUnit(class) endBinaryExpression(+, 1) endReturnStatement(true, return, ;) endBlockFunctionBody(2, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -3543,7 +3543,7 @@ beginCompilationUnit(class) endBinaryExpression(+, 1) endReturnStatement(true, return, ;) endBlockFunctionBody(2, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -3603,7 +3603,7 @@ beginCompilationUnit(class) endBinaryExpression(+, 1) endReturnStatement(true, return, ;) endBlockFunctionBody(2, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -3660,7 +3660,7 @@ beginCompilationUnit(class) endBinaryExpression(+, 1) endReturnStatement(true, return, ;) endBlockFunctionBody(2, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -3718,7 +3718,7 @@ beginCompilationUnit(class) endBinaryExpression(+, 1) endReturnStatement(true, return, ;) endBlockFunctionBody(2, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -3776,7 +3776,7 @@ beginCompilationUnit(class) endBinaryExpression(+, 1) endReturnStatement(true, return, ;) endBlockFunctionBody(2, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -3834,7 +3834,7 @@ beginCompilationUnit(class) endBinaryExpression(+, 1) endReturnStatement(true, return, ;) endBlockFunctionBody(2, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -3892,7 +3892,7 @@ beginCompilationUnit(class) endBinaryExpression(+, 1) endReturnStatement(true, return, ;) endBlockFunctionBody(2, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -3905,7 +3905,7 @@ beginCompilationUnit(class) handleIdentifier(super, fieldDeclaration) handleNoFieldInitializer(() handleRecoverableError(Message[Template(ExpectedAfterButGot), Expected ';' after this., null, {string: ;}], super, super) - endClassFields(null, null, null, null, null, null, null, 1, int, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) endMember() beginMetadataStar(() endMetadataStar(0) @@ -3962,7 +3962,7 @@ beginCompilationUnit(class) endBinaryExpression(+, 1) endReturnStatement(true, return, ;) endBlockFunctionBody(2, {, }) - endClassMethod(null, , (, null, }) + endMethod(DeclarationKind.Class, null, , (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -4034,7 +4034,7 @@ beginCompilationUnit(class) endBinaryExpression(+, 1) handleExpressionStatement(+, ;) endBlockFunctionBody(4, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -4092,7 +4092,7 @@ beginCompilationUnit(class) endBinaryExpression(+, 1) endReturnStatement(true, return, ;) endBlockFunctionBody(2, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -4151,7 +4151,7 @@ beginCompilationUnit(class) endBinaryExpression(+, 1) endReturnStatement(true, return, ;) endBlockFunctionBody(2, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -4208,7 +4208,7 @@ beginCompilationUnit(class) handleThrowExpression(throw, 1) endReturnStatement(true, return, ;) endBlockFunctionBody(2, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -4267,7 +4267,7 @@ beginCompilationUnit(class) endBinaryExpression(+, 1) endReturnStatement(true, return, ;) endBlockFunctionBody(2, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -4336,7 +4336,7 @@ beginCompilationUnit(class) endBinaryExpression(+, 1) handleExpressionStatement((, ;) endBlockFunctionBody(4, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -4394,7 +4394,7 @@ beginCompilationUnit(class) endBinaryExpression(+, 1) endReturnStatement(true, return, ;) endBlockFunctionBody(2, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -4481,7 +4481,7 @@ beginCompilationUnit(class) endBinaryExpression(+, 1) handleExpressionStatement(+, ;) endBlockFunctionBody(6, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -4568,7 +4568,7 @@ beginCompilationUnit(class) endBinaryExpression(+, 1) handleExpressionStatement(+, ;) endBlockFunctionBody(6, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -4639,7 +4639,7 @@ beginCompilationUnit(class) endWhileStatementBody(;) endWhileStatement(while, ;) endBlockFunctionBody(3, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -4699,7 +4699,7 @@ beginCompilationUnit(class) endBinaryExpression(+, 1) endReturnStatement(true, return, ;) endBlockFunctionBody(2, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -4757,7 +4757,7 @@ beginCompilationUnit(class) endBinaryExpression(+, 1) endReturnStatement(true, return, ;) endBlockFunctionBody(2, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 70, {, }) endClassDeclaration(class, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/keyword_named_class_methods.dart.intertwined.expect b/pkg/front_end/parser_testcases/error_recovery/keyword_named_class_methods.dart.intertwined.expect index eafcd09f07b..a842affcd1e 100644 --- a/pkg/front_end/parser_testcases/error_recovery/keyword_named_class_methods.dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/error_recovery/keyword_named_class_methods.dart.intertwined.expect @@ -167,7 +167,7 @@ parseUnit(class) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(2, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -309,7 +309,7 @@ parseUnit(class) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(2, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -446,7 +446,7 @@ parseUnit(class) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(2, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -588,7 +588,7 @@ parseUnit(class) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(2, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -733,7 +733,7 @@ parseUnit(class) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(2, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -908,7 +908,7 @@ parseUnit(class) listener: handleExpressionStatement((, ;) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(4, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -1053,7 +1053,7 @@ parseUnit(class) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(2, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -1198,7 +1198,7 @@ parseUnit(class) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(2, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -1343,7 +1343,7 @@ parseUnit(class) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(2, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -1483,7 +1483,7 @@ parseUnit(class) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(2, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -1658,7 +1658,7 @@ parseUnit(class) listener: handleExpressionStatement((, ;) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(4, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -1800,7 +1800,7 @@ parseUnit(class) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(2, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -1945,7 +1945,7 @@ parseUnit(class) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(2, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -2087,7 +2087,7 @@ parseUnit(class) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(2, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -2285,7 +2285,7 @@ parseUnit(class) listener: endDoWhileStatement(do, while, ;) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(3, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -2427,7 +2427,7 @@ parseUnit(class) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(2, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -2619,7 +2619,7 @@ parseUnit(class) listener: handleExpressionStatement((, ;) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(4, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -2764,7 +2764,7 @@ parseUnit(class) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(2, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -2906,7 +2906,7 @@ parseUnit(class) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(2, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -3051,7 +3051,7 @@ parseUnit(class) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(2, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -3193,7 +3193,7 @@ parseUnit(class) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(2, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -3335,7 +3335,7 @@ parseUnit(class) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(2, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -3477,7 +3477,7 @@ parseUnit(class) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(2, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -3618,7 +3618,7 @@ parseUnit(class) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(2, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -3852,7 +3852,7 @@ parseUnit(class) listener: handleExpressionStatement(+, ;) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(6, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -3997,7 +3997,7 @@ parseUnit(class) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(2, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -4206,7 +4206,7 @@ parseUnit(class) listener: endForStatement(;) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(3, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -4348,7 +4348,7 @@ parseUnit(class) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(2, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -4491,7 +4491,7 @@ parseUnit(class) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(2, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -4633,7 +4633,7 @@ parseUnit(class) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(2, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -4814,7 +4814,7 @@ parseUnit(class) listener: endIfStatement(if, null, ;) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(3, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -4956,7 +4956,7 @@ parseUnit(class) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(2, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -5098,7 +5098,7 @@ parseUnit(class) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(2, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -5243,7 +5243,7 @@ parseUnit(class) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(2, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -5385,7 +5385,7 @@ parseUnit(class) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(2, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -5527,7 +5527,7 @@ parseUnit(class) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(2, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -5702,7 +5702,7 @@ parseUnit(class) listener: handleExpressionStatement(+, ;) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(3, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -5844,7 +5844,7 @@ parseUnit(class) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(2, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -5986,7 +5986,7 @@ parseUnit(class) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(2, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -6128,7 +6128,7 @@ parseUnit(class) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(2, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -6270,7 +6270,7 @@ parseUnit(class) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(2, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -6421,7 +6421,7 @@ parseUnit(class) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(2, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -6562,7 +6562,7 @@ parseUnit(class) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(2, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -6704,7 +6704,7 @@ parseUnit(class) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(2, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -6846,7 +6846,7 @@ parseUnit(class) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(2, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -6990,7 +6990,7 @@ parseUnit(class) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(2, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -7132,7 +7132,7 @@ parseUnit(class) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(2, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -7274,7 +7274,7 @@ parseUnit(class) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(2, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -7416,7 +7416,7 @@ parseUnit(class) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(2, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -7558,7 +7558,7 @@ parseUnit(class) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(2, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -7703,7 +7703,7 @@ parseUnit(class) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(2, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -7843,7 +7843,7 @@ parseUnit(class) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(2, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -7986,7 +7986,7 @@ parseUnit(class) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(2, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -8128,7 +8128,7 @@ parseUnit(class) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(2, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -8270,7 +8270,7 @@ parseUnit(class) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(2, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -8412,7 +8412,7 @@ parseUnit(class) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(2, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -8436,7 +8436,7 @@ parseUnit(class) reportRecoverableError(super, Message[Template(ExpectedAfterButGot), Expected ';' after this., null, {string: ;}]) listener: handleRecoverableError(Message[Template(ExpectedAfterButGot), Expected ';' after this., null, {string: ;}], super, super) rewriter() - listener: endClassFields(null, null, null, null, null, null, null, 1, int, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, () parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, WrapperClass) @@ -8575,7 +8575,7 @@ parseUnit(class) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(2, {, }) - listener: endClassMethod(null, , (, null, }) + listener: endMethod(DeclarationKind.Class, null, , (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -8765,7 +8765,7 @@ parseUnit(class) listener: handleExpressionStatement(+, ;) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(4, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -8907,7 +8907,7 @@ parseUnit(class) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(2, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -9045,7 +9045,7 @@ parseUnit(class) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(2, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -9184,7 +9184,7 @@ parseUnit(class) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(2, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -9325,7 +9325,7 @@ parseUnit(class) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(2, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -9506,7 +9506,7 @@ parseUnit(class) listener: handleExpressionStatement((, ;) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(4, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -9648,7 +9648,7 @@ parseUnit(class) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(2, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -9882,7 +9882,7 @@ parseUnit(class) listener: handleExpressionStatement(+, ;) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(6, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -10117,7 +10117,7 @@ parseUnit(class) listener: handleExpressionStatement(+, ;) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(6, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -10298,7 +10298,7 @@ parseUnit(class) listener: endWhileStatement(while, ;) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(3, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -10443,7 +10443,7 @@ parseUnit(class) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(2, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -10585,7 +10585,7 @@ parseUnit(class) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(2, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 70, {, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/keyword_named_class_methods_2.dart.expect b/pkg/front_end/parser_testcases/error_recovery/keyword_named_class_methods_2.dart.expect index 319fa0743b2..41c33f2d710 100644 --- a/pkg/front_end/parser_testcases/error_recovery/keyword_named_class_methods_2.dart.expect +++ b/pkg/front_end/parser_testcases/error_recovery/keyword_named_class_methods_2.dart.expect @@ -538,7 +538,7 @@ beginCompilationUnit(class) endBinaryExpression(+, 1) endReturnStatement(true, return, ;) endBlockFunctionBody(2, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -596,7 +596,7 @@ beginCompilationUnit(class) endBinaryExpression(+, 1) endReturnStatement(true, return, ;) endBlockFunctionBody(2, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -653,7 +653,7 @@ beginCompilationUnit(class) endBinaryExpression(+, 1) endReturnStatement(true, return, ;) endBlockFunctionBody(2, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -711,7 +711,7 @@ beginCompilationUnit(class) endBinaryExpression(+, 1) endReturnStatement(true, return, ;) endBlockFunctionBody(2, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -769,7 +769,7 @@ beginCompilationUnit(class) endBinaryExpression(+, 1) endReturnStatement(true, return, ;) endBlockFunctionBody(2, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -835,7 +835,7 @@ beginCompilationUnit(class) endBinaryExpression(+, 1) handleExpressionStatement((, ;) endBlockFunctionBody(4, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -895,7 +895,7 @@ beginCompilationUnit(class) endBinaryExpression(+, 1) endReturnStatement(true, return, ;) endBlockFunctionBody(2, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -955,7 +955,7 @@ beginCompilationUnit(class) endBinaryExpression(+, 1) endReturnStatement(true, return, ;) endBlockFunctionBody(2, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -1015,7 +1015,7 @@ beginCompilationUnit(class) endBinaryExpression(+, 1) endReturnStatement(true, return, ;) endBlockFunctionBody(2, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -1074,7 +1074,7 @@ beginCompilationUnit(class) endBinaryExpression(+, 1) endReturnStatement(true, return, ;) endBlockFunctionBody(2, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -1140,7 +1140,7 @@ beginCompilationUnit(class) endBinaryExpression(+, 1) handleExpressionStatement((, ;) endBlockFunctionBody(4, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -1198,7 +1198,7 @@ beginCompilationUnit(class) endBinaryExpression(+, 1) endReturnStatement(true, return, ;) endBlockFunctionBody(2, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -1258,7 +1258,7 @@ beginCompilationUnit(class) endBinaryExpression(+, 1) endReturnStatement(true, return, ;) endBlockFunctionBody(2, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -1316,7 +1316,7 @@ beginCompilationUnit(class) endBinaryExpression(+, 1) endReturnStatement(true, return, ;) endBlockFunctionBody(2, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -1392,7 +1392,7 @@ beginCompilationUnit(class) handleRecoverableError(Message[Template(ExpectedAfterButGot), Expected ';' after this., null, {string: ;}], ;, ;) endDoWhileStatement(do, while, ;) endBlockFunctionBody(3, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -1450,7 +1450,7 @@ beginCompilationUnit(class) endBinaryExpression(+, 1) endReturnStatement(true, return, ;) endBlockFunctionBody(2, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -1521,7 +1521,7 @@ beginCompilationUnit(class) endBinaryExpression(+, 1) handleExpressionStatement((, ;) endBlockFunctionBody(4, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -1581,7 +1581,7 @@ beginCompilationUnit(class) endBinaryExpression(+, 1) endReturnStatement(true, return, ;) endBlockFunctionBody(2, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -1639,7 +1639,7 @@ beginCompilationUnit(class) endBinaryExpression(+, 1) endReturnStatement(true, return, ;) endBlockFunctionBody(2, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -1699,7 +1699,7 @@ beginCompilationUnit(class) endBinaryExpression(+, 1) endReturnStatement(true, return, ;) endBlockFunctionBody(2, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -1757,7 +1757,7 @@ beginCompilationUnit(class) endBinaryExpression(+, 1) endReturnStatement(true, return, ;) endBlockFunctionBody(2, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -1815,7 +1815,7 @@ beginCompilationUnit(class) endBinaryExpression(+, 1) endReturnStatement(true, return, ;) endBlockFunctionBody(2, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -1873,7 +1873,7 @@ beginCompilationUnit(class) endBinaryExpression(+, 1) endReturnStatement(true, return, ;) endBlockFunctionBody(2, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -1932,7 +1932,7 @@ beginCompilationUnit(class) endBinaryExpression(+, 1) endReturnStatement(true, return, ;) endBlockFunctionBody(2, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -2019,7 +2019,7 @@ beginCompilationUnit(class) endBinaryExpression(+, 1) handleExpressionStatement(+, ;) endBlockFunctionBody(6, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -2079,7 +2079,7 @@ beginCompilationUnit(class) endBinaryExpression(+, 1) endReturnStatement(true, return, ;) endBlockFunctionBody(2, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -2159,7 +2159,7 @@ beginCompilationUnit(class) endForStatementBody(;) endForStatement(;) endBlockFunctionBody(3, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -2217,7 +2217,7 @@ beginCompilationUnit(class) endBinaryExpression(+, 1) endReturnStatement(true, return, ;) endBlockFunctionBody(2, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -2275,7 +2275,7 @@ beginCompilationUnit(class) endBinaryExpression(+, 1) endReturnStatement(true, return, ;) endBlockFunctionBody(2, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -2333,7 +2333,7 @@ beginCompilationUnit(class) endBinaryExpression(+, 1) endReturnStatement(true, return, ;) endBlockFunctionBody(2, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -2404,7 +2404,7 @@ beginCompilationUnit(class) endThenStatement(+, ;) endIfStatement(if, null, ;) endBlockFunctionBody(3, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -2462,7 +2462,7 @@ beginCompilationUnit(class) endBinaryExpression(+, 1) endReturnStatement(true, return, ;) endBlockFunctionBody(2, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -2520,7 +2520,7 @@ beginCompilationUnit(class) endBinaryExpression(+, 1) endReturnStatement(true, return, ;) endBlockFunctionBody(2, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -2580,7 +2580,7 @@ beginCompilationUnit(class) endBinaryExpression(+, 1) endReturnStatement(true, return, ;) endBlockFunctionBody(2, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -2638,7 +2638,7 @@ beginCompilationUnit(class) endBinaryExpression(+, 1) endReturnStatement(true, return, ;) endBlockFunctionBody(2, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -2696,7 +2696,7 @@ beginCompilationUnit(class) endBinaryExpression(+, 1) endReturnStatement(true, return, ;) endBlockFunctionBody(2, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -2770,7 +2770,7 @@ beginCompilationUnit(class) endBinaryExpression(+, 1) handleExpressionStatement(+, ;) endBlockFunctionBody(3, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -2828,7 +2828,7 @@ beginCompilationUnit(class) endBinaryExpression(+, 1) endReturnStatement(true, return, ;) endBlockFunctionBody(2, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -2886,7 +2886,7 @@ beginCompilationUnit(class) endBinaryExpression(+, 1) endReturnStatement(true, return, ;) endBlockFunctionBody(2, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -2944,7 +2944,7 @@ beginCompilationUnit(class) endBinaryExpression(+, 1) endReturnStatement(true, return, ;) endBlockFunctionBody(2, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -3002,7 +3002,7 @@ beginCompilationUnit(class) endBinaryExpression(+, 1) endReturnStatement(true, return, ;) endBlockFunctionBody(2, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -3066,7 +3066,7 @@ beginCompilationUnit(class) endBinaryExpression(+, 1) endReturnStatement(true, return, ;) endBlockFunctionBody(2, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -3125,7 +3125,7 @@ beginCompilationUnit(class) endBinaryExpression(+, 1) endReturnStatement(true, return, ;) endBlockFunctionBody(2, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -3183,7 +3183,7 @@ beginCompilationUnit(class) endBinaryExpression(+, 1) endReturnStatement(true, return, ;) endBlockFunctionBody(2, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -3241,7 +3241,7 @@ beginCompilationUnit(class) endBinaryExpression(+, 1) endReturnStatement(true, return, ;) endBlockFunctionBody(2, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -3299,7 +3299,7 @@ beginCompilationUnit(class) endBinaryExpression(+, 1) endReturnStatement(true, return, ;) endBlockFunctionBody(2, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -3357,7 +3357,7 @@ beginCompilationUnit(class) endBinaryExpression(+, 1) endReturnStatement(true, return, ;) endBlockFunctionBody(2, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -3415,7 +3415,7 @@ beginCompilationUnit(class) endBinaryExpression(+, 1) endReturnStatement(true, return, ;) endBlockFunctionBody(2, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -3473,7 +3473,7 @@ beginCompilationUnit(class) endBinaryExpression(+, 1) endReturnStatement(true, return, ;) endBlockFunctionBody(2, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -3531,7 +3531,7 @@ beginCompilationUnit(class) endBinaryExpression(+, 1) endReturnStatement(true, return, ;) endBlockFunctionBody(2, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -3591,7 +3591,7 @@ beginCompilationUnit(class) endBinaryExpression(+, 1) endReturnStatement(true, return, ;) endBlockFunctionBody(2, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -3648,7 +3648,7 @@ beginCompilationUnit(class) endBinaryExpression(+, 1) endReturnStatement(true, return, ;) endBlockFunctionBody(2, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -3706,7 +3706,7 @@ beginCompilationUnit(class) endBinaryExpression(+, 1) endReturnStatement(true, return, ;) endBlockFunctionBody(2, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -3764,7 +3764,7 @@ beginCompilationUnit(class) endBinaryExpression(+, 1) endReturnStatement(true, return, ;) endBlockFunctionBody(2, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -3822,7 +3822,7 @@ beginCompilationUnit(class) endBinaryExpression(+, 1) endReturnStatement(true, return, ;) endBlockFunctionBody(2, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -3880,7 +3880,7 @@ beginCompilationUnit(class) endBinaryExpression(+, 1) endReturnStatement(true, return, ;) endBlockFunctionBody(2, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -3893,7 +3893,7 @@ beginCompilationUnit(class) handleIdentifier(super, fieldDeclaration) handleNoFieldInitializer(() handleRecoverableError(Message[Template(ExpectedAfterButGot), Expected ';' after this., null, {string: ;}], super, super) - endClassFields(null, null, null, null, null, null, null, 1, int, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) endMember() beginMetadataStar(() endMetadataStar(0) @@ -3950,7 +3950,7 @@ beginCompilationUnit(class) endBinaryExpression(+, 1) endReturnStatement(true, return, ;) endBlockFunctionBody(2, {, }) - endClassMethod(null, , (, null, }) + endMethod(DeclarationKind.Class, null, , (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -4010,7 +4010,7 @@ beginCompilationUnit(class) endBinaryExpression(+, 1) endReturnStatement(true, return, ;) endBlockFunctionBody(2, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -4068,7 +4068,7 @@ beginCompilationUnit(class) endBinaryExpression(+, 1) endReturnStatement(true, return, ;) endBlockFunctionBody(2, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -4127,7 +4127,7 @@ beginCompilationUnit(class) endBinaryExpression(+, 1) endReturnStatement(true, return, ;) endBlockFunctionBody(2, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -4184,7 +4184,7 @@ beginCompilationUnit(class) handleThrowExpression(throw, 1) endReturnStatement(true, return, ;) endBlockFunctionBody(2, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -4243,7 +4243,7 @@ beginCompilationUnit(class) endBinaryExpression(+, 1) endReturnStatement(true, return, ;) endBlockFunctionBody(2, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -4312,7 +4312,7 @@ beginCompilationUnit(class) endBinaryExpression(+, 1) handleExpressionStatement((, ;) endBlockFunctionBody(4, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -4370,7 +4370,7 @@ beginCompilationUnit(class) endBinaryExpression(+, 1) endReturnStatement(true, return, ;) endBlockFunctionBody(2, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -4457,7 +4457,7 @@ beginCompilationUnit(class) endBinaryExpression(+, 1) handleExpressionStatement(+, ;) endBlockFunctionBody(6, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -4544,7 +4544,7 @@ beginCompilationUnit(class) endBinaryExpression(+, 1) handleExpressionStatement(+, ;) endBlockFunctionBody(6, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -4615,7 +4615,7 @@ beginCompilationUnit(class) endWhileStatementBody(;) endWhileStatement(while, ;) endBlockFunctionBody(3, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -4675,7 +4675,7 @@ beginCompilationUnit(class) endBinaryExpression(+, 1) endReturnStatement(true, return, ;) endBlockFunctionBody(2, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -4733,7 +4733,7 @@ beginCompilationUnit(class) endBinaryExpression(+, 1) endReturnStatement(true, return, ;) endBlockFunctionBody(2, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 70, {, }) endClassDeclaration(class, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/keyword_named_class_methods_2.dart.intertwined.expect b/pkg/front_end/parser_testcases/error_recovery/keyword_named_class_methods_2.dart.intertwined.expect index c857c73ab00..2f9be0604c8 100644 --- a/pkg/front_end/parser_testcases/error_recovery/keyword_named_class_methods_2.dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/error_recovery/keyword_named_class_methods_2.dart.intertwined.expect @@ -178,7 +178,7 @@ parseUnit(class) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(2, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -331,7 +331,7 @@ parseUnit(class) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(2, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -478,7 +478,7 @@ parseUnit(class) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(2, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -631,7 +631,7 @@ parseUnit(class) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(2, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -787,7 +787,7 @@ parseUnit(class) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(2, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -974,7 +974,7 @@ parseUnit(class) listener: handleExpressionStatement((, ;) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(4, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -1129,7 +1129,7 @@ parseUnit(class) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(2, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -1284,7 +1284,7 @@ parseUnit(class) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(2, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -1439,7 +1439,7 @@ parseUnit(class) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(2, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -1589,7 +1589,7 @@ parseUnit(class) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(2, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -1776,7 +1776,7 @@ parseUnit(class) listener: handleExpressionStatement((, ;) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(4, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -1929,7 +1929,7 @@ parseUnit(class) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(2, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -2084,7 +2084,7 @@ parseUnit(class) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(2, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -2237,7 +2237,7 @@ parseUnit(class) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(2, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -2449,7 +2449,7 @@ parseUnit(class) listener: endDoWhileStatement(do, while, ;) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(3, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -2602,7 +2602,7 @@ parseUnit(class) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(2, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -2808,7 +2808,7 @@ parseUnit(class) listener: handleExpressionStatement((, ;) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(4, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -2963,7 +2963,7 @@ parseUnit(class) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(2, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -3116,7 +3116,7 @@ parseUnit(class) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(2, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -3271,7 +3271,7 @@ parseUnit(class) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(2, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -3424,7 +3424,7 @@ parseUnit(class) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(2, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -3577,7 +3577,7 @@ parseUnit(class) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(2, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -3730,7 +3730,7 @@ parseUnit(class) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(2, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -3881,7 +3881,7 @@ parseUnit(class) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(2, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -4130,7 +4130,7 @@ parseUnit(class) listener: handleExpressionStatement(+, ;) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(6, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -4285,7 +4285,7 @@ parseUnit(class) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(2, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -4508,7 +4508,7 @@ parseUnit(class) listener: endForStatement(;) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(3, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -4661,7 +4661,7 @@ parseUnit(class) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(2, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -4815,7 +4815,7 @@ parseUnit(class) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(2, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -4968,7 +4968,7 @@ parseUnit(class) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(2, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -5161,7 +5161,7 @@ parseUnit(class) listener: endIfStatement(if, null, ;) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(3, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -5314,7 +5314,7 @@ parseUnit(class) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(2, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -5467,7 +5467,7 @@ parseUnit(class) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(2, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -5622,7 +5622,7 @@ parseUnit(class) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(2, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -5775,7 +5775,7 @@ parseUnit(class) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(2, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -5928,7 +5928,7 @@ parseUnit(class) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(2, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -6112,7 +6112,7 @@ parseUnit(class) listener: handleExpressionStatement(+, ;) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(3, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -6265,7 +6265,7 @@ parseUnit(class) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(2, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -6418,7 +6418,7 @@ parseUnit(class) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(2, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -6571,7 +6571,7 @@ parseUnit(class) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(2, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -6724,7 +6724,7 @@ parseUnit(class) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(2, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -6885,7 +6885,7 @@ parseUnit(class) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(2, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -7036,7 +7036,7 @@ parseUnit(class) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(2, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -7189,7 +7189,7 @@ parseUnit(class) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(2, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -7342,7 +7342,7 @@ parseUnit(class) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(2, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -7497,7 +7497,7 @@ parseUnit(class) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(2, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -7650,7 +7650,7 @@ parseUnit(class) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(2, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -7803,7 +7803,7 @@ parseUnit(class) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(2, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -7956,7 +7956,7 @@ parseUnit(class) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(2, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -8109,7 +8109,7 @@ parseUnit(class) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(2, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -8264,7 +8264,7 @@ parseUnit(class) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(2, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -8414,7 +8414,7 @@ parseUnit(class) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(2, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -8568,7 +8568,7 @@ parseUnit(class) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(2, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -8721,7 +8721,7 @@ parseUnit(class) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(2, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -8874,7 +8874,7 @@ parseUnit(class) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(2, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -9027,7 +9027,7 @@ parseUnit(class) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(2, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -9051,7 +9051,7 @@ parseUnit(class) reportRecoverableError(super, Message[Template(ExpectedAfterButGot), Expected ';' after this., null, {string: ;}]) listener: handleRecoverableError(Message[Template(ExpectedAfterButGot), Expected ';' after this., null, {string: ;}], super, super) rewriter() - listener: endClassFields(null, null, null, null, null, null, null, 1, int, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, () parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, WrapperClass) @@ -9200,7 +9200,7 @@ parseUnit(class) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(2, {, }) - listener: endClassMethod(null, , (, null, }) + listener: endMethod(DeclarationKind.Class, null, , (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -9357,7 +9357,7 @@ parseUnit(class) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(2, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -9510,7 +9510,7 @@ parseUnit(class) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(2, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -9658,7 +9658,7 @@ parseUnit(class) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(2, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -9809,7 +9809,7 @@ parseUnit(class) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(2, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -9960,7 +9960,7 @@ parseUnit(class) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(2, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -10153,7 +10153,7 @@ parseUnit(class) listener: handleExpressionStatement((, ;) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(4, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -10306,7 +10306,7 @@ parseUnit(class) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(2, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -10555,7 +10555,7 @@ parseUnit(class) listener: handleExpressionStatement(+, ;) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(6, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -10804,7 +10804,7 @@ parseUnit(class) listener: handleExpressionStatement(+, ;) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(6, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -10997,7 +10997,7 @@ parseUnit(class) listener: endWhileStatement(while, ;) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(3, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -11152,7 +11152,7 @@ parseUnit(class) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(2, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -11305,7 +11305,7 @@ parseUnit(class) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(2, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 70, {, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/method_called_with.dart.expect b/pkg/front_end/parser_testcases/error_recovery/method_called_with.dart.expect index 1bafbb13503..d5c4e85889d 100644 --- a/pkg/front_end/parser_testcases/error_recovery/method_called_with.dart.expect +++ b/pkg/front_end/parser_testcases/error_recovery/method_called_with.dart.expect @@ -54,7 +54,7 @@ beginCompilationUnit(class) handleAsyncModifier(null, null) handleLiteralInt(7) handleExpressionFunctionBody(=>, ;) - endClassMethod(null, int, (, null, ;) + endMethod(DeclarationKind.Class, null, int, (, null, ;) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -68,7 +68,7 @@ beginCompilationUnit(class) beginFieldInitializer(=) handleLiteralInt(7) endFieldInitializer(=, 7) - endClassFields(null, null, null, null, null, null, null, 1, int, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -85,7 +85,7 @@ beginCompilationUnit(class) handleAsyncModifier(null, null) handleLiteralInt(7) handleExpressionFunctionBody(=>, ;) - endClassMethod(get, int, =>, null, ;) + endMethod(DeclarationKind.Class, get, int, =>, null, ;) endMember() beginMetadataStar(void) endMetadataStar(0) @@ -110,7 +110,7 @@ beginCompilationUnit(class) handleAsyncModifier(null, null) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) - endClassMethod(set, void, (, null, }) + endMethod(DeclarationKind.Class, set, void, (, null, }) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 4, {, }) endClassDeclaration(class, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/method_called_with.dart.intertwined.expect b/pkg/front_end/parser_testcases/error_recovery/method_called_with.dart.intertwined.expect index fa81e573ef3..02aa85c4da2 100644 --- a/pkg/front_end/parser_testcases/error_recovery/method_called_with.dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/error_recovery/method_called_with.dart.intertwined.expect @@ -71,7 +71,7 @@ parseUnit(class) ensureSemicolon(7) listener: handleExpressionFunctionBody(=>, ;) inGenerator() - listener: endClassMethod(null, int, (, null, ;) + listener: endMethod(DeclarationKind.Class, null, int, (, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, C) @@ -101,7 +101,7 @@ parseUnit(class) parseLiteralInt(=) listener: handleLiteralInt(7) listener: endFieldInitializer(=, 7) - listener: endClassFields(null, null, null, null, null, null, null, 1, int, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, C) @@ -144,7 +144,7 @@ parseUnit(class) ensureSemicolon(7) listener: handleExpressionFunctionBody(=>, ;) inGenerator() - listener: endClassMethod(get, int, =>, null, ;) + listener: endMethod(DeclarationKind.Class, get, int, =>, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, void) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, C) @@ -191,7 +191,7 @@ parseUnit(class) listener: beginBlockFunctionBody({) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(0, {, }) - listener: endClassMethod(set, void, (, null, }) + listener: endMethod(DeclarationKind.Class, set, void, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 4, {, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/method_called_with_prime.dart.expect b/pkg/front_end/parser_testcases/error_recovery/method_called_with_prime.dart.expect index 51cb72ca075..c02478bfa63 100644 --- a/pkg/front_end/parser_testcases/error_recovery/method_called_with_prime.dart.expect +++ b/pkg/front_end/parser_testcases/error_recovery/method_called_with_prime.dart.expect @@ -27,7 +27,7 @@ beginCompilationUnit(class) handleAsyncModifier(null, null) handleLiteralInt(7) handleExpressionFunctionBody(=>, ;) - endClassMethod(null, int, (, null, ;) + endMethod(DeclarationKind.Class, null, int, (, null, ;) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -40,7 +40,7 @@ beginCompilationUnit(class) beginFieldInitializer(=) handleLiteralInt(7) endFieldInitializer(=, 7) - endClassFields(null, null, null, null, null, null, null, 1, int, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -56,7 +56,7 @@ beginCompilationUnit(class) handleAsyncModifier(null, null) handleLiteralInt(7) handleExpressionFunctionBody(=>, ;) - endClassMethod(get, int, =>, null, ;) + endMethod(DeclarationKind.Class, get, int, =>, null, ;) endMember() beginMetadataStar(void) endMetadataStar(0) @@ -80,7 +80,7 @@ beginCompilationUnit(class) handleAsyncModifier(null, null) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) - endClassMethod(set, void, (, null, }) + endMethod(DeclarationKind.Class, set, void, (, null, }) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 4, {, }) endClassDeclaration(class, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/method_called_with_prime.dart.intertwined.expect b/pkg/front_end/parser_testcases/error_recovery/method_called_with_prime.dart.intertwined.expect index cf4a6ae8e05..5cc88d82080 100644 --- a/pkg/front_end/parser_testcases/error_recovery/method_called_with_prime.dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/error_recovery/method_called_with_prime.dart.intertwined.expect @@ -67,7 +67,7 @@ parseUnit(class) ensureSemicolon(7) listener: handleExpressionFunctionBody(=>, ;) inGenerator() - listener: endClassMethod(null, int, (, null, ;) + listener: endMethod(DeclarationKind.Class, null, int, (, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, C) @@ -93,7 +93,7 @@ parseUnit(class) parseLiteralInt(=) listener: handleLiteralInt(7) listener: endFieldInitializer(=, 7) - listener: endClassFields(null, null, null, null, null, null, null, 1, int, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, C) @@ -132,7 +132,7 @@ parseUnit(class) ensureSemicolon(7) listener: handleExpressionFunctionBody(=>, ;) inGenerator() - listener: endClassMethod(get, int, =>, null, ;) + listener: endMethod(DeclarationKind.Class, get, int, =>, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, void) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, C) @@ -175,7 +175,7 @@ parseUnit(class) listener: beginBlockFunctionBody({) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(0, {, }) - listener: endClassMethod(set, void, (, null, }) + listener: endMethod(DeclarationKind.Class, set, void, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 4, {, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/method_called_with_prime2.dart.expect b/pkg/front_end/parser_testcases/error_recovery/method_called_with_prime2.dart.expect index c090264bb68..b434da7f0b3 100644 --- a/pkg/front_end/parser_testcases/error_recovery/method_called_with_prime2.dart.expect +++ b/pkg/front_end/parser_testcases/error_recovery/method_called_with_prime2.dart.expect @@ -70,7 +70,7 @@ beginCompilationUnit(class) handleIdentifier(foo, fieldDeclaration) handleNoFieldInitializer(class) handleRecoverableError(Message[Template(ExpectedAfterButGot), Expected ';' after this., null, {string: ;}], foo, foo) - endClassFields(null, null, null, null, null, null, null, 1, foo, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, foo, ;) endMember() beginMetadataStar(class) endMetadataStar(0) diff --git a/pkg/front_end/parser_testcases/error_recovery/method_called_with_prime2.dart.intertwined.expect b/pkg/front_end/parser_testcases/error_recovery/method_called_with_prime2.dart.intertwined.expect index 427c4c7b0eb..7e9da8e3680 100644 --- a/pkg/front_end/parser_testcases/error_recovery/method_called_with_prime2.dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/error_recovery/method_called_with_prime2.dart.intertwined.expect @@ -100,7 +100,7 @@ parseUnit(class) reportRecoverableError(foo, Message[Template(ExpectedAfterButGot), Expected ';' after this., null, {string: ;}]) listener: handleRecoverableError(Message[Template(ExpectedAfterButGot), Expected ';' after this., null, {string: ;}], foo, foo) rewriter() - listener: endClassFields(null, null, null, null, null, null, null, 1, foo, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, foo, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, class) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, M1) diff --git a/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_01.dart.expect b/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_01.dart.expect index ff29347d921..21be4b204cb 100644 --- a/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_01.dart.expect +++ b/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_01.dart.expect @@ -59,7 +59,7 @@ beginCompilationUnit(class) endThenStatement({, }) endIfStatement(if, null, }) endBlockFunctionBody(1, {, }) - endClassMethod(null, void, (, null, }) + endMethod(DeclarationKind.Class, null, void, (, null, }) endMember() beginMetadataStar(void) endMetadataStar(0) @@ -74,7 +74,7 @@ beginCompilationUnit(class) handleAsyncModifier(null, null) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) - endClassMethod(null, void, (, null, }) + endMethod(DeclarationKind.Class, null, void, (, null, }) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 2, {, }) endClassDeclaration(class, }) @@ -105,7 +105,7 @@ beginCompilationUnit(class) handleAsyncModifier(null, null) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) - endClassMethod(null, void, (, null, }) + endMethod(DeclarationKind.Class, null, void, (, null, }) endMember() beginMetadataStar(void) endMetadataStar(0) @@ -120,7 +120,7 @@ beginCompilationUnit(class) handleAsyncModifier(null, null) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) - endClassMethod(null, void, (, null, }) + endMethod(DeclarationKind.Class, null, void, (, null, }) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 2, {, }) endClassDeclaration(class, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_01.dart.intertwined.expect b/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_01.dart.intertwined.expect index 17c7adf8347..a9186cc4bc4 100644 --- a/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_01.dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_01.dart.intertwined.expect @@ -138,7 +138,7 @@ parseUnit(UnmatchedToken({)) listener: endIfStatement(if, null, }) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(1, {, }) - listener: endClassMethod(null, void, (, null, }) + listener: endMethod(DeclarationKind.Class, null, void, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, void) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Foo) @@ -169,7 +169,7 @@ parseUnit(UnmatchedToken({)) listener: beginBlockFunctionBody({) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(0, {, }) - listener: endClassMethod(null, void, (, null, }) + listener: endMethod(DeclarationKind.Class, null, void, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 2, {, }) @@ -229,7 +229,7 @@ parseUnit(UnmatchedToken({)) listener: beginBlockFunctionBody({) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(0, {, }) - listener: endClassMethod(null, void, (, null, }) + listener: endMethod(DeclarationKind.Class, null, void, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, void) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Bar) @@ -260,7 +260,7 @@ parseUnit(UnmatchedToken({)) listener: beginBlockFunctionBody({) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(0, {, }) - listener: endClassMethod(null, void, (, null, }) + listener: endMethod(DeclarationKind.Class, null, void, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 2, {, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_01.dart.outline.expect b/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_01.dart.outline.expect index bd7a9c8a880..b8bce4c183d 100644 --- a/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_01.dart.outline.expect +++ b/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_01.dart.outline.expect @@ -1,6 +1,6 @@ Class: Foo -Class method: Foo.foo_method1 -Class method: Foo.foo_method2 +Method: Foo.foo_method1 +Method: Foo.foo_method2 Class: Bar -Class method: Bar.bar_method1 -Class method: Bar.bar_method2 +Method: Bar.bar_method1 +Method: Bar.bar_method2 diff --git a/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_02.dart.expect b/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_02.dart.expect index f9a507db29b..6c397eb5399 100644 --- a/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_02.dart.expect +++ b/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_02.dart.expect @@ -45,7 +45,7 @@ beginCompilationUnit(class) endThenStatement({, }) endIfStatement(if, null, }) endBlockFunctionBody(1, {, }) - endClassMethod(null, void, (, null, }) + endMethod(DeclarationKind.Class, null, void, (, null, }) endMember() beginMetadataStar(void) endMetadataStar(0) @@ -60,7 +60,7 @@ beginCompilationUnit(class) handleAsyncModifier(null, null) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) - endClassMethod(null, void, (, null, }) + endMethod(DeclarationKind.Class, null, void, (, null, }) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 2, {, }) endClassDeclaration(class, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_02.dart.intertwined.expect b/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_02.dart.intertwined.expect index 98206c2ce5f..a531c3ac8d7 100644 --- a/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_02.dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_02.dart.intertwined.expect @@ -97,7 +97,7 @@ parseUnit(UnmatchedToken({)) listener: endIfStatement(if, null, }) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(1, {, }) - listener: endClassMethod(null, void, (, null, }) + listener: endMethod(DeclarationKind.Class, null, void, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, void) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Foo) @@ -128,7 +128,7 @@ parseUnit(UnmatchedToken({)) listener: beginBlockFunctionBody({) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(0, {, }) - listener: endClassMethod(null, void, (, null, }) + listener: endMethod(DeclarationKind.Class, null, void, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 2, {, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_02.dart.outline.expect b/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_02.dart.outline.expect index 96af17b0795..f467bf3630d 100644 --- a/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_02.dart.outline.expect +++ b/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_02.dart.outline.expect @@ -1,5 +1,5 @@ Class: Foo -Class method: Foo.foo_method1 -Class method: Foo.foo_method2 +Method: Foo.foo_method1 +Method: Foo.foo_method2 Top-level method: toplevel_method1 Top-level method: toplevel_method2 diff --git a/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_03.dart.expect b/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_03.dart.expect index 6489ba0dfca..60970a8b3d7 100644 --- a/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_03.dart.expect +++ b/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_03.dart.expect @@ -87,7 +87,7 @@ beginCompilationUnit(class) endThenStatement({, }) endIfStatement(if, null, }) endBlockFunctionBody(1, {, }) - endClassMethod(null, void, (, null, }) + endMethod(DeclarationKind.Class, null, void, (, null, }) endMember() beginMetadataStar(void) endMetadataStar(0) @@ -102,7 +102,7 @@ beginCompilationUnit(class) handleAsyncModifier(null, null) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) - endClassMethod(null, void, (, null, }) + endMethod(DeclarationKind.Class, null, void, (, null, }) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 2, {, }) endClassDeclaration(class, }) @@ -133,7 +133,7 @@ beginCompilationUnit(class) handleAsyncModifier(null, null) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) - endClassMethod(null, void, (, null, }) + endMethod(DeclarationKind.Class, null, void, (, null, }) endMember() beginMetadataStar(void) endMetadataStar(0) @@ -148,7 +148,7 @@ beginCompilationUnit(class) handleAsyncModifier(null, null) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) - endClassMethod(null, void, (, null, }) + endMethod(DeclarationKind.Class, null, void, (, null, }) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 2, {, }) endClassDeclaration(class, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_03.dart.intertwined.expect b/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_03.dart.intertwined.expect index bf132d78d02..26e18be7090 100644 --- a/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_03.dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_03.dart.intertwined.expect @@ -220,7 +220,7 @@ parseUnit(UnmatchedToken({)) listener: endIfStatement(if, null, }) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(1, {, }) - listener: endClassMethod(null, void, (, null, }) + listener: endMethod(DeclarationKind.Class, null, void, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, void) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Foo) @@ -251,7 +251,7 @@ parseUnit(UnmatchedToken({)) listener: beginBlockFunctionBody({) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(0, {, }) - listener: endClassMethod(null, void, (, null, }) + listener: endMethod(DeclarationKind.Class, null, void, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 2, {, }) @@ -311,7 +311,7 @@ parseUnit(UnmatchedToken({)) listener: beginBlockFunctionBody({) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(0, {, }) - listener: endClassMethod(null, void, (, null, }) + listener: endMethod(DeclarationKind.Class, null, void, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, void) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Bar) @@ -342,7 +342,7 @@ parseUnit(UnmatchedToken({)) listener: beginBlockFunctionBody({) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(0, {, }) - listener: endClassMethod(null, void, (, null, }) + listener: endMethod(DeclarationKind.Class, null, void, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 2, {, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_03.dart.outline.expect b/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_03.dart.outline.expect index bd7a9c8a880..b8bce4c183d 100644 --- a/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_03.dart.outline.expect +++ b/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_03.dart.outline.expect @@ -1,6 +1,6 @@ Class: Foo -Class method: Foo.foo_method1 -Class method: Foo.foo_method2 +Method: Foo.foo_method1 +Method: Foo.foo_method2 Class: Bar -Class method: Bar.bar_method1 -Class method: Bar.bar_method2 +Method: Bar.bar_method1 +Method: Bar.bar_method2 diff --git a/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_04.dart.expect b/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_04.dart.expect index 8d2e0504773..06997801936 100644 --- a/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_04.dart.expect +++ b/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_04.dart.expect @@ -96,7 +96,7 @@ beginCompilationUnit(class) endThenStatement({, }) endIfStatement(if, null, }) endBlockFunctionBody(1, {, }) - endClassMethod(null, void, (, null, }) + endMethod(DeclarationKind.Class, null, void, (, null, }) endMember() beginMetadataStar(void) endMetadataStar(0) @@ -111,7 +111,7 @@ beginCompilationUnit(class) handleAsyncModifier(null, null) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) - endClassMethod(null, void, (, null, }) + endMethod(DeclarationKind.Class, null, void, (, null, }) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 2, {, }) endClassDeclaration(class, }) @@ -142,7 +142,7 @@ beginCompilationUnit(class) handleAsyncModifier(null, null) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) - endClassMethod(null, void, (, null, }) + endMethod(DeclarationKind.Class, null, void, (, null, }) endMember() beginMetadataStar(void) endMetadataStar(0) @@ -157,7 +157,7 @@ beginCompilationUnit(class) handleAsyncModifier(null, null) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) - endClassMethod(null, void, (, null, }) + endMethod(DeclarationKind.Class, null, void, (, null, }) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 2, {, }) endClassDeclaration(class, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_04.dart.intertwined.expect b/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_04.dart.intertwined.expect index 722e08b04ce..a9482b022a7 100644 --- a/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_04.dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_04.dart.intertwined.expect @@ -247,7 +247,7 @@ parseUnit(UnmatchedToken({)) listener: endIfStatement(if, null, }) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(1, {, }) - listener: endClassMethod(null, void, (, null, }) + listener: endMethod(DeclarationKind.Class, null, void, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, void) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Foo) @@ -278,7 +278,7 @@ parseUnit(UnmatchedToken({)) listener: beginBlockFunctionBody({) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(0, {, }) - listener: endClassMethod(null, void, (, null, }) + listener: endMethod(DeclarationKind.Class, null, void, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 2, {, }) @@ -338,7 +338,7 @@ parseUnit(UnmatchedToken({)) listener: beginBlockFunctionBody({) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(0, {, }) - listener: endClassMethod(null, void, (, null, }) + listener: endMethod(DeclarationKind.Class, null, void, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, void) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Bar) @@ -369,7 +369,7 @@ parseUnit(UnmatchedToken({)) listener: beginBlockFunctionBody({) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(0, {, }) - listener: endClassMethod(null, void, (, null, }) + listener: endMethod(DeclarationKind.Class, null, void, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 2, {, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_04.dart.outline.expect b/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_04.dart.outline.expect index bd7a9c8a880..b8bce4c183d 100644 --- a/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_04.dart.outline.expect +++ b/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_04.dart.outline.expect @@ -1,6 +1,6 @@ Class: Foo -Class method: Foo.foo_method1 -Class method: Foo.foo_method2 +Method: Foo.foo_method1 +Method: Foo.foo_method2 Class: Bar -Class method: Bar.bar_method1 -Class method: Bar.bar_method2 +Method: Bar.bar_method1 +Method: Bar.bar_method2 diff --git a/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_05.dart.expect b/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_05.dart.expect index b54aafe2ea7..b5253575dca 100644 --- a/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_05.dart.expect +++ b/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_05.dart.expect @@ -98,7 +98,7 @@ beginCompilationUnit(class) endThenStatement({, }) endIfStatement(if, null, }) endBlockFunctionBody(1, {, }) - endClassMethod(null, void, (, null, }) + endMethod(DeclarationKind.Class, null, void, (, null, }) endMember() beginMetadataStar(void) endMetadataStar(0) @@ -113,7 +113,7 @@ beginCompilationUnit(class) handleAsyncModifier(null, null) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) - endClassMethod(null, void, (, null, }) + endMethod(DeclarationKind.Class, null, void, (, null, }) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 2, {, }) endClassDeclaration(class, }) @@ -144,7 +144,7 @@ beginCompilationUnit(class) handleAsyncModifier(null, null) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) - endClassMethod(null, void, (, null, }) + endMethod(DeclarationKind.Class, null, void, (, null, }) endMember() beginMetadataStar(void) endMetadataStar(0) @@ -159,7 +159,7 @@ beginCompilationUnit(class) handleAsyncModifier(null, null) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) - endClassMethod(null, void, (, null, }) + endMethod(DeclarationKind.Class, null, void, (, null, }) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 2, {, }) endClassDeclaration(class, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_05.dart.intertwined.expect b/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_05.dart.intertwined.expect index 9657401bdcf..e2ca2b4a960 100644 --- a/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_05.dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_05.dart.intertwined.expect @@ -250,7 +250,7 @@ parseUnit(UnmatchedToken({)) listener: endIfStatement(if, null, }) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(1, {, }) - listener: endClassMethod(null, void, (, null, }) + listener: endMethod(DeclarationKind.Class, null, void, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, void) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Foo) @@ -281,7 +281,7 @@ parseUnit(UnmatchedToken({)) listener: beginBlockFunctionBody({) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(0, {, }) - listener: endClassMethod(null, void, (, null, }) + listener: endMethod(DeclarationKind.Class, null, void, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 2, {, }) @@ -341,7 +341,7 @@ parseUnit(UnmatchedToken({)) listener: beginBlockFunctionBody({) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(0, {, }) - listener: endClassMethod(null, void, (, null, }) + listener: endMethod(DeclarationKind.Class, null, void, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, void) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Bar) @@ -372,7 +372,7 @@ parseUnit(UnmatchedToken({)) listener: beginBlockFunctionBody({) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(0, {, }) - listener: endClassMethod(null, void, (, null, }) + listener: endMethod(DeclarationKind.Class, null, void, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 2, {, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_05.dart.outline.expect b/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_05.dart.outline.expect index bd7a9c8a880..b8bce4c183d 100644 --- a/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_05.dart.outline.expect +++ b/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_05.dart.outline.expect @@ -1,6 +1,6 @@ Class: Foo -Class method: Foo.foo_method1 -Class method: Foo.foo_method2 +Method: Foo.foo_method1 +Method: Foo.foo_method2 Class: Bar -Class method: Bar.bar_method1 -Class method: Bar.bar_method2 +Method: Bar.bar_method1 +Method: Bar.bar_method2 diff --git a/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_06.dart.expect b/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_06.dart.expect index e8ba1d99b05..260c2131227 100644 --- a/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_06.dart.expect +++ b/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_06.dart.expect @@ -58,7 +58,7 @@ beginCompilationUnit(class) endWhileStatementBody(}) endWhileStatement(while, }) endBlockFunctionBody(2, {, }) - endClassMethod(null, void, (, null, }) + endMethod(DeclarationKind.Class, null, void, (, null, }) endMember() beginMetadataStar(void) endMetadataStar(0) @@ -73,7 +73,7 @@ beginCompilationUnit(class) handleAsyncModifier(null, null) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) - endClassMethod(null, void, (, null, }) + endMethod(DeclarationKind.Class, null, void, (, null, }) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 2, {, }) endClassDeclaration(class, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_06.dart.intertwined.expect b/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_06.dart.intertwined.expect index f297412f128..931225c3fdf 100644 --- a/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_06.dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_06.dart.intertwined.expect @@ -127,7 +127,7 @@ parseUnit(UnmatchedToken({)) listener: endWhileStatement(while, }) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(2, {, }) - listener: endClassMethod(null, void, (, null, }) + listener: endMethod(DeclarationKind.Class, null, void, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, void) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Foo) @@ -158,7 +158,7 @@ parseUnit(UnmatchedToken({)) listener: beginBlockFunctionBody({) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(0, {, }) - listener: endClassMethod(null, void, (, null, }) + listener: endMethod(DeclarationKind.Class, null, void, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 2, {, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_06.dart.outline.expect b/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_06.dart.outline.expect index 96af17b0795..f467bf3630d 100644 --- a/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_06.dart.outline.expect +++ b/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_06.dart.outline.expect @@ -1,5 +1,5 @@ Class: Foo -Class method: Foo.foo_method1 -Class method: Foo.foo_method2 +Method: Foo.foo_method1 +Method: Foo.foo_method2 Top-level method: toplevel_method1 Top-level method: toplevel_method2 diff --git a/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_07.dart.expect b/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_07.dart.expect index 5346a757039..b9f306eb6f1 100644 --- a/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_07.dart.expect +++ b/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_07.dart.expect @@ -65,7 +65,7 @@ beginCompilationUnit(class) endForStatementBody(}) endForStatement(}) endBlockFunctionBody(1, {, }) - endClassMethod(null, void, (, null, }) + endMethod(DeclarationKind.Class, null, void, (, null, }) endMember() beginMetadataStar(void) endMetadataStar(0) @@ -80,7 +80,7 @@ beginCompilationUnit(class) handleAsyncModifier(null, null) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) - endClassMethod(null, void, (, null, }) + endMethod(DeclarationKind.Class, null, void, (, null, }) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 2, {, }) endClassDeclaration(class, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_07.dart.intertwined.expect b/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_07.dart.intertwined.expect index de659a47672..16c02cc981b 100644 --- a/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_07.dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_07.dart.intertwined.expect @@ -145,7 +145,7 @@ parseUnit(UnmatchedToken({)) listener: endForStatement(}) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(1, {, }) - listener: endClassMethod(null, void, (, null, }) + listener: endMethod(DeclarationKind.Class, null, void, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, void) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Foo) @@ -176,7 +176,7 @@ parseUnit(UnmatchedToken({)) listener: beginBlockFunctionBody({) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(0, {, }) - listener: endClassMethod(null, void, (, null, }) + listener: endMethod(DeclarationKind.Class, null, void, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 2, {, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_07.dart.outline.expect b/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_07.dart.outline.expect index 96af17b0795..f467bf3630d 100644 --- a/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_07.dart.outline.expect +++ b/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_07.dart.outline.expect @@ -1,5 +1,5 @@ Class: Foo -Class method: Foo.foo_method1 -Class method: Foo.foo_method2 +Method: Foo.foo_method1 +Method: Foo.foo_method2 Top-level method: toplevel_method1 Top-level method: toplevel_method2 diff --git a/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_08.dart.expect b/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_08.dart.expect index 32f7ce75555..26c1b5fb081 100644 --- a/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_08.dart.expect +++ b/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_08.dart.expect @@ -49,7 +49,7 @@ beginCompilationUnit(class) endSwitchBlock(0, {, }) endSwitchStatement(switch, }) endBlockFunctionBody(1, {, }) - endClassMethod(null, void, (, null, }) + endMethod(DeclarationKind.Class, null, void, (, null, }) endMember() beginMetadataStar(void) endMetadataStar(0) @@ -64,7 +64,7 @@ beginCompilationUnit(class) handleAsyncModifier(null, null) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) - endClassMethod(null, void, (, null, }) + endMethod(DeclarationKind.Class, null, void, (, null, }) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 2, {, }) endClassDeclaration(class, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_08.dart.intertwined.expect b/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_08.dart.intertwined.expect index 4c4bca72f5c..7323f3d1790 100644 --- a/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_08.dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_08.dart.intertwined.expect @@ -98,7 +98,7 @@ parseUnit(UnmatchedToken({)) listener: endSwitchStatement(switch, }) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(1, {, }) - listener: endClassMethod(null, void, (, null, }) + listener: endMethod(DeclarationKind.Class, null, void, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, void) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Foo) @@ -129,7 +129,7 @@ parseUnit(UnmatchedToken({)) listener: beginBlockFunctionBody({) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(0, {, }) - listener: endClassMethod(null, void, (, null, }) + listener: endMethod(DeclarationKind.Class, null, void, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 2, {, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_08.dart.outline.expect b/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_08.dart.outline.expect index 96af17b0795..f467bf3630d 100644 --- a/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_08.dart.outline.expect +++ b/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_08.dart.outline.expect @@ -1,5 +1,5 @@ Class: Foo -Class method: Foo.foo_method1 -Class method: Foo.foo_method2 +Method: Foo.foo_method1 +Method: Foo.foo_method2 Top-level method: toplevel_method1 Top-level method: toplevel_method2 diff --git a/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_09.dart.expect b/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_09.dart.expect index 34e71e300b8..58f59513a33 100644 --- a/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_09.dart.expect +++ b/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_09.dart.expect @@ -66,7 +66,7 @@ beginCompilationUnit(class) endElseStatement(else, }) endIfStatement(if, else, }) endBlockFunctionBody(1, {, }) - endClassMethod(null, void, (, null, }) + endMethod(DeclarationKind.Class, null, void, (, null, }) endMember() beginMetadataStar(void) endMetadataStar(0) @@ -81,7 +81,7 @@ beginCompilationUnit(class) handleAsyncModifier(null, null) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) - endClassMethod(null, void, (, null, }) + endMethod(DeclarationKind.Class, null, void, (, null, }) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 2, {, }) endClassDeclaration(class, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_09.dart.intertwined.expect b/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_09.dart.intertwined.expect index 9d95ea988f4..0e6056a5c2c 100644 --- a/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_09.dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_09.dart.intertwined.expect @@ -148,7 +148,7 @@ parseUnit(UnmatchedToken({)) listener: endIfStatement(if, else, }) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(1, {, }) - listener: endClassMethod(null, void, (, null, }) + listener: endMethod(DeclarationKind.Class, null, void, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, void) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Foo) @@ -179,7 +179,7 @@ parseUnit(UnmatchedToken({)) listener: beginBlockFunctionBody({) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(0, {, }) - listener: endClassMethod(null, void, (, null, }) + listener: endMethod(DeclarationKind.Class, null, void, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 2, {, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_09.dart.outline.expect b/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_09.dart.outline.expect index 96af17b0795..f467bf3630d 100644 --- a/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_09.dart.outline.expect +++ b/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_09.dart.outline.expect @@ -1,5 +1,5 @@ Class: Foo -Class method: Foo.foo_method1 -Class method: Foo.foo_method2 +Method: Foo.foo_method1 +Method: Foo.foo_method2 Top-level method: toplevel_method1 Top-level method: toplevel_method2 diff --git a/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_10.dart.expect b/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_10.dart.expect index 9ecb65241dd..449766f927c 100644 --- a/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_10.dart.expect +++ b/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_10.dart.expect @@ -78,7 +78,7 @@ beginCompilationUnit(class) endElseStatement(else, }) endIfStatement(if, else, }) endBlockFunctionBody(1, {, }) - endClassMethod(null, void, (, null, }) + endMethod(DeclarationKind.Class, null, void, (, null, }) endMember() beginMetadataStar(void) endMetadataStar(0) @@ -93,7 +93,7 @@ beginCompilationUnit(class) handleAsyncModifier(null, null) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) - endClassMethod(null, void, (, null, }) + endMethod(DeclarationKind.Class, null, void, (, null, }) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 2, {, }) endClassDeclaration(class, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_10.dart.intertwined.expect b/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_10.dart.intertwined.expect index 48c5e31e453..cbe70e9fa05 100644 --- a/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_10.dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_10.dart.intertwined.expect @@ -181,7 +181,7 @@ parseUnit(UnmatchedToken({)) listener: endIfStatement(if, else, }) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(1, {, }) - listener: endClassMethod(null, void, (, null, }) + listener: endMethod(DeclarationKind.Class, null, void, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, void) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Foo) @@ -212,7 +212,7 @@ parseUnit(UnmatchedToken({)) listener: beginBlockFunctionBody({) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(0, {, }) - listener: endClassMethod(null, void, (, null, }) + listener: endMethod(DeclarationKind.Class, null, void, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 2, {, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_10.dart.outline.expect b/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_10.dart.outline.expect index 96af17b0795..f467bf3630d 100644 --- a/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_10.dart.outline.expect +++ b/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_10.dart.outline.expect @@ -1,5 +1,5 @@ Class: Foo -Class method: Foo.foo_method1 -Class method: Foo.foo_method2 +Method: Foo.foo_method1 +Method: Foo.foo_method2 Top-level method: toplevel_method1 Top-level method: toplevel_method2 diff --git a/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_11.dart.expect b/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_11.dart.expect index 38835314a7f..10d4d37f9b3 100644 --- a/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_11.dart.expect +++ b/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_11.dart.expect @@ -49,7 +49,7 @@ beginCompilationUnit(class) handleRecoverableError(OnlyTry, try, try) endTryStatement(0, try, null, }) endBlockFunctionBody(1, {, }) - endClassMethod(null, void, (, null, }) + endMethod(DeclarationKind.Class, null, void, (, null, }) endMember() beginMetadataStar(void) endMetadataStar(0) @@ -64,7 +64,7 @@ beginCompilationUnit(class) handleAsyncModifier(null, null) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) - endClassMethod(null, void, (, null, }) + endMethod(DeclarationKind.Class, null, void, (, null, }) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 2, {, }) endClassDeclaration(class, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_11.dart.intertwined.expect b/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_11.dart.intertwined.expect index 71fc8f8337b..950d26c0dab 100644 --- a/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_11.dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_11.dart.intertwined.expect @@ -81,7 +81,7 @@ parseUnit(UnmatchedToken({)) listener: endTryStatement(0, try, null, }) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(1, {, }) - listener: endClassMethod(null, void, (, null, }) + listener: endMethod(DeclarationKind.Class, null, void, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, void) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Foo) @@ -112,7 +112,7 @@ parseUnit(UnmatchedToken({)) listener: beginBlockFunctionBody({) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(0, {, }) - listener: endClassMethod(null, void, (, null, }) + listener: endMethod(DeclarationKind.Class, null, void, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 2, {, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_11.dart.outline.expect b/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_11.dart.outline.expect index 96af17b0795..f467bf3630d 100644 --- a/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_11.dart.outline.expect +++ b/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_11.dart.outline.expect @@ -1,5 +1,5 @@ Class: Foo -Class method: Foo.foo_method1 -Class method: Foo.foo_method2 +Method: Foo.foo_method1 +Method: Foo.foo_method2 Top-level method: toplevel_method1 Top-level method: toplevel_method2 diff --git a/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_12.dart.expect b/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_12.dart.expect index ad8a6423162..0e9bab89063 100644 --- a/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_12.dart.expect +++ b/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_12.dart.expect @@ -58,7 +58,7 @@ beginCompilationUnit(class) handleCatchBlock(null, catch, null) endTryStatement(1, try, null, }) endBlockFunctionBody(1, {, }) - endClassMethod(null, void, (, null, }) + endMethod(DeclarationKind.Class, null, void, (, null, }) endMember() beginMetadataStar(void) endMetadataStar(0) @@ -73,7 +73,7 @@ beginCompilationUnit(class) handleAsyncModifier(null, null) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) - endClassMethod(null, void, (, null, }) + endMethod(DeclarationKind.Class, null, void, (, null, }) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 2, {, }) endClassDeclaration(class, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_12.dart.intertwined.expect b/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_12.dart.intertwined.expect index 612b9994333..579f6e31c06 100644 --- a/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_12.dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_12.dart.intertwined.expect @@ -101,7 +101,7 @@ parseUnit(UnmatchedToken({)) listener: endTryStatement(1, try, null, }) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(1, {, }) - listener: endClassMethod(null, void, (, null, }) + listener: endMethod(DeclarationKind.Class, null, void, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, void) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Foo) @@ -132,7 +132,7 @@ parseUnit(UnmatchedToken({)) listener: beginBlockFunctionBody({) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(0, {, }) - listener: endClassMethod(null, void, (, null, }) + listener: endMethod(DeclarationKind.Class, null, void, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 2, {, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_12.dart.outline.expect b/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_12.dart.outline.expect index 96af17b0795..f467bf3630d 100644 --- a/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_12.dart.outline.expect +++ b/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_12.dart.outline.expect @@ -1,5 +1,5 @@ Class: Foo -Class method: Foo.foo_method1 -Class method: Foo.foo_method2 +Method: Foo.foo_method1 +Method: Foo.foo_method2 Top-level method: toplevel_method1 Top-level method: toplevel_method2 diff --git a/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_13.dart.expect b/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_13.dart.expect index fe139caf8d7..9ccefd60a18 100644 --- a/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_13.dart.expect +++ b/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_13.dart.expect @@ -61,7 +61,7 @@ beginCompilationUnit(class) handleFinallyBlock(finally) endTryStatement(1, try, finally, }) endBlockFunctionBody(1, {, }) - endClassMethod(null, void, (, null, }) + endMethod(DeclarationKind.Class, null, void, (, null, }) endMember() beginMetadataStar(void) endMetadataStar(0) @@ -76,7 +76,7 @@ beginCompilationUnit(class) handleAsyncModifier(null, null) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) - endClassMethod(null, void, (, null, }) + endMethod(DeclarationKind.Class, null, void, (, null, }) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 2, {, }) endClassDeclaration(class, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_13.dart.intertwined.expect b/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_13.dart.intertwined.expect index 4e2b98b3737..419478d22e2 100644 --- a/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_13.dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_13.dart.intertwined.expect @@ -107,7 +107,7 @@ parseUnit(UnmatchedToken({)) listener: endTryStatement(1, try, finally, }) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(1, {, }) - listener: endClassMethod(null, void, (, null, }) + listener: endMethod(DeclarationKind.Class, null, void, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, void) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Foo) @@ -138,7 +138,7 @@ parseUnit(UnmatchedToken({)) listener: beginBlockFunctionBody({) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(0, {, }) - listener: endClassMethod(null, void, (, null, }) + listener: endMethod(DeclarationKind.Class, null, void, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 2, {, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_13.dart.outline.expect b/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_13.dart.outline.expect index 96af17b0795..f467bf3630d 100644 --- a/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_13.dart.outline.expect +++ b/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_13.dart.outline.expect @@ -1,5 +1,5 @@ Class: Foo -Class method: Foo.foo_method1 -Class method: Foo.foo_method2 +Method: Foo.foo_method1 +Method: Foo.foo_method2 Top-level method: toplevel_method1 Top-level method: toplevel_method2 diff --git a/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_14.dart.expect b/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_14.dart.expect index b4c7141bb90..eb33e749ca0 100644 --- a/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_14.dart.expect +++ b/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_14.dart.expect @@ -74,7 +74,7 @@ beginCompilationUnit(class) endThenStatement({, }) endIfStatement(if, null, }) endBlockFunctionBody(1, {, }) - endClassMethod(null, void, (, null, }) + endMethod(DeclarationKind.Class, null, void, (, null, }) endMember() beginMetadataStar(void) endMetadataStar(0) @@ -98,7 +98,7 @@ beginCompilationUnit(class) handleAsyncModifier(null, null) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) - endClassMethod(null, void, (, null, }) + endMethod(DeclarationKind.Class, null, void, (, null, }) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 2, {, }) endClassDeclaration(class, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_14.dart.intertwined.expect b/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_14.dart.intertwined.expect index 305f0cbb2c6..df97e761d4a 100644 --- a/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_14.dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_14.dart.intertwined.expect @@ -173,7 +173,7 @@ parseUnit(UnmatchedToken({)) listener: endIfStatement(if, null, }) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(1, {, }) - listener: endClassMethod(null, void, (, null, }) + listener: endMethod(DeclarationKind.Class, null, void, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, void) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Foo) @@ -216,7 +216,7 @@ parseUnit(UnmatchedToken({)) listener: beginBlockFunctionBody({) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(0, {, }) - listener: endClassMethod(null, void, (, null, }) + listener: endMethod(DeclarationKind.Class, null, void, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 2, {, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_14.dart.outline.expect b/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_14.dart.outline.expect index 96af17b0795..f467bf3630d 100644 --- a/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_14.dart.outline.expect +++ b/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_14.dart.outline.expect @@ -1,5 +1,5 @@ Class: Foo -Class method: Foo.foo_method1 -Class method: Foo.foo_method2 +Method: Foo.foo_method1 +Method: Foo.foo_method2 Top-level method: toplevel_method1 Top-level method: toplevel_method2 diff --git a/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_15.dart.expect b/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_15.dart.expect index 6895278e644..5ed5fcc226d 100644 --- a/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_15.dart.expect +++ b/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_15.dart.expect @@ -54,7 +54,7 @@ beginCompilationUnit(class) endThenStatement({, }) endIfStatement(if, null, }) endBlockFunctionBody(1, {, }) - endClassMethod(null, void, (, null, }) + endMethod(DeclarationKind.Class, null, void, (, null, }) endMember() beginMetadataStar(void) endMetadataStar(0) @@ -128,7 +128,7 @@ beginCompilationUnit(class) endThenStatement({, }) endIfStatement(if, null, }) endBlockFunctionBody(1, {, }) - endClassMethod(null, void, (, null, }) + endMethod(DeclarationKind.Class, null, void, (, null, }) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 2, {, }) endClassDeclaration(class, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_15.dart.intertwined.expect b/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_15.dart.intertwined.expect index 62f44f3759f..742d98aa191 100644 --- a/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_15.dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_15.dart.intertwined.expect @@ -109,7 +109,7 @@ parseUnit(UnmatchedToken({)) listener: endIfStatement(if, null, }) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(1, {, }) - listener: endClassMethod(null, void, (, null, }) + listener: endMethod(DeclarationKind.Class, null, void, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, void) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Foo) @@ -286,7 +286,7 @@ parseUnit(UnmatchedToken({)) listener: endIfStatement(if, null, }) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(1, {, }) - listener: endClassMethod(null, void, (, null, }) + listener: endMethod(DeclarationKind.Class, null, void, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 2, {, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_15.dart.outline.expect b/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_15.dart.outline.expect index 96af17b0795..f467bf3630d 100644 --- a/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_15.dart.outline.expect +++ b/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_15.dart.outline.expect @@ -1,5 +1,5 @@ Class: Foo -Class method: Foo.foo_method1 -Class method: Foo.foo_method2 +Method: Foo.foo_method1 +Method: Foo.foo_method2 Top-level method: toplevel_method1 Top-level method: toplevel_method2 diff --git a/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_string_interpolation_1.dart.expect b/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_string_interpolation_1.dart.expect index 1a3c704e7d8..d5939176aa5 100644 --- a/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_string_interpolation_1.dart.expect +++ b/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_string_interpolation_1.dart.expect @@ -35,7 +35,7 @@ beginCompilationUnit(class) handleAsyncModifier(null, null) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) - endClassMethod(null, method1, (, null, }) + endMethod(DeclarationKind.Class, null, method1, (, null, }) endMember() beginMetadataStar(method2) endMetadataStar(0) @@ -50,7 +50,7 @@ beginCompilationUnit(class) handleAsyncModifier(null, null) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) - endClassMethod(null, method2, (, null, }) + endMethod(DeclarationKind.Class, null, method2, (, null, }) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 2, {, }) endClassDeclaration(class, }) @@ -105,7 +105,7 @@ beginCompilationUnit(class) handleSend(print, )) handleExpressionStatement(print, ;) endBlockFunctionBody(1, {, }) - endClassMethod(null, method1, (, null, }) + endMethod(DeclarationKind.Class, null, method1, (, null, }) endMember() beginMetadataStar(method2) endMetadataStar(0) @@ -120,7 +120,7 @@ beginCompilationUnit(class) handleAsyncModifier(null, null) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) - endClassMethod(null, method2, (, null, }) + endMethod(DeclarationKind.Class, null, method2, (, null, }) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 2, {, }) endClassDeclaration(class, }) @@ -151,7 +151,7 @@ beginCompilationUnit(class) handleAsyncModifier(null, null) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) - endClassMethod(null, method1, (, null, }) + endMethod(DeclarationKind.Class, null, method1, (, null, }) endMember() beginMetadataStar(method2) endMetadataStar(0) @@ -166,7 +166,7 @@ beginCompilationUnit(class) handleAsyncModifier(null, null) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) - endClassMethod(null, method2, (, null, }) + endMethod(DeclarationKind.Class, null, method2, (, null, }) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 2, {, }) endClassDeclaration(class, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_string_interpolation_1.dart.intertwined.expect b/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_string_interpolation_1.dart.intertwined.expect index f50855b9fda..cb8f39b9917 100644 --- a/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_string_interpolation_1.dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_string_interpolation_1.dart.intertwined.expect @@ -57,7 +57,7 @@ parseUnit(UnmatchedToken(${)) listener: beginBlockFunctionBody({) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(0, {, }) - listener: endClassMethod(null, method1, (, null, }) + listener: endMethod(DeclarationKind.Class, null, method1, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, method2) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, A) @@ -89,7 +89,7 @@ parseUnit(UnmatchedToken(${)) listener: beginBlockFunctionBody({) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(0, {, }) - listener: endClassMethod(null, method2, (, null, }) + listener: endMethod(DeclarationKind.Class, null, method2, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 2, {, }) @@ -219,7 +219,7 @@ parseUnit(UnmatchedToken(${)) listener: handleExpressionStatement(print, ;) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(1, {, }) - listener: endClassMethod(null, method1, (, null, }) + listener: endMethod(DeclarationKind.Class, null, method1, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, method2) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, B) @@ -251,7 +251,7 @@ parseUnit(UnmatchedToken(${)) listener: beginBlockFunctionBody({) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(0, {, }) - listener: endClassMethod(null, method2, (, null, }) + listener: endMethod(DeclarationKind.Class, null, method2, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 2, {, }) @@ -312,7 +312,7 @@ parseUnit(UnmatchedToken(${)) listener: beginBlockFunctionBody({) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(0, {, }) - listener: endClassMethod(null, method1, (, null, }) + listener: endMethod(DeclarationKind.Class, null, method1, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, method2) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, C) @@ -344,7 +344,7 @@ parseUnit(UnmatchedToken(${)) listener: beginBlockFunctionBody({) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(0, {, }) - listener: endClassMethod(null, method2, (, null, }) + listener: endMethod(DeclarationKind.Class, null, method2, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 2, {, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_string_interpolation_1.dart.outline.expect b/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_string_interpolation_1.dart.outline.expect index b45256acb15..b9091d3e5a0 100644 --- a/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_string_interpolation_1.dart.outline.expect +++ b/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_string_interpolation_1.dart.outline.expect @@ -1,9 +1,9 @@ Class: A -Class method: A.method1 -Class method: A.method2 +Method: A.method1 +Method: A.method2 Class: B -Class method: B.method1 -Class method: B.method2 +Method: B.method1 +Method: B.method2 Class: C -Class method: C.method1 -Class method: C.method2 +Method: C.method1 +Method: C.method2 diff --git a/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_string_interpolation_2.dart.expect b/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_string_interpolation_2.dart.expect index e19d38835dd..55c9568f686 100644 --- a/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_string_interpolation_2.dart.expect +++ b/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_string_interpolation_2.dart.expect @@ -67,7 +67,7 @@ beginCompilationUnit(class) handleAsyncModifier(null, null) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) - endClassMethod(null, method1, (, null, }) + endMethod(DeclarationKind.Class, null, method1, (, null, }) endMember() beginMetadataStar(method2) endMetadataStar(0) @@ -82,7 +82,7 @@ beginCompilationUnit(class) handleAsyncModifier(null, null) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) - endClassMethod(null, method2, (, null, }) + endMethod(DeclarationKind.Class, null, method2, (, null, }) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 2, {, }) endClassDeclaration(class, }) @@ -156,7 +156,7 @@ beginCompilationUnit(class) handleRecoverableError(Message[Template(ExpectedAfterButGot), Expected ';' after this., null, {string: ;}], ");", ");") handleExpressionStatement(print, ;) endBlockFunctionBody(1, {, }) - endClassMethod(null, method1, (, null, }) + endMethod(DeclarationKind.Class, null, method1, (, null, }) endMember() beginMetadataStar(method2) endMetadataStar(0) @@ -171,7 +171,7 @@ beginCompilationUnit(class) handleAsyncModifier(null, null) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) - endClassMethod(null, method2, (, null, }) + endMethod(DeclarationKind.Class, null, method2, (, null, }) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 2, {, }) endClassDeclaration(class, }) @@ -202,7 +202,7 @@ beginCompilationUnit(class) handleAsyncModifier(null, null) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) - endClassMethod(null, method1, (, null, }) + endMethod(DeclarationKind.Class, null, method1, (, null, }) endMember() beginMetadataStar(method2) endMetadataStar(0) @@ -217,7 +217,7 @@ beginCompilationUnit(class) handleAsyncModifier(null, null) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) - endClassMethod(null, method2, (, null, }) + endMethod(DeclarationKind.Class, null, method2, (, null, }) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 2, {, }) endClassDeclaration(class, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_string_interpolation_2.dart.intertwined.expect b/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_string_interpolation_2.dart.intertwined.expect index fe4448a391d..51dddb2c447 100644 --- a/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_string_interpolation_2.dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_string_interpolation_2.dart.intertwined.expect @@ -57,7 +57,7 @@ parseUnit(UnmatchedToken(${)) listener: beginBlockFunctionBody({) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(0, {, }) - listener: endClassMethod(null, method1, (, null, }) + listener: endMethod(DeclarationKind.Class, null, method1, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, method2) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, A) @@ -89,7 +89,7 @@ parseUnit(UnmatchedToken(${)) listener: beginBlockFunctionBody({) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(0, {, }) - listener: endClassMethod(null, method2, (, null, }) + listener: endMethod(DeclarationKind.Class, null, method2, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 2, {, }) @@ -289,7 +289,7 @@ parseUnit(UnmatchedToken(${)) listener: handleExpressionStatement(print, ;) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(1, {, }) - listener: endClassMethod(null, method1, (, null, }) + listener: endMethod(DeclarationKind.Class, null, method1, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, method2) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, B) @@ -321,7 +321,7 @@ parseUnit(UnmatchedToken(${)) listener: beginBlockFunctionBody({) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(0, {, }) - listener: endClassMethod(null, method2, (, null, }) + listener: endMethod(DeclarationKind.Class, null, method2, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 2, {, }) @@ -382,7 +382,7 @@ parseUnit(UnmatchedToken(${)) listener: beginBlockFunctionBody({) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(0, {, }) - listener: endClassMethod(null, method1, (, null, }) + listener: endMethod(DeclarationKind.Class, null, method1, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, method2) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, C) @@ -414,7 +414,7 @@ parseUnit(UnmatchedToken(${)) listener: beginBlockFunctionBody({) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(0, {, }) - listener: endClassMethod(null, method2, (, null, }) + listener: endMethod(DeclarationKind.Class, null, method2, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 2, {, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_string_interpolation_2.dart.outline.expect b/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_string_interpolation_2.dart.outline.expect index b45256acb15..b9091d3e5a0 100644 --- a/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_string_interpolation_2.dart.outline.expect +++ b/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_string_interpolation_2.dart.outline.expect @@ -1,9 +1,9 @@ Class: A -Class method: A.method1 -Class method: A.method2 +Method: A.method1 +Method: A.method2 Class: B -Class method: B.method1 -Class method: B.method2 +Method: B.method1 +Method: B.method2 Class: C -Class method: C.method1 -Class method: C.method2 +Method: C.method1 +Method: C.method2 diff --git a/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_string_missing_end_quote.dart.expect b/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_string_missing_end_quote.dart.expect index a0461fbf9af..3f9e4965ec1 100644 --- a/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_string_missing_end_quote.dart.expect +++ b/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_string_missing_end_quote.dart.expect @@ -39,7 +39,7 @@ beginCompilationUnit(class) handleAsyncModifier(null, null) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) - endClassMethod(null, method1, (, null, }) + endMethod(DeclarationKind.Class, null, method1, (, null, }) endMember() beginMetadataStar(method2) endMetadataStar(0) @@ -54,7 +54,7 @@ beginCompilationUnit(class) handleAsyncModifier(null, null) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) - endClassMethod(null, method2, (, null, }) + endMethod(DeclarationKind.Class, null, method2, (, null, }) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 2, {, }) endClassDeclaration(class, }) @@ -103,7 +103,7 @@ beginCompilationUnit(class) handleRecoverableError(Message[Template(ExpectedAfterButGot), Expected ';' after this., null, {string: ;}], "hello world", "hello world") handleExpressionStatement(print, ;) endBlockFunctionBody(1, {, }) - endClassMethod(null, method1, (, null, }) + endMethod(DeclarationKind.Class, null, method1, (, null, }) endMember() beginMetadataStar(method2) endMetadataStar(0) @@ -118,7 +118,7 @@ beginCompilationUnit(class) handleAsyncModifier(null, null) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) - endClassMethod(null, method2, (, null, }) + endMethod(DeclarationKind.Class, null, method2, (, null, }) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 2, {, }) endClassDeclaration(class, }) @@ -149,7 +149,7 @@ beginCompilationUnit(class) handleAsyncModifier(null, null) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) - endClassMethod(null, method1, (, null, }) + endMethod(DeclarationKind.Class, null, method1, (, null, }) endMember() beginMetadataStar(method2) endMetadataStar(0) @@ -164,7 +164,7 @@ beginCompilationUnit(class) handleAsyncModifier(null, null) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) - endClassMethod(null, method2, (, null, }) + endMethod(DeclarationKind.Class, null, method2, (, null, }) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 2, {, }) endClassDeclaration(class, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_string_missing_end_quote.dart.intertwined.expect b/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_string_missing_end_quote.dart.intertwined.expect index b7803f2be09..ae4761d22b7 100644 --- a/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_string_missing_end_quote.dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_string_missing_end_quote.dart.intertwined.expect @@ -57,7 +57,7 @@ parseUnit(UnterminatedString(")) listener: beginBlockFunctionBody({) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(0, {, }) - listener: endClassMethod(null, method1, (, null, }) + listener: endMethod(DeclarationKind.Class, null, method1, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, method2) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, A) @@ -89,7 +89,7 @@ parseUnit(UnterminatedString(")) listener: beginBlockFunctionBody({) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(0, {, }) - listener: endClassMethod(null, method2, (, null, }) + listener: endMethod(DeclarationKind.Class, null, method2, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 2, {, }) @@ -195,7 +195,7 @@ parseUnit(UnterminatedString(")) listener: handleExpressionStatement(print, ;) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(1, {, }) - listener: endClassMethod(null, method1, (, null, }) + listener: endMethod(DeclarationKind.Class, null, method1, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, method2) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, B) @@ -227,7 +227,7 @@ parseUnit(UnterminatedString(")) listener: beginBlockFunctionBody({) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(0, {, }) - listener: endClassMethod(null, method2, (, null, }) + listener: endMethod(DeclarationKind.Class, null, method2, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 2, {, }) @@ -288,7 +288,7 @@ parseUnit(UnterminatedString(")) listener: beginBlockFunctionBody({) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(0, {, }) - listener: endClassMethod(null, method1, (, null, }) + listener: endMethod(DeclarationKind.Class, null, method1, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, method2) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, C) @@ -320,7 +320,7 @@ parseUnit(UnterminatedString(")) listener: beginBlockFunctionBody({) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(0, {, }) - listener: endClassMethod(null, method2, (, null, }) + listener: endMethod(DeclarationKind.Class, null, method2, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 2, {, }) diff --git a/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_string_missing_end_quote.dart.outline.expect b/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_string_missing_end_quote.dart.outline.expect index b45256acb15..b9091d3e5a0 100644 --- a/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_string_missing_end_quote.dart.outline.expect +++ b/pkg/front_end/parser_testcases/error_recovery/with_outline/typing_string_missing_end_quote.dart.outline.expect @@ -1,9 +1,9 @@ Class: A -Class method: A.method1 -Class method: A.method2 +Method: A.method1 +Method: A.method2 Class: B -Class method: B.method1 -Class method: B.method2 +Method: B.method1 +Method: B.method2 Class: C -Class method: C.method1 -Class method: C.method2 +Method: C.method1 +Method: C.method2 diff --git a/pkg/front_end/parser_testcases/extension_named_type.dart.expect b/pkg/front_end/parser_testcases/extension_named_type.dart.expect index 1d39bbb4d9f..be4bcf8b138 100644 --- a/pkg/front_end/parser_testcases/extension_named_type.dart.expect +++ b/pkg/front_end/parser_testcases/extension_named_type.dart.expect @@ -53,7 +53,7 @@ beginCompilationUnit(class) handleAsyncModifier(null, null) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) - endExtensionTypeMethod(null, method, (, null, }) + endMethod(DeclarationKind.ExtensionType, null, method, (, null, }) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.ExtensionType, 1, {, }) endExtensionTypeDeclaration(extension, null, extension, type, }) diff --git a/pkg/front_end/parser_testcases/extension_named_type.dart.intertwined.expect b/pkg/front_end/parser_testcases/extension_named_type.dart.intertwined.expect index f27151fe10d..11320ccb55e 100644 --- a/pkg/front_end/parser_testcases/extension_named_type.dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/extension_named_type.dart.intertwined.expect @@ -94,7 +94,7 @@ parseUnit(class) listener: beginBlockFunctionBody({) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(0, {, }) - listener: endExtensionTypeMethod(null, method, (, null, }) + listener: endMethod(DeclarationKind.ExtensionType, null, method, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.ExtensionType, 1, {, }) diff --git a/pkg/front_end/parser_testcases/extensions/covariant.dart.expect b/pkg/front_end/parser_testcases/extensions/covariant.dart.expect index 8b4e07c0bd3..7005a48ebef 100644 --- a/pkg/front_end/parser_testcases/extensions/covariant.dart.expect +++ b/pkg/front_end/parser_testcases/extensions/covariant.dart.expect @@ -71,7 +71,7 @@ beginCompilationUnit(class) handleAsyncModifier(null, null) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) - endExtensionMethod(null, addChild, (, null, }) + endMethod(DeclarationKind.Extension, null, addChild, (, null, }) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Extension, 1, {, }) endExtensionDeclaration(extension, extension, on, }) diff --git a/pkg/front_end/parser_testcases/extensions/covariant.dart.intertwined.expect b/pkg/front_end/parser_testcases/extensions/covariant.dart.intertwined.expect index cb7902114ba..cf2f9001632 100644 --- a/pkg/front_end/parser_testcases/extensions/covariant.dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/extensions/covariant.dart.intertwined.expect @@ -122,7 +122,7 @@ parseUnit(class) listener: beginBlockFunctionBody({) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(0, {, }) - listener: endExtensionMethod(null, addChild, (, null, }) + listener: endMethod(DeclarationKind.Extension, null, addChild, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Extension, 1, {, }) diff --git a/pkg/front_end/parser_testcases/extensions/not_covariant.dart.expect b/pkg/front_end/parser_testcases/extensions/not_covariant.dart.expect index 7bb84383d2b..ef856233a45 100644 --- a/pkg/front_end/parser_testcases/extensions/not_covariant.dart.expect +++ b/pkg/front_end/parser_testcases/extensions/not_covariant.dart.expect @@ -64,7 +64,7 @@ beginCompilationUnit(class) handleAsyncModifier(null, null) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) - endExtensionMethod(null, addChild, (, null, }) + endMethod(DeclarationKind.Extension, null, addChild, (, null, }) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Extension, 1, {, }) endExtensionDeclaration(extension, extension, on, }) diff --git a/pkg/front_end/parser_testcases/extensions/not_covariant.dart.intertwined.expect b/pkg/front_end/parser_testcases/extensions/not_covariant.dart.intertwined.expect index c6c116cbf8c..6590cd40737 100644 --- a/pkg/front_end/parser_testcases/extensions/not_covariant.dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/extensions/not_covariant.dart.intertwined.expect @@ -120,7 +120,7 @@ parseUnit(class) listener: beginBlockFunctionBody({) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(0, {, }) - listener: endExtensionMethod(null, addChild, (, null, }) + listener: endMethod(DeclarationKind.Extension, null, addChild, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Extension, 1, {, }) diff --git a/pkg/front_end/parser_testcases/extensions/static.dart.expect b/pkg/front_end/parser_testcases/extensions/static.dart.expect index fa3aa3db72e..5898ccaa882 100644 --- a/pkg/front_end/parser_testcases/extensions/static.dart.expect +++ b/pkg/front_end/parser_testcases/extensions/static.dart.expect @@ -64,7 +64,7 @@ beginCompilationUnit(class) handleAsyncModifier(null, null) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) - endExtensionMethod(null, static, (, null, }) + endMethod(DeclarationKind.Extension, null, static, (, null, }) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Extension, 1, {, }) endExtensionDeclaration(extension, extension, on, }) diff --git a/pkg/front_end/parser_testcases/extensions/static.dart.intertwined.expect b/pkg/front_end/parser_testcases/extensions/static.dart.intertwined.expect index 9db940ded41..98ce47bc564 100644 --- a/pkg/front_end/parser_testcases/extensions/static.dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/extensions/static.dart.intertwined.expect @@ -119,7 +119,7 @@ parseUnit(class) listener: beginBlockFunctionBody({) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(0, {, }) - listener: endExtensionMethod(null, static, (, null, }) + listener: endMethod(DeclarationKind.Extension, null, static, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Extension, 1, {, }) diff --git a/pkg/front_end/parser_testcases/extensions/static_covariant.dart.expect b/pkg/front_end/parser_testcases/extensions/static_covariant.dart.expect index 92263392acf..27dbae87789 100644 --- a/pkg/front_end/parser_testcases/extensions/static_covariant.dart.expect +++ b/pkg/front_end/parser_testcases/extensions/static_covariant.dart.expect @@ -71,7 +71,7 @@ beginCompilationUnit(class) handleAsyncModifier(null, null) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) - endExtensionMethod(null, static, (, null, }) + endMethod(DeclarationKind.Extension, null, static, (, null, }) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Extension, 1, {, }) endExtensionDeclaration(extension, extension, on, }) diff --git a/pkg/front_end/parser_testcases/extensions/static_covariant.dart.intertwined.expect b/pkg/front_end/parser_testcases/extensions/static_covariant.dart.intertwined.expect index a917b9f8092..c43ea4500d1 100644 --- a/pkg/front_end/parser_testcases/extensions/static_covariant.dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/extensions/static_covariant.dart.intertwined.expect @@ -121,7 +121,7 @@ parseUnit(class) listener: beginBlockFunctionBody({) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(0, {, }) - listener: endExtensionMethod(null, static, (, null, }) + listener: endMethod(DeclarationKind.Extension, null, static, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Extension, 1, {, }) diff --git a/pkg/front_end/parser_testcases/general/augment_super.dart.expect b/pkg/front_end/parser_testcases/general/augment_super.dart.expect index 37fced9e47b..9eea16c38cb 100644 --- a/pkg/front_end/parser_testcases/general/augment_super.dart.expect +++ b/pkg/front_end/parser_testcases/general/augment_super.dart.expect @@ -490,7 +490,7 @@ beginCompilationUnit(augment) handleIdentifier(augment, fieldDeclaration) handleNoFieldInitializer(void) handleRecoverableError(Message[Template(ExpectedAfterButGot), Expected ';' after this., null, {string: ;}], augment, augment) - endClassFields(null, null, null, null, null, null, null, 1, augment, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, augment, ;) endMember() beginMetadataStar(void) endMetadataStar(0) @@ -521,7 +521,7 @@ beginCompilationUnit(augment) endRecordLiteral((, 0, null) handleExpressionStatement((, ;) endBlockFunctionBody(2, {, }) - endClassMethod(null, void, (, null, }) + endMethod(DeclarationKind.Class, null, void, (, null, }) endMember() beginMetadataStar(augment) endMetadataStar(0) @@ -532,7 +532,7 @@ beginCompilationUnit(augment) handleIdentifier(augment, fieldDeclaration) handleNoFieldInitializer(void) handleRecoverableError(Message[Template(ExpectedAfterButGot), Expected ';' after this., null, {string: ;}], augment, augment) - endClassFields(null, null, null, null, null, null, null, 1, augment, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, augment, ;) endMember() beginMetadataStar(void) endMetadataStar(0) @@ -569,7 +569,7 @@ beginCompilationUnit(augment) handleSend(augment, augment) handleExpressionStatement(augment, ;) endBlockFunctionBody(3, {, }) - endClassMethod(null, void, (, null, }) + endMethod(DeclarationKind.Class, null, void, (, null, }) endMember() beginMetadataStar(augment) endMetadataStar(0) @@ -581,7 +581,7 @@ beginCompilationUnit(augment) handleIdentifier(int, fieldDeclaration) handleNoFieldInitializer(get) handleRecoverableError(Message[Template(ExpectedAfterButGot), Expected ';' after this., null, {string: ;}], int, int) - endClassFields(null, null, null, null, null, null, null, 1, augment, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, augment, ;) endMember() beginMetadataStar(get) endMetadataStar(0) @@ -634,7 +634,7 @@ beginCompilationUnit(augment) handleSuperExpression(super, expression) handleExpressionStatement(super, ;) endBlockFunctionBody(6, {, }) - endClassMethod(get, get, {, null, }) + endMethod(DeclarationKind.Class, get, get, {, null, }) endMember() beginMetadataStar(augment) endMetadataStar(0) @@ -645,7 +645,7 @@ beginCompilationUnit(augment) handleIdentifier(augment, fieldDeclaration) handleNoFieldInitializer(void) handleRecoverableError(Message[Template(ExpectedAfterButGot), Expected ';' after this., null, {string: ;}], augment, augment) - endClassFields(null, null, null, null, null, null, null, 1, augment, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, augment, ;) endMember() beginMetadataStar(void) endMetadataStar(0) @@ -686,7 +686,7 @@ beginCompilationUnit(augment) endInitializedIdentifier(super) endVariablesDeclaration(1, ;) endBlockFunctionBody(1, {, }) - endClassMethod(set, void, (, null, }) + endMethod(DeclarationKind.Class, set, void, (, null, }) endMember() beginMetadataStar(void) endMetadataStar(0) @@ -751,7 +751,7 @@ beginCompilationUnit(augment) handleSend(augment, augment) handleExpressionStatement(augment, ;) endBlockFunctionBody(6, {, }) - endClassMethod(null, void, (, null, }) + endMethod(DeclarationKind.Class, null, void, (, null, }) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 9, {, }) endClassDeclaration(class, }) diff --git a/pkg/front_end/parser_testcases/general/augment_super.dart.intertwined.expect b/pkg/front_end/parser_testcases/general/augment_super.dart.intertwined.expect index f5ff7510feb..7fdd39adc43 100644 --- a/pkg/front_end/parser_testcases/general/augment_super.dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/general/augment_super.dart.intertwined.expect @@ -744,7 +744,7 @@ parseUnit(augment) reportRecoverableError(augment, Message[Template(ExpectedAfterButGot), Expected ';' after this., null, {string: ;}]) listener: handleRecoverableError(Message[Template(ExpectedAfterButGot), Expected ';' after this., null, {string: ;}], augment, augment) rewriter() - listener: endClassFields(null, null, null, null, null, null, null, 1, augment, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, augment, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, void) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Class) @@ -819,7 +819,7 @@ parseUnit(augment) listener: handleExpressionStatement((, ;) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(2, {, }) - listener: endClassMethod(null, void, (, null, }) + listener: endMethod(DeclarationKind.Class, null, void, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, augment) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Class) @@ -842,7 +842,7 @@ parseUnit(augment) reportRecoverableError(augment, Message[Template(ExpectedAfterButGot), Expected ';' after this., null, {string: ;}]) listener: handleRecoverableError(Message[Template(ExpectedAfterButGot), Expected ';' after this., null, {string: ;}], augment, augment) rewriter() - listener: endClassFields(null, null, null, null, null, null, null, 1, augment, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, augment, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, void) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Class) @@ -937,7 +937,7 @@ parseUnit(augment) listener: handleExpressionStatement(augment, ;) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(3, {, }) - listener: endClassMethod(null, void, (, null, }) + listener: endMethod(DeclarationKind.Class, null, void, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, augment) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Class) @@ -958,7 +958,7 @@ parseUnit(augment) reportRecoverableError(int, Message[Template(ExpectedAfterButGot), Expected ';' after this., null, {string: ;}]) listener: handleRecoverableError(Message[Template(ExpectedAfterButGot), Expected ';' after this., null, {string: ;}], int, int) rewriter() - listener: endClassFields(null, null, null, null, null, null, null, 1, augment, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, augment, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, get) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Class) @@ -1121,7 +1121,7 @@ parseUnit(augment) listener: handleExpressionStatement(super, ;) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(6, {, }) - listener: endClassMethod(get, get, {, null, }) + listener: endMethod(DeclarationKind.Class, get, get, {, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, augment) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Class) @@ -1144,7 +1144,7 @@ parseUnit(augment) reportRecoverableError(augment, Message[Template(ExpectedAfterButGot), Expected ';' after this., null, {string: ;}]) listener: handleRecoverableError(Message[Template(ExpectedAfterButGot), Expected ';' after this., null, {string: ;}], augment, augment) rewriter() - listener: endClassFields(null, null, null, null, null, null, null, 1, augment, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, augment, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, void) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Class) @@ -1223,7 +1223,7 @@ parseUnit(augment) listener: endVariablesDeclaration(1, ;) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(1, {, }) - listener: endClassMethod(set, void, (, null, }) + listener: endMethod(DeclarationKind.Class, set, void, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, void) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Class) @@ -1385,7 +1385,7 @@ parseUnit(augment) listener: handleExpressionStatement(augment, ;) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(6, {, }) - listener: endClassMethod(null, void, (, null, }) + listener: endMethod(DeclarationKind.Class, null, void, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 9, {, }) diff --git a/pkg/front_end/parser_testcases/general/augment_super_2.dart.expect b/pkg/front_end/parser_testcases/general/augment_super_2.dart.expect index 91d001dd1d5..6f6e56c9898 100644 --- a/pkg/front_end/parser_testcases/general/augment_super_2.dart.expect +++ b/pkg/front_end/parser_testcases/general/augment_super_2.dart.expect @@ -496,7 +496,7 @@ beginCompilationUnit(augment) handleIdentifier(augment, fieldDeclaration) handleNoFieldInitializer(void) handleRecoverableError(Message[Template(ExpectedAfterButGot), Expected ';' after this., null, {string: ;}], augment, augment) - endClassFields(null, null, null, null, null, null, null, 1, augment, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, augment, ;) endMember() beginMetadataStar(void) endMetadataStar(0) @@ -527,7 +527,7 @@ beginCompilationUnit(augment) endRecordLiteral((, 0, null) handleExpressionStatement((, ;) endBlockFunctionBody(2, {, }) - endClassMethod(null, void, (, null, }) + endMethod(DeclarationKind.Class, null, void, (, null, }) endMember() beginMetadataStar(augment) endMetadataStar(0) @@ -538,7 +538,7 @@ beginCompilationUnit(augment) handleIdentifier(augment, fieldDeclaration) handleNoFieldInitializer(void) handleRecoverableError(Message[Template(ExpectedAfterButGot), Expected ';' after this., null, {string: ;}], augment, augment) - endClassFields(null, null, null, null, null, null, null, 1, augment, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, augment, ;) endMember() beginMetadataStar(void) endMetadataStar(0) @@ -575,7 +575,7 @@ beginCompilationUnit(augment) handleSend(augment, augment) handleExpressionStatement(augment, ;) endBlockFunctionBody(3, {, }) - endClassMethod(null, void, (, null, }) + endMethod(DeclarationKind.Class, null, void, (, null, }) endMember() beginMetadataStar(augment) endMetadataStar(0) @@ -587,7 +587,7 @@ beginCompilationUnit(augment) handleIdentifier(int, fieldDeclaration) handleNoFieldInitializer(get) handleRecoverableError(Message[Template(ExpectedAfterButGot), Expected ';' after this., null, {string: ;}], int, int) - endClassFields(null, null, null, null, null, null, null, 1, augment, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, augment, ;) endMember() beginMetadataStar(get) endMetadataStar(0) @@ -640,7 +640,7 @@ beginCompilationUnit(augment) handleSuperExpression(super, expression) handleExpressionStatement(super, ;) endBlockFunctionBody(6, {, }) - endClassMethod(get, get, {, null, }) + endMethod(DeclarationKind.Class, get, get, {, null, }) endMember() beginMetadataStar(augment) endMetadataStar(0) @@ -651,7 +651,7 @@ beginCompilationUnit(augment) handleIdentifier(augment, fieldDeclaration) handleNoFieldInitializer(void) handleRecoverableError(Message[Template(ExpectedAfterButGot), Expected ';' after this., null, {string: ;}], augment, augment) - endClassFields(null, null, null, null, null, null, null, 1, augment, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, augment, ;) endMember() beginMetadataStar(void) endMetadataStar(0) @@ -692,7 +692,7 @@ beginCompilationUnit(augment) endInitializedIdentifier(super) endVariablesDeclaration(1, ;) endBlockFunctionBody(1, {, }) - endClassMethod(set, void, (, null, }) + endMethod(DeclarationKind.Class, set, void, (, null, }) endMember() beginMetadataStar(void) endMetadataStar(0) @@ -757,7 +757,7 @@ beginCompilationUnit(augment) handleSend(augment, augment) handleExpressionStatement(augment, ;) endBlockFunctionBody(6, {, }) - endClassMethod(null, void, (, null, }) + endMethod(DeclarationKind.Class, null, void, (, null, }) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 9, {, }) endClassDeclaration(class, }) diff --git a/pkg/front_end/parser_testcases/general/augment_super_2.dart.intertwined.expect b/pkg/front_end/parser_testcases/general/augment_super_2.dart.intertwined.expect index 2e263dab9fc..e5651113e08 100644 --- a/pkg/front_end/parser_testcases/general/augment_super_2.dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/general/augment_super_2.dart.intertwined.expect @@ -792,7 +792,7 @@ parseUnit(augment) reportRecoverableError(augment, Message[Template(ExpectedAfterButGot), Expected ';' after this., null, {string: ;}]) listener: handleRecoverableError(Message[Template(ExpectedAfterButGot), Expected ';' after this., null, {string: ;}], augment, augment) rewriter() - listener: endClassFields(null, null, null, null, null, null, null, 1, augment, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, augment, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, void) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Class) @@ -869,7 +869,7 @@ parseUnit(augment) listener: handleExpressionStatement((, ;) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(2, {, }) - listener: endClassMethod(null, void, (, null, }) + listener: endMethod(DeclarationKind.Class, null, void, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, augment) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Class) @@ -892,7 +892,7 @@ parseUnit(augment) reportRecoverableError(augment, Message[Template(ExpectedAfterButGot), Expected ';' after this., null, {string: ;}]) listener: handleRecoverableError(Message[Template(ExpectedAfterButGot), Expected ';' after this., null, {string: ;}], augment, augment) rewriter() - listener: endClassFields(null, null, null, null, null, null, null, 1, augment, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, augment, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, void) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Class) @@ -993,7 +993,7 @@ parseUnit(augment) listener: handleExpressionStatement(augment, ;) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(3, {, }) - listener: endClassMethod(null, void, (, null, }) + listener: endMethod(DeclarationKind.Class, null, void, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, augment) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Class) @@ -1014,7 +1014,7 @@ parseUnit(augment) reportRecoverableError(int, Message[Template(ExpectedAfterButGot), Expected ';' after this., null, {string: ;}]) listener: handleRecoverableError(Message[Template(ExpectedAfterButGot), Expected ';' after this., null, {string: ;}], int, int) rewriter() - listener: endClassFields(null, null, null, null, null, null, null, 1, augment, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, augment, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, get) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Class) @@ -1187,7 +1187,7 @@ parseUnit(augment) listener: handleExpressionStatement(super, ;) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(6, {, }) - listener: endClassMethod(get, get, {, null, }) + listener: endMethod(DeclarationKind.Class, get, get, {, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, augment) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Class) @@ -1210,7 +1210,7 @@ parseUnit(augment) reportRecoverableError(augment, Message[Template(ExpectedAfterButGot), Expected ';' after this., null, {string: ;}]) listener: handleRecoverableError(Message[Template(ExpectedAfterButGot), Expected ';' after this., null, {string: ;}], augment, augment) rewriter() - listener: endClassFields(null, null, null, null, null, null, null, 1, augment, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, augment, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, void) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Class) @@ -1292,7 +1292,7 @@ parseUnit(augment) listener: endVariablesDeclaration(1, ;) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(1, {, }) - listener: endClassMethod(set, void, (, null, }) + listener: endMethod(DeclarationKind.Class, set, void, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, void) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Class) @@ -1462,7 +1462,7 @@ parseUnit(augment) listener: handleExpressionStatement(augment, ;) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(6, {, }) - listener: endClassMethod(null, void, (, null, }) + listener: endMethod(DeclarationKind.Class, null, void, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 9, {, }) diff --git a/pkg/front_end/parser_testcases/general/built_in_identifier_class_fields.dart.expect b/pkg/front_end/parser_testcases/general/built_in_identifier_class_fields.dart.expect index a276dfab4b3..6575537eb6f 100644 --- a/pkg/front_end/parser_testcases/general/built_in_identifier_class_fields.dart.expect +++ b/pkg/front_end/parser_testcases/general/built_in_identifier_class_fields.dart.expect @@ -23,7 +23,7 @@ beginCompilationUnit(class) beginFieldInitializer(=) handleLiteralInt(42) endFieldInitializer(=, 42) - endClassFields(null, null, null, null, null, null, null, 1, int, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -36,7 +36,7 @@ beginCompilationUnit(class) beginFieldInitializer(=) handleLiteralInt(42) endFieldInitializer(=, 42) - endClassFields(null, null, null, null, null, null, null, 1, int, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -49,7 +49,7 @@ beginCompilationUnit(class) beginFieldInitializer(=) handleLiteralInt(42) endFieldInitializer(=, 42) - endClassFields(null, null, null, null, null, null, null, 1, int, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -62,7 +62,7 @@ beginCompilationUnit(class) beginFieldInitializer(=) handleLiteralInt(42) endFieldInitializer(=, 42) - endClassFields(null, null, null, null, null, null, null, 1, int, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -75,7 +75,7 @@ beginCompilationUnit(class) beginFieldInitializer(=) handleLiteralInt(42) endFieldInitializer(=, 42) - endClassFields(null, null, null, null, null, null, null, 1, int, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -88,7 +88,7 @@ beginCompilationUnit(class) beginFieldInitializer(=) handleLiteralInt(42) endFieldInitializer(=, 42) - endClassFields(null, null, null, null, null, null, null, 1, int, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -101,7 +101,7 @@ beginCompilationUnit(class) beginFieldInitializer(=) handleLiteralInt(42) endFieldInitializer(=, 42) - endClassFields(null, null, null, null, null, null, null, 1, int, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -114,7 +114,7 @@ beginCompilationUnit(class) beginFieldInitializer(=) handleLiteralInt(42) endFieldInitializer(=, 42) - endClassFields(null, null, null, null, null, null, null, 1, int, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -127,7 +127,7 @@ beginCompilationUnit(class) beginFieldInitializer(=) handleLiteralInt(42) endFieldInitializer(=, 42) - endClassFields(null, null, null, null, null, null, null, 1, int, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -140,7 +140,7 @@ beginCompilationUnit(class) beginFieldInitializer(=) handleLiteralInt(42) endFieldInitializer(=, 42) - endClassFields(null, null, null, null, null, null, null, 1, int, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -153,7 +153,7 @@ beginCompilationUnit(class) beginFieldInitializer(=) handleLiteralInt(42) endFieldInitializer(=, 42) - endClassFields(null, null, null, null, null, null, null, 1, int, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -166,7 +166,7 @@ beginCompilationUnit(class) beginFieldInitializer(=) handleLiteralInt(42) endFieldInitializer(=, 42) - endClassFields(null, null, null, null, null, null, null, 1, int, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -179,7 +179,7 @@ beginCompilationUnit(class) beginFieldInitializer(=) handleLiteralInt(42) endFieldInitializer(=, 42) - endClassFields(null, null, null, null, null, null, null, 1, int, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -192,7 +192,7 @@ beginCompilationUnit(class) beginFieldInitializer(=) handleLiteralInt(42) endFieldInitializer(=, 42) - endClassFields(null, null, null, null, null, null, null, 1, int, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -205,7 +205,7 @@ beginCompilationUnit(class) beginFieldInitializer(=) handleLiteralInt(42) endFieldInitializer(=, 42) - endClassFields(null, null, null, null, null, null, null, 1, int, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -218,7 +218,7 @@ beginCompilationUnit(class) beginFieldInitializer(=) handleLiteralInt(42) endFieldInitializer(=, 42) - endClassFields(null, null, null, null, null, null, null, 1, int, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -231,7 +231,7 @@ beginCompilationUnit(class) beginFieldInitializer(=) handleLiteralInt(42) endFieldInitializer(=, 42) - endClassFields(null, null, null, null, null, null, null, 1, int, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -244,7 +244,7 @@ beginCompilationUnit(class) beginFieldInitializer(=) handleLiteralInt(42) endFieldInitializer(=, 42) - endClassFields(null, null, null, null, null, null, null, 1, int, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -257,7 +257,7 @@ beginCompilationUnit(class) beginFieldInitializer(=) handleLiteralInt(42) endFieldInitializer(=, 42) - endClassFields(null, null, null, null, null, null, null, 1, int, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -270,7 +270,7 @@ beginCompilationUnit(class) beginFieldInitializer(=) handleLiteralInt(42) endFieldInitializer(=, 42) - endClassFields(null, null, null, null, null, null, null, 1, int, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 20, {, }) endClassDeclaration(class, }) diff --git a/pkg/front_end/parser_testcases/general/built_in_identifier_class_fields.dart.intertwined.expect b/pkg/front_end/parser_testcases/general/built_in_identifier_class_fields.dart.intertwined.expect index 4dc9b7f4a72..1ac672dd112 100644 --- a/pkg/front_end/parser_testcases/general/built_in_identifier_class_fields.dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/general/built_in_identifier_class_fields.dart.intertwined.expect @@ -51,7 +51,7 @@ parseUnit(class) parseLiteralInt(=) listener: handleLiteralInt(42) listener: endFieldInitializer(=, 42) - listener: endClassFields(null, null, null, null, null, null, null, 1, int, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, WrapperClass) @@ -77,7 +77,7 @@ parseUnit(class) parseLiteralInt(=) listener: handleLiteralInt(42) listener: endFieldInitializer(=, 42) - listener: endClassFields(null, null, null, null, null, null, null, 1, int, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, WrapperClass) @@ -103,7 +103,7 @@ parseUnit(class) parseLiteralInt(=) listener: handleLiteralInt(42) listener: endFieldInitializer(=, 42) - listener: endClassFields(null, null, null, null, null, null, null, 1, int, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, WrapperClass) @@ -129,7 +129,7 @@ parseUnit(class) parseLiteralInt(=) listener: handleLiteralInt(42) listener: endFieldInitializer(=, 42) - listener: endClassFields(null, null, null, null, null, null, null, 1, int, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, WrapperClass) @@ -155,7 +155,7 @@ parseUnit(class) parseLiteralInt(=) listener: handleLiteralInt(42) listener: endFieldInitializer(=, 42) - listener: endClassFields(null, null, null, null, null, null, null, 1, int, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, WrapperClass) @@ -181,7 +181,7 @@ parseUnit(class) parseLiteralInt(=) listener: handleLiteralInt(42) listener: endFieldInitializer(=, 42) - listener: endClassFields(null, null, null, null, null, null, null, 1, int, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, WrapperClass) @@ -207,7 +207,7 @@ parseUnit(class) parseLiteralInt(=) listener: handleLiteralInt(42) listener: endFieldInitializer(=, 42) - listener: endClassFields(null, null, null, null, null, null, null, 1, int, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, WrapperClass) @@ -233,7 +233,7 @@ parseUnit(class) parseLiteralInt(=) listener: handleLiteralInt(42) listener: endFieldInitializer(=, 42) - listener: endClassFields(null, null, null, null, null, null, null, 1, int, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, WrapperClass) @@ -259,7 +259,7 @@ parseUnit(class) parseLiteralInt(=) listener: handleLiteralInt(42) listener: endFieldInitializer(=, 42) - listener: endClassFields(null, null, null, null, null, null, null, 1, int, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, WrapperClass) @@ -286,7 +286,7 @@ parseUnit(class) parseLiteralInt(=) listener: handleLiteralInt(42) listener: endFieldInitializer(=, 42) - listener: endClassFields(null, null, null, null, null, null, null, 1, int, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, WrapperClass) @@ -312,7 +312,7 @@ parseUnit(class) parseLiteralInt(=) listener: handleLiteralInt(42) listener: endFieldInitializer(=, 42) - listener: endClassFields(null, null, null, null, null, null, null, 1, int, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, WrapperClass) @@ -338,7 +338,7 @@ parseUnit(class) parseLiteralInt(=) listener: handleLiteralInt(42) listener: endFieldInitializer(=, 42) - listener: endClassFields(null, null, null, null, null, null, null, 1, int, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, WrapperClass) @@ -364,7 +364,7 @@ parseUnit(class) parseLiteralInt(=) listener: handleLiteralInt(42) listener: endFieldInitializer(=, 42) - listener: endClassFields(null, null, null, null, null, null, null, 1, int, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, WrapperClass) @@ -390,7 +390,7 @@ parseUnit(class) parseLiteralInt(=) listener: handleLiteralInt(42) listener: endFieldInitializer(=, 42) - listener: endClassFields(null, null, null, null, null, null, null, 1, int, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, WrapperClass) @@ -417,7 +417,7 @@ parseUnit(class) parseLiteralInt(=) listener: handleLiteralInt(42) listener: endFieldInitializer(=, 42) - listener: endClassFields(null, null, null, null, null, null, null, 1, int, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, WrapperClass) @@ -443,7 +443,7 @@ parseUnit(class) parseLiteralInt(=) listener: handleLiteralInt(42) listener: endFieldInitializer(=, 42) - listener: endClassFields(null, null, null, null, null, null, null, 1, int, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, WrapperClass) @@ -469,7 +469,7 @@ parseUnit(class) parseLiteralInt(=) listener: handleLiteralInt(42) listener: endFieldInitializer(=, 42) - listener: endClassFields(null, null, null, null, null, null, null, 1, int, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, WrapperClass) @@ -496,7 +496,7 @@ parseUnit(class) parseLiteralInt(=) listener: handleLiteralInt(42) listener: endFieldInitializer(=, 42) - listener: endClassFields(null, null, null, null, null, null, null, 1, int, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, WrapperClass) @@ -522,7 +522,7 @@ parseUnit(class) parseLiteralInt(=) listener: handleLiteralInt(42) listener: endFieldInitializer(=, 42) - listener: endClassFields(null, null, null, null, null, null, null, 1, int, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, WrapperClass) @@ -548,7 +548,7 @@ parseUnit(class) parseLiteralInt(=) listener: handleLiteralInt(42) listener: endFieldInitializer(=, 42) - listener: endClassFields(null, null, null, null, null, null, null, 1, int, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 20, {, }) diff --git a/pkg/front_end/parser_testcases/general/built_in_identifier_class_methods.dart.expect b/pkg/front_end/parser_testcases/general/built_in_identifier_class_methods.dart.expect index 1c4b51d2d6c..e1f8c39f8ee 100644 --- a/pkg/front_end/parser_testcases/general/built_in_identifier_class_methods.dart.expect +++ b/pkg/front_end/parser_testcases/general/built_in_identifier_class_methods.dart.expect @@ -65,7 +65,7 @@ beginCompilationUnit(class) handleSend(abstract, )) endReturnStatement(true, return, ;) endBlockFunctionBody(2, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -120,7 +120,7 @@ beginCompilationUnit(class) handleSend(as, )) endReturnStatement(true, return, ;) endBlockFunctionBody(2, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -175,7 +175,7 @@ beginCompilationUnit(class) handleSend(covariant, )) endReturnStatement(true, return, ;) endBlockFunctionBody(2, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -230,7 +230,7 @@ beginCompilationUnit(class) handleSend(deferred, )) endReturnStatement(true, return, ;) endBlockFunctionBody(2, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -285,7 +285,7 @@ beginCompilationUnit(class) handleSend(dynamic, )) endReturnStatement(true, return, ;) endBlockFunctionBody(2, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -340,7 +340,7 @@ beginCompilationUnit(class) handleSend(export, )) endReturnStatement(true, return, ;) endBlockFunctionBody(2, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -395,7 +395,7 @@ beginCompilationUnit(class) handleSend(external, )) endReturnStatement(true, return, ;) endBlockFunctionBody(2, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -450,7 +450,7 @@ beginCompilationUnit(class) handleSend(factory, )) endReturnStatement(true, return, ;) endBlockFunctionBody(2, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -505,7 +505,7 @@ beginCompilationUnit(class) handleSend(Function, )) endReturnStatement(true, return, ;) endBlockFunctionBody(2, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -560,7 +560,7 @@ beginCompilationUnit(class) handleSend(get, )) endReturnStatement(true, return, ;) endBlockFunctionBody(2, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -615,7 +615,7 @@ beginCompilationUnit(class) handleSend(implements, )) endReturnStatement(true, return, ;) endBlockFunctionBody(2, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -670,7 +670,7 @@ beginCompilationUnit(class) handleSend(import, )) endReturnStatement(true, return, ;) endBlockFunctionBody(2, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -725,7 +725,7 @@ beginCompilationUnit(class) handleSend(interface, )) endReturnStatement(true, return, ;) endBlockFunctionBody(2, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -780,7 +780,7 @@ beginCompilationUnit(class) handleSend(library, )) endReturnStatement(true, return, ;) endBlockFunctionBody(2, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -835,7 +835,7 @@ beginCompilationUnit(class) handleSend(operator, )) endReturnStatement(true, return, ;) endBlockFunctionBody(2, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -890,7 +890,7 @@ beginCompilationUnit(class) handleSend(mixin, )) endReturnStatement(true, return, ;) endBlockFunctionBody(2, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -945,7 +945,7 @@ beginCompilationUnit(class) handleSend(part, )) endReturnStatement(true, return, ;) endBlockFunctionBody(2, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -1000,7 +1000,7 @@ beginCompilationUnit(class) handleSend(set, )) endReturnStatement(true, return, ;) endBlockFunctionBody(2, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -1055,7 +1055,7 @@ beginCompilationUnit(class) handleSend(static, )) endReturnStatement(true, return, ;) endBlockFunctionBody(2, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -1110,7 +1110,7 @@ beginCompilationUnit(class) handleSend(typedef, )) endReturnStatement(true, return, ;) endBlockFunctionBody(2, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 20, {, }) endClassDeclaration(class, }) diff --git a/pkg/front_end/parser_testcases/general/built_in_identifier_class_methods.dart.intertwined.expect b/pkg/front_end/parser_testcases/general/built_in_identifier_class_methods.dart.intertwined.expect index bfce113ea41..abaa37d7895 100644 --- a/pkg/front_end/parser_testcases/general/built_in_identifier_class_methods.dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/general/built_in_identifier_class_methods.dart.intertwined.expect @@ -171,7 +171,7 @@ parseUnit(class) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(2, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -317,7 +317,7 @@ parseUnit(class) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(2, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -463,7 +463,7 @@ parseUnit(class) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(2, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -609,7 +609,7 @@ parseUnit(class) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(2, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -755,7 +755,7 @@ parseUnit(class) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(2, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -901,7 +901,7 @@ parseUnit(class) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(2, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -1047,7 +1047,7 @@ parseUnit(class) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(2, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -1193,7 +1193,7 @@ parseUnit(class) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(2, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -1339,7 +1339,7 @@ parseUnit(class) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(2, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -1486,7 +1486,7 @@ parseUnit(class) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(2, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -1632,7 +1632,7 @@ parseUnit(class) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(2, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -1778,7 +1778,7 @@ parseUnit(class) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(2, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -1924,7 +1924,7 @@ parseUnit(class) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(2, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -2070,7 +2070,7 @@ parseUnit(class) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(2, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -2218,7 +2218,7 @@ parseUnit(class) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(2, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -2364,7 +2364,7 @@ parseUnit(class) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(2, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -2510,7 +2510,7 @@ parseUnit(class) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(2, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -2657,7 +2657,7 @@ parseUnit(class) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(2, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -2803,7 +2803,7 @@ parseUnit(class) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(2, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, WrapperClass) @@ -2949,7 +2949,7 @@ parseUnit(class) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(2, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 20, {, }) diff --git a/pkg/front_end/parser_testcases/general/factory_constructor_head_pre_feature.dart.expect b/pkg/front_end/parser_testcases/general/factory_constructor_head_pre_feature.dart.expect index e489d1dee07..911006d6ed1 100644 --- a/pkg/front_end/parser_testcases/general/factory_constructor_head_pre_feature.dart.expect +++ b/pkg/front_end/parser_testcases/general/factory_constructor_head_pre_feature.dart.expect @@ -50,36 +50,36 @@ beginCompilationUnit(class) handleNoInitializers() handleAsyncModifier(null, null) handleEmptyFunctionBody(;) - endClassMethod(null, external, (, null, ;) + endMethod(DeclarationKind.Class, null, external, (, null, ;) endMember() beginMetadataStar(external) endMetadataStar(0) beginMember() - beginFactoryMethod(DeclarationKind.Class, ;, external, null) + beginFactory(DeclarationKind.Class, ;, external, null) handleIdentifier(C, methodDeclaration) handleNoTypeVariables(() beginFormalParameters((, MemberKind.Factory) endFormalParameters(0, (, ), MemberKind.Factory) handleAsyncModifier(null, null) handleEmptyFunctionBody(;) - endClassFactoryMethod(external, factory, ;) + endFactory(DeclarationKind.Class, external, factory, ;) endMember() beginMetadataStar(external) endMetadataStar(0) beginMember() - beginFactoryMethod(DeclarationKind.Class, ;, external, null) + beginFactory(DeclarationKind.Class, ;, external, null) handleIdentifier(name, methodDeclaration) handleNoTypeVariables(() beginFormalParameters((, MemberKind.Factory) endFormalParameters(0, (, ), MemberKind.Factory) handleAsyncModifier(null, null) handleEmptyFunctionBody(;) - endClassFactoryMethod(external, factory, ;) + endFactory(DeclarationKind.Class, external, factory, ;) endMember() beginMetadataStar(external) endMetadataStar(0) beginMember() - beginFactoryMethod(DeclarationKind.Class, ;, external, null) + beginFactory(DeclarationKind.Class, ;, external, null) handleIdentifier(C, methodDeclaration) handleIdentifier(name, methodDeclarationContinuation) handleQualified(.) @@ -88,7 +88,7 @@ beginCompilationUnit(class) endFormalParameters(0, (, ), MemberKind.Factory) handleAsyncModifier(null, null) handleEmptyFunctionBody(;) - endClassFactoryMethod(external, factory, ;) + endFactory(DeclarationKind.Class, external, factory, ;) endMember() beginMetadataStar(factory) endMetadataStar(0) @@ -107,12 +107,12 @@ beginCompilationUnit(class) endArguments(0, (, )) handleSend(C, )) handleExpressionFunctionBody(=>, ;) - endClassMethod(null, factory, (, null, ;) + endMethod(DeclarationKind.Class, null, factory, (, null, ;) endMember() beginMetadataStar(factory) endMetadataStar(0) beginMember() - beginFactoryMethod(DeclarationKind.Class, ;, null, null) + beginFactory(DeclarationKind.Class, ;, null, null) handleIdentifier(C, methodDeclaration) handleNoTypeVariables(() beginFormalParameters((, MemberKind.Factory) @@ -124,12 +124,12 @@ beginCompilationUnit(class) endArguments(0, (, )) handleSend(C, )) handleExpressionFunctionBody(=>, ;) - endClassFactoryMethod(factory, factory, ;) + endFactory(DeclarationKind.Class, factory, factory, ;) endMember() beginMetadataStar(factory) endMetadataStar(0) beginMember() - beginFactoryMethod(DeclarationKind.Class, ;, null, null) + beginFactory(DeclarationKind.Class, ;, null, null) handleIdentifier(name, methodDeclaration) handleNoTypeVariables(() beginFormalParameters((, MemberKind.Factory) @@ -141,12 +141,12 @@ beginCompilationUnit(class) endArguments(0, (, )) handleSend(C, )) handleExpressionFunctionBody(=>, ;) - endClassFactoryMethod(factory, factory, ;) + endFactory(DeclarationKind.Class, factory, factory, ;) endMember() beginMetadataStar(factory) endMetadataStar(0) beginMember() - beginFactoryMethod(DeclarationKind.Class, ;, null, null) + beginFactory(DeclarationKind.Class, ;, null, null) handleIdentifier(C, methodDeclaration) handleIdentifier(name, methodDeclarationContinuation) handleQualified(.) @@ -160,7 +160,7 @@ beginCompilationUnit(class) endArguments(0, (, )) handleSend(C, )) handleExpressionFunctionBody(=>, ;) - endClassFactoryMethod(factory, factory, ;) + endFactory(DeclarationKind.Class, factory, factory, ;) endMember() beginMetadataStar(factory) endMetadataStar(0) @@ -175,12 +175,12 @@ beginCompilationUnit(class) handleAsyncModifier(null, null) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) - endClassMethod(null, factory, (, null, }) + endMethod(DeclarationKind.Class, null, factory, (, null, }) endMember() beginMetadataStar(factory) endMetadataStar(0) beginMember() - beginFactoryMethod(DeclarationKind.Class, }, null, null) + beginFactory(DeclarationKind.Class, }, null, null) handleIdentifier(C, methodDeclaration) handleNoTypeVariables(() beginFormalParameters((, MemberKind.Factory) @@ -188,12 +188,12 @@ beginCompilationUnit(class) handleAsyncModifier(null, null) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) - endClassFactoryMethod(factory, factory, }) + endFactory(DeclarationKind.Class, factory, factory, }) endMember() beginMetadataStar(factory) endMetadataStar(0) beginMember() - beginFactoryMethod(DeclarationKind.Class, }, null, null) + beginFactory(DeclarationKind.Class, }, null, null) handleIdentifier(name, methodDeclaration) handleNoTypeVariables(() beginFormalParameters((, MemberKind.Factory) @@ -201,12 +201,12 @@ beginCompilationUnit(class) handleAsyncModifier(null, null) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) - endClassFactoryMethod(factory, factory, }) + endFactory(DeclarationKind.Class, factory, factory, }) endMember() beginMetadataStar(factory) endMetadataStar(0) beginMember() - beginFactoryMethod(DeclarationKind.Class, }, null, null) + beginFactory(DeclarationKind.Class, }, null, null) handleIdentifier(C, methodDeclaration) handleIdentifier(name, methodDeclarationContinuation) handleQualified(.) @@ -216,7 +216,7 @@ beginCompilationUnit(class) handleAsyncModifier(null, null) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) - endClassFactoryMethod(factory, factory, }) + endFactory(DeclarationKind.Class, factory, factory, }) endMember() beginMetadataStar(factory) endMetadataStar(0) @@ -237,12 +237,12 @@ beginCompilationUnit(class) handleNoConstructorReferenceContinuationAfterTypeArguments(C) endConstructorReference(C, null, C, ConstructorReferenceContext.RedirectingFactory) endRedirectingFactoryBody(=, ;) - endClassMethod(null, factory, (, null, ;) + endMethod(DeclarationKind.Class, null, factory, (, null, ;) endMember() beginMetadataStar(factory) endMetadataStar(0) beginMember() - beginFactoryMethod(DeclarationKind.Class, ;, null, null) + beginFactory(DeclarationKind.Class, ;, null, null) handleIdentifier(C, methodDeclaration) handleNoTypeVariables(() beginFormalParameters((, MemberKind.Factory) @@ -255,12 +255,12 @@ beginCompilationUnit(class) handleNoConstructorReferenceContinuationAfterTypeArguments(C) endConstructorReference(C, null, C, ConstructorReferenceContext.RedirectingFactory) endRedirectingFactoryBody(=, ;) - endClassFactoryMethod(factory, factory, ;) + endFactory(DeclarationKind.Class, factory, factory, ;) endMember() beginMetadataStar(factory) endMetadataStar(0) beginMember() - beginFactoryMethod(DeclarationKind.Class, ;, null, null) + beginFactory(DeclarationKind.Class, ;, null, null) handleIdentifier(name, methodDeclaration) handleNoTypeVariables(() beginFormalParameters((, MemberKind.Factory) @@ -273,12 +273,12 @@ beginCompilationUnit(class) handleNoConstructorReferenceContinuationAfterTypeArguments(C) endConstructorReference(C, null, C, ConstructorReferenceContext.RedirectingFactory) endRedirectingFactoryBody(=, ;) - endClassFactoryMethod(factory, factory, ;) + endFactory(DeclarationKind.Class, factory, factory, ;) endMember() beginMetadataStar(factory) endMetadataStar(0) beginMember() - beginFactoryMethod(DeclarationKind.Class, ;, null, null) + beginFactory(DeclarationKind.Class, ;, null, null) handleIdentifier(C, methodDeclaration) handleIdentifier(name, methodDeclarationContinuation) handleQualified(.) @@ -293,7 +293,7 @@ beginCompilationUnit(class) handleNoConstructorReferenceContinuationAfterTypeArguments(C) endConstructorReference(C, null, C, ConstructorReferenceContext.RedirectingFactory) endRedirectingFactoryBody(=, ;) - endClassFactoryMethod(factory, factory, ;) + endFactory(DeclarationKind.Class, factory, factory, ;) endMember() beginMetadataStar(external) endMetadataStar(0) @@ -308,36 +308,36 @@ beginCompilationUnit(class) handleAsyncModifier(null, null) handleEmptyFunctionBody(;) handleRecoverableError(ConstMethod, const, const) - endClassMethod(null, external, (, null, ;) + endMethod(DeclarationKind.Class, null, external, (, null, ;) endMember() beginMetadataStar(external) endMetadataStar(0) beginMember() - beginFactoryMethod(DeclarationKind.Class, ;, external, const) + beginFactory(DeclarationKind.Class, ;, external, const) handleIdentifier(C, methodDeclaration) handleNoTypeVariables(() beginFormalParameters((, MemberKind.Factory) endFormalParameters(0, (, ), MemberKind.Factory) handleAsyncModifier(null, null) handleEmptyFunctionBody(;) - endClassFactoryMethod(external, factory, ;) + endFactory(DeclarationKind.Class, external, factory, ;) endMember() beginMetadataStar(external) endMetadataStar(0) beginMember() - beginFactoryMethod(DeclarationKind.Class, ;, external, const) + beginFactory(DeclarationKind.Class, ;, external, const) handleIdentifier(name, methodDeclaration) handleNoTypeVariables(() beginFormalParameters((, MemberKind.Factory) endFormalParameters(0, (, ), MemberKind.Factory) handleAsyncModifier(null, null) handleEmptyFunctionBody(;) - endClassFactoryMethod(external, factory, ;) + endFactory(DeclarationKind.Class, external, factory, ;) endMember() beginMetadataStar(external) endMetadataStar(0) beginMember() - beginFactoryMethod(DeclarationKind.Class, ;, external, const) + beginFactory(DeclarationKind.Class, ;, external, const) handleIdentifier(C, methodDeclaration) handleIdentifier(name, methodDeclarationContinuation) handleQualified(.) @@ -346,7 +346,7 @@ beginCompilationUnit(class) endFormalParameters(0, (, ), MemberKind.Factory) handleAsyncModifier(null, null) handleEmptyFunctionBody(;) - endClassFactoryMethod(external, factory, ;) + endFactory(DeclarationKind.Class, external, factory, ;) endMember() beginMetadataStar(const) endMetadataStar(0) @@ -366,12 +366,12 @@ beginCompilationUnit(class) handleSend(C, )) handleExpressionFunctionBody(=>, ;) handleRecoverableError(ConstMethod, const, const) - endClassMethod(null, const, (, null, ;) + endMethod(DeclarationKind.Class, null, const, (, null, ;) endMember() beginMetadataStar(const) endMetadataStar(0) beginMember() - beginFactoryMethod(DeclarationKind.Class, ;, null, const) + beginFactory(DeclarationKind.Class, ;, null, const) handleIdentifier(C, methodDeclaration) handleNoTypeVariables(() beginFormalParameters((, MemberKind.Factory) @@ -384,12 +384,12 @@ beginCompilationUnit(class) endArguments(0, (, )) handleSend(C, )) handleExpressionFunctionBody(=>, ;) - endClassFactoryMethod(const, factory, ;) + endFactory(DeclarationKind.Class, const, factory, ;) endMember() beginMetadataStar(const) endMetadataStar(0) beginMember() - beginFactoryMethod(DeclarationKind.Class, ;, null, const) + beginFactory(DeclarationKind.Class, ;, null, const) handleIdentifier(name, methodDeclaration) handleNoTypeVariables(() beginFormalParameters((, MemberKind.Factory) @@ -402,12 +402,12 @@ beginCompilationUnit(class) endArguments(0, (, )) handleSend(C, )) handleExpressionFunctionBody(=>, ;) - endClassFactoryMethod(const, factory, ;) + endFactory(DeclarationKind.Class, const, factory, ;) endMember() beginMetadataStar(const) endMetadataStar(0) beginMember() - beginFactoryMethod(DeclarationKind.Class, ;, null, const) + beginFactory(DeclarationKind.Class, ;, null, const) handleIdentifier(C, methodDeclaration) handleIdentifier(name, methodDeclarationContinuation) handleQualified(.) @@ -422,7 +422,7 @@ beginCompilationUnit(class) endArguments(0, (, )) handleSend(C, )) handleExpressionFunctionBody(=>, ;) - endClassFactoryMethod(const, factory, ;) + endFactory(DeclarationKind.Class, const, factory, ;) endMember() beginMetadataStar(const) endMetadataStar(0) @@ -438,12 +438,12 @@ beginCompilationUnit(class) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) handleRecoverableError(ConstMethod, const, const) - endClassMethod(null, const, (, null, }) + endMethod(DeclarationKind.Class, null, const, (, null, }) endMember() beginMetadataStar(const) endMetadataStar(0) beginMember() - beginFactoryMethod(DeclarationKind.Class, }, null, const) + beginFactory(DeclarationKind.Class, }, null, const) handleIdentifier(C, methodDeclaration) handleNoTypeVariables(() beginFormalParameters((, MemberKind.Factory) @@ -452,12 +452,12 @@ beginCompilationUnit(class) handleConstFactory(const) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) - endClassFactoryMethod(const, factory, }) + endFactory(DeclarationKind.Class, const, factory, }) endMember() beginMetadataStar(const) endMetadataStar(0) beginMember() - beginFactoryMethod(DeclarationKind.Class, }, null, const) + beginFactory(DeclarationKind.Class, }, null, const) handleIdentifier(name, methodDeclaration) handleNoTypeVariables(() beginFormalParameters((, MemberKind.Factory) @@ -466,12 +466,12 @@ beginCompilationUnit(class) handleConstFactory(const) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) - endClassFactoryMethod(const, factory, }) + endFactory(DeclarationKind.Class, const, factory, }) endMember() beginMetadataStar(const) endMetadataStar(0) beginMember() - beginFactoryMethod(DeclarationKind.Class, }, null, const) + beginFactory(DeclarationKind.Class, }, null, const) handleIdentifier(C, methodDeclaration) handleIdentifier(name, methodDeclarationContinuation) handleQualified(.) @@ -482,7 +482,7 @@ beginCompilationUnit(class) handleConstFactory(const) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) - endClassFactoryMethod(const, factory, }) + endFactory(DeclarationKind.Class, const, factory, }) endMember() beginMetadataStar(const) endMetadataStar(0) @@ -504,12 +504,12 @@ beginCompilationUnit(class) endConstructorReference(C, null, C, ConstructorReferenceContext.RedirectingFactory) endRedirectingFactoryBody(=, ;) handleRecoverableError(ConstMethod, const, const) - endClassMethod(null, const, (, null, ;) + endMethod(DeclarationKind.Class, null, const, (, null, ;) endMember() beginMetadataStar(const) endMetadataStar(0) beginMember() - beginFactoryMethod(DeclarationKind.Class, ;, null, const) + beginFactory(DeclarationKind.Class, ;, null, const) handleIdentifier(C, methodDeclaration) handleNoTypeVariables(() beginFormalParameters((, MemberKind.Factory) @@ -522,12 +522,12 @@ beginCompilationUnit(class) handleNoConstructorReferenceContinuationAfterTypeArguments(C) endConstructorReference(C, null, C, ConstructorReferenceContext.RedirectingFactory) endRedirectingFactoryBody(=, ;) - endClassFactoryMethod(const, factory, ;) + endFactory(DeclarationKind.Class, const, factory, ;) endMember() beginMetadataStar(const) endMetadataStar(0) beginMember() - beginFactoryMethod(DeclarationKind.Class, ;, null, const) + beginFactory(DeclarationKind.Class, ;, null, const) handleIdentifier(name, methodDeclaration) handleNoTypeVariables(() beginFormalParameters((, MemberKind.Factory) @@ -540,12 +540,12 @@ beginCompilationUnit(class) handleNoConstructorReferenceContinuationAfterTypeArguments(C) endConstructorReference(C, null, C, ConstructorReferenceContext.RedirectingFactory) endRedirectingFactoryBody(=, ;) - endClassFactoryMethod(const, factory, ;) + endFactory(DeclarationKind.Class, const, factory, ;) endMember() beginMetadataStar(const) endMetadataStar(0) beginMember() - beginFactoryMethod(DeclarationKind.Class, ;, null, const) + beginFactory(DeclarationKind.Class, ;, null, const) handleIdentifier(C, methodDeclaration) handleIdentifier(name, methodDeclarationContinuation) handleQualified(.) @@ -560,7 +560,7 @@ beginCompilationUnit(class) handleNoConstructorReferenceContinuationAfterTypeArguments(C) endConstructorReference(C, null, C, ConstructorReferenceContext.RedirectingFactory) endRedirectingFactoryBody(=, ;) - endClassFactoryMethod(const, factory, ;) + endFactory(DeclarationKind.Class, const, factory, ;) endMember() beginMetadataStar(void) endMetadataStar(0) @@ -579,7 +579,7 @@ beginCompilationUnit(class) endArguments(0, (, )) handleSend(C, )) handleExpressionFunctionBody(=>, ;) - endClassMethod(null, void, (, null, ;) + endMethod(DeclarationKind.Class, null, void, (, null, ;) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 33, {, }) endClassDeclaration(class, }) diff --git a/pkg/front_end/parser_testcases/general/factory_constructor_head_pre_feature.dart.intertwined.expect b/pkg/front_end/parser_testcases/general/factory_constructor_head_pre_feature.dart.intertwined.expect index 93bd17133c2..48b2f2ecedd 100644 --- a/pkg/front_end/parser_testcases/general/factory_constructor_head_pre_feature.dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/general/factory_constructor_head_pre_feature.dart.intertwined.expect @@ -54,7 +54,7 @@ parseUnit(class) inPlainSync() parseFunctionBody(), false, true) listener: handleEmptyFunctionBody(;) - listener: endClassMethod(null, external, (, null, ;) + listener: endMethod(DeclarationKind.Class, null, external, (, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, external) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, C) @@ -63,7 +63,7 @@ parseUnit(class) listener: endMetadataStar(0) listener: beginMember() parseFactoryMethod(external, DeclarationKind.Class, ;, external, null, null, true) - listener: beginFactoryMethod(DeclarationKind.Class, ;, external, null) + listener: beginFactory(DeclarationKind.Class, ;, external, null) ensureIdentifier(factory, methodDeclaration) listener: handleIdentifier(C, methodDeclaration) parseQualifiedRestOpt(C, methodDeclarationContinuation) @@ -79,7 +79,7 @@ parseUnit(class) inPlainSync() parseFunctionBody(), false, true) listener: handleEmptyFunctionBody(;) - listener: endClassFactoryMethod(external, factory, ;) + listener: endFactory(DeclarationKind.Class, external, factory, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, external) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, C) @@ -88,7 +88,7 @@ parseUnit(class) listener: endMetadataStar(0) listener: beginMember() parseFactoryMethod(external, DeclarationKind.Class, ;, external, null, null, true) - listener: beginFactoryMethod(DeclarationKind.Class, ;, external, null) + listener: beginFactory(DeclarationKind.Class, ;, external, null) ensureIdentifier(factory, methodDeclaration) listener: handleIdentifier(name, methodDeclaration) parseQualifiedRestOpt(name, methodDeclarationContinuation) @@ -104,7 +104,7 @@ parseUnit(class) inPlainSync() parseFunctionBody(), false, true) listener: handleEmptyFunctionBody(;) - listener: endClassFactoryMethod(external, factory, ;) + listener: endFactory(DeclarationKind.Class, external, factory, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, external) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, C) @@ -113,7 +113,7 @@ parseUnit(class) listener: endMetadataStar(0) listener: beginMember() parseFactoryMethod(external, DeclarationKind.Class, ;, external, null, null, true) - listener: beginFactoryMethod(DeclarationKind.Class, ;, external, null) + listener: beginFactory(DeclarationKind.Class, ;, external, null) ensureIdentifier(factory, methodDeclaration) listener: handleIdentifier(C, methodDeclaration) parseQualifiedRestOpt(C, methodDeclarationContinuation) @@ -133,7 +133,7 @@ parseUnit(class) inPlainSync() parseFunctionBody(), false, true) listener: handleEmptyFunctionBody(;) - listener: endClassFactoryMethod(external, factory, ;) + listener: endFactory(DeclarationKind.Class, external, factory, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, factory) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, C) @@ -184,7 +184,7 @@ parseUnit(class) ensureSemicolon()) listener: handleExpressionFunctionBody(=>, ;) inGenerator() - listener: endClassMethod(null, factory, (, null, ;) + listener: endMethod(DeclarationKind.Class, null, factory, (, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, factory) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, C) @@ -193,7 +193,7 @@ parseUnit(class) listener: endMetadataStar(0) listener: beginMember() parseFactoryMethod(;, DeclarationKind.Class, ;, null, null, null, true) - listener: beginFactoryMethod(DeclarationKind.Class, ;, null, null) + listener: beginFactory(DeclarationKind.Class, ;, null, null) ensureIdentifier(factory, methodDeclaration) listener: handleIdentifier(C, methodDeclaration) parseQualifiedRestOpt(C, methodDeclarationContinuation) @@ -231,7 +231,7 @@ parseUnit(class) ensureSemicolon()) listener: handleExpressionFunctionBody(=>, ;) inGenerator() - listener: endClassFactoryMethod(factory, factory, ;) + listener: endFactory(DeclarationKind.Class, factory, factory, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, factory) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, C) @@ -240,7 +240,7 @@ parseUnit(class) listener: endMetadataStar(0) listener: beginMember() parseFactoryMethod(;, DeclarationKind.Class, ;, null, null, null, true) - listener: beginFactoryMethod(DeclarationKind.Class, ;, null, null) + listener: beginFactory(DeclarationKind.Class, ;, null, null) ensureIdentifier(factory, methodDeclaration) listener: handleIdentifier(name, methodDeclaration) parseQualifiedRestOpt(name, methodDeclarationContinuation) @@ -278,7 +278,7 @@ parseUnit(class) ensureSemicolon()) listener: handleExpressionFunctionBody(=>, ;) inGenerator() - listener: endClassFactoryMethod(factory, factory, ;) + listener: endFactory(DeclarationKind.Class, factory, factory, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, factory) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, C) @@ -287,7 +287,7 @@ parseUnit(class) listener: endMetadataStar(0) listener: beginMember() parseFactoryMethod(;, DeclarationKind.Class, ;, null, null, null, true) - listener: beginFactoryMethod(DeclarationKind.Class, ;, null, null) + listener: beginFactory(DeclarationKind.Class, ;, null, null) ensureIdentifier(factory, methodDeclaration) listener: handleIdentifier(C, methodDeclaration) parseQualifiedRestOpt(C, methodDeclarationContinuation) @@ -329,7 +329,7 @@ parseUnit(class) ensureSemicolon()) listener: handleExpressionFunctionBody(=>, ;) inGenerator() - listener: endClassFactoryMethod(factory, factory, ;) + listener: endFactory(DeclarationKind.Class, factory, factory, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, factory) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, C) @@ -360,7 +360,7 @@ parseUnit(class) listener: beginBlockFunctionBody({) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(0, {, }) - listener: endClassMethod(null, factory, (, null, }) + listener: endMethod(DeclarationKind.Class, null, factory, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, factory) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, C) @@ -369,7 +369,7 @@ parseUnit(class) listener: endMetadataStar(0) listener: beginMember() parseFactoryMethod(}, DeclarationKind.Class, }, null, null, null, true) - listener: beginFactoryMethod(DeclarationKind.Class, }, null, null) + listener: beginFactory(DeclarationKind.Class, }, null, null) ensureIdentifier(factory, methodDeclaration) listener: handleIdentifier(C, methodDeclaration) parseQualifiedRestOpt(C, methodDeclarationContinuation) @@ -387,7 +387,7 @@ parseUnit(class) listener: beginBlockFunctionBody({) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(0, {, }) - listener: endClassFactoryMethod(factory, factory, }) + listener: endFactory(DeclarationKind.Class, factory, factory, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, factory) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, C) @@ -396,7 +396,7 @@ parseUnit(class) listener: endMetadataStar(0) listener: beginMember() parseFactoryMethod(}, DeclarationKind.Class, }, null, null, null, true) - listener: beginFactoryMethod(DeclarationKind.Class, }, null, null) + listener: beginFactory(DeclarationKind.Class, }, null, null) ensureIdentifier(factory, methodDeclaration) listener: handleIdentifier(name, methodDeclaration) parseQualifiedRestOpt(name, methodDeclarationContinuation) @@ -414,7 +414,7 @@ parseUnit(class) listener: beginBlockFunctionBody({) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(0, {, }) - listener: endClassFactoryMethod(factory, factory, }) + listener: endFactory(DeclarationKind.Class, factory, factory, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, factory) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, C) @@ -423,7 +423,7 @@ parseUnit(class) listener: endMetadataStar(0) listener: beginMember() parseFactoryMethod(}, DeclarationKind.Class, }, null, null, null, true) - listener: beginFactoryMethod(DeclarationKind.Class, }, null, null) + listener: beginFactory(DeclarationKind.Class, }, null, null) ensureIdentifier(factory, methodDeclaration) listener: handleIdentifier(C, methodDeclaration) parseQualifiedRestOpt(C, methodDeclarationContinuation) @@ -445,7 +445,7 @@ parseUnit(class) listener: beginBlockFunctionBody({) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(0, {, }) - listener: endClassFactoryMethod(factory, factory, }) + listener: endFactory(DeclarationKind.Class, factory, factory, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, factory) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, C) @@ -485,7 +485,7 @@ parseUnit(class) listener: endConstructorReference(C, null, C, ConstructorReferenceContext.RedirectingFactory) ensureSemicolon(C) listener: endRedirectingFactoryBody(=, ;) - listener: endClassMethod(null, factory, (, null, ;) + listener: endMethod(DeclarationKind.Class, null, factory, (, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, factory) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, C) @@ -494,7 +494,7 @@ parseUnit(class) listener: endMetadataStar(0) listener: beginMember() parseFactoryMethod(;, DeclarationKind.Class, ;, null, null, null, true) - listener: beginFactoryMethod(DeclarationKind.Class, ;, null, null) + listener: beginFactory(DeclarationKind.Class, ;, null, null) ensureIdentifier(factory, methodDeclaration) listener: handleIdentifier(C, methodDeclaration) parseQualifiedRestOpt(C, methodDeclarationContinuation) @@ -520,7 +520,7 @@ parseUnit(class) listener: endConstructorReference(C, null, C, ConstructorReferenceContext.RedirectingFactory) ensureSemicolon(C) listener: endRedirectingFactoryBody(=, ;) - listener: endClassFactoryMethod(factory, factory, ;) + listener: endFactory(DeclarationKind.Class, factory, factory, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, factory) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, C) @@ -529,7 +529,7 @@ parseUnit(class) listener: endMetadataStar(0) listener: beginMember() parseFactoryMethod(;, DeclarationKind.Class, ;, null, null, null, true) - listener: beginFactoryMethod(DeclarationKind.Class, ;, null, null) + listener: beginFactory(DeclarationKind.Class, ;, null, null) ensureIdentifier(factory, methodDeclaration) listener: handleIdentifier(name, methodDeclaration) parseQualifiedRestOpt(name, methodDeclarationContinuation) @@ -555,7 +555,7 @@ parseUnit(class) listener: endConstructorReference(C, null, C, ConstructorReferenceContext.RedirectingFactory) ensureSemicolon(C) listener: endRedirectingFactoryBody(=, ;) - listener: endClassFactoryMethod(factory, factory, ;) + listener: endFactory(DeclarationKind.Class, factory, factory, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, factory) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, C) @@ -564,7 +564,7 @@ parseUnit(class) listener: endMetadataStar(0) listener: beginMember() parseFactoryMethod(;, DeclarationKind.Class, ;, null, null, null, true) - listener: beginFactoryMethod(DeclarationKind.Class, ;, null, null) + listener: beginFactory(DeclarationKind.Class, ;, null, null) ensureIdentifier(factory, methodDeclaration) listener: handleIdentifier(C, methodDeclaration) parseQualifiedRestOpt(C, methodDeclarationContinuation) @@ -594,7 +594,7 @@ parseUnit(class) listener: endConstructorReference(C, null, C, ConstructorReferenceContext.RedirectingFactory) ensureSemicolon(C) listener: endRedirectingFactoryBody(=, ;) - listener: endClassFactoryMethod(factory, factory, ;) + listener: endFactory(DeclarationKind.Class, factory, factory, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, external) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, C) @@ -625,7 +625,7 @@ parseUnit(class) listener: handleEmptyFunctionBody(;) reportRecoverableError(const, ConstMethod) listener: handleRecoverableError(ConstMethod, const, const) - listener: endClassMethod(null, external, (, null, ;) + listener: endMethod(DeclarationKind.Class, null, external, (, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, external) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, C) @@ -634,7 +634,7 @@ parseUnit(class) listener: endMetadataStar(0) listener: beginMember() parseFactoryMethod(const, DeclarationKind.Class, ;, external, null, const, true) - listener: beginFactoryMethod(DeclarationKind.Class, ;, external, const) + listener: beginFactory(DeclarationKind.Class, ;, external, const) ensureIdentifier(factory, methodDeclaration) listener: handleIdentifier(C, methodDeclaration) parseQualifiedRestOpt(C, methodDeclarationContinuation) @@ -650,7 +650,7 @@ parseUnit(class) inPlainSync() parseFunctionBody(), false, true) listener: handleEmptyFunctionBody(;) - listener: endClassFactoryMethod(external, factory, ;) + listener: endFactory(DeclarationKind.Class, external, factory, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, external) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, C) @@ -659,7 +659,7 @@ parseUnit(class) listener: endMetadataStar(0) listener: beginMember() parseFactoryMethod(const, DeclarationKind.Class, ;, external, null, const, true) - listener: beginFactoryMethod(DeclarationKind.Class, ;, external, const) + listener: beginFactory(DeclarationKind.Class, ;, external, const) ensureIdentifier(factory, methodDeclaration) listener: handleIdentifier(name, methodDeclaration) parseQualifiedRestOpt(name, methodDeclarationContinuation) @@ -675,7 +675,7 @@ parseUnit(class) inPlainSync() parseFunctionBody(), false, true) listener: handleEmptyFunctionBody(;) - listener: endClassFactoryMethod(external, factory, ;) + listener: endFactory(DeclarationKind.Class, external, factory, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, external) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, C) @@ -684,7 +684,7 @@ parseUnit(class) listener: endMetadataStar(0) listener: beginMember() parseFactoryMethod(const, DeclarationKind.Class, ;, external, null, const, true) - listener: beginFactoryMethod(DeclarationKind.Class, ;, external, const) + listener: beginFactory(DeclarationKind.Class, ;, external, const) ensureIdentifier(factory, methodDeclaration) listener: handleIdentifier(C, methodDeclaration) parseQualifiedRestOpt(C, methodDeclarationContinuation) @@ -704,7 +704,7 @@ parseUnit(class) inPlainSync() parseFunctionBody(), false, true) listener: handleEmptyFunctionBody(;) - listener: endClassFactoryMethod(external, factory, ;) + listener: endFactory(DeclarationKind.Class, external, factory, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, const) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, C) @@ -757,7 +757,7 @@ parseUnit(class) inGenerator() reportRecoverableError(const, ConstMethod) listener: handleRecoverableError(ConstMethod, const, const) - listener: endClassMethod(null, const, (, null, ;) + listener: endMethod(DeclarationKind.Class, null, const, (, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, const) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, C) @@ -766,7 +766,7 @@ parseUnit(class) listener: endMetadataStar(0) listener: beginMember() parseFactoryMethod(const, DeclarationKind.Class, ;, null, null, const, true) - listener: beginFactoryMethod(DeclarationKind.Class, ;, null, const) + listener: beginFactory(DeclarationKind.Class, ;, null, const) ensureIdentifier(factory, methodDeclaration) listener: handleIdentifier(C, methodDeclaration) parseQualifiedRestOpt(C, methodDeclarationContinuation) @@ -805,7 +805,7 @@ parseUnit(class) ensureSemicolon()) listener: handleExpressionFunctionBody(=>, ;) inGenerator() - listener: endClassFactoryMethod(const, factory, ;) + listener: endFactory(DeclarationKind.Class, const, factory, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, const) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, C) @@ -814,7 +814,7 @@ parseUnit(class) listener: endMetadataStar(0) listener: beginMember() parseFactoryMethod(const, DeclarationKind.Class, ;, null, null, const, true) - listener: beginFactoryMethod(DeclarationKind.Class, ;, null, const) + listener: beginFactory(DeclarationKind.Class, ;, null, const) ensureIdentifier(factory, methodDeclaration) listener: handleIdentifier(name, methodDeclaration) parseQualifiedRestOpt(name, methodDeclarationContinuation) @@ -853,7 +853,7 @@ parseUnit(class) ensureSemicolon()) listener: handleExpressionFunctionBody(=>, ;) inGenerator() - listener: endClassFactoryMethod(const, factory, ;) + listener: endFactory(DeclarationKind.Class, const, factory, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, const) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, C) @@ -862,7 +862,7 @@ parseUnit(class) listener: endMetadataStar(0) listener: beginMember() parseFactoryMethod(const, DeclarationKind.Class, ;, null, null, const, true) - listener: beginFactoryMethod(DeclarationKind.Class, ;, null, const) + listener: beginFactory(DeclarationKind.Class, ;, null, const) ensureIdentifier(factory, methodDeclaration) listener: handleIdentifier(C, methodDeclaration) parseQualifiedRestOpt(C, methodDeclarationContinuation) @@ -905,7 +905,7 @@ parseUnit(class) ensureSemicolon()) listener: handleExpressionFunctionBody(=>, ;) inGenerator() - listener: endClassFactoryMethod(const, factory, ;) + listener: endFactory(DeclarationKind.Class, const, factory, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, const) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, C) @@ -938,7 +938,7 @@ parseUnit(class) listener: endBlockFunctionBody(0, {, }) reportRecoverableError(const, ConstMethod) listener: handleRecoverableError(ConstMethod, const, const) - listener: endClassMethod(null, const, (, null, }) + listener: endMethod(DeclarationKind.Class, null, const, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, const) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, C) @@ -947,7 +947,7 @@ parseUnit(class) listener: endMetadataStar(0) listener: beginMember() parseFactoryMethod(const, DeclarationKind.Class, }, null, null, const, true) - listener: beginFactoryMethod(DeclarationKind.Class, }, null, const) + listener: beginFactory(DeclarationKind.Class, }, null, const) ensureIdentifier(factory, methodDeclaration) listener: handleIdentifier(C, methodDeclaration) parseQualifiedRestOpt(C, methodDeclarationContinuation) @@ -966,7 +966,7 @@ parseUnit(class) listener: beginBlockFunctionBody({) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(0, {, }) - listener: endClassFactoryMethod(const, factory, }) + listener: endFactory(DeclarationKind.Class, const, factory, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, const) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, C) @@ -975,7 +975,7 @@ parseUnit(class) listener: endMetadataStar(0) listener: beginMember() parseFactoryMethod(const, DeclarationKind.Class, }, null, null, const, true) - listener: beginFactoryMethod(DeclarationKind.Class, }, null, const) + listener: beginFactory(DeclarationKind.Class, }, null, const) ensureIdentifier(factory, methodDeclaration) listener: handleIdentifier(name, methodDeclaration) parseQualifiedRestOpt(name, methodDeclarationContinuation) @@ -994,7 +994,7 @@ parseUnit(class) listener: beginBlockFunctionBody({) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(0, {, }) - listener: endClassFactoryMethod(const, factory, }) + listener: endFactory(DeclarationKind.Class, const, factory, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, const) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, C) @@ -1003,7 +1003,7 @@ parseUnit(class) listener: endMetadataStar(0) listener: beginMember() parseFactoryMethod(const, DeclarationKind.Class, }, null, null, const, true) - listener: beginFactoryMethod(DeclarationKind.Class, }, null, const) + listener: beginFactory(DeclarationKind.Class, }, null, const) ensureIdentifier(factory, methodDeclaration) listener: handleIdentifier(C, methodDeclaration) parseQualifiedRestOpt(C, methodDeclarationContinuation) @@ -1026,7 +1026,7 @@ parseUnit(class) listener: beginBlockFunctionBody({) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(0, {, }) - listener: endClassFactoryMethod(const, factory, }) + listener: endFactory(DeclarationKind.Class, const, factory, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, const) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, C) @@ -1068,7 +1068,7 @@ parseUnit(class) listener: endRedirectingFactoryBody(=, ;) reportRecoverableError(const, ConstMethod) listener: handleRecoverableError(ConstMethod, const, const) - listener: endClassMethod(null, const, (, null, ;) + listener: endMethod(DeclarationKind.Class, null, const, (, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, const) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, C) @@ -1077,7 +1077,7 @@ parseUnit(class) listener: endMetadataStar(0) listener: beginMember() parseFactoryMethod(const, DeclarationKind.Class, ;, null, null, const, true) - listener: beginFactoryMethod(DeclarationKind.Class, ;, null, const) + listener: beginFactory(DeclarationKind.Class, ;, null, const) ensureIdentifier(factory, methodDeclaration) listener: handleIdentifier(C, methodDeclaration) parseQualifiedRestOpt(C, methodDeclarationContinuation) @@ -1103,7 +1103,7 @@ parseUnit(class) listener: endConstructorReference(C, null, C, ConstructorReferenceContext.RedirectingFactory) ensureSemicolon(C) listener: endRedirectingFactoryBody(=, ;) - listener: endClassFactoryMethod(const, factory, ;) + listener: endFactory(DeclarationKind.Class, const, factory, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, const) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, C) @@ -1112,7 +1112,7 @@ parseUnit(class) listener: endMetadataStar(0) listener: beginMember() parseFactoryMethod(const, DeclarationKind.Class, ;, null, null, const, true) - listener: beginFactoryMethod(DeclarationKind.Class, ;, null, const) + listener: beginFactory(DeclarationKind.Class, ;, null, const) ensureIdentifier(factory, methodDeclaration) listener: handleIdentifier(name, methodDeclaration) parseQualifiedRestOpt(name, methodDeclarationContinuation) @@ -1138,7 +1138,7 @@ parseUnit(class) listener: endConstructorReference(C, null, C, ConstructorReferenceContext.RedirectingFactory) ensureSemicolon(C) listener: endRedirectingFactoryBody(=, ;) - listener: endClassFactoryMethod(const, factory, ;) + listener: endFactory(DeclarationKind.Class, const, factory, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, const) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, C) @@ -1147,7 +1147,7 @@ parseUnit(class) listener: endMetadataStar(0) listener: beginMember() parseFactoryMethod(const, DeclarationKind.Class, ;, null, null, const, true) - listener: beginFactoryMethod(DeclarationKind.Class, ;, null, const) + listener: beginFactory(DeclarationKind.Class, ;, null, const) ensureIdentifier(factory, methodDeclaration) listener: handleIdentifier(C, methodDeclaration) parseQualifiedRestOpt(C, methodDeclarationContinuation) @@ -1177,7 +1177,7 @@ parseUnit(class) listener: endConstructorReference(C, null, C, ConstructorReferenceContext.RedirectingFactory) ensureSemicolon(C) listener: endRedirectingFactoryBody(=, ;) - listener: endClassFactoryMethod(const, factory, ;) + listener: endFactory(DeclarationKind.Class, const, factory, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, void) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, C) @@ -1228,7 +1228,7 @@ parseUnit(class) ensureSemicolon()) listener: handleExpressionFunctionBody(=>, ;) inGenerator() - listener: endClassMethod(null, void, (, null, ;) + listener: endMethod(DeclarationKind.Class, null, void, (, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 33, {, }) diff --git a/pkg/front_end/parser_testcases/general/issue_41121.dart.expect b/pkg/front_end/parser_testcases/general/issue_41121.dart.expect index 759ae046e5c..fadc5db10ae 100644 --- a/pkg/front_end/parser_testcases/general/issue_41121.dart.expect +++ b/pkg/front_end/parser_testcases/general/issue_41121.dart.expect @@ -63,7 +63,7 @@ beginCompilationUnit(class) handleType(Configuration, null) handleIdentifier(_configuration, fieldDeclaration) handleNoFieldInitializer(;) - endClassFields(null, null, null, null, null, null, null, 1, Configuration, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, Configuration, ;) endMember() beginMetadataStar(ConfigurationService) endMetadataStar(0) @@ -110,7 +110,7 @@ beginCompilationUnit(class) handleAsyncModifier(null, null) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) - endClassConstructor(ConfigurationService, (, :, }) + endConstructor(DeclarationKind.Class, ConfigurationService, (, :, }) endMember() beginMetadataStar(void) endMetadataStar(0) @@ -160,7 +160,7 @@ beginCompilationUnit(class) handleRecoverableError(ConstructorWithWrongName, configuration, configuration) handleRecoverableError(SetterConstructor, set, set) handleRecoverableError(ConstructorWithReturnType, void, void) - endClassConstructor(void, (, :, }) + endConstructor(DeclarationKind.Class, void, (, :, }) endMember() beginMetadataStar(Configuration) endMetadataStar(0) @@ -215,7 +215,7 @@ beginCompilationUnit(class) handleRecoverableError(ConstructorWithWrongName, configuration, configuration) handleRecoverableError(GetterConstructor, get, get) handleRecoverableError(ConstructorWithReturnType, Configuration, Configuration) - endClassConstructor(Configuration, (, :, }) + endConstructor(DeclarationKind.Class, Configuration, (, :, }) endMember() beginMetadataStar(void) endMetadataStar(0) @@ -241,7 +241,7 @@ beginCompilationUnit(class) endBlockFunctionBody(0, {, }) handleRecoverableError(ConstructorWithWrongName, method, method) handleRecoverableError(ConstructorWithReturnType, void, void) - endClassConstructor(void, (, :, }) + endConstructor(DeclarationKind.Class, void, (, :, }) endMember() beginMetadataStar(Foo) endMetadataStar(0) @@ -266,7 +266,7 @@ beginCompilationUnit(class) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) handleRecoverableError(ConstructorWithWrongName, Foo, Foo) - endClassConstructor(Foo, (, :, }) + endConstructor(DeclarationKind.Class, Foo, (, :, }) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 6, {, }) endClassDeclaration(class, }) @@ -298,7 +298,7 @@ beginCompilationUnit(class) handleAsyncModifier(null, null) handleThisExpression(this, expression) handleExpressionFunctionBody(=>, ;) - endClassMethod(get, Configuration, =>, null, ;) + endMethod(DeclarationKind.Class, get, Configuration, =>, null, ;) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 1, {, }) endClassDeclaration(class, }) diff --git a/pkg/front_end/parser_testcases/general/issue_41121.dart.intertwined.expect b/pkg/front_end/parser_testcases/general/issue_41121.dart.intertwined.expect index 8f93851da8d..6ecbd7c539c 100644 --- a/pkg/front_end/parser_testcases/general/issue_41121.dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/general/issue_41121.dart.intertwined.expect @@ -42,7 +42,7 @@ parseUnit(class) listener: handleIdentifier(_configuration, fieldDeclaration) parseFieldInitializerOpt(_configuration, _configuration, null, null, null, null, null, DeclarationKind.Class, ConfigurationService) listener: handleNoFieldInitializer(;) - listener: endClassFields(null, null, null, null, null, null, null, 1, Configuration, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, Configuration, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, ConfigurationService) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, ConfigurationService) @@ -147,7 +147,7 @@ parseUnit(class) listener: beginBlockFunctionBody({) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(0, {, }) - listener: endClassConstructor(ConfigurationService, (, :, }) + listener: endConstructor(DeclarationKind.Class, ConfigurationService, (, :, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, void) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, ConfigurationService) @@ -257,7 +257,7 @@ parseUnit(class) listener: handleRecoverableError(SetterConstructor, set, set) reportRecoverableError(void, ConstructorWithReturnType) listener: handleRecoverableError(ConstructorWithReturnType, void, void) - listener: endClassConstructor(void, (, :, }) + listener: endConstructor(DeclarationKind.Class, void, (, :, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, Configuration) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, ConfigurationService) @@ -393,7 +393,7 @@ parseUnit(class) listener: handleRecoverableError(GetterConstructor, get, get) reportRecoverableError(Configuration, ConstructorWithReturnType) listener: handleRecoverableError(ConstructorWithReturnType, Configuration, Configuration) - listener: endClassConstructor(Configuration, (, :, }) + listener: endConstructor(DeclarationKind.Class, Configuration, (, :, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, void) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, ConfigurationService) @@ -455,7 +455,7 @@ parseUnit(class) listener: handleRecoverableError(ConstructorWithWrongName, method, method) reportRecoverableError(void, ConstructorWithReturnType) listener: handleRecoverableError(ConstructorWithReturnType, void, void) - listener: endClassConstructor(void, (, :, }) + listener: endConstructor(DeclarationKind.Class, void, (, :, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, Foo) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, ConfigurationService) @@ -516,7 +516,7 @@ parseUnit(class) listener: endBlockFunctionBody(0, {, }) reportRecoverableError(Foo, ConstructorWithWrongName) listener: handleRecoverableError(ConstructorWithWrongName, Foo, Foo) - listener: endClassConstructor(Foo, (, :, }) + listener: endConstructor(DeclarationKind.Class, Foo, (, :, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 6, {, }) @@ -584,7 +584,7 @@ parseUnit(class) ensureSemicolon(this) listener: handleExpressionFunctionBody(=>, ;) inGenerator() - listener: endClassMethod(get, Configuration, =>, null, ;) + listener: endMethod(DeclarationKind.Class, get, Configuration, =>, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 1, {, }) diff --git a/pkg/front_end/parser_testcases/general/issue_45848_06.dart.expect b/pkg/front_end/parser_testcases/general/issue_45848_06.dart.expect index 44d3219b112..5c9417e3f23 100644 --- a/pkg/front_end/parser_testcases/general/issue_45848_06.dart.expect +++ b/pkg/front_end/parser_testcases/general/issue_45848_06.dart.expect @@ -196,7 +196,7 @@ beginCompilationUnit(void) handleLiteralBool(true) endReturnStatement(true, return, ;) endBlockFunctionBody(1, {, }) - endExtensionMethod(null, bool, (, null, }) + endMethod(DeclarationKind.Extension, null, bool, (, null, }) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Extension, 1, {, }) endExtensionDeclaration(extension, extension, on, }) diff --git a/pkg/front_end/parser_testcases/general/issue_45848_06.dart.intertwined.expect b/pkg/front_end/parser_testcases/general/issue_45848_06.dart.intertwined.expect index b44001019ac..565217828d9 100644 --- a/pkg/front_end/parser_testcases/general/issue_45848_06.dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/general/issue_45848_06.dart.intertwined.expect @@ -441,7 +441,7 @@ parseUnit(void) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(1, {, }) - listener: endExtensionMethod(null, bool, (, null, }) + listener: endMethod(DeclarationKind.Extension, null, bool, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Extension, 1, {, }) diff --git a/pkg/front_end/parser_testcases/general/new_as_identifier.dart.expect b/pkg/front_end/parser_testcases/general/new_as_identifier.dart.expect index c8e81889efd..95aa80dcc7a 100644 --- a/pkg/front_end/parser_testcases/general/new_as_identifier.dart.expect +++ b/pkg/front_end/parser_testcases/general/new_as_identifier.dart.expect @@ -69,7 +69,7 @@ beginCompilationUnit(class) handleNoInitializers() handleAsyncModifier(null, null) handleEmptyFunctionBody(;) - endClassConstructor(C, (, null, ;) + endConstructor(DeclarationKind.Class, C, (, null, ;) endMember() beginMetadataStar(C) endMetadataStar(0) @@ -102,7 +102,7 @@ beginCompilationUnit(class) handleAsyncModifier(null, null) handleRecoverableError(Message[Template(ExpectedFunctionBody), Expected a function body, but got 'new'., null, {lexeme: new}], new, new) handleInvalidFunctionBody({) - endClassConstructor(C, (, :, }) + endConstructor(DeclarationKind.Class, C, (, :, }) endMember() beginMetadataStar(new) endMetadataStar(0) @@ -126,7 +126,7 @@ beginCompilationUnit(class) handleAsyncModifier(null, null) handleRecoverableError(Message[Template(ExpectedFunctionBody), Expected a function body, but got 'null'., null, {lexeme: null}], null, null) handleInvalidFunctionBody({) - endClassMethod(null, operator, (, null, }) + endMethod(DeclarationKind.Class, null, operator, (, null, }) endMember() beginMetadataStar(null) endMetadataStar(0) @@ -159,7 +159,7 @@ beginCompilationUnit(class) beginMetadataStar(factory) endMetadataStar(0) beginMember() - beginFactoryMethod(DeclarationKind.Class, {, null, null) + beginFactory(DeclarationKind.Class, {, null, null) handleIdentifier(D, methodDeclaration) handleNewAsIdentifier(new) handleIdentifier(new, methodDeclarationContinuation) @@ -174,12 +174,12 @@ beginCompilationUnit(class) endArguments(0, (, )) handleSend(C, )) handleExpressionFunctionBody(=>, ;) - endClassFactoryMethod(factory, factory, ;) + endFactory(DeclarationKind.Class, factory, factory, ;) endMember() beginMetadataStar(factory) endMetadataStar(0) beginMember() - beginFactoryMethod(DeclarationKind.Class, ;, null, null) + beginFactory(DeclarationKind.Class, ;, null, null) handleIdentifier(D, methodDeclaration) handleIdentifier(factory_redirection, methodDeclarationContinuation) handleQualified(.) @@ -197,12 +197,12 @@ beginCompilationUnit(class) handleNoConstructorReferenceContinuationAfterTypeArguments(new) endConstructorReference(C, null, new, ConstructorReferenceContext.RedirectingFactory) endRedirectingFactoryBody(=, ;) - endClassFactoryMethod(factory, factory, ;) + endFactory(DeclarationKind.Class, factory, factory, ;) endMember() beginMetadataStar(factory) endMetadataStar(0) beginMember() - beginFactoryMethod(DeclarationKind.Class, ;, null, null) + beginFactory(DeclarationKind.Class, ;, null, null) handleIdentifier(D, methodDeclaration) handleIdentifier(factory_redirection_generic, methodDeclarationContinuation) handleQualified(.) @@ -222,12 +222,12 @@ beginCompilationUnit(class) handleIdentifier(new, constructorReferenceContinuationAfterTypeArguments) endConstructorReference(C, ., new, ConstructorReferenceContext.RedirectingFactory) endRedirectingFactoryBody(=, ;) - endClassFactoryMethod(factory, factory, ;) + endFactory(DeclarationKind.Class, factory, factory, ;) endMember() beginMetadataStar(factory) endMetadataStar(0) beginMember() - beginFactoryMethod(DeclarationKind.Class, ;, null, null) + beginFactory(DeclarationKind.Class, ;, null, null) handleIdentifier(D, methodDeclaration) handleIdentifier(factory_redirection_prefixed, methodDeclarationContinuation) handleQualified(.) @@ -245,12 +245,12 @@ beginCompilationUnit(class) handleIdentifier(new, constructorReferenceContinuationAfterTypeArguments) endConstructorReference(prefix, ., new, ConstructorReferenceContext.RedirectingFactory) endRedirectingFactoryBody(=, ;) - endClassFactoryMethod(factory, factory, ;) + endFactory(DeclarationKind.Class, factory, factory, ;) endMember() beginMetadataStar(factory) endMetadataStar(0) beginMember() - beginFactoryMethod(DeclarationKind.Class, ;, null, null) + beginFactory(DeclarationKind.Class, ;, null, null) handleIdentifier(D, methodDeclaration) handleIdentifier(factory_redirection_prefixed_generic, methodDeclarationContinuation) handleQualified(.) @@ -272,7 +272,7 @@ beginCompilationUnit(class) handleIdentifier(new, constructorReferenceContinuationAfterTypeArguments) endConstructorReference(prefix, ., new, ConstructorReferenceContext.RedirectingFactory) endRedirectingFactoryBody(=, ;) - endClassFactoryMethod(factory, factory, ;) + endFactory(DeclarationKind.Class, factory, factory, ;) endMember() beginMetadataStar(D) endMetadataStar(0) @@ -299,7 +299,7 @@ beginCompilationUnit(class) endInitializers(1, :, )) handleAsyncModifier(null, null) handleEmptyFunctionBody(;) - endClassConstructor(D, (, :, ;) + endConstructor(DeclarationKind.Class, D, (, :, ;) endMember() beginMetadataStar(D) endMetadataStar(0) @@ -326,7 +326,7 @@ beginCompilationUnit(class) endInitializers(1, :, )) handleAsyncModifier(null, null) handleEmptyFunctionBody(;) - endClassConstructor(D, (, :, ;) + endConstructor(DeclarationKind.Class, D, (, :, ;) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 7, {, }) endClassDeclaration(class, }) diff --git a/pkg/front_end/parser_testcases/general/new_as_identifier.dart.intertwined.expect b/pkg/front_end/parser_testcases/general/new_as_identifier.dart.intertwined.expect index 77711989ea7..3cdee4579dd 100644 --- a/pkg/front_end/parser_testcases/general/new_as_identifier.dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/general/new_as_identifier.dart.intertwined.expect @@ -61,7 +61,7 @@ parseUnit(class) inPlainSync() parseFunctionBody(), false, true) listener: handleEmptyFunctionBody(;) - listener: endClassConstructor(C, (, null, ;) + listener: endConstructor(DeclarationKind.Class, C, (, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, C) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, C) @@ -147,7 +147,7 @@ parseUnit(class) rewriter() rewriter() listener: handleInvalidFunctionBody({) - listener: endClassConstructor(C, (, :, }) + listener: endConstructor(DeclarationKind.Class, C, (, :, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, new) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, C) @@ -203,7 +203,7 @@ parseUnit(class) rewriter() rewriter() listener: handleInvalidFunctionBody({) - listener: endClassMethod(null, operator, (, null, }) + listener: endMethod(DeclarationKind.Class, null, operator, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, null) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, C) @@ -263,7 +263,7 @@ parseUnit(class) listener: endMetadataStar(0) listener: beginMember() parseFactoryMethod({, DeclarationKind.Class, {, null, null, null, true) - listener: beginFactoryMethod(DeclarationKind.Class, {, null, null) + listener: beginFactory(DeclarationKind.Class, {, null, null) ensureIdentifier(factory, methodDeclaration) listener: handleIdentifier(D, methodDeclaration) parseQualifiedRestOpt(D, methodDeclarationContinuation) @@ -307,7 +307,7 @@ parseUnit(class) ensureSemicolon()) listener: handleExpressionFunctionBody(=>, ;) inGenerator() - listener: endClassFactoryMethod(factory, factory, ;) + listener: endFactory(DeclarationKind.Class, factory, factory, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, factory) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, D) @@ -316,7 +316,7 @@ parseUnit(class) listener: endMetadataStar(0) listener: beginMember() parseFactoryMethod(;, DeclarationKind.Class, ;, null, null, null, true) - listener: beginFactoryMethod(DeclarationKind.Class, ;, null, null) + listener: beginFactory(DeclarationKind.Class, ;, null, null) ensureIdentifier(factory, methodDeclaration) listener: handleIdentifier(D, methodDeclaration) parseQualifiedRestOpt(D, methodDeclarationContinuation) @@ -352,7 +352,7 @@ parseUnit(class) listener: endConstructorReference(C, null, new, ConstructorReferenceContext.RedirectingFactory) ensureSemicolon(new) listener: endRedirectingFactoryBody(=, ;) - listener: endClassFactoryMethod(factory, factory, ;) + listener: endFactory(DeclarationKind.Class, factory, factory, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, factory) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, D) @@ -361,7 +361,7 @@ parseUnit(class) listener: endMetadataStar(0) listener: beginMember() parseFactoryMethod(;, DeclarationKind.Class, ;, null, null, null, true) - listener: beginFactoryMethod(DeclarationKind.Class, ;, null, null) + listener: beginFactory(DeclarationKind.Class, ;, null, null) ensureIdentifier(factory, methodDeclaration) listener: handleIdentifier(D, methodDeclaration) parseQualifiedRestOpt(D, methodDeclarationContinuation) @@ -398,7 +398,7 @@ parseUnit(class) listener: endConstructorReference(C, ., new, ConstructorReferenceContext.RedirectingFactory) ensureSemicolon(new) listener: endRedirectingFactoryBody(=, ;) - listener: endClassFactoryMethod(factory, factory, ;) + listener: endFactory(DeclarationKind.Class, factory, factory, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, factory) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, D) @@ -407,7 +407,7 @@ parseUnit(class) listener: endMetadataStar(0) listener: beginMember() parseFactoryMethod(;, DeclarationKind.Class, ;, null, null, null, true) - listener: beginFactoryMethod(DeclarationKind.Class, ;, null, null) + listener: beginFactory(DeclarationKind.Class, ;, null, null) ensureIdentifier(factory, methodDeclaration) listener: handleIdentifier(D, methodDeclaration) parseQualifiedRestOpt(D, methodDeclarationContinuation) @@ -444,7 +444,7 @@ parseUnit(class) listener: endConstructorReference(prefix, ., new, ConstructorReferenceContext.RedirectingFactory) ensureSemicolon(new) listener: endRedirectingFactoryBody(=, ;) - listener: endClassFactoryMethod(factory, factory, ;) + listener: endFactory(DeclarationKind.Class, factory, factory, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, factory) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, D) @@ -453,7 +453,7 @@ parseUnit(class) listener: endMetadataStar(0) listener: beginMember() parseFactoryMethod(;, DeclarationKind.Class, ;, null, null, null, true) - listener: beginFactoryMethod(DeclarationKind.Class, ;, null, null) + listener: beginFactory(DeclarationKind.Class, ;, null, null) ensureIdentifier(factory, methodDeclaration) listener: handleIdentifier(D, methodDeclaration) parseQualifiedRestOpt(D, methodDeclarationContinuation) @@ -494,7 +494,7 @@ parseUnit(class) listener: endConstructorReference(prefix, ., new, ConstructorReferenceContext.RedirectingFactory) ensureSemicolon(new) listener: endRedirectingFactoryBody(=, ;) - listener: endClassFactoryMethod(factory, factory, ;) + listener: endFactory(DeclarationKind.Class, factory, factory, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, D) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, D) @@ -558,7 +558,7 @@ parseUnit(class) inPlainSync() parseFunctionBody(), false, true) listener: handleEmptyFunctionBody(;) - listener: endClassConstructor(D, (, :, ;) + listener: endConstructor(DeclarationKind.Class, D, (, :, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, D) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, D) @@ -621,7 +621,7 @@ parseUnit(class) inPlainSync() parseFunctionBody(), false, true) listener: handleEmptyFunctionBody(;) - listener: endClassConstructor(D, (, :, ;) + listener: endConstructor(DeclarationKind.Class, D, (, :, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 7, {, }) diff --git a/pkg/front_end/parser_testcases/general/operator_01.dart.expect b/pkg/front_end/parser_testcases/general/operator_01.dart.expect index b34925cb398..577de625fb9 100644 --- a/pkg/front_end/parser_testcases/general/operator_01.dart.expect +++ b/pkg/front_end/parser_testcases/general/operator_01.dart.expect @@ -39,7 +39,7 @@ beginCompilationUnit(class) handleLiteralBool(true) endReturnStatement(true, return, ;) endBlockFunctionBody(1, {, }) - endClassMethod(null, bool, (, null, }) + endMethod(DeclarationKind.Class, null, bool, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -68,7 +68,7 @@ beginCompilationUnit(class) handleLiteralInt(42) endReturnStatement(true, return, ;) endBlockFunctionBody(1, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(bool) endMetadataStar(0) @@ -97,7 +97,7 @@ beginCompilationUnit(class) handleLiteralBool(true) endReturnStatement(true, return, ;) endBlockFunctionBody(1, {, }) - endClassMethod(null, bool, (, null, }) + endMethod(DeclarationKind.Class, null, bool, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -126,7 +126,7 @@ beginCompilationUnit(class) handleLiteralInt(42) endReturnStatement(true, return, ;) endBlockFunctionBody(1, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -155,7 +155,7 @@ beginCompilationUnit(class) handleLiteralInt(42) endReturnStatement(true, return, ;) endBlockFunctionBody(1, {, }) - endClassMethod(null, int, (, null, }) + endMethod(DeclarationKind.Class, null, int, (, null, }) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 5, {, }) endClassDeclaration(class, }) diff --git a/pkg/front_end/parser_testcases/general/operator_01.dart.intertwined.expect b/pkg/front_end/parser_testcases/general/operator_01.dart.intertwined.expect index 4302983e125..daa6dceb842 100644 --- a/pkg/front_end/parser_testcases/general/operator_01.dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/general/operator_01.dart.intertwined.expect @@ -85,7 +85,7 @@ parseUnit(class) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(1, {, }) - listener: endClassMethod(null, bool, (, null, }) + listener: endMethod(DeclarationKind.Class, null, bool, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Foo) @@ -145,7 +145,7 @@ parseUnit(class) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(1, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, bool) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Foo) @@ -205,7 +205,7 @@ parseUnit(class) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(1, {, }) - listener: endClassMethod(null, bool, (, null, }) + listener: endMethod(DeclarationKind.Class, null, bool, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Foo) @@ -265,7 +265,7 @@ parseUnit(class) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(1, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Foo) @@ -325,7 +325,7 @@ parseUnit(class) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(1, {, }) - listener: endClassMethod(null, int, (, null, }) + listener: endMethod(DeclarationKind.Class, null, int, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 5, {, }) diff --git a/pkg/front_end/parser_testcases/general/operator_hat_class.crash_dart.expect b/pkg/front_end/parser_testcases/general/operator_hat_class.crash_dart.expect index 847295fab14..0597456df7c 100644 --- a/pkg/front_end/parser_testcases/general/operator_hat_class.crash_dart.expect +++ b/pkg/front_end/parser_testcases/general/operator_hat_class.crash_dart.expect @@ -41,7 +41,7 @@ beginCompilationUnit(class) handleAsyncModifier(null, null) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) - endClassConstructor(operator, (, null, }) + endConstructor(DeclarationKind.Class, operator, (, null, }) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 1, {, }) endClassDeclaration(class, }) diff --git a/pkg/front_end/parser_testcases/general/operator_hat_class.crash_dart.intertwined.expect b/pkg/front_end/parser_testcases/general/operator_hat_class.crash_dart.intertwined.expect index 06f076fc145..dc7f9dfa3d3 100644 --- a/pkg/front_end/parser_testcases/general/operator_hat_class.crash_dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/general/operator_hat_class.crash_dart.intertwined.expect @@ -69,7 +69,7 @@ parseUnit(class) listener: beginBlockFunctionBody({) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(0, {, }) - listener: endClassConstructor(operator, (, null, }) + listener: endConstructor(DeclarationKind.Class, operator, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 1, {, }) diff --git a/pkg/front_end/parser_testcases/inline_class/extension_type.dart.expect b/pkg/front_end/parser_testcases/inline_class/extension_type.dart.expect index dbb2e0dec36..358d23238f1 100644 --- a/pkg/front_end/parser_testcases/inline_class/extension_type.dart.expect +++ b/pkg/front_end/parser_testcases/inline_class/extension_type.dart.expect @@ -131,7 +131,7 @@ beginCompilationUnit(extension) handleNoInitializers() handleAsyncModifier(null, null) handleEmptyFunctionBody(;) - endExtensionTypeConstructor(ExtensionType4, (, null, ;) + endConstructor(DeclarationKind.ExtensionType, ExtensionType4, (, null, ;) endMember() beginMetadataStar(ExtensionType4) endMetadataStar(0) @@ -168,12 +168,12 @@ beginCompilationUnit(extension) endInitializers(1, :, )) handleAsyncModifier(null, null) handleEmptyFunctionBody(;) - endExtensionTypeConstructor(ExtensionType4, (, :, ;) + endConstructor(DeclarationKind.ExtensionType, ExtensionType4, (, :, ;) endMember() beginMetadataStar(factory) endMetadataStar(0) beginMember() - beginFactoryMethod(DeclarationKind.ExtensionType, ;, null, null) + beginFactory(DeclarationKind.ExtensionType, ;, null, null) handleIdentifier(ExtensionType4, methodDeclaration) handleIdentifier(fact, methodDeclarationContinuation) handleQualified(.) @@ -200,12 +200,12 @@ beginCompilationUnit(extension) endArguments(1, (, )) handleSend(ExtensionType4, )) handleExpressionFunctionBody(=>, ;) - endExtensionTypeFactoryMethod(factory, factory, ;) + endFactory(DeclarationKind.ExtensionType, factory, factory, ;) endMember() beginMetadataStar(factory) endMetadataStar(0) beginMember() - beginFactoryMethod(DeclarationKind.ExtensionType, ;, null, null) + beginFactory(DeclarationKind.ExtensionType, ;, null, null) handleIdentifier(ExtensionType4, methodDeclaration) handleIdentifier(redirectingFactory, methodDeclarationContinuation) handleQualified(.) @@ -229,7 +229,7 @@ beginCompilationUnit(extension) handleNoConstructorReferenceContinuationAfterTypeArguments(ExtensionType4) endConstructorReference(ExtensionType4, null, ExtensionType4, ConstructorReferenceContext.RedirectingFactory) endRedirectingFactoryBody(=, ;) - endExtensionTypeFactoryMethod(factory, factory, ;) + endFactory(DeclarationKind.ExtensionType, factory, factory, ;) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -243,7 +243,7 @@ beginCompilationUnit(extension) handleLiteralInt(42) endFieldInitializer(=, 42) handleRecoverableError(ExtensionTypeDeclaresInstanceField, field, field) - endExtensionTypeFields(null, null, null, null, null, null, null, 1, int, ;) + endFields(DeclarationKind.ExtensionType, null, null, null, null, null, null, null, 1, int, ;) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -262,7 +262,7 @@ beginCompilationUnit(extension) handleNoArguments(;) handleSend(it, it) handleExpressionFunctionBody(=>, ;) - endExtensionTypeMethod(get, int, =>, null, ;) + endMethod(DeclarationKind.ExtensionType, get, int, =>, null, ;) endMember() beginMetadataStar(void) endMetadataStar(0) @@ -286,7 +286,7 @@ beginCompilationUnit(extension) handleAsyncModifier(null, null) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) - endExtensionTypeMethod(set, void, (, null, }) + endMethod(DeclarationKind.ExtensionType, set, void, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -306,7 +306,7 @@ beginCompilationUnit(extension) handleNoArguments(;) handleSend(it, it) handleExpressionFunctionBody(=>, ;) - endExtensionTypeMethod(null, int, (, null, ;) + endMethod(DeclarationKind.ExtensionType, null, int, (, null, ;) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -335,7 +335,7 @@ beginCompilationUnit(extension) handleNoArguments(;) handleSend(it, it) handleExpressionFunctionBody(=>, ;) - endExtensionTypeMethod(null, int, (, null, ;) + endMethod(DeclarationKind.ExtensionType, null, int, (, null, ;) endMember() beginMetadataStar(void) endMetadataStar(0) @@ -368,7 +368,7 @@ beginCompilationUnit(extension) handleAsyncModifier(null, null) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) - endExtensionTypeMethod(null, void, (, null, }) + endMethod(DeclarationKind.ExtensionType, null, void, (, null, }) endMember() beginMetadataStar(static) endMetadataStar(0) @@ -381,7 +381,7 @@ beginCompilationUnit(extension) beginFieldInitializer(=) handleLiteralInt(42) endFieldInitializer(=, 42) - endExtensionTypeFields(null, null, null, static, null, null, null, 1, static, ;) + endFields(DeclarationKind.ExtensionType, null, null, null, static, null, null, null, 1, static, ;) endMember() beginMetadataStar(static) endMetadataStar(0) @@ -397,7 +397,7 @@ beginCompilationUnit(extension) handleAsyncModifier(null, null) handleLiteralInt(42) handleExpressionFunctionBody(=>, ;) - endExtensionTypeMethod(get, static, =>, null, ;) + endMethod(DeclarationKind.ExtensionType, get, static, =>, null, ;) endMember() beginMetadataStar(static) endMetadataStar(0) @@ -421,7 +421,7 @@ beginCompilationUnit(extension) handleAsyncModifier(null, null) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) - endExtensionTypeMethod(set, static, (, null, }) + endMethod(DeclarationKind.ExtensionType, set, static, (, null, }) endMember() beginMetadataStar(static) endMetadataStar(0) @@ -438,7 +438,7 @@ beginCompilationUnit(extension) handleAsyncModifier(null, null) handleLiteralInt(42) handleExpressionFunctionBody(=>, ;) - endExtensionTypeMethod(null, static, (, null, ;) + endMethod(DeclarationKind.ExtensionType, null, static, (, null, ;) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.ExtensionType, 14, {, }) endExtensionTypeDeclaration(extension, null, extension, type, }) diff --git a/pkg/front_end/parser_testcases/inline_class/extension_type.dart.intertwined.expect b/pkg/front_end/parser_testcases/inline_class/extension_type.dart.intertwined.expect index 77079e44823..fa827a5d636 100644 --- a/pkg/front_end/parser_testcases/inline_class/extension_type.dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/inline_class/extension_type.dart.intertwined.expect @@ -206,7 +206,7 @@ parseUnit(extension) inPlainSync() parseFunctionBody(), false, true) listener: handleEmptyFunctionBody(;) - listener: endExtensionTypeConstructor(ExtensionType4, (, null, ;) + listener: endConstructor(DeclarationKind.ExtensionType, ExtensionType4, (, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, ExtensionType4) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.ExtensionType, ExtensionType4) @@ -277,7 +277,7 @@ parseUnit(extension) inPlainSync() parseFunctionBody(), false, true) listener: handleEmptyFunctionBody(;) - listener: endExtensionTypeConstructor(ExtensionType4, (, :, ;) + listener: endConstructor(DeclarationKind.ExtensionType, ExtensionType4, (, :, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, factory) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.ExtensionType, ExtensionType4) @@ -286,7 +286,7 @@ parseUnit(extension) listener: endMetadataStar(0) listener: beginMember() parseFactoryMethod(;, DeclarationKind.ExtensionType, ;, null, null, null, true) - listener: beginFactoryMethod(DeclarationKind.ExtensionType, ;, null, null) + listener: beginFactory(DeclarationKind.ExtensionType, ;, null, null) ensureIdentifier(factory, methodDeclaration) listener: handleIdentifier(ExtensionType4, methodDeclaration) parseQualifiedRestOpt(ExtensionType4, methodDeclarationContinuation) @@ -345,7 +345,7 @@ parseUnit(extension) ensureSemicolon()) listener: handleExpressionFunctionBody(=>, ;) inGenerator() - listener: endExtensionTypeFactoryMethod(factory, factory, ;) + listener: endFactory(DeclarationKind.ExtensionType, factory, factory, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, factory) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.ExtensionType, ExtensionType4) @@ -354,7 +354,7 @@ parseUnit(extension) listener: endMetadataStar(0) listener: beginMember() parseFactoryMethod(;, DeclarationKind.ExtensionType, ;, null, null, null, true) - listener: beginFactoryMethod(DeclarationKind.ExtensionType, ;, null, null) + listener: beginFactory(DeclarationKind.ExtensionType, ;, null, null) ensureIdentifier(factory, methodDeclaration) listener: handleIdentifier(ExtensionType4, methodDeclaration) parseQualifiedRestOpt(ExtensionType4, methodDeclarationContinuation) @@ -396,7 +396,7 @@ parseUnit(extension) listener: endConstructorReference(ExtensionType4, null, ExtensionType4, ConstructorReferenceContext.RedirectingFactory) ensureSemicolon(ExtensionType4) listener: endRedirectingFactoryBody(=, ;) - listener: endExtensionTypeFactoryMethod(factory, factory, ;) + listener: endFactory(DeclarationKind.ExtensionType, factory, factory, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.ExtensionType, ExtensionType4) @@ -424,7 +424,7 @@ parseUnit(extension) listener: endFieldInitializer(=, 42) reportRecoverableError(field, ExtensionTypeDeclaresInstanceField) listener: handleRecoverableError(ExtensionTypeDeclaresInstanceField, field, field) - listener: endExtensionTypeFields(null, null, null, null, null, null, null, 1, int, ;) + listener: endFields(DeclarationKind.ExtensionType, null, null, null, null, null, null, null, 1, int, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.ExtensionType, ExtensionType4) @@ -470,7 +470,7 @@ parseUnit(extension) ensureSemicolon(it) listener: handleExpressionFunctionBody(=>, ;) inGenerator() - listener: endExtensionTypeMethod(get, int, =>, null, ;) + listener: endMethod(DeclarationKind.ExtensionType, get, int, =>, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, void) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.ExtensionType, ExtensionType4) @@ -513,7 +513,7 @@ parseUnit(extension) listener: beginBlockFunctionBody({) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(0, {, }) - listener: endExtensionTypeMethod(set, void, (, null, }) + listener: endMethod(DeclarationKind.ExtensionType, set, void, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.ExtensionType, ExtensionType4) @@ -562,7 +562,7 @@ parseUnit(extension) ensureSemicolon(it) listener: handleExpressionFunctionBody(=>, ;) inGenerator() - listener: endExtensionTypeMethod(null, int, (, null, ;) + listener: endMethod(DeclarationKind.ExtensionType, null, int, (, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.ExtensionType, ExtensionType4) @@ -622,7 +622,7 @@ parseUnit(extension) ensureSemicolon(it) listener: handleExpressionFunctionBody(=>, ;) inGenerator() - listener: endExtensionTypeMethod(null, int, (, null, ;) + listener: endMethod(DeclarationKind.ExtensionType, null, int, (, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, void) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.ExtensionType, ExtensionType4) @@ -676,7 +676,7 @@ parseUnit(extension) listener: beginBlockFunctionBody({) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(0, {, }) - listener: endExtensionTypeMethod(null, void, (, null, }) + listener: endMethod(DeclarationKind.ExtensionType, null, void, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, static) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.ExtensionType, ExtensionType4) @@ -702,7 +702,7 @@ parseUnit(extension) parseLiteralInt(=) listener: handleLiteralInt(42) listener: endFieldInitializer(=, 42) - listener: endExtensionTypeFields(null, null, null, static, null, null, null, 1, static, ;) + listener: endFields(DeclarationKind.ExtensionType, null, null, null, static, null, null, null, 1, static, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, static) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.ExtensionType, ExtensionType4) @@ -740,7 +740,7 @@ parseUnit(extension) ensureSemicolon(42) listener: handleExpressionFunctionBody(=>, ;) inGenerator() - listener: endExtensionTypeMethod(get, static, =>, null, ;) + listener: endMethod(DeclarationKind.ExtensionType, get, static, =>, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, static) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.ExtensionType, ExtensionType4) @@ -782,7 +782,7 @@ parseUnit(extension) listener: beginBlockFunctionBody({) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(0, {, }) - listener: endExtensionTypeMethod(set, static, (, null, }) + listener: endMethod(DeclarationKind.ExtensionType, set, static, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, static) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.ExtensionType, ExtensionType4) @@ -823,7 +823,7 @@ parseUnit(extension) ensureSemicolon(42) listener: handleExpressionFunctionBody(=>, ;) inGenerator() - listener: endExtensionTypeMethod(null, static, (, null, ;) + listener: endMethod(DeclarationKind.ExtensionType, null, static, (, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.ExtensionType, 14, {, }) diff --git a/pkg/front_end/parser_testcases/inline_class/extension_type_const.dart.expect b/pkg/front_end/parser_testcases/inline_class/extension_type_const.dart.expect index 53ae47e112d..90566abc451 100644 --- a/pkg/front_end/parser_testcases/inline_class/extension_type_const.dart.expect +++ b/pkg/front_end/parser_testcases/inline_class/extension_type_const.dart.expect @@ -131,7 +131,7 @@ beginCompilationUnit(extension) handleNoInitializers() handleAsyncModifier(null, null) handleEmptyFunctionBody(;) - endExtensionTypeConstructor(const, (, null, ;) + endConstructor(DeclarationKind.ExtensionType, const, (, null, ;) endMember() beginMetadataStar(const) endMetadataStar(0) @@ -168,12 +168,12 @@ beginCompilationUnit(extension) endInitializers(1, :, )) handleAsyncModifier(null, null) handleEmptyFunctionBody(;) - endExtensionTypeConstructor(const, (, :, ;) + endConstructor(DeclarationKind.ExtensionType, const, (, :, ;) endMember() beginMetadataStar(factory) endMetadataStar(0) beginMember() - beginFactoryMethod(DeclarationKind.ExtensionType, ;, null, null) + beginFactory(DeclarationKind.ExtensionType, ;, null, null) handleIdentifier(ExtensionType4, methodDeclaration) handleIdentifier(fact, methodDeclarationContinuation) handleQualified(.) @@ -200,12 +200,12 @@ beginCompilationUnit(extension) endArguments(1, (, )) handleSend(ExtensionType4, )) handleExpressionFunctionBody(=>, ;) - endExtensionTypeFactoryMethod(factory, factory, ;) + endFactory(DeclarationKind.ExtensionType, factory, factory, ;) endMember() beginMetadataStar(const) endMetadataStar(0) beginMember() - beginFactoryMethod(DeclarationKind.ExtensionType, ;, null, const) + beginFactory(DeclarationKind.ExtensionType, ;, null, const) handleIdentifier(ExtensionType4, methodDeclaration) handleIdentifier(redirectingFactory, methodDeclarationContinuation) handleQualified(.) @@ -229,7 +229,7 @@ beginCompilationUnit(extension) handleNoConstructorReferenceContinuationAfterTypeArguments(ExtensionType4) endConstructorReference(ExtensionType4, null, ExtensionType4, ConstructorReferenceContext.RedirectingFactory) endRedirectingFactoryBody(=, ;) - endExtensionTypeFactoryMethod(const, factory, ;) + endFactory(DeclarationKind.ExtensionType, const, factory, ;) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -243,7 +243,7 @@ beginCompilationUnit(extension) handleLiteralInt(42) endFieldInitializer(=, 42) handleRecoverableError(ExtensionTypeDeclaresInstanceField, field, field) - endExtensionTypeFields(null, null, null, null, null, null, null, 1, int, ;) + endFields(DeclarationKind.ExtensionType, null, null, null, null, null, null, null, 1, int, ;) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -262,7 +262,7 @@ beginCompilationUnit(extension) handleNoArguments(;) handleSend(it, it) handleExpressionFunctionBody(=>, ;) - endExtensionTypeMethod(get, int, =>, null, ;) + endMethod(DeclarationKind.ExtensionType, get, int, =>, null, ;) endMember() beginMetadataStar(void) endMetadataStar(0) @@ -286,7 +286,7 @@ beginCompilationUnit(extension) handleAsyncModifier(null, null) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) - endExtensionTypeMethod(set, void, (, null, }) + endMethod(DeclarationKind.ExtensionType, set, void, (, null, }) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -306,7 +306,7 @@ beginCompilationUnit(extension) handleNoArguments(;) handleSend(it, it) handleExpressionFunctionBody(=>, ;) - endExtensionTypeMethod(null, int, (, null, ;) + endMethod(DeclarationKind.ExtensionType, null, int, (, null, ;) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -335,7 +335,7 @@ beginCompilationUnit(extension) handleNoArguments(;) handleSend(it, it) handleExpressionFunctionBody(=>, ;) - endExtensionTypeMethod(null, int, (, null, ;) + endMethod(DeclarationKind.ExtensionType, null, int, (, null, ;) endMember() beginMetadataStar(void) endMetadataStar(0) @@ -368,7 +368,7 @@ beginCompilationUnit(extension) handleAsyncModifier(null, null) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) - endExtensionTypeMethod(null, void, (, null, }) + endMethod(DeclarationKind.ExtensionType, null, void, (, null, }) endMember() beginMetadataStar(static) endMetadataStar(0) @@ -381,7 +381,7 @@ beginCompilationUnit(extension) beginFieldInitializer(=) handleLiteralInt(42) endFieldInitializer(=, 42) - endExtensionTypeFields(null, null, null, static, null, null, null, 1, static, ;) + endFields(DeclarationKind.ExtensionType, null, null, null, static, null, null, null, 1, static, ;) endMember() beginMetadataStar(static) endMetadataStar(0) @@ -397,7 +397,7 @@ beginCompilationUnit(extension) handleAsyncModifier(null, null) handleLiteralInt(42) handleExpressionFunctionBody(=>, ;) - endExtensionTypeMethod(get, static, =>, null, ;) + endMethod(DeclarationKind.ExtensionType, get, static, =>, null, ;) endMember() beginMetadataStar(static) endMetadataStar(0) @@ -421,7 +421,7 @@ beginCompilationUnit(extension) handleAsyncModifier(null, null) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) - endExtensionTypeMethod(set, static, (, null, }) + endMethod(DeclarationKind.ExtensionType, set, static, (, null, }) endMember() beginMetadataStar(static) endMetadataStar(0) @@ -438,7 +438,7 @@ beginCompilationUnit(extension) handleAsyncModifier(null, null) handleLiteralInt(42) handleExpressionFunctionBody(=>, ;) - endExtensionTypeMethod(null, static, (, null, ;) + endMethod(DeclarationKind.ExtensionType, null, static, (, null, ;) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.ExtensionType, 14, {, }) endExtensionTypeDeclaration(extension, null, extension, type, }) diff --git a/pkg/front_end/parser_testcases/inline_class/extension_type_const.dart.intertwined.expect b/pkg/front_end/parser_testcases/inline_class/extension_type_const.dart.intertwined.expect index b8857d11172..e98a18f00d9 100644 --- a/pkg/front_end/parser_testcases/inline_class/extension_type_const.dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/inline_class/extension_type_const.dart.intertwined.expect @@ -205,7 +205,7 @@ parseUnit(extension) inPlainSync() parseFunctionBody(), false, true) listener: handleEmptyFunctionBody(;) - listener: endExtensionTypeConstructor(const, (, null, ;) + listener: endConstructor(DeclarationKind.ExtensionType, const, (, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, const) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.ExtensionType, ExtensionType4) @@ -275,7 +275,7 @@ parseUnit(extension) inPlainSync() parseFunctionBody(), false, true) listener: handleEmptyFunctionBody(;) - listener: endExtensionTypeConstructor(const, (, :, ;) + listener: endConstructor(DeclarationKind.ExtensionType, const, (, :, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, factory) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.ExtensionType, ExtensionType4) @@ -284,7 +284,7 @@ parseUnit(extension) listener: endMetadataStar(0) listener: beginMember() parseFactoryMethod(;, DeclarationKind.ExtensionType, ;, null, null, null, true) - listener: beginFactoryMethod(DeclarationKind.ExtensionType, ;, null, null) + listener: beginFactory(DeclarationKind.ExtensionType, ;, null, null) ensureIdentifier(factory, methodDeclaration) listener: handleIdentifier(ExtensionType4, methodDeclaration) parseQualifiedRestOpt(ExtensionType4, methodDeclarationContinuation) @@ -343,7 +343,7 @@ parseUnit(extension) ensureSemicolon()) listener: handleExpressionFunctionBody(=>, ;) inGenerator() - listener: endExtensionTypeFactoryMethod(factory, factory, ;) + listener: endFactory(DeclarationKind.ExtensionType, factory, factory, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, const) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.ExtensionType, ExtensionType4) @@ -352,7 +352,7 @@ parseUnit(extension) listener: endMetadataStar(0) listener: beginMember() parseFactoryMethod(const, DeclarationKind.ExtensionType, ;, null, null, const, true) - listener: beginFactoryMethod(DeclarationKind.ExtensionType, ;, null, const) + listener: beginFactory(DeclarationKind.ExtensionType, ;, null, const) ensureIdentifier(factory, methodDeclaration) listener: handleIdentifier(ExtensionType4, methodDeclaration) parseQualifiedRestOpt(ExtensionType4, methodDeclarationContinuation) @@ -394,7 +394,7 @@ parseUnit(extension) listener: endConstructorReference(ExtensionType4, null, ExtensionType4, ConstructorReferenceContext.RedirectingFactory) ensureSemicolon(ExtensionType4) listener: endRedirectingFactoryBody(=, ;) - listener: endExtensionTypeFactoryMethod(const, factory, ;) + listener: endFactory(DeclarationKind.ExtensionType, const, factory, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.ExtensionType, ExtensionType4) @@ -422,7 +422,7 @@ parseUnit(extension) listener: endFieldInitializer(=, 42) reportRecoverableError(field, ExtensionTypeDeclaresInstanceField) listener: handleRecoverableError(ExtensionTypeDeclaresInstanceField, field, field) - listener: endExtensionTypeFields(null, null, null, null, null, null, null, 1, int, ;) + listener: endFields(DeclarationKind.ExtensionType, null, null, null, null, null, null, null, 1, int, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.ExtensionType, ExtensionType4) @@ -468,7 +468,7 @@ parseUnit(extension) ensureSemicolon(it) listener: handleExpressionFunctionBody(=>, ;) inGenerator() - listener: endExtensionTypeMethod(get, int, =>, null, ;) + listener: endMethod(DeclarationKind.ExtensionType, get, int, =>, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, void) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.ExtensionType, ExtensionType4) @@ -511,7 +511,7 @@ parseUnit(extension) listener: beginBlockFunctionBody({) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(0, {, }) - listener: endExtensionTypeMethod(set, void, (, null, }) + listener: endMethod(DeclarationKind.ExtensionType, set, void, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.ExtensionType, ExtensionType4) @@ -560,7 +560,7 @@ parseUnit(extension) ensureSemicolon(it) listener: handleExpressionFunctionBody(=>, ;) inGenerator() - listener: endExtensionTypeMethod(null, int, (, null, ;) + listener: endMethod(DeclarationKind.ExtensionType, null, int, (, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.ExtensionType, ExtensionType4) @@ -620,7 +620,7 @@ parseUnit(extension) ensureSemicolon(it) listener: handleExpressionFunctionBody(=>, ;) inGenerator() - listener: endExtensionTypeMethod(null, int, (, null, ;) + listener: endMethod(DeclarationKind.ExtensionType, null, int, (, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, void) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.ExtensionType, ExtensionType4) @@ -674,7 +674,7 @@ parseUnit(extension) listener: beginBlockFunctionBody({) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(0, {, }) - listener: endExtensionTypeMethod(null, void, (, null, }) + listener: endMethod(DeclarationKind.ExtensionType, null, void, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, static) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.ExtensionType, ExtensionType4) @@ -700,7 +700,7 @@ parseUnit(extension) parseLiteralInt(=) listener: handleLiteralInt(42) listener: endFieldInitializer(=, 42) - listener: endExtensionTypeFields(null, null, null, static, null, null, null, 1, static, ;) + listener: endFields(DeclarationKind.ExtensionType, null, null, null, static, null, null, null, 1, static, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, static) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.ExtensionType, ExtensionType4) @@ -738,7 +738,7 @@ parseUnit(extension) ensureSemicolon(42) listener: handleExpressionFunctionBody(=>, ;) inGenerator() - listener: endExtensionTypeMethod(get, static, =>, null, ;) + listener: endMethod(DeclarationKind.ExtensionType, get, static, =>, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, static) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.ExtensionType, ExtensionType4) @@ -780,7 +780,7 @@ parseUnit(extension) listener: beginBlockFunctionBody({) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(0, {, }) - listener: endExtensionTypeMethod(set, static, (, null, }) + listener: endMethod(DeclarationKind.ExtensionType, set, static, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, static) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.ExtensionType, ExtensionType4) @@ -821,7 +821,7 @@ parseUnit(extension) ensureSemicolon(42) listener: handleExpressionFunctionBody(=>, ;) inGenerator() - listener: endExtensionTypeMethod(null, static, (, null, ;) + listener: endMethod(DeclarationKind.ExtensionType, null, static, (, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.ExtensionType, 14, {, }) diff --git a/pkg/front_end/parser_testcases/nnbd/error_recovery/abstract_placement.dart.expect b/pkg/front_end/parser_testcases/nnbd/error_recovery/abstract_placement.dart.expect index 71c0c8a547b..ec75899dff7 100644 --- a/pkg/front_end/parser_testcases/nnbd/error_recovery/abstract_placement.dart.expect +++ b/pkg/front_end/parser_testcases/nnbd/error_recovery/abstract_placement.dart.expect @@ -76,7 +76,7 @@ beginCompilationUnit(abstract) handleType(int, null) handleIdentifier(i1, fieldDeclaration) handleNoFieldInitializer(;) - endClassFields(abstract, null, null, null, null, null, final, 1, final, ;) + endFields(DeclarationKind.Class, abstract, null, null, null, null, null, final, 1, final, ;) endMember() beginMetadataStar(final) endMetadataStar(0) @@ -86,7 +86,7 @@ beginCompilationUnit(abstract) handleNoType(abstract) handleIdentifier(i2, fieldDeclaration) handleNoFieldInitializer(;) - endClassFields(abstract, null, null, null, null, null, final, 1, final, ;) + endFields(DeclarationKind.Class, abstract, null, null, null, null, null, final, 1, final, ;) endMember() beginMetadataStar(covariant) endMetadataStar(0) @@ -98,7 +98,7 @@ beginCompilationUnit(abstract) handleType(num, null) handleIdentifier(i3, fieldDeclaration) handleNoFieldInitializer(;) - endClassFields(abstract, null, null, null, covariant, null, null, 1, covariant, ;) + endFields(DeclarationKind.Class, abstract, null, null, null, covariant, null, null, 1, covariant, ;) endMember() beginMetadataStar(covariant) endMetadataStar(0) @@ -108,7 +108,7 @@ beginCompilationUnit(abstract) handleNoType(var) handleIdentifier(i4, fieldDeclaration) handleNoFieldInitializer(;) - endClassFields(abstract, null, null, null, covariant, null, var, 1, covariant, ;) + endFields(DeclarationKind.Class, abstract, null, null, null, covariant, null, var, 1, covariant, ;) endMember() beginMetadataStar(final) endMetadataStar(0) @@ -118,7 +118,7 @@ beginCompilationUnit(abstract) handleNoType(abstract) handleIdentifier(i5, fieldDeclaration) handleNoFieldInitializer(;) - endClassFields(abstract, null, null, null, null, null, final, 1, final, ;) + endFields(DeclarationKind.Class, abstract, null, null, null, null, null, final, 1, final, ;) endMember() beginMetadataStar(var) endMetadataStar(0) @@ -128,7 +128,7 @@ beginCompilationUnit(abstract) handleNoType(abstract) handleIdentifier(i6, fieldDeclaration) handleNoFieldInitializer(;) - endClassFields(abstract, null, null, null, null, null, var, 1, var, ;) + endFields(DeclarationKind.Class, abstract, null, null, null, null, null, var, 1, var, ;) endMember() beginMetadataStar(C) endMetadataStar(0) @@ -140,7 +140,7 @@ beginCompilationUnit(abstract) handleIdentifier(abstract, fieldDeclaration) handleNoFieldInitializer(i7) handleRecoverableError(Message[Template(ExpectedAfterButGot), Expected ';' after this., null, {string: ;}], abstract, abstract) - endClassFields(null, null, null, null, null, null, null, 1, C, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, C, ;) endMember() beginMetadataStar(i7) endMetadataStar(0) @@ -150,7 +150,7 @@ beginCompilationUnit(abstract) handleNoType(;) handleIdentifier(i7, fieldDeclaration) handleNoFieldInitializer(;) - endClassFields(null, null, null, null, null, null, null, 1, i7, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, i7, ;) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 8, {, }) endClassDeclaration(abstract, }) @@ -189,7 +189,7 @@ beginCompilationUnit(abstract) handleNoType(required) handleIdentifier(x, fieldDeclaration) handleNoFieldInitializer(;) - endClassFields(null, null, null, null, covariant, null, null, 1, covariant, ;) + endFields(DeclarationKind.Class, null, null, null, null, covariant, null, null, 1, covariant, ;) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 1, {, }) endClassDeclaration(abstract, }) diff --git a/pkg/front_end/parser_testcases/nnbd/error_recovery/abstract_placement.dart.intertwined.expect b/pkg/front_end/parser_testcases/nnbd/error_recovery/abstract_placement.dart.intertwined.expect index ba4b543aef5..1d93e4d0c18 100644 --- a/pkg/front_end/parser_testcases/nnbd/error_recovery/abstract_placement.dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/nnbd/error_recovery/abstract_placement.dart.intertwined.expect @@ -46,7 +46,7 @@ parseUnit(abstract) listener: handleIdentifier(i1, fieldDeclaration) parseFieldInitializerOpt(i1, i1, null, abstract, null, null, final, DeclarationKind.Class, C) listener: handleNoFieldInitializer(;) - listener: endClassFields(abstract, null, null, null, null, null, final, 1, final, ;) + listener: endFields(DeclarationKind.Class, abstract, null, null, null, null, null, final, 1, final, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, final) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, C) @@ -65,7 +65,7 @@ parseUnit(abstract) listener: handleIdentifier(i2, fieldDeclaration) parseFieldInitializerOpt(i2, i2, null, abstract, null, null, final, DeclarationKind.Class, C) listener: handleNoFieldInitializer(;) - listener: endClassFields(abstract, null, null, null, null, null, final, 1, final, ;) + listener: endFields(DeclarationKind.Class, abstract, null, null, null, null, null, final, 1, final, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, covariant) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, C) @@ -84,7 +84,7 @@ parseUnit(abstract) listener: handleIdentifier(i3, fieldDeclaration) parseFieldInitializerOpt(i3, i3, null, abstract, null, null, null, DeclarationKind.Class, C) listener: handleNoFieldInitializer(;) - listener: endClassFields(abstract, null, null, null, covariant, null, null, 1, covariant, ;) + listener: endFields(DeclarationKind.Class, abstract, null, null, null, covariant, null, null, 1, covariant, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, covariant) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, C) @@ -103,7 +103,7 @@ parseUnit(abstract) listener: handleIdentifier(i4, fieldDeclaration) parseFieldInitializerOpt(i4, i4, null, abstract, null, null, var, DeclarationKind.Class, C) listener: handleNoFieldInitializer(;) - listener: endClassFields(abstract, null, null, null, covariant, null, var, 1, covariant, ;) + listener: endFields(DeclarationKind.Class, abstract, null, null, null, covariant, null, var, 1, covariant, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, final) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, C) @@ -122,7 +122,7 @@ parseUnit(abstract) listener: handleIdentifier(i5, fieldDeclaration) parseFieldInitializerOpt(i5, i5, null, abstract, null, null, final, DeclarationKind.Class, C) listener: handleNoFieldInitializer(;) - listener: endClassFields(abstract, null, null, null, null, null, final, 1, final, ;) + listener: endFields(DeclarationKind.Class, abstract, null, null, null, null, null, final, 1, final, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, var) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, C) @@ -141,7 +141,7 @@ parseUnit(abstract) listener: handleIdentifier(i6, fieldDeclaration) parseFieldInitializerOpt(i6, i6, null, abstract, null, null, var, DeclarationKind.Class, C) listener: handleNoFieldInitializer(;) - listener: endClassFields(abstract, null, null, null, null, null, var, 1, var, ;) + listener: endFields(DeclarationKind.Class, abstract, null, null, null, null, null, var, 1, var, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, C) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, C) @@ -162,7 +162,7 @@ parseUnit(abstract) reportRecoverableError(abstract, Message[Template(ExpectedAfterButGot), Expected ';' after this., null, {string: ;}]) listener: handleRecoverableError(Message[Template(ExpectedAfterButGot), Expected ';' after this., null, {string: ;}], abstract, abstract) rewriter() - listener: endClassFields(null, null, null, null, null, null, null, 1, C, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, C, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, i7) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, C) @@ -180,7 +180,7 @@ parseUnit(abstract) listener: handleIdentifier(i7, fieldDeclaration) parseFieldInitializerOpt(i7, i7, null, null, null, null, null, DeclarationKind.Class, C) listener: handleNoFieldInitializer(;) - listener: endClassFields(null, null, null, null, null, null, null, 1, i7, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, i7, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 8, {, }) @@ -252,7 +252,7 @@ parseUnit(abstract) listener: handleIdentifier(x, fieldDeclaration) parseFieldInitializerOpt(x, x, null, null, null, null, null, DeclarationKind.Class, Bar) listener: handleNoFieldInitializer(;) - listener: endClassFields(null, null, null, null, covariant, null, null, 1, covariant, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, covariant, null, null, 1, covariant, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 1, {, }) diff --git a/pkg/front_end/parser_testcases/nnbd/error_recovery/external_placement.dart.expect b/pkg/front_end/parser_testcases/nnbd/error_recovery/external_placement.dart.expect index fd93a78eef2..bf3c0d25c32 100644 --- a/pkg/front_end/parser_testcases/nnbd/error_recovery/external_placement.dart.expect +++ b/pkg/front_end/parser_testcases/nnbd/error_recovery/external_placement.dart.expect @@ -82,7 +82,7 @@ beginCompilationUnit(final) handleType(num, null) handleIdentifier(i3, fieldDeclaration) handleNoFieldInitializer(;) - endClassFields(null, null, external, null, covariant, null, null, 1, covariant, ;) + endFields(DeclarationKind.Class, null, null, external, null, covariant, null, null, 1, covariant, ;) endMember() beginMetadataStar(final) endMetadataStar(0) @@ -94,7 +94,7 @@ beginCompilationUnit(final) handleType(int, null) handleIdentifier(i4, fieldDeclaration) handleNoFieldInitializer(;) - endClassFields(null, null, external, null, null, null, final, 1, final, ;) + endFields(DeclarationKind.Class, null, null, external, null, null, null, final, 1, final, ;) endMember() beginMetadataStar(final) endMetadataStar(0) @@ -104,7 +104,7 @@ beginCompilationUnit(final) handleNoType(external) handleIdentifier(i5, fieldDeclaration) handleNoFieldInitializer(;) - endClassFields(null, null, external, null, null, null, final, 1, final, ;) + endFields(DeclarationKind.Class, null, null, external, null, null, null, final, 1, final, ;) endMember() beginMetadataStar(static) endMetadataStar(0) @@ -114,7 +114,7 @@ beginCompilationUnit(final) handleNoType(final) handleIdentifier(i6, fieldDeclaration) handleNoFieldInitializer(;) - endClassFields(null, null, external, static, null, null, final, 1, static, ;) + endFields(DeclarationKind.Class, null, null, external, static, null, null, final, 1, static, ;) endMember() beginMetadataStar(static) endMetadataStar(0) @@ -124,7 +124,7 @@ beginCompilationUnit(final) handleNoType(external) handleIdentifier(i7, fieldDeclaration) handleNoFieldInitializer(;) - endClassFields(null, null, external, static, null, null, final, 1, static, ;) + endFields(DeclarationKind.Class, null, null, external, static, null, null, final, 1, static, ;) endMember() beginMetadataStar(final) endMetadataStar(0) @@ -135,7 +135,7 @@ beginCompilationUnit(final) handleNoType(external) handleIdentifier(i8, fieldDeclaration) handleNoFieldInitializer(;) - endClassFields(null, null, external, static, null, null, final, 1, final, ;) + endFields(DeclarationKind.Class, null, null, external, static, null, null, final, 1, final, ;) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 6, {, }) endClassDeclaration(class, }) diff --git a/pkg/front_end/parser_testcases/nnbd/error_recovery/external_placement.dart.intertwined.expect b/pkg/front_end/parser_testcases/nnbd/error_recovery/external_placement.dart.intertwined.expect index 5dbb2212dc3..782da25c2a3 100644 --- a/pkg/front_end/parser_testcases/nnbd/error_recovery/external_placement.dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/nnbd/error_recovery/external_placement.dart.intertwined.expect @@ -84,7 +84,7 @@ parseUnit(final) listener: handleIdentifier(i3, fieldDeclaration) parseFieldInitializerOpt(i3, i3, null, null, null, external, null, DeclarationKind.Class, C) listener: handleNoFieldInitializer(;) - listener: endClassFields(null, null, external, null, covariant, null, null, 1, covariant, ;) + listener: endFields(DeclarationKind.Class, null, null, external, null, covariant, null, null, 1, covariant, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, final) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, C) @@ -105,7 +105,7 @@ parseUnit(final) listener: handleIdentifier(i4, fieldDeclaration) parseFieldInitializerOpt(i4, i4, null, null, null, external, final, DeclarationKind.Class, C) listener: handleNoFieldInitializer(;) - listener: endClassFields(null, null, external, null, null, null, final, 1, final, ;) + listener: endFields(DeclarationKind.Class, null, null, external, null, null, null, final, 1, final, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, final) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, C) @@ -124,7 +124,7 @@ parseUnit(final) listener: handleIdentifier(i5, fieldDeclaration) parseFieldInitializerOpt(i5, i5, null, null, null, external, final, DeclarationKind.Class, C) listener: handleNoFieldInitializer(;) - listener: endClassFields(null, null, external, null, null, null, final, 1, final, ;) + listener: endFields(DeclarationKind.Class, null, null, external, null, null, null, final, 1, final, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, static) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, C) @@ -143,7 +143,7 @@ parseUnit(final) listener: handleIdentifier(i6, fieldDeclaration) parseFieldInitializerOpt(i6, i6, null, null, null, external, final, DeclarationKind.Class, C) listener: handleNoFieldInitializer(;) - listener: endClassFields(null, null, external, static, null, null, final, 1, static, ;) + listener: endFields(DeclarationKind.Class, null, null, external, static, null, null, final, 1, static, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, static) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, C) @@ -162,7 +162,7 @@ parseUnit(final) listener: handleIdentifier(i7, fieldDeclaration) parseFieldInitializerOpt(i7, i7, null, null, null, external, final, DeclarationKind.Class, C) listener: handleNoFieldInitializer(;) - listener: endClassFields(null, null, external, static, null, null, final, 1, static, ;) + listener: endFields(DeclarationKind.Class, null, null, external, static, null, null, final, 1, static, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, final) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, C) @@ -183,7 +183,7 @@ parseUnit(final) listener: handleIdentifier(i8, fieldDeclaration) parseFieldInitializerOpt(i8, i8, null, null, null, external, final, DeclarationKind.Class, C) listener: handleNoFieldInitializer(;) - listener: endClassFields(null, null, external, static, null, null, final, 1, final, ;) + listener: endFields(DeclarationKind.Class, null, null, external, static, null, null, final, 1, final, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 6, {, }) diff --git a/pkg/front_end/parser_testcases/nnbd/error_recovery/late_without_var_etc.dart.expect b/pkg/front_end/parser_testcases/nnbd/error_recovery/late_without_var_etc.dart.expect index 536f1d40d61..1e8b6751239 100644 --- a/pkg/front_end/parser_testcases/nnbd/error_recovery/late_without_var_etc.dart.expect +++ b/pkg/front_end/parser_testcases/nnbd/error_recovery/late_without_var_etc.dart.expect @@ -76,7 +76,7 @@ beginCompilationUnit(void) handleNoType(late) handleIdentifier(z, fieldDeclaration) handleNoFieldInitializer(;) - endClassFields(null, null, null, null, null, late, null, 1, late, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, late, null, 1, late, ;) endMember() beginMetadataStar(void) endMetadataStar(0) @@ -101,7 +101,7 @@ beginCompilationUnit(void) endInitializedIdentifier(x) endVariablesDeclaration(1, ;) endBlockFunctionBody(1, {, }) - endClassMethod(null, void, (, null, }) + endMethod(DeclarationKind.Class, null, void, (, null, }) endMember() beginMetadataStar(static) endMetadataStar(0) @@ -126,7 +126,7 @@ beginCompilationUnit(void) endInitializedIdentifier(x) endVariablesDeclaration(1, ;) endBlockFunctionBody(1, {, }) - endClassMethod(null, static, (, null, }) + endMethod(DeclarationKind.Class, null, static, (, null, }) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 3, {, }) endClassDeclaration(class, }) diff --git a/pkg/front_end/parser_testcases/nnbd/error_recovery/late_without_var_etc.dart.intertwined.expect b/pkg/front_end/parser_testcases/nnbd/error_recovery/late_without_var_etc.dart.intertwined.expect index 74b93f29b4d..e41471da4aa 100644 --- a/pkg/front_end/parser_testcases/nnbd/error_recovery/late_without_var_etc.dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/nnbd/error_recovery/late_without_var_etc.dart.intertwined.expect @@ -110,7 +110,7 @@ parseUnit(void) listener: handleIdentifier(z, fieldDeclaration) parseFieldInitializerOpt(z, z, late, null, null, null, null, DeclarationKind.Class, Foo) listener: handleNoFieldInitializer(;) - listener: endClassFields(null, null, null, null, null, late, null, 1, late, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, late, null, 1, late, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, void) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Foo) @@ -163,7 +163,7 @@ parseUnit(void) listener: endVariablesDeclaration(1, ;) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(1, {, }) - listener: endClassMethod(null, void, (, null, }) + listener: endMethod(DeclarationKind.Class, null, void, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, static) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Foo) @@ -215,7 +215,7 @@ parseUnit(void) listener: endVariablesDeclaration(1, ;) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(1, {, }) - listener: endClassMethod(null, static, (, null, }) + listener: endMethod(DeclarationKind.Class, null, static, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 3, {, }) diff --git a/pkg/front_end/parser_testcases/nnbd/issue_39723.dart.expect b/pkg/front_end/parser_testcases/nnbd/issue_39723.dart.expect index 8898e4585ee..8fd3c9935f2 100644 --- a/pkg/front_end/parser_testcases/nnbd/issue_39723.dart.expect +++ b/pkg/front_end/parser_testcases/nnbd/issue_39723.dart.expect @@ -37,7 +37,7 @@ beginCompilationUnit(class) handleNoArguments(;) handleSend(index, index) handleExpressionFunctionBody(=>, ;) - endClassMethod(null, operator, (, null, ;) + endMethod(DeclarationKind.Class, null, operator, (, null, ;) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 1, {, }) endClassDeclaration(class, }) diff --git a/pkg/front_end/parser_testcases/nnbd/issue_39723.dart.intertwined.expect b/pkg/front_end/parser_testcases/nnbd/issue_39723.dart.intertwined.expect index 77afcf58d6f..1bc9cc2fb5d 100644 --- a/pkg/front_end/parser_testcases/nnbd/issue_39723.dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/nnbd/issue_39723.dart.intertwined.expect @@ -83,7 +83,7 @@ parseUnit(class) ensureSemicolon(index) listener: handleExpressionFunctionBody(=>, ;) inGenerator() - listener: endClassMethod(null, operator, (, null, ;) + listener: endMethod(DeclarationKind.Class, null, operator, (, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 1, {, }) diff --git a/pkg/front_end/parser_testcases/nnbd/issue_39723_prime.dart.expect b/pkg/front_end/parser_testcases/nnbd/issue_39723_prime.dart.expect index ef133c50974..c5e3dbe1235 100644 --- a/pkg/front_end/parser_testcases/nnbd/issue_39723_prime.dart.expect +++ b/pkg/front_end/parser_testcases/nnbd/issue_39723_prime.dart.expect @@ -37,7 +37,7 @@ beginCompilationUnit(class) handleNoArguments(;) handleSend(index, index) handleExpressionFunctionBody(=>, ;) - endClassMethod(null, operator, (, null, ;) + endMethod(DeclarationKind.Class, null, operator, (, null, ;) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 1, {, }) endClassDeclaration(class, }) diff --git a/pkg/front_end/parser_testcases/nnbd/issue_39723_prime.dart.intertwined.expect b/pkg/front_end/parser_testcases/nnbd/issue_39723_prime.dart.intertwined.expect index 90a7a8a1db4..2784811f7bc 100644 --- a/pkg/front_end/parser_testcases/nnbd/issue_39723_prime.dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/nnbd/issue_39723_prime.dart.intertwined.expect @@ -83,7 +83,7 @@ parseUnit(class) ensureSemicolon(index) listener: handleExpressionFunctionBody(=>, ;) inGenerator() - listener: endClassMethod(null, operator, (, null, ;) + listener: endMethod(DeclarationKind.Class, null, operator, (, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 1, {, }) diff --git a/pkg/front_end/parser_testcases/nnbd/issue_39858.dart.expect b/pkg/front_end/parser_testcases/nnbd/issue_39858.dart.expect index 53c647ea25b..a053f1a61f4 100644 --- a/pkg/front_end/parser_testcases/nnbd/issue_39858.dart.expect +++ b/pkg/front_end/parser_testcases/nnbd/issue_39858.dart.expect @@ -46,7 +46,7 @@ beginCompilationUnit(class) handleNoType(late) handleIdentifier(x1, fieldDeclaration) handleNoFieldInitializer(;) - endClassFields(null, null, null, null, null, late, null, 1, late, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, late, null, 1, late, ;) endMember() beginMetadataStar(static) endMetadataStar(0) @@ -56,7 +56,7 @@ beginCompilationUnit(class) handleNoType(late) handleIdentifier(x2, fieldDeclaration) handleNoFieldInitializer(;) - endClassFields(null, null, null, static, null, late, null, 1, static, ;) + endFields(DeclarationKind.Class, null, null, null, static, null, late, null, 1, static, ;) endMember() beginMetadataStar(covariant) endMetadataStar(0) @@ -66,7 +66,7 @@ beginCompilationUnit(class) handleNoType(late) handleIdentifier(x3, fieldDeclaration) handleNoFieldInitializer(;) - endClassFields(null, null, null, null, covariant, late, null, 1, covariant, ;) + endFields(DeclarationKind.Class, null, null, null, null, covariant, late, null, 1, covariant, ;) endMember() beginMetadataStar(late) endMetadataStar(0) @@ -78,7 +78,7 @@ beginCompilationUnit(class) beginFieldInitializer(=) handleLiteralInt(0) endFieldInitializer(=, 0) - endClassFields(null, null, null, null, null, late, null, 1, late, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, late, null, 1, late, ;) endMember() beginMetadataStar(static) endMetadataStar(0) @@ -90,7 +90,7 @@ beginCompilationUnit(class) beginFieldInitializer(=) handleLiteralInt(0) endFieldInitializer(=, 0) - endClassFields(null, null, null, static, null, late, null, 1, static, ;) + endFields(DeclarationKind.Class, null, null, null, static, null, late, null, 1, static, ;) endMember() beginMetadataStar(covariant) endMetadataStar(0) @@ -102,7 +102,7 @@ beginCompilationUnit(class) beginFieldInitializer(=) handleLiteralInt(0) endFieldInitializer(=, 0) - endClassFields(null, null, null, null, covariant, late, null, 1, covariant, ;) + endFields(DeclarationKind.Class, null, null, null, null, covariant, late, null, 1, covariant, ;) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 6, {, }) endClassDeclaration(class, }) diff --git a/pkg/front_end/parser_testcases/nnbd/issue_39858.dart.intertwined.expect b/pkg/front_end/parser_testcases/nnbd/issue_39858.dart.intertwined.expect index 28f1552bdea..fc4b6eaa9e5 100644 --- a/pkg/front_end/parser_testcases/nnbd/issue_39858.dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/nnbd/issue_39858.dart.intertwined.expect @@ -43,7 +43,7 @@ parseUnit(class) listener: handleIdentifier(x1, fieldDeclaration) parseFieldInitializerOpt(x1, x1, late, null, null, null, null, DeclarationKind.Class, X) listener: handleNoFieldInitializer(;) - listener: endClassFields(null, null, null, null, null, late, null, 1, late, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, late, null, 1, late, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, static) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, X) @@ -61,7 +61,7 @@ parseUnit(class) listener: handleIdentifier(x2, fieldDeclaration) parseFieldInitializerOpt(x2, x2, late, null, null, null, null, DeclarationKind.Class, X) listener: handleNoFieldInitializer(;) - listener: endClassFields(null, null, null, static, null, late, null, 1, static, ;) + listener: endFields(DeclarationKind.Class, null, null, null, static, null, late, null, 1, static, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, covariant) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, X) @@ -79,7 +79,7 @@ parseUnit(class) listener: handleIdentifier(x3, fieldDeclaration) parseFieldInitializerOpt(x3, x3, late, null, null, null, null, DeclarationKind.Class, X) listener: handleNoFieldInitializer(;) - listener: endClassFields(null, null, null, null, covariant, late, null, 1, covariant, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, covariant, late, null, 1, covariant, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, late) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, X) @@ -106,7 +106,7 @@ parseUnit(class) parseLiteralInt(=) listener: handleLiteralInt(0) listener: endFieldInitializer(=, 0) - listener: endClassFields(null, null, null, null, null, late, null, 1, late, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, late, null, 1, late, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, static) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, X) @@ -133,7 +133,7 @@ parseUnit(class) parseLiteralInt(=) listener: handleLiteralInt(0) listener: endFieldInitializer(=, 0) - listener: endClassFields(null, null, null, static, null, late, null, 1, static, ;) + listener: endFields(DeclarationKind.Class, null, null, null, static, null, late, null, 1, static, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, covariant) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, X) @@ -160,7 +160,7 @@ parseUnit(class) parseLiteralInt(=) listener: handleLiteralInt(0) listener: endFieldInitializer(=, 0) - listener: endClassFields(null, null, null, null, covariant, late, null, 1, covariant, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, covariant, late, null, 1, covariant, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 6, {, }) diff --git a/pkg/front_end/parser_testcases/nnbd/issue_39858_prime1.dart.expect b/pkg/front_end/parser_testcases/nnbd/issue_39858_prime1.dart.expect index 63570610d41..cba28412c0b 100644 --- a/pkg/front_end/parser_testcases/nnbd/issue_39858_prime1.dart.expect +++ b/pkg/front_end/parser_testcases/nnbd/issue_39858_prime1.dart.expect @@ -19,7 +19,7 @@ beginCompilationUnit(class) handleNoType(var) handleIdentifier(x1, fieldDeclaration) handleNoFieldInitializer(;) - endClassFields(null, null, null, null, null, null, var, 1, var, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, var, 1, var, ;) endMember() beginMetadataStar(static) endMetadataStar(0) @@ -28,7 +28,7 @@ beginCompilationUnit(class) handleNoType(var) handleIdentifier(x2, fieldDeclaration) handleNoFieldInitializer(;) - endClassFields(null, null, null, static, null, null, var, 1, static, ;) + endFields(DeclarationKind.Class, null, null, null, static, null, null, var, 1, static, ;) endMember() beginMetadataStar(covariant) endMetadataStar(0) @@ -37,7 +37,7 @@ beginCompilationUnit(class) handleNoType(var) handleIdentifier(x3, fieldDeclaration) handleNoFieldInitializer(;) - endClassFields(null, null, null, null, covariant, null, var, 1, covariant, ;) + endFields(DeclarationKind.Class, null, null, null, null, covariant, null, var, 1, covariant, ;) endMember() beginMetadataStar(var) endMetadataStar(0) @@ -48,7 +48,7 @@ beginCompilationUnit(class) beginFieldInitializer(=) handleLiteralInt(0) endFieldInitializer(=, 0) - endClassFields(null, null, null, null, null, null, var, 1, var, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, var, 1, var, ;) endMember() beginMetadataStar(static) endMetadataStar(0) @@ -59,7 +59,7 @@ beginCompilationUnit(class) beginFieldInitializer(=) handleLiteralInt(0) endFieldInitializer(=, 0) - endClassFields(null, null, null, static, null, null, var, 1, static, ;) + endFields(DeclarationKind.Class, null, null, null, static, null, null, var, 1, static, ;) endMember() beginMetadataStar(covariant) endMetadataStar(0) @@ -70,7 +70,7 @@ beginCompilationUnit(class) beginFieldInitializer(=) handleLiteralInt(0) endFieldInitializer(=, 0) - endClassFields(null, null, null, null, covariant, null, var, 1, covariant, ;) + endFields(DeclarationKind.Class, null, null, null, null, covariant, null, var, 1, covariant, ;) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 6, {, }) endClassDeclaration(class, }) diff --git a/pkg/front_end/parser_testcases/nnbd/issue_39858_prime1.dart.intertwined.expect b/pkg/front_end/parser_testcases/nnbd/issue_39858_prime1.dart.intertwined.expect index b7e010ff9c2..4ab5e7cb926 100644 --- a/pkg/front_end/parser_testcases/nnbd/issue_39858_prime1.dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/nnbd/issue_39858_prime1.dart.intertwined.expect @@ -42,7 +42,7 @@ parseUnit(class) listener: handleIdentifier(x1, fieldDeclaration) parseFieldInitializerOpt(x1, x1, null, null, null, null, var, DeclarationKind.Class, X) listener: handleNoFieldInitializer(;) - listener: endClassFields(null, null, null, null, null, null, var, 1, var, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, var, 1, var, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, static) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, X) @@ -59,7 +59,7 @@ parseUnit(class) listener: handleIdentifier(x2, fieldDeclaration) parseFieldInitializerOpt(x2, x2, null, null, null, null, var, DeclarationKind.Class, X) listener: handleNoFieldInitializer(;) - listener: endClassFields(null, null, null, static, null, null, var, 1, static, ;) + listener: endFields(DeclarationKind.Class, null, null, null, static, null, null, var, 1, static, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, covariant) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, X) @@ -76,7 +76,7 @@ parseUnit(class) listener: handleIdentifier(x3, fieldDeclaration) parseFieldInitializerOpt(x3, x3, null, null, null, null, var, DeclarationKind.Class, X) listener: handleNoFieldInitializer(;) - listener: endClassFields(null, null, null, null, covariant, null, var, 1, covariant, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, covariant, null, var, 1, covariant, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, var) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, X) @@ -102,7 +102,7 @@ parseUnit(class) parseLiteralInt(=) listener: handleLiteralInt(0) listener: endFieldInitializer(=, 0) - listener: endClassFields(null, null, null, null, null, null, var, 1, var, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, var, 1, var, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, static) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, X) @@ -128,7 +128,7 @@ parseUnit(class) parseLiteralInt(=) listener: handleLiteralInt(0) listener: endFieldInitializer(=, 0) - listener: endClassFields(null, null, null, static, null, null, var, 1, static, ;) + listener: endFields(DeclarationKind.Class, null, null, null, static, null, null, var, 1, static, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, covariant) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, X) @@ -154,7 +154,7 @@ parseUnit(class) parseLiteralInt(=) listener: handleLiteralInt(0) listener: endFieldInitializer(=, 0) - listener: endClassFields(null, null, null, null, covariant, null, var, 1, covariant, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, covariant, null, var, 1, covariant, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 6, {, }) diff --git a/pkg/front_end/parser_testcases/nnbd/issue_40805_01.dart.expect b/pkg/front_end/parser_testcases/nnbd/issue_40805_01.dart.expect index 0a5780199c4..953ea66876f 100644 --- a/pkg/front_end/parser_testcases/nnbd/issue_40805_01.dart.expect +++ b/pkg/front_end/parser_testcases/nnbd/issue_40805_01.dart.expect @@ -21,7 +21,7 @@ beginCompilationUnit(class) handleType(int, null) handleIdentifier(x, fieldDeclaration) handleNoFieldInitializer(;) - endClassFields(null, null, null, null, covariant, late, final, 1, covariant, ;) + endFields(DeclarationKind.Class, null, null, null, null, covariant, late, final, 1, covariant, ;) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 1, {, }) endClassDeclaration(class, }) diff --git a/pkg/front_end/parser_testcases/nnbd/issue_40805_01.dart.intertwined.expect b/pkg/front_end/parser_testcases/nnbd/issue_40805_01.dart.intertwined.expect index df7bda561e5..f928dcf74a7 100644 --- a/pkg/front_end/parser_testcases/nnbd/issue_40805_01.dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/nnbd/issue_40805_01.dart.intertwined.expect @@ -44,7 +44,7 @@ parseUnit(class) listener: handleIdentifier(x, fieldDeclaration) parseFieldInitializerOpt(x, x, late, null, null, null, final, DeclarationKind.Class, C) listener: handleNoFieldInitializer(;) - listener: endClassFields(null, null, null, null, covariant, late, final, 1, covariant, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, covariant, late, final, 1, covariant, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 1, {, }) diff --git a/pkg/front_end/parser_testcases/nnbd/issue_40805_02.dart.expect b/pkg/front_end/parser_testcases/nnbd/issue_40805_02.dart.expect index 8dfda8057fb..4951411c966 100644 --- a/pkg/front_end/parser_testcases/nnbd/issue_40805_02.dart.expect +++ b/pkg/front_end/parser_testcases/nnbd/issue_40805_02.dart.expect @@ -30,7 +30,7 @@ beginCompilationUnit(class) beginFieldInitializer(=) handleLiteralInt(42) endFieldInitializer(=, 42) - endClassFields(null, null, null, null, null, late, final, 1, covariant, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, late, final, 1, covariant, ;) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 1, {, }) endClassDeclaration(class, }) diff --git a/pkg/front_end/parser_testcases/nnbd/issue_40805_02.dart.intertwined.expect b/pkg/front_end/parser_testcases/nnbd/issue_40805_02.dart.intertwined.expect index ec0bb7c9391..08090a85988 100644 --- a/pkg/front_end/parser_testcases/nnbd/issue_40805_02.dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/nnbd/issue_40805_02.dart.intertwined.expect @@ -55,7 +55,7 @@ parseUnit(class) parseLiteralInt(=) listener: handleLiteralInt(42) listener: endFieldInitializer(=, 42) - listener: endClassFields(null, null, null, null, null, late, final, 1, covariant, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, late, final, 1, covariant, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 1, {, }) diff --git a/pkg/front_end/parser_testcases/nnbd/issue_40805_03.dart.expect b/pkg/front_end/parser_testcases/nnbd/issue_40805_03.dart.expect index d35abc4a9cd..f13ef7b5771 100644 --- a/pkg/front_end/parser_testcases/nnbd/issue_40805_03.dart.expect +++ b/pkg/front_end/parser_testcases/nnbd/issue_40805_03.dart.expect @@ -30,7 +30,7 @@ beginCompilationUnit(class) beginFieldInitializer(=) handleLiteralInt(42) endFieldInitializer(=, 42) - endClassFields(null, null, null, null, null, null, final, 1, covariant, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, covariant, ;) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 1, {, }) endClassDeclaration(class, }) diff --git a/pkg/front_end/parser_testcases/nnbd/issue_40805_03.dart.intertwined.expect b/pkg/front_end/parser_testcases/nnbd/issue_40805_03.dart.intertwined.expect index a32ad8db64c..6681c814f53 100644 --- a/pkg/front_end/parser_testcases/nnbd/issue_40805_03.dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/nnbd/issue_40805_03.dart.intertwined.expect @@ -55,7 +55,7 @@ parseUnit(class) parseLiteralInt(=) listener: handleLiteralInt(42) listener: endFieldInitializer(=, 42) - listener: endClassFields(null, null, null, null, null, null, final, 1, covariant, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, covariant, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 1, {, }) diff --git a/pkg/front_end/parser_testcases/nnbd/issue_40834_01.dart.expect b/pkg/front_end/parser_testcases/nnbd/issue_40834_01.dart.expect index a2a51f9c599..da6bf2ffefd 100644 --- a/pkg/front_end/parser_testcases/nnbd/issue_40834_01.dart.expect +++ b/pkg/front_end/parser_testcases/nnbd/issue_40834_01.dart.expect @@ -21,7 +21,7 @@ beginCompilationUnit(class) handleType(String, ?) handleIdentifier(x, fieldDeclaration) handleNoFieldInitializer(;) - endClassFields(null, null, null, null, null, null, null, 1, String, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, String, ;) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -32,7 +32,7 @@ beginCompilationUnit(class) handleType(int, null) handleIdentifier(y, fieldDeclaration) handleNoFieldInitializer(;) - endClassFields(null, null, null, null, null, null, null, 1, int, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) endMember() beginMetadataStar(Foo) endMetadataStar(0) @@ -81,7 +81,7 @@ beginCompilationUnit(class) endInitializers(2, :, 0) handleAsyncModifier(null, null) handleEmptyFunctionBody(;) - endClassConstructor(Foo, (, :, ;) + endConstructor(DeclarationKind.Class, Foo, (, :, ;) endMember() beginMetadataStar(Foo) endMetadataStar(0) @@ -145,7 +145,7 @@ beginCompilationUnit(class) endInitializers(2, :, null) handleAsyncModifier(null, null) handleEmptyFunctionBody(;) - endClassConstructor(Foo, (, :, ;) + endConstructor(DeclarationKind.Class, Foo, (, :, ;) endMember() beginMetadataStar(Foo) endMetadataStar(0) @@ -209,7 +209,7 @@ beginCompilationUnit(class) endInitializers(2, :, null) handleAsyncModifier(null, null) handleEmptyFunctionBody(;) - endClassConstructor(Foo, (, :, ;) + endConstructor(DeclarationKind.Class, Foo, (, :, ;) endMember() beginMetadataStar(Foo) endMetadataStar(0) @@ -273,7 +273,7 @@ beginCompilationUnit(class) endInitializers(2, :, null) handleAsyncModifier(null, null) handleEmptyFunctionBody(;) - endClassConstructor(Foo, (, :, ;) + endConstructor(DeclarationKind.Class, Foo, (, :, ;) endMember() beginMetadataStar(Foo) endMetadataStar(0) @@ -337,7 +337,7 @@ beginCompilationUnit(class) endInitializers(2, :, null) handleAsyncModifier(null, null) handleEmptyFunctionBody(;) - endClassConstructor(Foo, (, :, ;) + endConstructor(DeclarationKind.Class, Foo, (, :, ;) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 7, {, }) endClassDeclaration(class, }) diff --git a/pkg/front_end/parser_testcases/nnbd/issue_40834_01.dart.intertwined.expect b/pkg/front_end/parser_testcases/nnbd/issue_40834_01.dart.intertwined.expect index f8ae47dcdd6..cc44854bc34 100644 --- a/pkg/front_end/parser_testcases/nnbd/issue_40834_01.dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/nnbd/issue_40834_01.dart.intertwined.expect @@ -42,7 +42,7 @@ parseUnit(class) listener: handleIdentifier(x, fieldDeclaration) parseFieldInitializerOpt(x, x, null, null, null, null, null, DeclarationKind.Class, Foo) listener: handleNoFieldInitializer(;) - listener: endClassFields(null, null, null, null, null, null, null, 1, String, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, String, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Foo) @@ -59,7 +59,7 @@ parseUnit(class) listener: handleIdentifier(y, fieldDeclaration) parseFieldInitializerOpt(y, y, null, null, null, null, null, DeclarationKind.Class, Foo) listener: handleNoFieldInitializer(;) - listener: endClassFields(null, null, null, null, null, null, null, 1, int, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, Foo) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Foo) @@ -168,7 +168,7 @@ parseUnit(class) inPlainSync() parseFunctionBody(0, false, true) listener: handleEmptyFunctionBody(;) - listener: endClassConstructor(Foo, (, :, ;) + listener: endConstructor(DeclarationKind.Class, Foo, (, :, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, Foo) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Foo) @@ -314,7 +314,7 @@ parseUnit(class) inPlainSync() parseFunctionBody(null, false, true) listener: handleEmptyFunctionBody(;) - listener: endClassConstructor(Foo, (, :, ;) + listener: endConstructor(DeclarationKind.Class, Foo, (, :, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, Foo) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Foo) @@ -460,7 +460,7 @@ parseUnit(class) inPlainSync() parseFunctionBody(null, false, true) listener: handleEmptyFunctionBody(;) - listener: endClassConstructor(Foo, (, :, ;) + listener: endConstructor(DeclarationKind.Class, Foo, (, :, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, Foo) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Foo) @@ -606,7 +606,7 @@ parseUnit(class) inPlainSync() parseFunctionBody(null, false, true) listener: handleEmptyFunctionBody(;) - listener: endClassConstructor(Foo, (, :, ;) + listener: endConstructor(DeclarationKind.Class, Foo, (, :, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, Foo) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Foo) @@ -752,7 +752,7 @@ parseUnit(class) inPlainSync() parseFunctionBody(null, false, true) listener: handleEmptyFunctionBody(;) - listener: endClassConstructor(Foo, (, :, ;) + listener: endConstructor(DeclarationKind.Class, Foo, (, :, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 7, {, }) diff --git a/pkg/front_end/parser_testcases/nnbd/issue_40834_02.dart.expect b/pkg/front_end/parser_testcases/nnbd/issue_40834_02.dart.expect index fb20ba81dc3..36f0e1bf109 100644 --- a/pkg/front_end/parser_testcases/nnbd/issue_40834_02.dart.expect +++ b/pkg/front_end/parser_testcases/nnbd/issue_40834_02.dart.expect @@ -21,7 +21,7 @@ beginCompilationUnit(class) handleType(String, ?) handleIdentifier(x, fieldDeclaration) handleNoFieldInitializer(;) - endClassFields(null, null, null, null, null, null, null, 1, String, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, String, ;) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -32,7 +32,7 @@ beginCompilationUnit(class) handleType(int, null) handleIdentifier(y, fieldDeclaration) handleNoFieldInitializer(;) - endClassFields(null, null, null, null, null, null, null, 1, int, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) endMember() beginMetadataStar(Foo) endMetadataStar(0) @@ -81,7 +81,7 @@ beginCompilationUnit(class) endInitializers(2, :, 0) handleAsyncModifier(null, null) handleEmptyFunctionBody(;) - endClassConstructor(Foo, (, :, ;) + endConstructor(DeclarationKind.Class, Foo, (, :, ;) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 3, {, }) endClassDeclaration(class, }) diff --git a/pkg/front_end/parser_testcases/nnbd/issue_40834_02.dart.intertwined.expect b/pkg/front_end/parser_testcases/nnbd/issue_40834_02.dart.intertwined.expect index f92e13d3fab..78ca4b160cb 100644 --- a/pkg/front_end/parser_testcases/nnbd/issue_40834_02.dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/nnbd/issue_40834_02.dart.intertwined.expect @@ -42,7 +42,7 @@ parseUnit(class) listener: handleIdentifier(x, fieldDeclaration) parseFieldInitializerOpt(x, x, null, null, null, null, null, DeclarationKind.Class, Foo) listener: handleNoFieldInitializer(;) - listener: endClassFields(null, null, null, null, null, null, null, 1, String, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, String, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Foo) @@ -59,7 +59,7 @@ parseUnit(class) listener: handleIdentifier(y, fieldDeclaration) parseFieldInitializerOpt(y, y, null, null, null, null, null, DeclarationKind.Class, Foo) listener: handleNoFieldInitializer(;) - listener: endClassFields(null, null, null, null, null, null, null, 1, int, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, Foo) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Foo) @@ -168,7 +168,7 @@ parseUnit(class) inPlainSync() parseFunctionBody(0, false, true) listener: handleEmptyFunctionBody(;) - listener: endClassConstructor(Foo, (, :, ;) + listener: endConstructor(DeclarationKind.Class, Foo, (, :, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 3, {, }) diff --git a/pkg/front_end/parser_testcases/nnbd/issue_40834_03.dart.expect b/pkg/front_end/parser_testcases/nnbd/issue_40834_03.dart.expect index 5cea5cdc177..d593b37ae99 100644 --- a/pkg/front_end/parser_testcases/nnbd/issue_40834_03.dart.expect +++ b/pkg/front_end/parser_testcases/nnbd/issue_40834_03.dart.expect @@ -21,7 +21,7 @@ beginCompilationUnit(class) handleType(String, ?) handleIdentifier(x, fieldDeclaration) handleNoFieldInitializer(;) - endClassFields(null, null, null, null, null, null, null, 1, String, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, String, ;) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -32,7 +32,7 @@ beginCompilationUnit(class) handleType(int, null) handleIdentifier(y, fieldDeclaration) handleNoFieldInitializer(;) - endClassFields(null, null, null, null, null, null, null, 1, int, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) endMember() beginMetadataStar(Foo) endMetadataStar(0) @@ -92,7 +92,7 @@ beginCompilationUnit(class) endInitializers(2, :, 0) handleAsyncModifier(null, null) handleEmptyFunctionBody(;) - endClassConstructor(Foo, (, :, ;) + endConstructor(DeclarationKind.Class, Foo, (, :, ;) endMember() beginMetadataStar(void) endMetadataStar(0) @@ -149,7 +149,7 @@ beginCompilationUnit(class) endThenStatement({, }) endIfStatement(if, null, }) endBlockFunctionBody(1, {, }) - endClassMethod(null, void, (, null, }) + endMethod(DeclarationKind.Class, null, void, (, null, }) endMember() beginMetadataStar(void) endMetadataStar(0) @@ -206,7 +206,7 @@ beginCompilationUnit(class) endThenStatement({, }) endIfStatement(if, null, }) endBlockFunctionBody(1, {, }) - endClassMethod(null, void, (, null, }) + endMethod(DeclarationKind.Class, null, void, (, null, }) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 5, {, }) endClassDeclaration(class, }) diff --git a/pkg/front_end/parser_testcases/nnbd/issue_40834_03.dart.intertwined.expect b/pkg/front_end/parser_testcases/nnbd/issue_40834_03.dart.intertwined.expect index c9e41af5038..9a97a0ab904 100644 --- a/pkg/front_end/parser_testcases/nnbd/issue_40834_03.dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/nnbd/issue_40834_03.dart.intertwined.expect @@ -42,7 +42,7 @@ parseUnit(class) listener: handleIdentifier(x, fieldDeclaration) parseFieldInitializerOpt(x, x, null, null, null, null, null, DeclarationKind.Class, Foo) listener: handleNoFieldInitializer(;) - listener: endClassFields(null, null, null, null, null, null, null, 1, String, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, String, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Foo) @@ -59,7 +59,7 @@ parseUnit(class) listener: handleIdentifier(y, fieldDeclaration) parseFieldInitializerOpt(y, y, null, null, null, null, null, DeclarationKind.Class, Foo) listener: handleNoFieldInitializer(;) - listener: endClassFields(null, null, null, null, null, null, null, 1, int, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, Foo) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Foo) @@ -198,7 +198,7 @@ parseUnit(class) inPlainSync() parseFunctionBody(0, false, true) listener: handleEmptyFunctionBody(;) - listener: endClassConstructor(Foo, (, :, ;) + listener: endConstructor(DeclarationKind.Class, Foo, (, :, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, void) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Foo) @@ -338,7 +338,7 @@ parseUnit(class) listener: endIfStatement(if, null, }) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(1, {, }) - listener: endClassMethod(null, void, (, null, }) + listener: endMethod(DeclarationKind.Class, null, void, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, void) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Foo) @@ -478,7 +478,7 @@ parseUnit(class) listener: endIfStatement(if, null, }) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(1, {, }) - listener: endClassMethod(null, void, (, null, }) + listener: endMethod(DeclarationKind.Class, null, void, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 5, {, }) diff --git a/pkg/front_end/parser_testcases/nnbd/issue_41597.dart.expect b/pkg/front_end/parser_testcases/nnbd/issue_41597.dart.expect index 8edc714f321..5fa3db59b62 100644 --- a/pkg/front_end/parser_testcases/nnbd/issue_41597.dart.expect +++ b/pkg/front_end/parser_testcases/nnbd/issue_41597.dart.expect @@ -102,7 +102,7 @@ beginCompilationUnit(bool) endInitializers(1, :, )) handleAsyncModifier(null, null) handleEmptyFunctionBody(;) - endClassConstructor(C, (, :, ;) + endConstructor(DeclarationKind.Class, C, (, :, ;) endMember() beginMetadataStar(C) endMetadataStar(0) @@ -127,7 +127,7 @@ beginCompilationUnit(bool) endInitializers(1, :, !) handleAsyncModifier(null, null) handleEmptyFunctionBody(;) - endClassConstructor(C, (, :, ;) + endConstructor(DeclarationKind.Class, C, (, :, ;) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 2, {, }) endClassDeclaration(class, }) diff --git a/pkg/front_end/parser_testcases/nnbd/issue_41597.dart.intertwined.expect b/pkg/front_end/parser_testcases/nnbd/issue_41597.dart.intertwined.expect index 68bb16e9969..e1aa6991a48 100644 --- a/pkg/front_end/parser_testcases/nnbd/issue_41597.dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/nnbd/issue_41597.dart.intertwined.expect @@ -263,7 +263,7 @@ parseUnit(bool) inPlainSync() parseFunctionBody(), false, true) listener: handleEmptyFunctionBody(;) - listener: endClassConstructor(C, (, :, ;) + listener: endConstructor(DeclarationKind.Class, C, (, :, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, C) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, C) @@ -319,7 +319,7 @@ parseUnit(bool) inPlainSync() parseFunctionBody(!, false, true) listener: handleEmptyFunctionBody(;) - listener: endClassConstructor(C, (, :, ;) + listener: endConstructor(DeclarationKind.Class, C, (, :, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 2, {, }) diff --git a/pkg/front_end/parser_testcases/nnbd/issue_42621.dart.expect b/pkg/front_end/parser_testcases/nnbd/issue_42621.dart.expect index d37e52b2687..21c21203463 100644 --- a/pkg/front_end/parser_testcases/nnbd/issue_42621.dart.expect +++ b/pkg/front_end/parser_testcases/nnbd/issue_42621.dart.expect @@ -326,7 +326,7 @@ beginCompilationUnit(Order) handleType(List, ?) handleIdentifier(x, fieldDeclaration) handleNoFieldInitializer(;) - endClassFields(null, null, null, null, null, null, null, 1, List, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, List, ;) endMember() beginMetadataStar(int) endMetadataStar(0) @@ -337,7 +337,7 @@ beginCompilationUnit(Order) handleType(int, ?) handleIdentifier(y, fieldDeclaration) handleNoFieldInitializer(;) - endClassFields(null, null, null, null, null, null, null, 1, int, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 2, {, }) endClassDeclaration(class, }) diff --git a/pkg/front_end/parser_testcases/nnbd/issue_42621.dart.intertwined.expect b/pkg/front_end/parser_testcases/nnbd/issue_42621.dart.intertwined.expect index 52af2b746c7..de9fb79216d 100644 --- a/pkg/front_end/parser_testcases/nnbd/issue_42621.dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/nnbd/issue_42621.dart.intertwined.expect @@ -680,7 +680,7 @@ parseUnit(Order) listener: handleIdentifier(x, fieldDeclaration) parseFieldInitializerOpt(x, x, null, null, null, null, null, DeclarationKind.Class, Order) listener: handleNoFieldInitializer(;) - listener: endClassFields(null, null, null, null, null, null, null, 1, List, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, List, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, int) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Order) @@ -697,7 +697,7 @@ parseUnit(Order) listener: handleIdentifier(y, fieldDeclaration) parseFieldInitializerOpt(y, y, null, null, null, null, null, DeclarationKind.Class, Order) listener: handleNoFieldInitializer(;) - listener: endClassFields(null, null, null, null, null, null, null, 1, int, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 2, {, }) diff --git a/pkg/front_end/parser_testcases/nnbd/issue_49132.dart.expect b/pkg/front_end/parser_testcases/nnbd/issue_49132.dart.expect index fc5e65f9ebf..85619e7dcf7 100644 --- a/pkg/front_end/parser_testcases/nnbd/issue_49132.dart.expect +++ b/pkg/front_end/parser_testcases/nnbd/issue_49132.dart.expect @@ -79,7 +79,7 @@ beginCompilationUnit(class) endInitializers(2, :, ?) handleAsyncModifier(null, null) handleEmptyFunctionBody(;) - endClassConstructor(Foo, (, :, ;) + endConstructor(DeclarationKind.Class, Foo, (, :, ;) endMember() beginMetadataStar(Foo) endMetadataStar(0) @@ -148,7 +148,7 @@ beginCompilationUnit(class) endInitializers(2, :, ?) handleAsyncModifier(null, null) handleEmptyFunctionBody(;) - endClassConstructor(Foo, (, :, ;) + endConstructor(DeclarationKind.Class, Foo, (, :, ;) endMember() beginMetadataStar(Foo) endMetadataStar(0) @@ -217,7 +217,7 @@ beginCompilationUnit(class) endInitializers(2, :, int) handleAsyncModifier(null, null) handleEmptyFunctionBody(;) - endClassConstructor(Foo, (, :, ;) + endConstructor(DeclarationKind.Class, Foo, (, :, ;) endMember() beginMetadataStar(Foo) endMetadataStar(0) @@ -286,7 +286,7 @@ beginCompilationUnit(class) endInitializers(2, :, int) handleAsyncModifier(null, null) handleEmptyFunctionBody(;) - endClassConstructor(Foo, (, :, ;) + endConstructor(DeclarationKind.Class, Foo, (, :, ;) endMember() beginMetadataStar(Foo) endMetadataStar(0) @@ -356,7 +356,7 @@ beginCompilationUnit(class) handleAsyncModifier(null, null) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) - endClassConstructor(Foo, (, :, }) + endConstructor(DeclarationKind.Class, Foo, (, :, }) endMember() beginMetadataStar(Foo) endMetadataStar(0) @@ -426,7 +426,7 @@ beginCompilationUnit(class) handleAsyncModifier(null, null) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) - endClassConstructor(Foo, (, :, }) + endConstructor(DeclarationKind.Class, Foo, (, :, }) endMember() beginMetadataStar(Foo) endMetadataStar(0) @@ -496,7 +496,7 @@ beginCompilationUnit(class) handleAsyncModifier(null, null) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) - endClassConstructor(Foo, (, :, }) + endConstructor(DeclarationKind.Class, Foo, (, :, }) endMember() beginMetadataStar(Foo) endMetadataStar(0) @@ -566,7 +566,7 @@ beginCompilationUnit(class) handleAsyncModifier(null, null) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) - endClassConstructor(Foo, (, :, }) + endConstructor(DeclarationKind.Class, Foo, (, :, }) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 8, {, }) endClassDeclaration(class, }) diff --git a/pkg/front_end/parser_testcases/nnbd/issue_49132.dart.intertwined.expect b/pkg/front_end/parser_testcases/nnbd/issue_49132.dart.intertwined.expect index 2c3bb631a70..c1414cefb09 100644 --- a/pkg/front_end/parser_testcases/nnbd/issue_49132.dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/nnbd/issue_49132.dart.intertwined.expect @@ -165,7 +165,7 @@ parseUnit(class) inPlainSync() parseFunctionBody(?, false, true) listener: handleEmptyFunctionBody(;) - listener: endClassConstructor(Foo, (, :, ;) + listener: endConstructor(DeclarationKind.Class, Foo, (, :, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, Foo) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Foo) @@ -305,7 +305,7 @@ parseUnit(class) inPlainSync() parseFunctionBody(?, false, true) listener: handleEmptyFunctionBody(;) - listener: endClassConstructor(Foo, (, :, ;) + listener: endConstructor(DeclarationKind.Class, Foo, (, :, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, Foo) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Foo) @@ -445,7 +445,7 @@ parseUnit(class) inPlainSync() parseFunctionBody(int, false, true) listener: handleEmptyFunctionBody(;) - listener: endClassConstructor(Foo, (, :, ;) + listener: endConstructor(DeclarationKind.Class, Foo, (, :, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, Foo) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Foo) @@ -585,7 +585,7 @@ parseUnit(class) inPlainSync() parseFunctionBody(int, false, true) listener: handleEmptyFunctionBody(;) - listener: endClassConstructor(Foo, (, :, ;) + listener: endConstructor(DeclarationKind.Class, Foo, (, :, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, Foo) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Foo) @@ -733,7 +733,7 @@ parseUnit(class) listener: beginBlockFunctionBody({) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(0, {, }) - listener: endClassConstructor(Foo, (, :, }) + listener: endConstructor(DeclarationKind.Class, Foo, (, :, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, Foo) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Foo) @@ -881,7 +881,7 @@ parseUnit(class) listener: beginBlockFunctionBody({) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(0, {, }) - listener: endClassConstructor(Foo, (, :, }) + listener: endConstructor(DeclarationKind.Class, Foo, (, :, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, Foo) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Foo) @@ -1023,7 +1023,7 @@ parseUnit(class) listener: beginBlockFunctionBody({) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(0, {, }) - listener: endClassConstructor(Foo, (, :, }) + listener: endConstructor(DeclarationKind.Class, Foo, (, :, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, Foo) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Foo) @@ -1165,7 +1165,7 @@ parseUnit(class) listener: beginBlockFunctionBody({) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(0, {, }) - listener: endClassConstructor(Foo, (, :, }) + listener: endConstructor(DeclarationKind.Class, Foo, (, :, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 8, {, }) diff --git a/pkg/front_end/parser_testcases/nnbd/issue_49132_not_nullable.dart.expect b/pkg/front_end/parser_testcases/nnbd/issue_49132_not_nullable.dart.expect index 5540f824d2c..38613936e93 100644 --- a/pkg/front_end/parser_testcases/nnbd/issue_49132_not_nullable.dart.expect +++ b/pkg/front_end/parser_testcases/nnbd/issue_49132_not_nullable.dart.expect @@ -21,7 +21,7 @@ beginCompilationUnit(class) handleType(dynamic, null) handleIdentifier(x, fieldDeclaration) handleNoFieldInitializer(;) - endClassFields(null, null, null, null, null, null, null, 1, dynamic, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, dynamic, ;) endMember() beginMetadataStar(Foo) endMetadataStar(0) @@ -72,7 +72,7 @@ beginCompilationUnit(class) handleAsyncModifier(null, null) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) - endClassConstructor(Foo, (, :, }) + endConstructor(DeclarationKind.Class, Foo, (, :, }) endMember() beginMetadataStar(Foo) endMetadataStar(0) @@ -132,7 +132,7 @@ beginCompilationUnit(class) handleAsyncModifier(null, null) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) - endClassConstructor(Foo, (, :, }) + endConstructor(DeclarationKind.Class, Foo, (, :, }) endMember() beginMetadataStar(Foo) endMetadataStar(0) @@ -183,7 +183,7 @@ beginCompilationUnit(class) handleAsyncModifier(null, null) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) - endClassConstructor(Foo, (, :, }) + endConstructor(DeclarationKind.Class, Foo, (, :, }) endMember() beginMetadataStar(Foo) endMetadataStar(0) @@ -243,7 +243,7 @@ beginCompilationUnit(class) handleAsyncModifier(null, null) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) - endClassConstructor(Foo, (, :, }) + endConstructor(DeclarationKind.Class, Foo, (, :, }) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 5, {, }) endClassDeclaration(class, }) diff --git a/pkg/front_end/parser_testcases/nnbd/issue_49132_not_nullable.dart.intertwined.expect b/pkg/front_end/parser_testcases/nnbd/issue_49132_not_nullable.dart.intertwined.expect index 8d0156d20d2..df8dcdecb1e 100644 --- a/pkg/front_end/parser_testcases/nnbd/issue_49132_not_nullable.dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/nnbd/issue_49132_not_nullable.dart.intertwined.expect @@ -42,7 +42,7 @@ parseUnit(class) listener: handleIdentifier(x, fieldDeclaration) parseFieldInitializerOpt(x, x, null, null, null, null, null, DeclarationKind.Class, Foo) listener: handleNoFieldInitializer(;) - listener: endClassFields(null, null, null, null, null, null, null, 1, dynamic, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, dynamic, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, Foo) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Foo) @@ -168,7 +168,7 @@ parseUnit(class) listener: beginBlockFunctionBody({) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(0, {, }) - listener: endClassConstructor(Foo, (, :, }) + listener: endConstructor(DeclarationKind.Class, Foo, (, :, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, Foo) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Foo) @@ -361,7 +361,7 @@ parseUnit(class) listener: beginBlockFunctionBody({) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(0, {, }) - listener: endClassConstructor(Foo, (, :, }) + listener: endConstructor(DeclarationKind.Class, Foo, (, :, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, Foo) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Foo) @@ -487,7 +487,7 @@ parseUnit(class) listener: beginBlockFunctionBody({) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(0, {, }) - listener: endClassConstructor(Foo, (, :, }) + listener: endConstructor(DeclarationKind.Class, Foo, (, :, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, Foo) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Foo) @@ -680,7 +680,7 @@ parseUnit(class) listener: beginBlockFunctionBody({) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(0, {, }) - listener: endClassConstructor(Foo, (, :, }) + listener: endConstructor(DeclarationKind.Class, Foo, (, :, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 5, {, }) diff --git a/pkg/front_end/parser_testcases/nnbd/issue_49132_prime.dart.expect b/pkg/front_end/parser_testcases/nnbd/issue_49132_prime.dart.expect index fccbf928c94..5d0e8637605 100644 --- a/pkg/front_end/parser_testcases/nnbd/issue_49132_prime.dart.expect +++ b/pkg/front_end/parser_testcases/nnbd/issue_49132_prime.dart.expect @@ -83,7 +83,7 @@ beginCompilationUnit(class) endInitializers(2, :, )) handleAsyncModifier(null, null) handleEmptyFunctionBody(;) - endClassConstructor(Foo, (, :, ;) + endConstructor(DeclarationKind.Class, Foo, (, :, ;) endMember() beginMetadataStar(Foo) endMetadataStar(0) @@ -156,7 +156,7 @@ beginCompilationUnit(class) endInitializers(2, :, )) handleAsyncModifier(null, null) handleEmptyFunctionBody(;) - endClassConstructor(Foo, (, :, ;) + endConstructor(DeclarationKind.Class, Foo, (, :, ;) endMember() beginMetadataStar(Foo) endMetadataStar(0) @@ -229,7 +229,7 @@ beginCompilationUnit(class) endInitializers(2, :, )) handleAsyncModifier(null, null) handleEmptyFunctionBody(;) - endClassConstructor(Foo, (, :, ;) + endConstructor(DeclarationKind.Class, Foo, (, :, ;) endMember() beginMetadataStar(Foo) endMetadataStar(0) @@ -302,7 +302,7 @@ beginCompilationUnit(class) endInitializers(2, :, )) handleAsyncModifier(null, null) handleEmptyFunctionBody(;) - endClassConstructor(Foo, (, :, ;) + endConstructor(DeclarationKind.Class, Foo, (, :, ;) endMember() beginMetadataStar(Foo) endMetadataStar(0) @@ -376,7 +376,7 @@ beginCompilationUnit(class) handleAsyncModifier(null, null) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) - endClassConstructor(Foo, (, :, }) + endConstructor(DeclarationKind.Class, Foo, (, :, }) endMember() beginMetadataStar(Foo) endMetadataStar(0) @@ -450,7 +450,7 @@ beginCompilationUnit(class) handleAsyncModifier(null, null) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) - endClassConstructor(Foo, (, :, }) + endConstructor(DeclarationKind.Class, Foo, (, :, }) endMember() beginMetadataStar(Foo) endMetadataStar(0) @@ -524,7 +524,7 @@ beginCompilationUnit(class) handleAsyncModifier(null, null) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) - endClassConstructor(Foo, (, :, }) + endConstructor(DeclarationKind.Class, Foo, (, :, }) endMember() beginMetadataStar(Foo) endMetadataStar(0) @@ -598,7 +598,7 @@ beginCompilationUnit(class) handleAsyncModifier(null, null) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) - endClassConstructor(Foo, (, :, }) + endConstructor(DeclarationKind.Class, Foo, (, :, }) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 8, {, }) endClassDeclaration(class, }) diff --git a/pkg/front_end/parser_testcases/nnbd/issue_49132_prime.dart.intertwined.expect b/pkg/front_end/parser_testcases/nnbd/issue_49132_prime.dart.intertwined.expect index 097d980476f..5311e2082bb 100644 --- a/pkg/front_end/parser_testcases/nnbd/issue_49132_prime.dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/nnbd/issue_49132_prime.dart.intertwined.expect @@ -189,7 +189,7 @@ parseUnit(class) inPlainSync() parseFunctionBody(), false, true) listener: handleEmptyFunctionBody(;) - listener: endClassConstructor(Foo, (, :, ;) + listener: endConstructor(DeclarationKind.Class, Foo, (, :, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, Foo) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Foo) @@ -353,7 +353,7 @@ parseUnit(class) inPlainSync() parseFunctionBody(), false, true) listener: handleEmptyFunctionBody(;) - listener: endClassConstructor(Foo, (, :, ;) + listener: endConstructor(DeclarationKind.Class, Foo, (, :, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, Foo) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Foo) @@ -517,7 +517,7 @@ parseUnit(class) inPlainSync() parseFunctionBody(), false, true) listener: handleEmptyFunctionBody(;) - listener: endClassConstructor(Foo, (, :, ;) + listener: endConstructor(DeclarationKind.Class, Foo, (, :, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, Foo) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Foo) @@ -681,7 +681,7 @@ parseUnit(class) inPlainSync() parseFunctionBody(), false, true) listener: handleEmptyFunctionBody(;) - listener: endClassConstructor(Foo, (, :, ;) + listener: endConstructor(DeclarationKind.Class, Foo, (, :, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, Foo) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Foo) @@ -847,7 +847,7 @@ parseUnit(class) listener: beginBlockFunctionBody({) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(0, {, }) - listener: endClassConstructor(Foo, (, :, }) + listener: endConstructor(DeclarationKind.Class, Foo, (, :, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, Foo) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Foo) @@ -1013,7 +1013,7 @@ parseUnit(class) listener: beginBlockFunctionBody({) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(0, {, }) - listener: endClassConstructor(Foo, (, :, }) + listener: endConstructor(DeclarationKind.Class, Foo, (, :, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, Foo) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Foo) @@ -1179,7 +1179,7 @@ parseUnit(class) listener: beginBlockFunctionBody({) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(0, {, }) - listener: endClassConstructor(Foo, (, :, }) + listener: endConstructor(DeclarationKind.Class, Foo, (, :, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, Foo) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Foo) @@ -1345,7 +1345,7 @@ parseUnit(class) listener: beginBlockFunctionBody({) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(0, {, }) - listener: endClassConstructor(Foo, (, :, }) + listener: endConstructor(DeclarationKind.Class, Foo, (, :, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 8, {, }) diff --git a/pkg/front_end/parser_testcases/nnbd/late_member.dart.expect b/pkg/front_end/parser_testcases/nnbd/late_member.dart.expect index 04adf5a1fd5..18960acda6c 100644 --- a/pkg/front_end/parser_testcases/nnbd/late_member.dart.expect +++ b/pkg/front_end/parser_testcases/nnbd/late_member.dart.expect @@ -152,7 +152,7 @@ beginCompilationUnit(main) handleSend(print, )) handleExpressionStatement(print, ;) endBlockFunctionBody(1, {, }) - endClassMethod(null, late, (, null, }) + endMethod(DeclarationKind.Class, null, late, (, null, }) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 1, {, }) endClassDeclaration(class, }) @@ -181,7 +181,7 @@ beginCompilationUnit(main) beginFieldInitializer(=) handleLiteralInt(42) endFieldInitializer(=, 42) - endClassFields(null, null, null, null, null, null, null, 1, int, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 1, {, }) endClassDeclaration(class, }) diff --git a/pkg/front_end/parser_testcases/nnbd/late_member.dart.intertwined.expect b/pkg/front_end/parser_testcases/nnbd/late_member.dart.intertwined.expect index ed319b28a3b..2bb330fd9ca 100644 --- a/pkg/front_end/parser_testcases/nnbd/late_member.dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/nnbd/late_member.dart.intertwined.expect @@ -409,7 +409,7 @@ parseUnit(main) listener: handleExpressionStatement(print, ;) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(1, {, }) - listener: endClassMethod(null, late, (, null, }) + listener: endMethod(DeclarationKind.Class, null, late, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 1, {, }) @@ -464,7 +464,7 @@ parseUnit(main) parseLiteralInt(=) listener: handleLiteralInt(42) listener: endFieldInitializer(=, 42) - listener: endClassFields(null, null, null, null, null, null, null, 1, int, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 1, {, }) diff --git a/pkg/front_end/parser_testcases/nnbd/late_modifier.dart.expect b/pkg/front_end/parser_testcases/nnbd/late_modifier.dart.expect index 7b535a0d8d6..d5184dd5bb6 100644 --- a/pkg/front_end/parser_testcases/nnbd/late_modifier.dart.expect +++ b/pkg/front_end/parser_testcases/nnbd/late_modifier.dart.expect @@ -170,7 +170,7 @@ beginCompilationUnit(main) handleSend(print, )) handleExpressionStatement(print, ;) endBlockFunctionBody(1, {, }) - endClassMethod(null, late, (, null, }) + endMethod(DeclarationKind.Class, null, late, (, null, }) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 1, {, }) endClassDeclaration(class, }) @@ -199,7 +199,7 @@ beginCompilationUnit(main) beginFieldInitializer(=) handleLiteralInt(42) endFieldInitializer(=, 42) - endClassFields(null, null, null, null, null, null, null, 1, int, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 1, {, }) endClassDeclaration(class, }) diff --git a/pkg/front_end/parser_testcases/nnbd/late_modifier.dart.intertwined.expect b/pkg/front_end/parser_testcases/nnbd/late_modifier.dart.intertwined.expect index 652ee48cc3e..1c6dba12ff6 100644 --- a/pkg/front_end/parser_testcases/nnbd/late_modifier.dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/nnbd/late_modifier.dart.intertwined.expect @@ -460,7 +460,7 @@ parseUnit(main) listener: handleExpressionStatement(print, ;) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(1, {, }) - listener: endClassMethod(null, late, (, null, }) + listener: endMethod(DeclarationKind.Class, null, late, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 1, {, }) @@ -515,7 +515,7 @@ parseUnit(main) parseLiteralInt(=) listener: handleLiteralInt(42) listener: endFieldInitializer(=, 42) - listener: endClassFields(null, null, null, null, null, null, null, 1, int, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 1, {, }) diff --git a/pkg/front_end/parser_testcases/nnbd/null_shorting_index.dart.expect b/pkg/front_end/parser_testcases/nnbd/null_shorting_index.dart.expect index 22e6a422547..b99788443f0 100644 --- a/pkg/front_end/parser_testcases/nnbd/null_shorting_index.dart.expect +++ b/pkg/front_end/parser_testcases/nnbd/null_shorting_index.dart.expect @@ -39,7 +39,7 @@ beginCompilationUnit(class) handleNoArguments(;) handleSend(index, index) handleExpressionFunctionBody(=>, ;) - endClassMethod(null, int, (, null, ;) + endMethod(DeclarationKind.Class, null, int, (, null, ;) endMember() beginMetadataStar(void) endMetadataStar(0) @@ -72,7 +72,7 @@ beginCompilationUnit(class) handleAsyncModifier(null, null) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) - endClassMethod(null, void, (, null, }) + endMethod(DeclarationKind.Class, null, void, (, null, }) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 2, {, }) endClassDeclaration(class, }) diff --git a/pkg/front_end/parser_testcases/nnbd/null_shorting_index.dart.intertwined.expect b/pkg/front_end/parser_testcases/nnbd/null_shorting_index.dart.intertwined.expect index a51992b0dbb..feaabdfb066 100644 --- a/pkg/front_end/parser_testcases/nnbd/null_shorting_index.dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/nnbd/null_shorting_index.dart.intertwined.expect @@ -85,7 +85,7 @@ parseUnit(class) ensureSemicolon(index) listener: handleExpressionFunctionBody(=>, ;) inGenerator() - listener: endClassMethod(null, int, (, null, ;) + listener: endMethod(DeclarationKind.Class, null, int, (, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, void) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Class1) @@ -139,7 +139,7 @@ parseUnit(class) listener: beginBlockFunctionBody({) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(0, {, }) - listener: endClassMethod(null, void, (, null, }) + listener: endMethod(DeclarationKind.Class, null, void, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 2, {, }) diff --git a/pkg/front_end/parser_testcases/nnbd/required_member.dart.expect b/pkg/front_end/parser_testcases/nnbd/required_member.dart.expect index 7ef4cdde413..85640546f75 100644 --- a/pkg/front_end/parser_testcases/nnbd/required_member.dart.expect +++ b/pkg/front_end/parser_testcases/nnbd/required_member.dart.expect @@ -152,7 +152,7 @@ beginCompilationUnit(main) handleSend(print, )) handleExpressionStatement(print, ;) endBlockFunctionBody(1, {, }) - endClassMethod(null, required, (, null, }) + endMethod(DeclarationKind.Class, null, required, (, null, }) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 1, {, }) endClassDeclaration(class, }) @@ -181,7 +181,7 @@ beginCompilationUnit(main) beginFieldInitializer(=) handleLiteralInt(42) endFieldInitializer(=, 42) - endClassFields(null, null, null, null, null, null, null, 1, int, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 1, {, }) endClassDeclaration(class, }) diff --git a/pkg/front_end/parser_testcases/nnbd/required_member.dart.intertwined.expect b/pkg/front_end/parser_testcases/nnbd/required_member.dart.intertwined.expect index a33fe62ff4d..aef11ec66a4 100644 --- a/pkg/front_end/parser_testcases/nnbd/required_member.dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/nnbd/required_member.dart.intertwined.expect @@ -409,7 +409,7 @@ parseUnit(main) listener: handleExpressionStatement(print, ;) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(1, {, }) - listener: endClassMethod(null, required, (, null, }) + listener: endMethod(DeclarationKind.Class, null, required, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 1, {, }) @@ -464,7 +464,7 @@ parseUnit(main) parseLiteralInt(=) listener: handleLiteralInt(42) listener: endFieldInitializer(=, 42) - listener: endClassFields(null, null, null, null, null, null, null, 1, int, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 1, {, }) diff --git a/pkg/front_end/parser_testcases/nnbd/required_modifier.dart.expect b/pkg/front_end/parser_testcases/nnbd/required_modifier.dart.expect index 8a855c2d6ec..c753220fe98 100644 --- a/pkg/front_end/parser_testcases/nnbd/required_modifier.dart.expect +++ b/pkg/front_end/parser_testcases/nnbd/required_modifier.dart.expect @@ -163,7 +163,7 @@ beginCompilationUnit(main) handleSend(print, )) handleExpressionStatement(print, ;) endBlockFunctionBody(1, {, }) - endClassMethod(null, required, (, null, }) + endMethod(DeclarationKind.Class, null, required, (, null, }) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 1, {, }) endClassDeclaration(class, }) @@ -192,7 +192,7 @@ beginCompilationUnit(main) beginFieldInitializer(=) handleLiteralInt(42) endFieldInitializer(=, 42) - endClassFields(null, null, null, null, null, null, null, 1, int, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 1, {, }) endClassDeclaration(class, }) diff --git a/pkg/front_end/parser_testcases/nnbd/required_modifier.dart.intertwined.expect b/pkg/front_end/parser_testcases/nnbd/required_modifier.dart.intertwined.expect index a083627d702..9aa56df2c27 100644 --- a/pkg/front_end/parser_testcases/nnbd/required_modifier.dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/nnbd/required_modifier.dart.intertwined.expect @@ -425,7 +425,7 @@ parseUnit(main) listener: handleExpressionStatement(print, ;) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(1, {, }) - listener: endClassMethod(null, required, (, null, }) + listener: endMethod(DeclarationKind.Class, null, required, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 1, {, }) @@ -480,7 +480,7 @@ parseUnit(main) parseLiteralInt(=) listener: handleLiteralInt(42) listener: endFieldInitializer(=, 42) - listener: endClassFields(null, null, null, null, null, null, null, 1, int, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 1, {, }) diff --git a/pkg/front_end/parser_testcases/no-triple-shift/define_triple_shift_method.dart.expect b/pkg/front_end/parser_testcases/no-triple-shift/define_triple_shift_method.dart.expect index c24743bef53..d4735a516aa 100644 --- a/pkg/front_end/parser_testcases/no-triple-shift/define_triple_shift_method.dart.expect +++ b/pkg/front_end/parser_testcases/no-triple-shift/define_triple_shift_method.dart.expect @@ -57,7 +57,7 @@ beginCompilationUnit(class) handleAsyncModifier(null, null) handleThisExpression(this, expression) handleExpressionFunctionBody(=>, ;) - endClassMethod(null, Foo, (, null, ;) + endMethod(DeclarationKind.Class, null, Foo, (, null, ;) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 1, {, }) endClassDeclaration(class, }) diff --git a/pkg/front_end/parser_testcases/no-triple-shift/define_triple_shift_method.dart.intertwined.expect b/pkg/front_end/parser_testcases/no-triple-shift/define_triple_shift_method.dart.intertwined.expect index 5947f758871..71782cc80f6 100644 --- a/pkg/front_end/parser_testcases/no-triple-shift/define_triple_shift_method.dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/no-triple-shift/define_triple_shift_method.dart.intertwined.expect @@ -77,7 +77,7 @@ parseUnit(class) ensureSemicolon(this) listener: handleExpressionFunctionBody(=>, ;) inGenerator() - listener: endClassMethod(null, Foo, (, null, ;) + listener: endMethod(DeclarationKind.Class, null, Foo, (, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 1, {, }) diff --git a/pkg/front_end/parser_testcases/no-triple-shift/define_triple_shift_method_prime.dart.expect b/pkg/front_end/parser_testcases/no-triple-shift/define_triple_shift_method_prime.dart.expect index a05fff3c1df..c0e92a4c910 100644 --- a/pkg/front_end/parser_testcases/no-triple-shift/define_triple_shift_method_prime.dart.expect +++ b/pkg/front_end/parser_testcases/no-triple-shift/define_triple_shift_method_prime.dart.expect @@ -34,7 +34,7 @@ beginCompilationUnit(class) handleAsyncModifier(null, null) handleThisExpression(this, expression) handleExpressionFunctionBody(=>, ;) - endClassMethod(null, Foo, (, null, ;) + endMethod(DeclarationKind.Class, null, Foo, (, null, ;) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 1, {, }) endClassDeclaration(class, }) diff --git a/pkg/front_end/parser_testcases/no-triple-shift/define_triple_shift_method_prime.dart.intertwined.expect b/pkg/front_end/parser_testcases/no-triple-shift/define_triple_shift_method_prime.dart.intertwined.expect index eb757f6dfb6..c7111af70e6 100644 --- a/pkg/front_end/parser_testcases/no-triple-shift/define_triple_shift_method_prime.dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/no-triple-shift/define_triple_shift_method_prime.dart.intertwined.expect @@ -74,7 +74,7 @@ parseUnit(class) ensureSemicolon(this) listener: handleExpressionFunctionBody(=>, ;) inGenerator() - listener: endClassMethod(null, Foo, (, null, ;) + listener: endMethod(DeclarationKind.Class, null, Foo, (, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 1, {, }) diff --git a/pkg/front_end/parser_testcases/no-triple-shift/triple_shift_not_triple_shift.dart.expect b/pkg/front_end/parser_testcases/no-triple-shift/triple_shift_not_triple_shift.dart.expect index 20d32c166c8..84d43bc607d 100644 --- a/pkg/front_end/parser_testcases/no-triple-shift/triple_shift_not_triple_shift.dart.expect +++ b/pkg/front_end/parser_testcases/no-triple-shift/triple_shift_not_triple_shift.dart.expect @@ -31,7 +31,7 @@ beginCompilationUnit(extension) beginLiteralString("Greater Than used") endLiteralString(0, ;) handleExpressionFunctionBody(=>, ;) - endExtensionMethod(null, String, (, null, ;) + endMethod(DeclarationKind.Extension, null, String, (, null, ;) endMember() beginMetadataStar(String) endMetadataStar(0) @@ -56,7 +56,7 @@ beginCompilationUnit(extension) beginLiteralString("Called") endLiteralString(0, ;) handleExpressionFunctionBody(=>, ;) - endExtensionMethod(null, String, (, null, ;) + endMethod(DeclarationKind.Extension, null, String, (, null, ;) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Extension, 2, {, }) endExtensionDeclaration(extension, extension, on, }) diff --git a/pkg/front_end/parser_testcases/no-triple-shift/triple_shift_not_triple_shift.dart.intertwined.expect b/pkg/front_end/parser_testcases/no-triple-shift/triple_shift_not_triple_shift.dart.intertwined.expect index 4d35e830257..b184e52957f 100644 --- a/pkg/front_end/parser_testcases/no-triple-shift/triple_shift_not_triple_shift.dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/no-triple-shift/triple_shift_not_triple_shift.dart.intertwined.expect @@ -66,7 +66,7 @@ parseUnit(extension) ensureSemicolon("Greater Than used") listener: handleExpressionFunctionBody(=>, ;) inGenerator() - listener: endExtensionMethod(null, String, (, null, ;) + listener: endMethod(DeclarationKind.Extension, null, String, (, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, String) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Extension, null) @@ -118,7 +118,7 @@ parseUnit(extension) ensureSemicolon("Called") listener: handleExpressionFunctionBody(=>, ;) inGenerator() - listener: endExtensionMethod(null, String, (, null, ;) + listener: endMethod(DeclarationKind.Extension, null, String, (, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Extension, 2, {, }) diff --git a/pkg/front_end/parser_testcases/patterns/cast_inside_extractor_pattern.dart.expect b/pkg/front_end/parser_testcases/patterns/cast_inside_extractor_pattern.dart.expect index bd2756a361d..d7201f5b4b5 100644 --- a/pkg/front_end/parser_testcases/patterns/cast_inside_extractor_pattern.dart.expect +++ b/pkg/front_end/parser_testcases/patterns/cast_inside_extractor_pattern.dart.expect @@ -21,7 +21,7 @@ beginCompilationUnit(class) handleType(int, ?) handleIdentifier(f, fieldDeclaration) handleNoFieldInitializer(;) - endClassFields(null, null, null, null, null, null, null, 1, int, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 1, {, }) endClassDeclaration(class, }) diff --git a/pkg/front_end/parser_testcases/patterns/cast_inside_extractor_pattern.dart.intertwined.expect b/pkg/front_end/parser_testcases/patterns/cast_inside_extractor_pattern.dart.intertwined.expect index 2f93041d4ac..56781e2d1bd 100644 --- a/pkg/front_end/parser_testcases/patterns/cast_inside_extractor_pattern.dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/patterns/cast_inside_extractor_pattern.dart.intertwined.expect @@ -42,7 +42,7 @@ parseUnit(class) listener: handleIdentifier(f, fieldDeclaration) parseFieldInitializerOpt(f, f, null, null, null, null, null, DeclarationKind.Class, C) listener: handleNoFieldInitializer(;) - listener: endClassFields(null, null, null, null, null, null, null, 1, int, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 1, {, }) diff --git a/pkg/front_end/parser_testcases/patterns/cast_inside_extractor_pattern_implicitly_named.dart.expect b/pkg/front_end/parser_testcases/patterns/cast_inside_extractor_pattern_implicitly_named.dart.expect index d0f742f1478..8fd949d582c 100644 --- a/pkg/front_end/parser_testcases/patterns/cast_inside_extractor_pattern_implicitly_named.dart.expect +++ b/pkg/front_end/parser_testcases/patterns/cast_inside_extractor_pattern_implicitly_named.dart.expect @@ -21,7 +21,7 @@ beginCompilationUnit(class) handleType(int, ?) handleIdentifier(f, fieldDeclaration) handleNoFieldInitializer(;) - endClassFields(null, null, null, null, null, null, null, 1, int, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 1, {, }) endClassDeclaration(class, }) diff --git a/pkg/front_end/parser_testcases/patterns/cast_inside_extractor_pattern_implicitly_named.dart.intertwined.expect b/pkg/front_end/parser_testcases/patterns/cast_inside_extractor_pattern_implicitly_named.dart.intertwined.expect index 3a08f1d4439..cb4bdbe068d 100644 --- a/pkg/front_end/parser_testcases/patterns/cast_inside_extractor_pattern_implicitly_named.dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/patterns/cast_inside_extractor_pattern_implicitly_named.dart.intertwined.expect @@ -42,7 +42,7 @@ parseUnit(class) listener: handleIdentifier(f, fieldDeclaration) parseFieldInitializerOpt(f, f, null, null, null, null, null, DeclarationKind.Class, C) listener: handleNoFieldInitializer(;) - listener: endClassFields(null, null, null, null, null, null, null, 1, int, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 1, {, }) diff --git a/pkg/front_end/parser_testcases/patterns/const_patterns.dart.expect b/pkg/front_end/parser_testcases/patterns/const_patterns.dart.expect index 95c2433284d..892f6210ffd 100644 --- a/pkg/front_end/parser_testcases/patterns/const_patterns.dart.expect +++ b/pkg/front_end/parser_testcases/patterns/const_patterns.dart.expect @@ -280,7 +280,7 @@ beginCompilationUnit(import) handleNoInitializers() handleAsyncModifier(null, null) handleEmptyFunctionBody(;) - endClassConstructor(const, (, null, ;) + endConstructor(DeclarationKind.Class, const, (, null, ;) endMember() beginMetadataStar(const) endMetadataStar(0) @@ -296,7 +296,7 @@ beginCompilationUnit(import) handleNoInitializers() handleAsyncModifier(null, null) handleEmptyFunctionBody(;) - endClassConstructor(const, (, null, ;) + endConstructor(DeclarationKind.Class, const, (, null, ;) endMember() beginMetadataStar(call) endMetadataStar(0) @@ -311,7 +311,7 @@ beginCompilationUnit(import) handleAsyncModifier(null, null) beginBlockFunctionBody({) endBlockFunctionBody(0, {, }) - endClassMethod(null, call, (, null, }) + endMethod(DeclarationKind.Class, null, call, (, null, }) endMember() beginMetadataStar(test) endMetadataStar(0) @@ -1736,7 +1736,7 @@ beginCompilationUnit(import) endSwitchBlock(2, {, }) endSwitchStatement(switch, }) endBlockFunctionBody(3, {, }) - endClassMethod(null, test, (, null, }) + endMethod(DeclarationKind.Class, null, test, (, null, }) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 4, {, }) endClassDeclaration(class, }) @@ -1783,7 +1783,7 @@ beginCompilationUnit(import) handleNoInitializers() handleAsyncModifier(null, null) handleEmptyFunctionBody(;) - endClassConstructor(const, (, null, ;) + endConstructor(DeclarationKind.Class, const, (, null, ;) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 1, {, }) endClassDeclaration(class, }) diff --git a/pkg/front_end/parser_testcases/patterns/const_patterns.dart.intertwined.expect b/pkg/front_end/parser_testcases/patterns/const_patterns.dart.intertwined.expect index 5253a55fa47..9c21431ad40 100644 --- a/pkg/front_end/parser_testcases/patterns/const_patterns.dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/patterns/const_patterns.dart.intertwined.expect @@ -146,7 +146,7 @@ parseUnit(import) inPlainSync() parseFunctionBody(), false, true) listener: handleEmptyFunctionBody(;) - listener: endClassConstructor(const, (, null, ;) + listener: endConstructor(DeclarationKind.Class, const, (, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, const) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Class) @@ -179,7 +179,7 @@ parseUnit(import) inPlainSync() parseFunctionBody(), false, true) listener: handleEmptyFunctionBody(;) - listener: endClassConstructor(const, (, null, ;) + listener: endConstructor(DeclarationKind.Class, const, (, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, call) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Class) @@ -211,7 +211,7 @@ parseUnit(import) listener: beginBlockFunctionBody({) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(0, {, }) - listener: endClassMethod(null, call, (, null, }) + listener: endMethod(DeclarationKind.Class, null, call, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, test) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Class) @@ -3171,7 +3171,7 @@ parseUnit(import) listener: endSwitchStatement(switch, }) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(3, {, }) - listener: endClassMethod(null, test, (, null, }) + listener: endMethod(DeclarationKind.Class, null, test, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 4, {, }) @@ -3251,7 +3251,7 @@ parseUnit(import) inPlainSync() parseFunctionBody(), false, true) listener: handleEmptyFunctionBody(;) - listener: endClassConstructor(const, (, null, ;) + listener: endConstructor(DeclarationKind.Class, const, (, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 1, {, }) diff --git a/pkg/front_end/parser_testcases/patterns/const_patterns_binary.dart.expect b/pkg/front_end/parser_testcases/patterns/const_patterns_binary.dart.expect index c6b5980a0aa..6d5a8d2714d 100644 --- a/pkg/front_end/parser_testcases/patterns/const_patterns_binary.dart.expect +++ b/pkg/front_end/parser_testcases/patterns/const_patterns_binary.dart.expect @@ -308,7 +308,7 @@ beginCompilationUnit(import) beginFieldInitializer(=) handleLiteralInt(2) endFieldInitializer(=, 2) - endClassFields(null, null, null, static, null, null, const, 1, static, ;) + endFields(DeclarationKind.Class, null, null, null, static, null, null, const, 1, static, ;) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 1, {, }) endClassDeclaration(class, }) diff --git a/pkg/front_end/parser_testcases/patterns/const_patterns_binary.dart.intertwined.expect b/pkg/front_end/parser_testcases/patterns/const_patterns_binary.dart.intertwined.expect index ffb13028df3..05fa94213f5 100644 --- a/pkg/front_end/parser_testcases/patterns/const_patterns_binary.dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/patterns/const_patterns_binary.dart.intertwined.expect @@ -98,7 +98,7 @@ parseUnit(import) parseLiteralInt(=) listener: handleLiteralInt(2) listener: endFieldInitializer(=, 2) - listener: endClassFields(null, null, null, static, null, null, const, 1, static, ;) + listener: endFields(DeclarationKind.Class, null, null, null, static, null, null, const, 1, static, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 1, {, }) diff --git a/pkg/front_end/parser_testcases/patterns/extractor_pattern_inside_cast.dart.expect b/pkg/front_end/parser_testcases/patterns/extractor_pattern_inside_cast.dart.expect index c336b07ec21..2b00c668320 100644 --- a/pkg/front_end/parser_testcases/patterns/extractor_pattern_inside_cast.dart.expect +++ b/pkg/front_end/parser_testcases/patterns/extractor_pattern_inside_cast.dart.expect @@ -21,7 +21,7 @@ beginCompilationUnit(class) handleType(int, ?) handleIdentifier(f, fieldDeclaration) handleNoFieldInitializer(;) - endClassFields(null, null, null, null, null, null, null, 1, int, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 1, {, }) endClassDeclaration(class, }) diff --git a/pkg/front_end/parser_testcases/patterns/extractor_pattern_inside_cast.dart.intertwined.expect b/pkg/front_end/parser_testcases/patterns/extractor_pattern_inside_cast.dart.intertwined.expect index ae07871e878..d4a5b3ddb7f 100644 --- a/pkg/front_end/parser_testcases/patterns/extractor_pattern_inside_cast.dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/patterns/extractor_pattern_inside_cast.dart.intertwined.expect @@ -42,7 +42,7 @@ parseUnit(class) listener: handleIdentifier(f, fieldDeclaration) parseFieldInitializerOpt(f, f, null, null, null, null, null, DeclarationKind.Class, C) listener: handleNoFieldInitializer(;) - listener: endClassFields(null, null, null, null, null, null, null, 1, int, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 1, {, }) diff --git a/pkg/front_end/parser_testcases/patterns/extractor_pattern_inside_null_assert.dart.expect b/pkg/front_end/parser_testcases/patterns/extractor_pattern_inside_null_assert.dart.expect index 825bd4912f9..71ea3ef324a 100644 --- a/pkg/front_end/parser_testcases/patterns/extractor_pattern_inside_null_assert.dart.expect +++ b/pkg/front_end/parser_testcases/patterns/extractor_pattern_inside_null_assert.dart.expect @@ -21,7 +21,7 @@ beginCompilationUnit(class) handleType(int, ?) handleIdentifier(f, fieldDeclaration) handleNoFieldInitializer(;) - endClassFields(null, null, null, null, null, null, null, 1, int, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 1, {, }) endClassDeclaration(class, }) diff --git a/pkg/front_end/parser_testcases/patterns/extractor_pattern_inside_null_assert.dart.intertwined.expect b/pkg/front_end/parser_testcases/patterns/extractor_pattern_inside_null_assert.dart.intertwined.expect index 3bd2cf1173a..5fbdea27c74 100644 --- a/pkg/front_end/parser_testcases/patterns/extractor_pattern_inside_null_assert.dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/patterns/extractor_pattern_inside_null_assert.dart.intertwined.expect @@ -42,7 +42,7 @@ parseUnit(class) listener: handleIdentifier(f, fieldDeclaration) parseFieldInitializerOpt(f, f, null, null, null, null, null, DeclarationKind.Class, C) listener: handleNoFieldInitializer(;) - listener: endClassFields(null, null, null, null, null, null, null, 1, int, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 1, {, }) diff --git a/pkg/front_end/parser_testcases/patterns/extractor_pattern_inside_null_check.dart.expect b/pkg/front_end/parser_testcases/patterns/extractor_pattern_inside_null_check.dart.expect index 8beae787df5..afec8cbdf9b 100644 --- a/pkg/front_end/parser_testcases/patterns/extractor_pattern_inside_null_check.dart.expect +++ b/pkg/front_end/parser_testcases/patterns/extractor_pattern_inside_null_check.dart.expect @@ -21,7 +21,7 @@ beginCompilationUnit(class) handleType(int, ?) handleIdentifier(f, fieldDeclaration) handleNoFieldInitializer(;) - endClassFields(null, null, null, null, null, null, null, 1, int, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 1, {, }) endClassDeclaration(class, }) diff --git a/pkg/front_end/parser_testcases/patterns/extractor_pattern_inside_null_check.dart.intertwined.expect b/pkg/front_end/parser_testcases/patterns/extractor_pattern_inside_null_check.dart.intertwined.expect index c7b80cc7513..84826111c90 100644 --- a/pkg/front_end/parser_testcases/patterns/extractor_pattern_inside_null_check.dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/patterns/extractor_pattern_inside_null_check.dart.intertwined.expect @@ -42,7 +42,7 @@ parseUnit(class) listener: handleIdentifier(f, fieldDeclaration) parseFieldInitializerOpt(f, f, null, null, null, null, null, DeclarationKind.Class, C) listener: handleNoFieldInitializer(;) - listener: endClassFields(null, null, null, null, null, null, null, 1, int, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 1, {, }) diff --git a/pkg/front_end/parser_testcases/patterns/extractor_pattern_with_type_args_inside_null_assert.dart.expect b/pkg/front_end/parser_testcases/patterns/extractor_pattern_with_type_args_inside_null_assert.dart.expect index d231124b0a0..2e674683a74 100644 --- a/pkg/front_end/parser_testcases/patterns/extractor_pattern_with_type_args_inside_null_assert.dart.expect +++ b/pkg/front_end/parser_testcases/patterns/extractor_pattern_with_type_args_inside_null_assert.dart.expect @@ -29,7 +29,7 @@ beginCompilationUnit(class) handleType(T, ?) handleIdentifier(f, fieldDeclaration) handleNoFieldInitializer(;) - endClassFields(null, null, null, null, null, null, null, 1, T, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, T, ;) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 1, {, }) endClassDeclaration(class, }) diff --git a/pkg/front_end/parser_testcases/patterns/extractor_pattern_with_type_args_inside_null_assert.dart.intertwined.expect b/pkg/front_end/parser_testcases/patterns/extractor_pattern_with_type_args_inside_null_assert.dart.intertwined.expect index 29baf9c0140..3306f6059fb 100644 --- a/pkg/front_end/parser_testcases/patterns/extractor_pattern_with_type_args_inside_null_assert.dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/patterns/extractor_pattern_with_type_args_inside_null_assert.dart.intertwined.expect @@ -50,7 +50,7 @@ parseUnit(class) listener: handleIdentifier(f, fieldDeclaration) parseFieldInitializerOpt(f, f, null, null, null, null, null, DeclarationKind.Class, C) listener: handleNoFieldInitializer(;) - listener: endClassFields(null, null, null, null, null, null, null, 1, T, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, T, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 1, {, }) diff --git a/pkg/front_end/parser_testcases/patterns/issue_51169.dart.expect b/pkg/front_end/parser_testcases/patterns/issue_51169.dart.expect index 86e88f273a7..32e08966c24 100644 --- a/pkg/front_end/parser_testcases/patterns/issue_51169.dart.expect +++ b/pkg/front_end/parser_testcases/patterns/issue_51169.dart.expect @@ -21,7 +21,7 @@ beginCompilationUnit(class) handleType(dynamic, null) handleIdentifier(field, fieldDeclaration) handleNoFieldInitializer(;) - endClassFields(null, null, null, null, null, null, null, 1, dynamic, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, dynamic, ;) endMember() beginMetadataStar(Class) endMetadataStar(0) @@ -42,7 +42,7 @@ beginCompilationUnit(class) handleNoInitializers() handleAsyncModifier(null, null) handleEmptyFunctionBody(;) - endClassConstructor(Class, (, null, ;) + endConstructor(DeclarationKind.Class, Class, (, null, ;) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 2, {, }) endClassDeclaration(class, }) diff --git a/pkg/front_end/parser_testcases/patterns/issue_51169.dart.intertwined.expect b/pkg/front_end/parser_testcases/patterns/issue_51169.dart.intertwined.expect index 62e2c5bbd21..8861853d5c8 100644 --- a/pkg/front_end/parser_testcases/patterns/issue_51169.dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/patterns/issue_51169.dart.intertwined.expect @@ -42,7 +42,7 @@ parseUnit(class) listener: handleIdentifier(field, fieldDeclaration) parseFieldInitializerOpt(field, field, null, null, null, null, null, DeclarationKind.Class, Class) listener: handleNoFieldInitializer(;) - listener: endClassFields(null, null, null, null, null, null, null, 1, dynamic, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, dynamic, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, Class) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Class) @@ -82,7 +82,7 @@ parseUnit(class) inPlainSync() parseFunctionBody(), false, true) listener: handleEmptyFunctionBody(;) - listener: endClassConstructor(Class, (, null, ;) + listener: endConstructor(DeclarationKind.Class, Class, (, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 2, {, }) diff --git a/pkg/front_end/parser_testcases/patterns/null_assert_inside_extractor_pattern.dart.expect b/pkg/front_end/parser_testcases/patterns/null_assert_inside_extractor_pattern.dart.expect index 4617edac8d7..98c838eb0d5 100644 --- a/pkg/front_end/parser_testcases/patterns/null_assert_inside_extractor_pattern.dart.expect +++ b/pkg/front_end/parser_testcases/patterns/null_assert_inside_extractor_pattern.dart.expect @@ -21,7 +21,7 @@ beginCompilationUnit(class) handleType(int, ?) handleIdentifier(f, fieldDeclaration) handleNoFieldInitializer(;) - endClassFields(null, null, null, null, null, null, null, 1, int, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 1, {, }) endClassDeclaration(class, }) diff --git a/pkg/front_end/parser_testcases/patterns/null_assert_inside_extractor_pattern.dart.intertwined.expect b/pkg/front_end/parser_testcases/patterns/null_assert_inside_extractor_pattern.dart.intertwined.expect index db4b6f7734b..8d3a0c399a3 100644 --- a/pkg/front_end/parser_testcases/patterns/null_assert_inside_extractor_pattern.dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/patterns/null_assert_inside_extractor_pattern.dart.intertwined.expect @@ -42,7 +42,7 @@ parseUnit(class) listener: handleIdentifier(f, fieldDeclaration) parseFieldInitializerOpt(f, f, null, null, null, null, null, DeclarationKind.Class, C) listener: handleNoFieldInitializer(;) - listener: endClassFields(null, null, null, null, null, null, null, 1, int, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 1, {, }) diff --git a/pkg/front_end/parser_testcases/patterns/null_assert_inside_extractor_pattern_implicitly_named.dart.expect b/pkg/front_end/parser_testcases/patterns/null_assert_inside_extractor_pattern_implicitly_named.dart.expect index fdf0328fc35..05d3c629290 100644 --- a/pkg/front_end/parser_testcases/patterns/null_assert_inside_extractor_pattern_implicitly_named.dart.expect +++ b/pkg/front_end/parser_testcases/patterns/null_assert_inside_extractor_pattern_implicitly_named.dart.expect @@ -21,7 +21,7 @@ beginCompilationUnit(class) handleType(int, ?) handleIdentifier(f, fieldDeclaration) handleNoFieldInitializer(;) - endClassFields(null, null, null, null, null, null, null, 1, int, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 1, {, }) endClassDeclaration(class, }) diff --git a/pkg/front_end/parser_testcases/patterns/null_assert_inside_extractor_pattern_implicitly_named.dart.intertwined.expect b/pkg/front_end/parser_testcases/patterns/null_assert_inside_extractor_pattern_implicitly_named.dart.intertwined.expect index 672be26fa23..573e0e0584b 100644 --- a/pkg/front_end/parser_testcases/patterns/null_assert_inside_extractor_pattern_implicitly_named.dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/patterns/null_assert_inside_extractor_pattern_implicitly_named.dart.intertwined.expect @@ -42,7 +42,7 @@ parseUnit(class) listener: handleIdentifier(f, fieldDeclaration) parseFieldInitializerOpt(f, f, null, null, null, null, null, DeclarationKind.Class, C) listener: handleNoFieldInitializer(;) - listener: endClassFields(null, null, null, null, null, null, null, 1, int, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 1, {, }) diff --git a/pkg/front_end/parser_testcases/patterns/null_check_inside_extractor_pattern.dart.expect b/pkg/front_end/parser_testcases/patterns/null_check_inside_extractor_pattern.dart.expect index aae774f91a6..49af93403b1 100644 --- a/pkg/front_end/parser_testcases/patterns/null_check_inside_extractor_pattern.dart.expect +++ b/pkg/front_end/parser_testcases/patterns/null_check_inside_extractor_pattern.dart.expect @@ -21,7 +21,7 @@ beginCompilationUnit(class) handleType(int, ?) handleIdentifier(f, fieldDeclaration) handleNoFieldInitializer(;) - endClassFields(null, null, null, null, null, null, null, 1, int, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 1, {, }) endClassDeclaration(class, }) diff --git a/pkg/front_end/parser_testcases/patterns/null_check_inside_extractor_pattern.dart.intertwined.expect b/pkg/front_end/parser_testcases/patterns/null_check_inside_extractor_pattern.dart.intertwined.expect index c8ca35c6c18..f0e6dcbac4d 100644 --- a/pkg/front_end/parser_testcases/patterns/null_check_inside_extractor_pattern.dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/patterns/null_check_inside_extractor_pattern.dart.intertwined.expect @@ -42,7 +42,7 @@ parseUnit(class) listener: handleIdentifier(f, fieldDeclaration) parseFieldInitializerOpt(f, f, null, null, null, null, null, DeclarationKind.Class, C) listener: handleNoFieldInitializer(;) - listener: endClassFields(null, null, null, null, null, null, null, 1, int, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 1, {, }) diff --git a/pkg/front_end/parser_testcases/patterns/null_check_inside_extractor_pattern_implicitly_named.dart.expect b/pkg/front_end/parser_testcases/patterns/null_check_inside_extractor_pattern_implicitly_named.dart.expect index e15c3dd4572..4f9cc60c71b 100644 --- a/pkg/front_end/parser_testcases/patterns/null_check_inside_extractor_pattern_implicitly_named.dart.expect +++ b/pkg/front_end/parser_testcases/patterns/null_check_inside_extractor_pattern_implicitly_named.dart.expect @@ -21,7 +21,7 @@ beginCompilationUnit(class) handleType(int, ?) handleIdentifier(f, fieldDeclaration) handleNoFieldInitializer(;) - endClassFields(null, null, null, null, null, null, null, 1, int, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 1, {, }) endClassDeclaration(class, }) diff --git a/pkg/front_end/parser_testcases/patterns/null_check_inside_extractor_pattern_implicitly_named.dart.intertwined.expect b/pkg/front_end/parser_testcases/patterns/null_check_inside_extractor_pattern_implicitly_named.dart.intertwined.expect index 6cc75289b07..8d85ca1aabf 100644 --- a/pkg/front_end/parser_testcases/patterns/null_check_inside_extractor_pattern_implicitly_named.dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/patterns/null_check_inside_extractor_pattern_implicitly_named.dart.intertwined.expect @@ -42,7 +42,7 @@ parseUnit(class) listener: handleIdentifier(f, fieldDeclaration) parseFieldInitializerOpt(f, f, null, null, null, null, null, DeclarationKind.Class, C) listener: handleNoFieldInitializer(;) - listener: endClassFields(null, null, null, null, null, null, null, 1, int, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 1, {, }) diff --git a/pkg/front_end/parser_testcases/patterns/patternVariableDeclaration_inClass.dart.expect b/pkg/front_end/parser_testcases/patterns/patternVariableDeclaration_inClass.dart.expect index 1759e209e12..1e977d46582 100644 --- a/pkg/front_end/parser_testcases/patterns/patternVariableDeclaration_inClass.dart.expect +++ b/pkg/front_end/parser_testcases/patterns/patternVariableDeclaration_inClass.dart.expect @@ -31,7 +31,7 @@ beginCompilationUnit(class) handleLiteralInt(1) endRecordLiteral((, 2, null) endFieldInitializer(=, )) - endClassFields(null, null, null, null, null, null, var, 1, var, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, var, 1, var, ;) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 1, {, }) endClassDeclaration(class, }) diff --git a/pkg/front_end/parser_testcases/patterns/patternVariableDeclaration_inClass.dart.intertwined.expect b/pkg/front_end/parser_testcases/patterns/patternVariableDeclaration_inClass.dart.intertwined.expect index 6020223a5e2..f7c946a6dc4 100644 --- a/pkg/front_end/parser_testcases/patterns/patternVariableDeclaration_inClass.dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/patterns/patternVariableDeclaration_inClass.dart.intertwined.expect @@ -73,7 +73,7 @@ parseUnit(class) ensureCloseParen(1, () listener: endRecordLiteral((, 2, null) listener: endFieldInitializer(=, )) - listener: endClassFields(null, null, null, null, null, null, var, 1, var, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, var, 1, var, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 1, {, }) diff --git a/pkg/front_end/parser_testcases/patterns/relational_inside_extractor_pattern.dart.expect b/pkg/front_end/parser_testcases/patterns/relational_inside_extractor_pattern.dart.expect index 2f2aec6afc9..cc788d9a217 100644 --- a/pkg/front_end/parser_testcases/patterns/relational_inside_extractor_pattern.dart.expect +++ b/pkg/front_end/parser_testcases/patterns/relational_inside_extractor_pattern.dart.expect @@ -21,7 +21,7 @@ beginCompilationUnit(class) handleType(int, ?) handleIdentifier(f, fieldDeclaration) handleNoFieldInitializer(;) - endClassFields(null, null, null, null, null, null, null, 1, int, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 1, {, }) endClassDeclaration(class, }) diff --git a/pkg/front_end/parser_testcases/patterns/relational_inside_extractor_pattern.dart.intertwined.expect b/pkg/front_end/parser_testcases/patterns/relational_inside_extractor_pattern.dart.intertwined.expect index 506cd3cf319..3d12fed32c9 100644 --- a/pkg/front_end/parser_testcases/patterns/relational_inside_extractor_pattern.dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/patterns/relational_inside_extractor_pattern.dart.intertwined.expect @@ -42,7 +42,7 @@ parseUnit(class) listener: handleIdentifier(f, fieldDeclaration) parseFieldInitializerOpt(f, f, null, null, null, null, null, DeclarationKind.Class, C) listener: handleNoFieldInitializer(;) - listener: endClassFields(null, null, null, null, null, null, null, 1, int, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, null, 1, int, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 1, {, }) diff --git a/pkg/front_end/parser_testcases/record/field_formal_parameter_with_explicit_record_type.dart.expect b/pkg/front_end/parser_testcases/record/field_formal_parameter_with_explicit_record_type.dart.expect index 635f6f83c86..2062ea3b6ab 100644 --- a/pkg/front_end/parser_testcases/record/field_formal_parameter_with_explicit_record_type.dart.expect +++ b/pkg/front_end/parser_testcases/record/field_formal_parameter_with_explicit_record_type.dart.expect @@ -50,7 +50,7 @@ beginCompilationUnit(class) handleNoInitializers() handleAsyncModifier(null, null) handleEmptyFunctionBody(;) - endClassConstructor(C, (, null, ;) + endConstructor(DeclarationKind.Class, C, (, null, ;) endMember() beginMetadataStar(C) endMetadataStar(0) @@ -92,7 +92,7 @@ beginCompilationUnit(class) handleNoInitializers() handleAsyncModifier(null, null) handleEmptyFunctionBody(;) - endClassConstructor(C, (, null, ;) + endConstructor(DeclarationKind.Class, C, (, null, ;) endMember() beginMetadataStar(C) endMetadataStar(0) @@ -134,7 +134,7 @@ beginCompilationUnit(class) handleNoInitializers() handleAsyncModifier(null, null) handleEmptyFunctionBody(;) - endClassConstructor(C, (, null, ;) + endConstructor(DeclarationKind.Class, C, (, null, ;) endMember() beginMetadataStar(C) endMetadataStar(0) @@ -174,7 +174,7 @@ beginCompilationUnit(class) handleNoInitializers() handleAsyncModifier(null, null) handleEmptyFunctionBody(;) - endClassConstructor(C, (, null, ;) + endConstructor(DeclarationKind.Class, C, (, null, ;) endMember() beginMetadataStar(C) endMetadataStar(0) @@ -216,7 +216,7 @@ beginCompilationUnit(class) handleNoInitializers() handleAsyncModifier(null, null) handleEmptyFunctionBody(;) - endClassConstructor(C, (, null, ;) + endConstructor(DeclarationKind.Class, C, (, null, ;) endMember() beginMetadataStar(C) endMetadataStar(0) @@ -258,7 +258,7 @@ beginCompilationUnit(class) handleNoInitializers() handleAsyncModifier(null, null) handleEmptyFunctionBody(;) - endClassConstructor(C, (, null, ;) + endConstructor(DeclarationKind.Class, C, (, null, ;) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 6, {, }) endClassDeclaration(class, }) diff --git a/pkg/front_end/parser_testcases/record/field_formal_parameter_with_explicit_record_type.dart.intertwined.expect b/pkg/front_end/parser_testcases/record/field_formal_parameter_with_explicit_record_type.dart.intertwined.expect index a550b488eae..a8bd22cc7d2 100644 --- a/pkg/front_end/parser_testcases/record/field_formal_parameter_with_explicit_record_type.dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/record/field_formal_parameter_with_explicit_record_type.dart.intertwined.expect @@ -93,7 +93,7 @@ parseUnit(class) inPlainSync() parseFunctionBody(), false, true) listener: handleEmptyFunctionBody(;) - listener: endClassConstructor(C, (, null, ;) + listener: endConstructor(DeclarationKind.Class, C, (, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, C) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, C) @@ -165,7 +165,7 @@ parseUnit(class) inPlainSync() parseFunctionBody(), false, true) listener: handleEmptyFunctionBody(;) - listener: endClassConstructor(C, (, null, ;) + listener: endConstructor(DeclarationKind.Class, C, (, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, C) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, C) @@ -237,7 +237,7 @@ parseUnit(class) inPlainSync() parseFunctionBody(), false, true) listener: handleEmptyFunctionBody(;) - listener: endClassConstructor(C, (, null, ;) + listener: endConstructor(DeclarationKind.Class, C, (, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, C) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, C) @@ -305,7 +305,7 @@ parseUnit(class) inPlainSync() parseFunctionBody(), false, true) listener: handleEmptyFunctionBody(;) - listener: endClassConstructor(C, (, null, ;) + listener: endConstructor(DeclarationKind.Class, C, (, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, C) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, C) @@ -377,7 +377,7 @@ parseUnit(class) inPlainSync() parseFunctionBody(), false, true) listener: handleEmptyFunctionBody(;) - listener: endClassConstructor(C, (, null, ;) + listener: endConstructor(DeclarationKind.Class, C, (, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, C) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, C) @@ -449,7 +449,7 @@ parseUnit(class) inPlainSync() parseFunctionBody(), false, true) listener: handleEmptyFunctionBody(;) - listener: endClassConstructor(C, (, null, ;) + listener: endConstructor(DeclarationKind.Class, C, (, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 6, {, }) diff --git a/pkg/front_end/parser_testcases/record/issue_52365.dart.expect b/pkg/front_end/parser_testcases/record/issue_52365.dart.expect index 63ef00f2669..d154e365437 100644 --- a/pkg/front_end/parser_testcases/record/issue_52365.dart.expect +++ b/pkg/front_end/parser_testcases/record/issue_52365.dart.expect @@ -703,7 +703,7 @@ beginCompilationUnit(void) handleSend(print, )) handleExpressionStatement(print, ;) endBlockFunctionBody(1, {, }) - endExtensionMethod(null, operator, (, null, }) + endMethod(DeclarationKind.Extension, null, operator, (, null, }) endMember() beginMetadataStar(operator) endMetadataStar(0) @@ -744,7 +744,7 @@ beginCompilationUnit(void) handleSend(print, )) handleExpressionStatement(print, ;) endBlockFunctionBody(1, {, }) - endExtensionMethod(null, operator, (, null, }) + endMethod(DeclarationKind.Extension, null, operator, (, null, }) endMember() beginMetadataStar(operator) endMetadataStar(0) @@ -785,7 +785,7 @@ beginCompilationUnit(void) handleSend(print, )) handleExpressionStatement(print, ;) endBlockFunctionBody(1, {, }) - endExtensionMethod(null, operator, (, null, }) + endMethod(DeclarationKind.Extension, null, operator, (, null, }) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Extension, 3, {, }) endExtensionDeclaration(extension, extension, on, }) @@ -838,7 +838,7 @@ beginCompilationUnit(void) handleSend(print, )) handleExpressionStatement(print, ;) endBlockFunctionBody(1, {, }) - endExtensionMethod(null, operator, (, null, }) + endMethod(DeclarationKind.Extension, null, operator, (, null, }) endMember() beginMetadataStar(operator) endMetadataStar(0) @@ -879,7 +879,7 @@ beginCompilationUnit(void) handleSend(print, )) handleExpressionStatement(print, ;) endBlockFunctionBody(1, {, }) - endExtensionMethod(null, operator, (, null, }) + endMethod(DeclarationKind.Extension, null, operator, (, null, }) endMember() beginMetadataStar(operator) endMetadataStar(0) @@ -920,7 +920,7 @@ beginCompilationUnit(void) handleSend(print, )) handleExpressionStatement(print, ;) endBlockFunctionBody(1, {, }) - endExtensionMethod(null, operator, (, null, }) + endMethod(DeclarationKind.Extension, null, operator, (, null, }) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Extension, 3, {, }) endExtensionDeclaration(extension, extension, on, }) diff --git a/pkg/front_end/parser_testcases/record/issue_52365.dart.intertwined.expect b/pkg/front_end/parser_testcases/record/issue_52365.dart.intertwined.expect index 508da9e31b8..888f5d26920 100644 --- a/pkg/front_end/parser_testcases/record/issue_52365.dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/record/issue_52365.dart.intertwined.expect @@ -2140,7 +2140,7 @@ parseUnit(void) listener: handleExpressionStatement(print, ;) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(1, {, }) - listener: endExtensionMethod(null, operator, (, null, }) + listener: endMethod(DeclarationKind.Extension, null, operator, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, operator) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Extension, FunctionExtension) @@ -2236,7 +2236,7 @@ parseUnit(void) listener: handleExpressionStatement(print, ;) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(1, {, }) - listener: endExtensionMethod(null, operator, (, null, }) + listener: endMethod(DeclarationKind.Extension, null, operator, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, operator) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Extension, FunctionExtension) @@ -2332,7 +2332,7 @@ parseUnit(void) listener: handleExpressionStatement(print, ;) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(1, {, }) - listener: endExtensionMethod(null, operator, (, null, }) + listener: endMethod(DeclarationKind.Extension, null, operator, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Extension, 3, {, }) @@ -2447,7 +2447,7 @@ parseUnit(void) listener: handleExpressionStatement(print, ;) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(1, {, }) - listener: endExtensionMethod(null, operator, (, null, }) + listener: endMethod(DeclarationKind.Extension, null, operator, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, operator) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Extension, RecordExtension) @@ -2543,7 +2543,7 @@ parseUnit(void) listener: handleExpressionStatement(print, ;) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(1, {, }) - listener: endExtensionMethod(null, operator, (, null, }) + listener: endMethod(DeclarationKind.Extension, null, operator, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, operator) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Extension, RecordExtension) @@ -2639,7 +2639,7 @@ parseUnit(void) listener: handleExpressionStatement(print, ;) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(1, {, }) - listener: endExtensionMethod(null, operator, (, null, }) + listener: endMethod(DeclarationKind.Extension, null, operator, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Extension, 3, {, }) diff --git a/pkg/front_end/parser_testcases/record/modifier_before_type_question.dart.expect b/pkg/front_end/parser_testcases/record/modifier_before_type_question.dart.expect index 4c9eec1b39a..66fbe1e99f6 100644 --- a/pkg/front_end/parser_testcases/record/modifier_before_type_question.dart.expect +++ b/pkg/front_end/parser_testcases/record/modifier_before_type_question.dart.expect @@ -21,7 +21,7 @@ beginCompilationUnit(abstract) handleType(int, null) handleIdentifier(foo1, fieldDeclaration) handleNoFieldInitializer(;) - endClassFields(abstract, null, null, null, null, null, null, 1, abstract, ;) + endFields(DeclarationKind.Class, abstract, null, null, null, null, null, null, 1, abstract, ;) endMember() beginMetadataStar(abstract) endMetadataStar(0) @@ -32,7 +32,7 @@ beginCompilationUnit(abstract) handleType(int, ?) handleIdentifier(foo2, fieldDeclaration) handleNoFieldInitializer(;) - endClassFields(abstract, null, null, null, null, null, null, 1, abstract, ;) + endFields(DeclarationKind.Class, abstract, null, null, null, null, null, null, 1, abstract, ;) endMember() beginMetadataStar(abstract) endMetadataStar(0) @@ -58,7 +58,7 @@ beginCompilationUnit(abstract) endRecordType((, null, 2, false) handleIdentifier(foo3, fieldDeclaration) handleNoFieldInitializer(;) - endClassFields(abstract, null, null, null, null, null, null, 1, abstract, ;) + endFields(DeclarationKind.Class, abstract, null, null, null, null, null, null, 1, abstract, ;) endMember() beginMetadataStar(abstract) endMetadataStar(0) @@ -84,7 +84,7 @@ beginCompilationUnit(abstract) endRecordType((, ?, 2, false) handleIdentifier(foo4, fieldDeclaration) handleNoFieldInitializer(;) - endClassFields(abstract, null, null, null, null, null, null, 1, abstract, ;) + endFields(DeclarationKind.Class, abstract, null, null, null, null, null, null, 1, abstract, ;) endMember() beginMetadataStar(abstract) endMetadataStar(0) @@ -107,7 +107,7 @@ beginCompilationUnit(abstract) endFunctionType(Function, null) handleIdentifier(foo5, fieldDeclaration) handleNoFieldInitializer(;) - endClassFields(abstract, null, null, null, null, null, null, 1, abstract, ;) + endFields(DeclarationKind.Class, abstract, null, null, null, null, null, null, 1, abstract, ;) endMember() beginMetadataStar(abstract) endMetadataStar(0) @@ -130,7 +130,7 @@ beginCompilationUnit(abstract) endFunctionType(Function, ?) handleIdentifier(foo6, fieldDeclaration) handleNoFieldInitializer(;) - endClassFields(abstract, null, null, null, null, null, null, 1, abstract, ;) + endFields(DeclarationKind.Class, abstract, null, null, null, null, null, null, 1, abstract, ;) endMember() beginMetadataStar(abstract) endMetadataStar(0) @@ -155,7 +155,7 @@ beginCompilationUnit(abstract) endFunctionType(Function, null) handleIdentifier(foo7, fieldDeclaration) handleNoFieldInitializer(;) - endClassFields(abstract, null, null, null, null, null, null, 1, abstract, ;) + endFields(DeclarationKind.Class, abstract, null, null, null, null, null, null, 1, abstract, ;) endMember() beginMetadataStar(abstract) endMetadataStar(0) @@ -180,7 +180,7 @@ beginCompilationUnit(abstract) endFunctionType(Function, ?) handleIdentifier(foo8, fieldDeclaration) handleNoFieldInitializer(;) - endClassFields(abstract, null, null, null, null, null, null, 1, abstract, ;) + endFields(DeclarationKind.Class, abstract, null, null, null, null, null, null, 1, abstract, ;) endMember() beginMetadataStar(abstract) endMetadataStar(0) @@ -220,7 +220,7 @@ beginCompilationUnit(abstract) endFunctionType(Function, null) handleIdentifier(foo9, fieldDeclaration) handleNoFieldInitializer(;) - endClassFields(abstract, null, null, null, null, null, null, 1, abstract, ;) + endFields(DeclarationKind.Class, abstract, null, null, null, null, null, null, 1, abstract, ;) endMember() beginMetadataStar(abstract) endMetadataStar(0) @@ -260,7 +260,7 @@ beginCompilationUnit(abstract) endFunctionType(Function, ?) handleIdentifier(foo10, fieldDeclaration) handleNoFieldInitializer(;) - endClassFields(abstract, null, null, null, null, null, null, 1, abstract, ;) + endFields(DeclarationKind.Class, abstract, null, null, null, null, null, null, 1, abstract, ;) endMember() beginMetadataStar(abstract) endMetadataStar(0) @@ -300,7 +300,7 @@ beginCompilationUnit(abstract) endFunctionType(Function, null) handleIdentifier(foo11, fieldDeclaration) handleNoFieldInitializer(;) - endClassFields(abstract, null, null, null, null, null, null, 1, abstract, ;) + endFields(DeclarationKind.Class, abstract, null, null, null, null, null, null, 1, abstract, ;) endMember() beginMetadataStar(abstract) endMetadataStar(0) @@ -340,7 +340,7 @@ beginCompilationUnit(abstract) endFunctionType(Function, ?) handleIdentifier(foo12, fieldDeclaration) handleNoFieldInitializer(;) - endClassFields(abstract, null, null, null, null, null, null, 1, abstract, ;) + endFields(DeclarationKind.Class, abstract, null, null, null, null, null, null, 1, abstract, ;) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 12, {, }) endClassDeclaration(abstract, }) diff --git a/pkg/front_end/parser_testcases/record/modifier_before_type_question.dart.intertwined.expect b/pkg/front_end/parser_testcases/record/modifier_before_type_question.dart.intertwined.expect index f82c00af5c1..0baece8a8ea 100644 --- a/pkg/front_end/parser_testcases/record/modifier_before_type_question.dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/record/modifier_before_type_question.dart.intertwined.expect @@ -42,7 +42,7 @@ parseUnit(abstract) listener: handleIdentifier(foo1, fieldDeclaration) parseFieldInitializerOpt(foo1, foo1, null, abstract, null, null, null, DeclarationKind.Class, Foo) listener: handleNoFieldInitializer(;) - listener: endClassFields(abstract, null, null, null, null, null, null, 1, abstract, ;) + listener: endFields(DeclarationKind.Class, abstract, null, null, null, null, null, null, 1, abstract, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, abstract) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Foo) @@ -59,7 +59,7 @@ parseUnit(abstract) listener: handleIdentifier(foo2, fieldDeclaration) parseFieldInitializerOpt(foo2, foo2, null, abstract, null, null, null, DeclarationKind.Class, Foo) listener: handleNoFieldInitializer(;) - listener: endClassFields(abstract, null, null, null, null, null, null, 1, abstract, ;) + listener: endFields(DeclarationKind.Class, abstract, null, null, null, null, null, null, 1, abstract, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, abstract) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Foo) @@ -96,7 +96,7 @@ parseUnit(abstract) listener: handleIdentifier(foo3, fieldDeclaration) parseFieldInitializerOpt(foo3, foo3, null, abstract, null, null, null, DeclarationKind.Class, Foo) listener: handleNoFieldInitializer(;) - listener: endClassFields(abstract, null, null, null, null, null, null, 1, abstract, ;) + listener: endFields(DeclarationKind.Class, abstract, null, null, null, null, null, null, 1, abstract, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, abstract) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Foo) @@ -133,7 +133,7 @@ parseUnit(abstract) listener: handleIdentifier(foo4, fieldDeclaration) parseFieldInitializerOpt(foo4, foo4, null, abstract, null, null, null, DeclarationKind.Class, Foo) listener: handleNoFieldInitializer(;) - listener: endClassFields(abstract, null, null, null, null, null, null, 1, abstract, ;) + listener: endFields(DeclarationKind.Class, abstract, null, null, null, null, null, null, 1, abstract, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, abstract) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Foo) @@ -166,7 +166,7 @@ parseUnit(abstract) listener: handleIdentifier(foo5, fieldDeclaration) parseFieldInitializerOpt(foo5, foo5, null, abstract, null, null, null, DeclarationKind.Class, Foo) listener: handleNoFieldInitializer(;) - listener: endClassFields(abstract, null, null, null, null, null, null, 1, abstract, ;) + listener: endFields(DeclarationKind.Class, abstract, null, null, null, null, null, null, 1, abstract, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, abstract) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Foo) @@ -199,7 +199,7 @@ parseUnit(abstract) listener: handleIdentifier(foo6, fieldDeclaration) parseFieldInitializerOpt(foo6, foo6, null, abstract, null, null, null, DeclarationKind.Class, Foo) listener: handleNoFieldInitializer(;) - listener: endClassFields(abstract, null, null, null, null, null, null, 1, abstract, ;) + listener: endFields(DeclarationKind.Class, abstract, null, null, null, null, null, null, 1, abstract, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, abstract) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Foo) @@ -235,7 +235,7 @@ parseUnit(abstract) listener: handleIdentifier(foo7, fieldDeclaration) parseFieldInitializerOpt(foo7, foo7, null, abstract, null, null, null, DeclarationKind.Class, Foo) listener: handleNoFieldInitializer(;) - listener: endClassFields(abstract, null, null, null, null, null, null, 1, abstract, ;) + listener: endFields(DeclarationKind.Class, abstract, null, null, null, null, null, null, 1, abstract, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, abstract) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Foo) @@ -271,7 +271,7 @@ parseUnit(abstract) listener: handleIdentifier(foo8, fieldDeclaration) parseFieldInitializerOpt(foo8, foo8, null, abstract, null, null, null, DeclarationKind.Class, Foo) listener: handleNoFieldInitializer(;) - listener: endClassFields(abstract, null, null, null, null, null, null, 1, abstract, ;) + listener: endFields(DeclarationKind.Class, abstract, null, null, null, null, null, null, 1, abstract, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, abstract) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Foo) @@ -326,7 +326,7 @@ parseUnit(abstract) listener: handleIdentifier(foo9, fieldDeclaration) parseFieldInitializerOpt(foo9, foo9, null, abstract, null, null, null, DeclarationKind.Class, Foo) listener: handleNoFieldInitializer(;) - listener: endClassFields(abstract, null, null, null, null, null, null, 1, abstract, ;) + listener: endFields(DeclarationKind.Class, abstract, null, null, null, null, null, null, 1, abstract, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, abstract) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Foo) @@ -381,7 +381,7 @@ parseUnit(abstract) listener: handleIdentifier(foo10, fieldDeclaration) parseFieldInitializerOpt(foo10, foo10, null, abstract, null, null, null, DeclarationKind.Class, Foo) listener: handleNoFieldInitializer(;) - listener: endClassFields(abstract, null, null, null, null, null, null, 1, abstract, ;) + listener: endFields(DeclarationKind.Class, abstract, null, null, null, null, null, null, 1, abstract, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, abstract) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Foo) @@ -436,7 +436,7 @@ parseUnit(abstract) listener: handleIdentifier(foo11, fieldDeclaration) parseFieldInitializerOpt(foo11, foo11, null, abstract, null, null, null, DeclarationKind.Class, Foo) listener: handleNoFieldInitializer(;) - listener: endClassFields(abstract, null, null, null, null, null, null, 1, abstract, ;) + listener: endFields(DeclarationKind.Class, abstract, null, null, null, null, null, null, 1, abstract, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, abstract) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Foo) @@ -491,7 +491,7 @@ parseUnit(abstract) listener: handleIdentifier(foo12, fieldDeclaration) parseFieldInitializerOpt(foo12, foo12, null, abstract, null, null, null, DeclarationKind.Class, Foo) listener: handleNoFieldInitializer(;) - listener: endClassFields(abstract, null, null, null, null, null, null, 1, abstract, ;) + listener: endFields(DeclarationKind.Class, abstract, null, null, null, null, null, null, 1, abstract, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 12, {, }) diff --git a/pkg/front_end/parser_testcases/record/operator_returning_record.dart.expect b/pkg/front_end/parser_testcases/record/operator_returning_record.dart.expect index d20069522c9..afbf5742769 100644 --- a/pkg/front_end/parser_testcases/record/operator_returning_record.dart.expect +++ b/pkg/front_end/parser_testcases/record/operator_returning_record.dart.expect @@ -57,7 +57,7 @@ beginCompilationUnit(class) endRecordLiteral((, 2, null) endReturnStatement(true, return, ;) endBlockFunctionBody(1, {, }) - endClassMethod(null, (, (, null, }) + endMethod(DeclarationKind.Class, null, (, (, null, }) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 1, {, }) endClassDeclaration(class, }) @@ -120,7 +120,7 @@ beginCompilationUnit(class) endRecordLiteral((, 2, null) endReturnStatement(true, return, ;) endBlockFunctionBody(1, {, }) - endClassMethod(null, (, (, null, }) + endMethod(DeclarationKind.Class, null, (, (, null, }) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 1, {, }) endClassDeclaration(class, }) diff --git a/pkg/front_end/parser_testcases/record/operator_returning_record.dart.intertwined.expect b/pkg/front_end/parser_testcases/record/operator_returning_record.dart.intertwined.expect index 02b97ebd7c6..ffe0b30dfe4 100644 --- a/pkg/front_end/parser_testcases/record/operator_returning_record.dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/record/operator_returning_record.dart.intertwined.expect @@ -124,7 +124,7 @@ parseUnit(class) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(1, {, }) - listener: endClassMethod(null, (, (, null, }) + listener: endMethod(DeclarationKind.Class, null, (, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 1, {, }) @@ -252,7 +252,7 @@ parseUnit(class) inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(1, {, }) - listener: endClassMethod(null, (, (, null, }) + listener: endMethod(DeclarationKind.Class, null, (, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 1, {, }) diff --git a/pkg/front_end/parser_testcases/record/record_type_03.dart.expect b/pkg/front_end/parser_testcases/record/record_type_03.dart.expect index 80643ab6b05..f59b2abe2e9 100644 --- a/pkg/front_end/parser_testcases/record/record_type_03.dart.expect +++ b/pkg/front_end/parser_testcases/record/record_type_03.dart.expect @@ -229,7 +229,7 @@ beginCompilationUnit(() handleLiteralInt(42) endRecordLiteral((, 2, null) handleExpressionFunctionBody(=>, ;) - endClassMethod(null, (, (, null, ;) + endMethod(DeclarationKind.Class, null, (, (, null, ;) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 1, {, }) endClassDeclaration(class, }) diff --git a/pkg/front_end/parser_testcases/record/record_type_03.dart.intertwined.expect b/pkg/front_end/parser_testcases/record/record_type_03.dart.intertwined.expect index 98299534d17..941741bcadc 100644 --- a/pkg/front_end/parser_testcases/record/record_type_03.dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/record/record_type_03.dart.intertwined.expect @@ -514,7 +514,7 @@ parseUnit(() ensureSemicolon()) listener: handleExpressionFunctionBody(=>, ;) inGenerator() - listener: endClassMethod(null, (, (, null, ;) + listener: endMethod(DeclarationKind.Class, null, (, (, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 1, {, }) diff --git a/pkg/front_end/parser_testcases/record/record_type_getter.dart.expect b/pkg/front_end/parser_testcases/record/record_type_getter.dart.expect index 82c2083e07c..9af1b7d7a4e 100644 --- a/pkg/front_end/parser_testcases/record/record_type_getter.dart.expect +++ b/pkg/front_end/parser_testcases/record/record_type_getter.dart.expect @@ -948,7 +948,7 @@ beginCompilationUnit(() endLiteralString(0, )) endRecordLiteral((, 2, null) handleExpressionFunctionBody(=>, ;) - endClassMethod(null, (, (, null, ;) + endMethod(DeclarationKind.Class, null, (, (, null, ;) endMember() beginMetadataStar(() endMetadataStar(0) @@ -996,7 +996,7 @@ beginCompilationUnit(() endRecordLiteral((, 2, null) endReturnStatement(true, return, ;) endBlockFunctionBody(1, {, }) - endClassMethod(null, (, (, null, }) + endMethod(DeclarationKind.Class, null, (, (, null, }) endMember() beginMetadataStar(() endMetadataStar(0) @@ -1039,7 +1039,7 @@ beginCompilationUnit(() endLiteralString(0, ;) handleThrowExpression(throw, "hello") handleExpressionFunctionBody(=>, ;) - endClassMethod(null, (, (, null, ;) + endMethod(DeclarationKind.Class, null, (, (, null, ;) endMember() beginMetadataStar(() endMetadataStar(0) @@ -1084,7 +1084,7 @@ beginCompilationUnit(() handleThrowExpression(throw, "hello") handleExpressionStatement(throw, ;) endBlockFunctionBody(1, {, }) - endClassMethod(null, (, (, null, }) + endMethod(DeclarationKind.Class, null, (, (, null, }) endMember() beginMetadataStar(() endMetadataStar(0) @@ -1128,7 +1128,7 @@ beginCompilationUnit(() handleThrowExpression(throw, "hello") handleExpressionFunctionBody(=>, ;) handleInvalidStatement(=>, GeneratorReturnsValue) - endClassMethod(null, (, (, null, ;) + endMethod(DeclarationKind.Class, null, (, (, null, ;) endMember() beginMetadataStar(() endMetadataStar(0) @@ -1173,7 +1173,7 @@ beginCompilationUnit(() handleThrowExpression(throw, "hello") handleExpressionStatement(throw, ;) endBlockFunctionBody(1, {, }) - endClassMethod(null, (, (, null, }) + endMethod(DeclarationKind.Class, null, (, (, null, }) endMember() beginMetadataStar(() endMetadataStar(0) @@ -1217,7 +1217,7 @@ beginCompilationUnit(() handleThrowExpression(throw, "hello") handleExpressionFunctionBody(=>, ;) handleInvalidStatement(=>, GeneratorReturnsValue) - endClassMethod(null, (, (, null, ;) + endMethod(DeclarationKind.Class, null, (, (, null, ;) endMember() beginMetadataStar(() endMetadataStar(0) @@ -1262,7 +1262,7 @@ beginCompilationUnit(() handleThrowExpression(throw, "hello") handleExpressionStatement(throw, ;) endBlockFunctionBody(1, {, }) - endClassMethod(null, (, (, null, }) + endMethod(DeclarationKind.Class, null, (, (, null, }) endMember() beginMetadataStar(() endMetadataStar(0) @@ -1297,7 +1297,7 @@ beginCompilationUnit(() endLiteralString(0, )) endRecordLiteral((, 2, null) handleExpressionFunctionBody(=>, ;) - endClassMethod(get, (, =>, null, ;) + endMethod(DeclarationKind.Class, get, (, =>, null, ;) endMember() beginMetadataStar(() endMetadataStar(0) @@ -1335,7 +1335,7 @@ beginCompilationUnit(() endRecordLiteral((, 2, null) endReturnStatement(true, return, ;) endBlockFunctionBody(1, {, }) - endClassMethod(get, (, {, null, }) + endMethod(DeclarationKind.Class, get, (, {, null, }) endMember() beginMetadataStar(() endMetadataStar(0) @@ -1368,7 +1368,7 @@ beginCompilationUnit(() endLiteralString(0, ;) handleThrowExpression(throw, "hello") handleExpressionFunctionBody(=>, ;) - endClassMethod(get, (, async, null, ;) + endMethod(DeclarationKind.Class, get, (, async, null, ;) endMember() beginMetadataStar(() endMetadataStar(0) @@ -1403,7 +1403,7 @@ beginCompilationUnit(() handleThrowExpression(throw, "hello") handleExpressionStatement(throw, ;) endBlockFunctionBody(1, {, }) - endClassMethod(get, (, async, null, }) + endMethod(DeclarationKind.Class, get, (, async, null, }) endMember() beginMetadataStar(() endMetadataStar(0) @@ -1437,7 +1437,7 @@ beginCompilationUnit(() handleThrowExpression(throw, "hello") handleExpressionFunctionBody(=>, ;) handleInvalidStatement(=>, GeneratorReturnsValue) - endClassMethod(get, (, async, null, ;) + endMethod(DeclarationKind.Class, get, (, async, null, ;) endMember() beginMetadataStar(() endMetadataStar(0) @@ -1472,7 +1472,7 @@ beginCompilationUnit(() handleThrowExpression(throw, "hello") handleExpressionStatement(throw, ;) endBlockFunctionBody(1, {, }) - endClassMethod(get, (, async, null, }) + endMethod(DeclarationKind.Class, get, (, async, null, }) endMember() beginMetadataStar(() endMetadataStar(0) @@ -1506,7 +1506,7 @@ beginCompilationUnit(() handleThrowExpression(throw, "hello") handleExpressionFunctionBody(=>, ;) handleInvalidStatement(=>, GeneratorReturnsValue) - endClassMethod(get, (, sync, null, ;) + endMethod(DeclarationKind.Class, get, (, sync, null, ;) endMember() beginMetadataStar(() endMetadataStar(0) @@ -1541,7 +1541,7 @@ beginCompilationUnit(() handleThrowExpression(throw, "hello") handleExpressionStatement(throw, ;) endBlockFunctionBody(1, {, }) - endClassMethod(get, (, sync, null, }) + endMethod(DeclarationKind.Class, get, (, sync, null, }) endMember() beginMetadataStar(() endMetadataStar(0) @@ -1576,7 +1576,7 @@ beginCompilationUnit(() endLiteralString(0, )) endRecordLiteral((, 2, null) handleExpressionFunctionBody(=>, ;) - endClassMethod(get, (, =>, null, ;) + endMethod(DeclarationKind.Class, get, (, =>, null, ;) endMember() beginMetadataStar(() endMetadataStar(0) @@ -1614,7 +1614,7 @@ beginCompilationUnit(() endRecordLiteral((, 2, null) endReturnStatement(true, return, ;) endBlockFunctionBody(1, {, }) - endClassMethod(get, (, {, null, }) + endMethod(DeclarationKind.Class, get, (, {, null, }) endMember() beginMetadataStar(() endMetadataStar(0) @@ -1647,7 +1647,7 @@ beginCompilationUnit(() endLiteralString(0, ;) handleThrowExpression(throw, "hello") handleExpressionFunctionBody(=>, ;) - endClassMethod(get, (, async, null, ;) + endMethod(DeclarationKind.Class, get, (, async, null, ;) endMember() beginMetadataStar(() endMetadataStar(0) @@ -1683,7 +1683,7 @@ beginCompilationUnit(() handleThrowExpression(throw, "hello") endReturnStatement(true, return, ;) endBlockFunctionBody(1, {, }) - endClassMethod(get, (, async, null, }) + endMethod(DeclarationKind.Class, get, (, async, null, }) endMember() beginMetadataStar(() endMetadataStar(0) @@ -1717,7 +1717,7 @@ beginCompilationUnit(() handleThrowExpression(throw, "hello") handleExpressionFunctionBody(=>, ;) handleInvalidStatement(=>, GeneratorReturnsValue) - endClassMethod(get, (, async, null, ;) + endMethod(DeclarationKind.Class, get, (, async, null, ;) endMember() beginMetadataStar(() endMetadataStar(0) @@ -1754,7 +1754,7 @@ beginCompilationUnit(() endReturnStatement(true, return, ;) handleInvalidStatement(return, GeneratorReturnsValue) endBlockFunctionBody(1, {, }) - endClassMethod(get, (, async, null, }) + endMethod(DeclarationKind.Class, get, (, async, null, }) endMember() beginMetadataStar(() endMetadataStar(0) @@ -1788,7 +1788,7 @@ beginCompilationUnit(() handleThrowExpression(throw, "hello") handleExpressionFunctionBody(=>, ;) handleInvalidStatement(=>, GeneratorReturnsValue) - endClassMethod(get, (, sync, null, ;) + endMethod(DeclarationKind.Class, get, (, sync, null, ;) endMember() beginMetadataStar(() endMetadataStar(0) @@ -1825,7 +1825,7 @@ beginCompilationUnit(() endReturnStatement(true, return, ;) handleInvalidStatement(return, GeneratorReturnsValue) endBlockFunctionBody(1, {, }) - endClassMethod(get, (, sync, null, }) + endMethod(DeclarationKind.Class, get, (, sync, null, }) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 24, {, }) endClassDeclaration(class, }) @@ -1886,7 +1886,7 @@ beginCompilationUnit(() endLiteralString(0, )) endRecordLiteral((, 2, null) handleExpressionFunctionBody(=>, ;) - endClassMethod(null, static, (, null, ;) + endMethod(DeclarationKind.Class, null, static, (, null, ;) endMember() beginMetadataStar(static) endMetadataStar(0) @@ -1934,7 +1934,7 @@ beginCompilationUnit(() endRecordLiteral((, 2, null) endReturnStatement(true, return, ;) endBlockFunctionBody(1, {, }) - endClassMethod(null, static, (, null, }) + endMethod(DeclarationKind.Class, null, static, (, null, }) endMember() beginMetadataStar(static) endMetadataStar(0) @@ -1977,7 +1977,7 @@ beginCompilationUnit(() endLiteralString(0, ;) handleThrowExpression(throw, "hello") handleExpressionFunctionBody(=>, ;) - endClassMethod(null, static, (, null, ;) + endMethod(DeclarationKind.Class, null, static, (, null, ;) endMember() beginMetadataStar(static) endMetadataStar(0) @@ -2022,7 +2022,7 @@ beginCompilationUnit(() handleThrowExpression(throw, "hello") handleExpressionStatement(throw, ;) endBlockFunctionBody(1, {, }) - endClassMethod(null, static, (, null, }) + endMethod(DeclarationKind.Class, null, static, (, null, }) endMember() beginMetadataStar(static) endMetadataStar(0) @@ -2066,7 +2066,7 @@ beginCompilationUnit(() handleThrowExpression(throw, "hello") handleExpressionFunctionBody(=>, ;) handleInvalidStatement(=>, GeneratorReturnsValue) - endClassMethod(null, static, (, null, ;) + endMethod(DeclarationKind.Class, null, static, (, null, ;) endMember() beginMetadataStar(static) endMetadataStar(0) @@ -2111,7 +2111,7 @@ beginCompilationUnit(() handleThrowExpression(throw, "hello") handleExpressionStatement(throw, ;) endBlockFunctionBody(1, {, }) - endClassMethod(null, static, (, null, }) + endMethod(DeclarationKind.Class, null, static, (, null, }) endMember() beginMetadataStar(static) endMetadataStar(0) @@ -2155,7 +2155,7 @@ beginCompilationUnit(() handleThrowExpression(throw, "hello") handleExpressionFunctionBody(=>, ;) handleInvalidStatement(=>, GeneratorReturnsValue) - endClassMethod(null, static, (, null, ;) + endMethod(DeclarationKind.Class, null, static, (, null, ;) endMember() beginMetadataStar(static) endMetadataStar(0) @@ -2200,7 +2200,7 @@ beginCompilationUnit(() handleThrowExpression(throw, "hello") handleExpressionStatement(throw, ;) endBlockFunctionBody(1, {, }) - endClassMethod(null, static, (, null, }) + endMethod(DeclarationKind.Class, null, static, (, null, }) endMember() beginMetadataStar(static) endMetadataStar(0) @@ -2235,7 +2235,7 @@ beginCompilationUnit(() endLiteralString(0, )) endRecordLiteral((, 2, null) handleExpressionFunctionBody(=>, ;) - endClassMethod(get, static, =>, null, ;) + endMethod(DeclarationKind.Class, get, static, =>, null, ;) endMember() beginMetadataStar(static) endMetadataStar(0) @@ -2273,7 +2273,7 @@ beginCompilationUnit(() endRecordLiteral((, 2, null) endReturnStatement(true, return, ;) endBlockFunctionBody(1, {, }) - endClassMethod(get, static, {, null, }) + endMethod(DeclarationKind.Class, get, static, {, null, }) endMember() beginMetadataStar(static) endMetadataStar(0) @@ -2306,7 +2306,7 @@ beginCompilationUnit(() endLiteralString(0, ;) handleThrowExpression(throw, "hello") handleExpressionFunctionBody(=>, ;) - endClassMethod(get, static, async, null, ;) + endMethod(DeclarationKind.Class, get, static, async, null, ;) endMember() beginMetadataStar(static) endMetadataStar(0) @@ -2341,7 +2341,7 @@ beginCompilationUnit(() handleThrowExpression(throw, "hello") handleExpressionStatement(throw, ;) endBlockFunctionBody(1, {, }) - endClassMethod(get, static, async, null, }) + endMethod(DeclarationKind.Class, get, static, async, null, }) endMember() beginMetadataStar(static) endMetadataStar(0) @@ -2375,7 +2375,7 @@ beginCompilationUnit(() handleThrowExpression(throw, "hello") handleExpressionFunctionBody(=>, ;) handleInvalidStatement(=>, GeneratorReturnsValue) - endClassMethod(get, static, async, null, ;) + endMethod(DeclarationKind.Class, get, static, async, null, ;) endMember() beginMetadataStar(static) endMetadataStar(0) @@ -2410,7 +2410,7 @@ beginCompilationUnit(() handleThrowExpression(throw, "hello") handleExpressionStatement(throw, ;) endBlockFunctionBody(1, {, }) - endClassMethod(get, static, async, null, }) + endMethod(DeclarationKind.Class, get, static, async, null, }) endMember() beginMetadataStar(static) endMetadataStar(0) @@ -2444,7 +2444,7 @@ beginCompilationUnit(() handleThrowExpression(throw, "hello") handleExpressionFunctionBody(=>, ;) handleInvalidStatement(=>, GeneratorReturnsValue) - endClassMethod(get, static, sync, null, ;) + endMethod(DeclarationKind.Class, get, static, sync, null, ;) endMember() beginMetadataStar(static) endMetadataStar(0) @@ -2479,7 +2479,7 @@ beginCompilationUnit(() handleThrowExpression(throw, "hello") handleExpressionStatement(throw, ;) endBlockFunctionBody(1, {, }) - endClassMethod(get, static, sync, null, }) + endMethod(DeclarationKind.Class, get, static, sync, null, }) endMember() beginMetadataStar(static) endMetadataStar(0) @@ -2514,7 +2514,7 @@ beginCompilationUnit(() endLiteralString(0, )) endRecordLiteral((, 2, null) handleExpressionFunctionBody(=>, ;) - endClassMethod(get, static, =>, null, ;) + endMethod(DeclarationKind.Class, get, static, =>, null, ;) endMember() beginMetadataStar(static) endMetadataStar(0) @@ -2552,7 +2552,7 @@ beginCompilationUnit(() endRecordLiteral((, 2, null) endReturnStatement(true, return, ;) endBlockFunctionBody(1, {, }) - endClassMethod(get, static, {, null, }) + endMethod(DeclarationKind.Class, get, static, {, null, }) endMember() beginMetadataStar(static) endMetadataStar(0) @@ -2585,7 +2585,7 @@ beginCompilationUnit(() endLiteralString(0, ;) handleThrowExpression(throw, "hello") handleExpressionFunctionBody(=>, ;) - endClassMethod(get, static, async, null, ;) + endMethod(DeclarationKind.Class, get, static, async, null, ;) endMember() beginMetadataStar(static) endMetadataStar(0) @@ -2620,7 +2620,7 @@ beginCompilationUnit(() handleThrowExpression(throw, "hello") handleExpressionStatement(throw, ;) endBlockFunctionBody(1, {, }) - endClassMethod(get, static, async, null, }) + endMethod(DeclarationKind.Class, get, static, async, null, }) endMember() beginMetadataStar(static) endMetadataStar(0) @@ -2654,7 +2654,7 @@ beginCompilationUnit(() handleThrowExpression(throw, "hello") handleExpressionFunctionBody(=>, ;) handleInvalidStatement(=>, GeneratorReturnsValue) - endClassMethod(get, static, async, null, ;) + endMethod(DeclarationKind.Class, get, static, async, null, ;) endMember() beginMetadataStar(static) endMetadataStar(0) @@ -2689,7 +2689,7 @@ beginCompilationUnit(() handleThrowExpression(throw, "hello") handleExpressionStatement(throw, ;) endBlockFunctionBody(1, {, }) - endClassMethod(get, static, async, null, }) + endMethod(DeclarationKind.Class, get, static, async, null, }) endMember() beginMetadataStar(static) endMetadataStar(0) @@ -2723,7 +2723,7 @@ beginCompilationUnit(() handleThrowExpression(throw, "hello") handleExpressionFunctionBody(=>, ;) handleInvalidStatement(=>, GeneratorReturnsValue) - endClassMethod(get, static, sync, null, ;) + endMethod(DeclarationKind.Class, get, static, sync, null, ;) endMember() beginMetadataStar(static) endMetadataStar(0) @@ -2758,7 +2758,7 @@ beginCompilationUnit(() handleThrowExpression(throw, "hello") handleExpressionStatement(throw, ;) endBlockFunctionBody(1, {, }) - endClassMethod(get, static, sync, null, }) + endMethod(DeclarationKind.Class, get, static, sync, null, }) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 24, {, }) endClassDeclaration(class, }) diff --git a/pkg/front_end/parser_testcases/record/record_type_getter.dart.intertwined.expect b/pkg/front_end/parser_testcases/record/record_type_getter.dart.intertwined.expect index 70529007e69..1766df78c9c 100644 --- a/pkg/front_end/parser_testcases/record/record_type_getter.dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/record/record_type_getter.dart.intertwined.expect @@ -1962,7 +1962,7 @@ parseUnit(() ensureSemicolon()) listener: handleExpressionFunctionBody(=>, ;) inGenerator() - listener: endClassMethod(null, (, (, null, ;) + listener: endMethod(DeclarationKind.Class, null, (, (, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, () parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Foo) @@ -2067,7 +2067,7 @@ parseUnit(() inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(1, {, }) - listener: endClassMethod(null, (, (, null, }) + listener: endMethod(DeclarationKind.Class, null, (, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, () parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Foo) @@ -2151,7 +2151,7 @@ parseUnit(() ensureSemicolon("hello") listener: handleExpressionFunctionBody(=>, ;) inGenerator() - listener: endClassMethod(null, (, (, null, ;) + listener: endMethod(DeclarationKind.Class, null, (, (, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, () parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Foo) @@ -2243,7 +2243,7 @@ parseUnit(() listener: handleExpressionStatement(throw, ;) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(1, {, }) - listener: endClassMethod(null, (, (, null, }) + listener: endMethod(DeclarationKind.Class, null, (, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, () parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Foo) @@ -2328,7 +2328,7 @@ parseUnit(() listener: handleExpressionFunctionBody(=>, ;) inGenerator() listener: handleInvalidStatement(=>, GeneratorReturnsValue) - listener: endClassMethod(null, (, (, null, ;) + listener: endMethod(DeclarationKind.Class, null, (, (, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, () parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Foo) @@ -2420,7 +2420,7 @@ parseUnit(() listener: handleExpressionStatement(throw, ;) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(1, {, }) - listener: endClassMethod(null, (, (, null, }) + listener: endMethod(DeclarationKind.Class, null, (, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, () parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Foo) @@ -2505,7 +2505,7 @@ parseUnit(() listener: handleExpressionFunctionBody(=>, ;) inGenerator() listener: handleInvalidStatement(=>, GeneratorReturnsValue) - listener: endClassMethod(null, (, (, null, ;) + listener: endMethod(DeclarationKind.Class, null, (, (, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, () parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Foo) @@ -2597,7 +2597,7 @@ parseUnit(() listener: handleExpressionStatement(throw, ;) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(1, {, }) - listener: endClassMethod(null, (, (, null, }) + listener: endMethod(DeclarationKind.Class, null, (, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, () parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Foo) @@ -2679,7 +2679,7 @@ parseUnit(() ensureSemicolon()) listener: handleExpressionFunctionBody(=>, ;) inGenerator() - listener: endClassMethod(get, (, =>, null, ;) + listener: endMethod(DeclarationKind.Class, get, (, =>, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, () parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Foo) @@ -2768,7 +2768,7 @@ parseUnit(() inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(1, {, }) - listener: endClassMethod(get, (, {, null, }) + listener: endMethod(DeclarationKind.Class, get, (, {, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, () parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Foo) @@ -2836,7 +2836,7 @@ parseUnit(() ensureSemicolon("hello") listener: handleExpressionFunctionBody(=>, ;) inGenerator() - listener: endClassMethod(get, (, async, null, ;) + listener: endMethod(DeclarationKind.Class, get, (, async, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, () parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Foo) @@ -2912,7 +2912,7 @@ parseUnit(() listener: handleExpressionStatement(throw, ;) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(1, {, }) - listener: endClassMethod(get, (, async, null, }) + listener: endMethod(DeclarationKind.Class, get, (, async, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, () parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Foo) @@ -2981,7 +2981,7 @@ parseUnit(() listener: handleExpressionFunctionBody(=>, ;) inGenerator() listener: handleInvalidStatement(=>, GeneratorReturnsValue) - listener: endClassMethod(get, (, async, null, ;) + listener: endMethod(DeclarationKind.Class, get, (, async, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, () parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Foo) @@ -3057,7 +3057,7 @@ parseUnit(() listener: handleExpressionStatement(throw, ;) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(1, {, }) - listener: endClassMethod(get, (, async, null, }) + listener: endMethod(DeclarationKind.Class, get, (, async, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, () parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Foo) @@ -3126,7 +3126,7 @@ parseUnit(() listener: handleExpressionFunctionBody(=>, ;) inGenerator() listener: handleInvalidStatement(=>, GeneratorReturnsValue) - listener: endClassMethod(get, (, sync, null, ;) + listener: endMethod(DeclarationKind.Class, get, (, sync, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, () parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Foo) @@ -3202,7 +3202,7 @@ parseUnit(() listener: handleExpressionStatement(throw, ;) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(1, {, }) - listener: endClassMethod(get, (, sync, null, }) + listener: endMethod(DeclarationKind.Class, get, (, sync, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, () parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Foo) @@ -3284,7 +3284,7 @@ parseUnit(() ensureSemicolon()) listener: handleExpressionFunctionBody(=>, ;) inGenerator() - listener: endClassMethod(get, (, =>, null, ;) + listener: endMethod(DeclarationKind.Class, get, (, =>, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, () parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Foo) @@ -3373,7 +3373,7 @@ parseUnit(() inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(1, {, }) - listener: endClassMethod(get, (, {, null, }) + listener: endMethod(DeclarationKind.Class, get, (, {, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, () parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Foo) @@ -3441,7 +3441,7 @@ parseUnit(() ensureSemicolon("hello") listener: handleExpressionFunctionBody(=>, ;) inGenerator() - listener: endClassMethod(get, (, async, null, ;) + listener: endMethod(DeclarationKind.Class, get, (, async, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, () parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Foo) @@ -3516,7 +3516,7 @@ parseUnit(() inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(1, {, }) - listener: endClassMethod(get, (, async, null, }) + listener: endMethod(DeclarationKind.Class, get, (, async, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, () parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Foo) @@ -3585,7 +3585,7 @@ parseUnit(() listener: handleExpressionFunctionBody(=>, ;) inGenerator() listener: handleInvalidStatement(=>, GeneratorReturnsValue) - listener: endClassMethod(get, (, async, null, ;) + listener: endMethod(DeclarationKind.Class, get, (, async, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, () parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Foo) @@ -3661,7 +3661,7 @@ parseUnit(() listener: handleInvalidStatement(return, GeneratorReturnsValue) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(1, {, }) - listener: endClassMethod(get, (, async, null, }) + listener: endMethod(DeclarationKind.Class, get, (, async, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, () parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Foo) @@ -3730,7 +3730,7 @@ parseUnit(() listener: handleExpressionFunctionBody(=>, ;) inGenerator() listener: handleInvalidStatement(=>, GeneratorReturnsValue) - listener: endClassMethod(get, (, sync, null, ;) + listener: endMethod(DeclarationKind.Class, get, (, sync, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, () parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Foo) @@ -3806,7 +3806,7 @@ parseUnit(() listener: handleInvalidStatement(return, GeneratorReturnsValue) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(1, {, }) - listener: endClassMethod(get, (, sync, null, }) + listener: endMethod(DeclarationKind.Class, get, (, sync, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 24, {, }) @@ -3932,7 +3932,7 @@ parseUnit(() ensureSemicolon()) listener: handleExpressionFunctionBody(=>, ;) inGenerator() - listener: endClassMethod(null, static, (, null, ;) + listener: endMethod(DeclarationKind.Class, null, static, (, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, static) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Bar) @@ -4036,7 +4036,7 @@ parseUnit(() inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(1, {, }) - listener: endClassMethod(null, static, (, null, }) + listener: endMethod(DeclarationKind.Class, null, static, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, static) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Bar) @@ -4119,7 +4119,7 @@ parseUnit(() ensureSemicolon("hello") listener: handleExpressionFunctionBody(=>, ;) inGenerator() - listener: endClassMethod(null, static, (, null, ;) + listener: endMethod(DeclarationKind.Class, null, static, (, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, static) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Bar) @@ -4210,7 +4210,7 @@ parseUnit(() listener: handleExpressionStatement(throw, ;) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(1, {, }) - listener: endClassMethod(null, static, (, null, }) + listener: endMethod(DeclarationKind.Class, null, static, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, static) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Bar) @@ -4294,7 +4294,7 @@ parseUnit(() listener: handleExpressionFunctionBody(=>, ;) inGenerator() listener: handleInvalidStatement(=>, GeneratorReturnsValue) - listener: endClassMethod(null, static, (, null, ;) + listener: endMethod(DeclarationKind.Class, null, static, (, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, static) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Bar) @@ -4385,7 +4385,7 @@ parseUnit(() listener: handleExpressionStatement(throw, ;) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(1, {, }) - listener: endClassMethod(null, static, (, null, }) + listener: endMethod(DeclarationKind.Class, null, static, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, static) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Bar) @@ -4469,7 +4469,7 @@ parseUnit(() listener: handleExpressionFunctionBody(=>, ;) inGenerator() listener: handleInvalidStatement(=>, GeneratorReturnsValue) - listener: endClassMethod(null, static, (, null, ;) + listener: endMethod(DeclarationKind.Class, null, static, (, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, static) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Bar) @@ -4560,7 +4560,7 @@ parseUnit(() listener: handleExpressionStatement(throw, ;) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(1, {, }) - listener: endClassMethod(null, static, (, null, }) + listener: endMethod(DeclarationKind.Class, null, static, (, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, static) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Bar) @@ -4641,7 +4641,7 @@ parseUnit(() ensureSemicolon()) listener: handleExpressionFunctionBody(=>, ;) inGenerator() - listener: endClassMethod(get, static, =>, null, ;) + listener: endMethod(DeclarationKind.Class, get, static, =>, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, static) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Bar) @@ -4729,7 +4729,7 @@ parseUnit(() inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(1, {, }) - listener: endClassMethod(get, static, {, null, }) + listener: endMethod(DeclarationKind.Class, get, static, {, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, static) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Bar) @@ -4796,7 +4796,7 @@ parseUnit(() ensureSemicolon("hello") listener: handleExpressionFunctionBody(=>, ;) inGenerator() - listener: endClassMethod(get, static, async, null, ;) + listener: endMethod(DeclarationKind.Class, get, static, async, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, static) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Bar) @@ -4871,7 +4871,7 @@ parseUnit(() listener: handleExpressionStatement(throw, ;) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(1, {, }) - listener: endClassMethod(get, static, async, null, }) + listener: endMethod(DeclarationKind.Class, get, static, async, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, static) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Bar) @@ -4939,7 +4939,7 @@ parseUnit(() listener: handleExpressionFunctionBody(=>, ;) inGenerator() listener: handleInvalidStatement(=>, GeneratorReturnsValue) - listener: endClassMethod(get, static, async, null, ;) + listener: endMethod(DeclarationKind.Class, get, static, async, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, static) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Bar) @@ -5014,7 +5014,7 @@ parseUnit(() listener: handleExpressionStatement(throw, ;) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(1, {, }) - listener: endClassMethod(get, static, async, null, }) + listener: endMethod(DeclarationKind.Class, get, static, async, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, static) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Bar) @@ -5082,7 +5082,7 @@ parseUnit(() listener: handleExpressionFunctionBody(=>, ;) inGenerator() listener: handleInvalidStatement(=>, GeneratorReturnsValue) - listener: endClassMethod(get, static, sync, null, ;) + listener: endMethod(DeclarationKind.Class, get, static, sync, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, static) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Bar) @@ -5157,7 +5157,7 @@ parseUnit(() listener: handleExpressionStatement(throw, ;) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(1, {, }) - listener: endClassMethod(get, static, sync, null, }) + listener: endMethod(DeclarationKind.Class, get, static, sync, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, static) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Bar) @@ -5238,7 +5238,7 @@ parseUnit(() ensureSemicolon()) listener: handleExpressionFunctionBody(=>, ;) inGenerator() - listener: endClassMethod(get, static, =>, null, ;) + listener: endMethod(DeclarationKind.Class, get, static, =>, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, static) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Bar) @@ -5326,7 +5326,7 @@ parseUnit(() inGenerator() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(1, {, }) - listener: endClassMethod(get, static, {, null, }) + listener: endMethod(DeclarationKind.Class, get, static, {, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, static) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Bar) @@ -5393,7 +5393,7 @@ parseUnit(() ensureSemicolon("hello") listener: handleExpressionFunctionBody(=>, ;) inGenerator() - listener: endClassMethod(get, static, async, null, ;) + listener: endMethod(DeclarationKind.Class, get, static, async, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, static) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Bar) @@ -5468,7 +5468,7 @@ parseUnit(() listener: handleExpressionStatement(throw, ;) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(1, {, }) - listener: endClassMethod(get, static, async, null, }) + listener: endMethod(DeclarationKind.Class, get, static, async, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, static) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Bar) @@ -5536,7 +5536,7 @@ parseUnit(() listener: handleExpressionFunctionBody(=>, ;) inGenerator() listener: handleInvalidStatement(=>, GeneratorReturnsValue) - listener: endClassMethod(get, static, async, null, ;) + listener: endMethod(DeclarationKind.Class, get, static, async, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, static) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Bar) @@ -5611,7 +5611,7 @@ parseUnit(() listener: handleExpressionStatement(throw, ;) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(1, {, }) - listener: endClassMethod(get, static, async, null, }) + listener: endMethod(DeclarationKind.Class, get, static, async, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, static) parseClassOrMixinOrExtensionOrEnumMemberImpl(}, DeclarationKind.Class, Bar) @@ -5679,7 +5679,7 @@ parseUnit(() listener: handleExpressionFunctionBody(=>, ;) inGenerator() listener: handleInvalidStatement(=>, GeneratorReturnsValue) - listener: endClassMethod(get, static, sync, null, ;) + listener: endMethod(DeclarationKind.Class, get, static, sync, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, static) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Bar) @@ -5754,7 +5754,7 @@ parseUnit(() listener: handleExpressionStatement(throw, ;) notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endBlockFunctionBody(1, {, }) - listener: endClassMethod(get, static, sync, null, }) + listener: endMethod(DeclarationKind.Class, get, static, sync, null, }) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 24, {, }) diff --git a/pkg/front_end/parser_testcases/record/record_type_setter.dart.expect b/pkg/front_end/parser_testcases/record/record_type_setter.dart.expect index 226a91a260a..f5777743b5b 100644 --- a/pkg/front_end/parser_testcases/record/record_type_setter.dart.expect +++ b/pkg/front_end/parser_testcases/record/record_type_setter.dart.expect @@ -217,7 +217,7 @@ beginCompilationUnit(() endLiteralString(0, )) endRecordLiteral((, 2, null) handleExpressionFunctionBody(=>, ;) - endClassMethod(null, (, (, null, ;) + endMethod(DeclarationKind.Class, null, (, (, null, ;) endMember() beginMetadataStar(void) endMetadataStar(0) @@ -260,7 +260,7 @@ beginCompilationUnit(() endLiteralString(0, )) endRecordLiteral((, 2, null) handleExpressionFunctionBody(=>, ;) - endClassMethod(set, void, (, null, ;) + endMethod(DeclarationKind.Class, set, void, (, null, ;) endMember() beginMetadataStar(() endMetadataStar(0) @@ -295,7 +295,7 @@ beginCompilationUnit(() endLiteralString(0, )) endRecordLiteral((, 2, null) handleExpressionFunctionBody(=>, ;) - endClassMethod(get, (, =>, null, ;) + endMethod(DeclarationKind.Class, get, (, =>, null, ;) endMember() beginMetadataStar(void) endMetadataStar(0) @@ -338,7 +338,7 @@ beginCompilationUnit(() endLiteralString(0, )) endRecordLiteral((, 2, null) handleExpressionFunctionBody(=>, ;) - endClassMethod(set, void, (, null, ;) + endMethod(DeclarationKind.Class, set, void, (, null, ;) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 4, {, }) endClassDeclaration(class, }) @@ -399,7 +399,7 @@ beginCompilationUnit(() endLiteralString(0, )) endRecordLiteral((, 2, null) handleExpressionFunctionBody(=>, ;) - endClassMethod(null, static, (, null, ;) + endMethod(DeclarationKind.Class, null, static, (, null, ;) endMember() beginMetadataStar(static) endMetadataStar(0) @@ -442,7 +442,7 @@ beginCompilationUnit(() endLiteralString(0, )) endRecordLiteral((, 2, null) handleExpressionFunctionBody(=>, ;) - endClassMethod(set, static, (, null, ;) + endMethod(DeclarationKind.Class, set, static, (, null, ;) endMember() beginMetadataStar(static) endMetadataStar(0) @@ -477,7 +477,7 @@ beginCompilationUnit(() endLiteralString(0, )) endRecordLiteral((, 2, null) handleExpressionFunctionBody(=>, ;) - endClassMethod(get, static, =>, null, ;) + endMethod(DeclarationKind.Class, get, static, =>, null, ;) endMember() beginMetadataStar(static) endMetadataStar(0) @@ -520,7 +520,7 @@ beginCompilationUnit(() endLiteralString(0, )) endRecordLiteral((, 2, null) handleExpressionFunctionBody(=>, ;) - endClassMethod(set, static, (, null, ;) + endMethod(DeclarationKind.Class, set, static, (, null, ;) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 4, {, }) endClassDeclaration(class, }) diff --git a/pkg/front_end/parser_testcases/record/record_type_setter.dart.intertwined.expect b/pkg/front_end/parser_testcases/record/record_type_setter.dart.intertwined.expect index da5bca9f704..33cd8049e63 100644 --- a/pkg/front_end/parser_testcases/record/record_type_setter.dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/record/record_type_setter.dart.intertwined.expect @@ -476,7 +476,7 @@ parseUnit(() ensureSemicolon()) listener: handleExpressionFunctionBody(=>, ;) inGenerator() - listener: endClassMethod(null, (, (, null, ;) + listener: endMethod(DeclarationKind.Class, null, (, (, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, void) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Foo) @@ -571,7 +571,7 @@ parseUnit(() ensureSemicolon()) listener: handleExpressionFunctionBody(=>, ;) inGenerator() - listener: endClassMethod(set, void, (, null, ;) + listener: endMethod(DeclarationKind.Class, set, void, (, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, () parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Foo) @@ -653,7 +653,7 @@ parseUnit(() ensureSemicolon()) listener: handleExpressionFunctionBody(=>, ;) inGenerator() - listener: endClassMethod(get, (, =>, null, ;) + listener: endMethod(DeclarationKind.Class, get, (, =>, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, void) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Foo) @@ -748,7 +748,7 @@ parseUnit(() ensureSemicolon()) listener: handleExpressionFunctionBody(=>, ;) inGenerator() - listener: endClassMethod(set, void, (, null, ;) + listener: endMethod(DeclarationKind.Class, set, void, (, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 4, {, }) @@ -874,7 +874,7 @@ parseUnit(() ensureSemicolon()) listener: handleExpressionFunctionBody(=>, ;) inGenerator() - listener: endClassMethod(null, static, (, null, ;) + listener: endMethod(DeclarationKind.Class, null, static, (, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, static) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Bar) @@ -968,7 +968,7 @@ parseUnit(() ensureSemicolon()) listener: handleExpressionFunctionBody(=>, ;) inGenerator() - listener: endClassMethod(set, static, (, null, ;) + listener: endMethod(DeclarationKind.Class, set, static, (, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, static) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Bar) @@ -1049,7 +1049,7 @@ parseUnit(() ensureSemicolon()) listener: handleExpressionFunctionBody(=>, ;) inGenerator() - listener: endClassMethod(get, static, =>, null, ;) + listener: endMethod(DeclarationKind.Class, get, static, =>, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, static) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Bar) @@ -1143,7 +1143,7 @@ parseUnit(() ensureSemicolon()) listener: handleExpressionFunctionBody(=>, ;) inGenerator() - listener: endClassMethod(set, static, (, null, ;) + listener: endMethod(DeclarationKind.Class, set, static, (, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 4, {, }) diff --git a/pkg/front_end/parser_testcases/record/record_type_with_modifiers.dart.expect b/pkg/front_end/parser_testcases/record/record_type_with_modifiers.dart.expect index e2c5119eeb5..090ff84fb96 100644 --- a/pkg/front_end/parser_testcases/record/record_type_with_modifiers.dart.expect +++ b/pkg/front_end/parser_testcases/record/record_type_with_modifiers.dart.expect @@ -41,7 +41,7 @@ beginCompilationUnit(class) handleLiteralInt(42) endRecordLiteral((, 2, null) endFieldInitializer(=, )) - endClassFields(null, null, null, null, null, null, final, 1, final, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) endMember() beginMetadataStar(static) endMetadataStar(0) @@ -72,7 +72,7 @@ beginCompilationUnit(class) handleLiteralInt(42) endRecordLiteral((, 2, null) endFieldInitializer(=, )) - endClassFields(null, null, null, static, null, null, null, 1, static, ;) + endFields(DeclarationKind.Class, null, null, null, static, null, null, null, 1, static, ;) endMember() beginMetadataStar(static) endMetadataStar(0) @@ -103,7 +103,7 @@ beginCompilationUnit(class) handleLiteralInt(42) endRecordLiteral((, 2, null) endFieldInitializer(=, )) - endClassFields(null, null, null, static, null, null, final, 1, static, ;) + endFields(DeclarationKind.Class, null, null, null, static, null, null, final, 1, static, ;) endMember() beginMetadataStar(static) endMetadataStar(0) @@ -134,7 +134,7 @@ beginCompilationUnit(class) handleLiteralInt(42) endRecordLiteral((, 2, null) endFieldInitializer(=, )) - endClassFields(null, null, null, static, null, null, const, 1, static, ;) + endFields(DeclarationKind.Class, null, null, null, static, null, null, const, 1, static, ;) endMember() beginMetadataStar(late) endMetadataStar(0) @@ -160,7 +160,7 @@ beginCompilationUnit(class) endRecordType((, null, 2, false) handleIdentifier(c, fieldDeclaration) handleNoFieldInitializer(;) - endClassFields(null, null, null, null, null, late, null, 1, late, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, late, null, 1, late, ;) endMember() beginMetadataStar(late) endMetadataStar(0) @@ -186,7 +186,7 @@ beginCompilationUnit(class) endRecordType((, null, 2, false) handleIdentifier(d, fieldDeclaration) handleNoFieldInitializer(;) - endClassFields(null, null, null, null, null, late, final, 1, late, ;) + endFields(DeclarationKind.Class, null, null, null, null, null, late, final, 1, late, ;) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 6, {, }) endClassDeclaration(class, }) diff --git a/pkg/front_end/parser_testcases/record/record_type_with_modifiers.dart.intertwined.expect b/pkg/front_end/parser_testcases/record/record_type_with_modifiers.dart.intertwined.expect index a6f60e90518..db155297bb0 100644 --- a/pkg/front_end/parser_testcases/record/record_type_with_modifiers.dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/record/record_type_with_modifiers.dart.intertwined.expect @@ -93,7 +93,7 @@ parseUnit(class) ensureCloseParen(42, () listener: endRecordLiteral((, 2, null) listener: endFieldInitializer(=, )) - listener: endClassFields(null, null, null, null, null, null, final, 1, final, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, null, final, 1, final, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, static) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Foo) @@ -160,7 +160,7 @@ parseUnit(class) ensureCloseParen(42, () listener: endRecordLiteral((, 2, null) listener: endFieldInitializer(=, )) - listener: endClassFields(null, null, null, static, null, null, null, 1, static, ;) + listener: endFields(DeclarationKind.Class, null, null, null, static, null, null, null, 1, static, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, static) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Foo) @@ -228,7 +228,7 @@ parseUnit(class) ensureCloseParen(42, () listener: endRecordLiteral((, 2, null) listener: endFieldInitializer(=, )) - listener: endClassFields(null, null, null, static, null, null, final, 1, static, ;) + listener: endFields(DeclarationKind.Class, null, null, null, static, null, null, final, 1, static, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, static) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Foo) @@ -295,7 +295,7 @@ parseUnit(class) ensureCloseParen(42, () listener: endRecordLiteral((, 2, null) listener: endFieldInitializer(=, )) - listener: endClassFields(null, null, null, static, null, null, const, 1, static, ;) + listener: endFields(DeclarationKind.Class, null, null, null, static, null, null, const, 1, static, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, late) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Foo) @@ -334,7 +334,7 @@ parseUnit(class) listener: handleIdentifier(c, fieldDeclaration) parseFieldInitializerOpt(c, c, late, null, null, null, null, DeclarationKind.Class, Foo) listener: handleNoFieldInitializer(;) - listener: endClassFields(null, null, null, null, null, late, null, 1, late, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, late, null, 1, late, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, late) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Foo) @@ -374,7 +374,7 @@ parseUnit(class) listener: handleIdentifier(d, fieldDeclaration) parseFieldInitializerOpt(d, d, late, null, null, null, final, DeclarationKind.Class, Foo) listener: handleNoFieldInitializer(;) - listener: endClassFields(null, null, null, null, null, late, final, 1, late, ;) + listener: endFields(DeclarationKind.Class, null, null, null, null, null, late, final, 1, late, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 6, {, }) diff --git a/pkg/front_end/parser_testcases/record/super_parameters_record_type.dart.expect b/pkg/front_end/parser_testcases/record/super_parameters_record_type.dart.expect index 26071e6f3b5..01ecc623476 100644 --- a/pkg/front_end/parser_testcases/record/super_parameters_record_type.dart.expect +++ b/pkg/front_end/parser_testcases/record/super_parameters_record_type.dart.expect @@ -50,7 +50,7 @@ beginCompilationUnit(class) handleNoInitializers() handleAsyncModifier(null, null) handleEmptyFunctionBody(;) - endClassConstructor(Foo, (, null, ;) + endConstructor(DeclarationKind.Class, Foo, (, null, ;) endMember() beginMetadataStar(Foo) endMetadataStar(0) @@ -90,7 +90,7 @@ beginCompilationUnit(class) handleNoInitializers() handleAsyncModifier(null, null) handleEmptyFunctionBody(;) - endClassConstructor(Foo, (, null, ;) + endConstructor(DeclarationKind.Class, Foo, (, null, ;) endMember() beginMetadataStar(Foo) endMetadataStar(0) @@ -130,7 +130,7 @@ beginCompilationUnit(class) handleNoInitializers() handleAsyncModifier(null, null) handleEmptyFunctionBody(;) - endClassConstructor(Foo, (, null, ;) + endConstructor(DeclarationKind.Class, Foo, (, null, ;) endMember() beginMetadataStar(Foo) endMetadataStar(0) @@ -170,7 +170,7 @@ beginCompilationUnit(class) handleNoInitializers() handleAsyncModifier(null, null) handleEmptyFunctionBody(;) - endClassConstructor(Foo, (, null, ;) + endConstructor(DeclarationKind.Class, Foo, (, null, ;) endMember() endClassOrMixinOrExtensionBody(DeclarationKind.Class, 4, {, }) endClassDeclaration(class, }) diff --git a/pkg/front_end/parser_testcases/record/super_parameters_record_type.dart.intertwined.expect b/pkg/front_end/parser_testcases/record/super_parameters_record_type.dart.intertwined.expect index 7b909540e62..3654b43ab49 100644 --- a/pkg/front_end/parser_testcases/record/super_parameters_record_type.dart.intertwined.expect +++ b/pkg/front_end/parser_testcases/record/super_parameters_record_type.dart.intertwined.expect @@ -90,7 +90,7 @@ parseUnit(class) inPlainSync() parseFunctionBody(), false, true) listener: handleEmptyFunctionBody(;) - listener: endClassConstructor(Foo, (, null, ;) + listener: endConstructor(DeclarationKind.Class, Foo, (, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, Foo) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Foo) @@ -156,7 +156,7 @@ parseUnit(class) inPlainSync() parseFunctionBody(), false, true) listener: handleEmptyFunctionBody(;) - listener: endClassConstructor(Foo, (, null, ;) + listener: endConstructor(DeclarationKind.Class, Foo, (, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, Foo) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Foo) @@ -222,7 +222,7 @@ parseUnit(class) inPlainSync() parseFunctionBody(), false, true) listener: handleEmptyFunctionBody(;) - listener: endClassConstructor(Foo, (, null, ;) + listener: endConstructor(DeclarationKind.Class, Foo, (, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, Foo) parseClassOrMixinOrExtensionOrEnumMemberImpl(;, DeclarationKind.Class, Foo) @@ -288,7 +288,7 @@ parseUnit(class) inPlainSync() parseFunctionBody(), false, true) listener: handleEmptyFunctionBody(;) - listener: endClassConstructor(Foo, (, null, ;) + listener: endConstructor(DeclarationKind.Class, Foo, (, null, ;) listener: endMember() notEofOrType(CLOSE_CURLY_BRACKET, }) listener: endClassOrMixinOrExtensionBody(DeclarationKind.Class, 4, {, }) diff --git a/pkg/front_end/test/crashing_test_case_minimizer_impl.dart b/pkg/front_end/test/crashing_test_case_minimizer_impl.dart index f375f385a7b..e412b4d4bda 100644 --- a/pkg/front_end/test/crashing_test_case_minimizer_impl.dart +++ b/pkg/front_end/test/crashing_test_case_minimizer_impl.dart @@ -1691,7 +1691,9 @@ worlds: if (body.beginToken.offset + 2 < body.endToken.offset) { helper.replacements.add( new _Replacement( - body.beginToken.offset, body.endToken.offset), + body.beginToken.offset, + body.endToken.offset, + ), ); what = "extension type body"; success = await _tryReplaceAndCompile( @@ -1747,18 +1749,18 @@ worlds: bool shouldCompile = false; String what = ""; if (child is MemberEnd) { - if (child.isClassConstructor()) { - ClassConstructorEnd memberDecl = child.getClassConstructor(); + if (child.isConstructor()) { + ConstructorEnd memberDecl = child.getConstructor(); helper.replacements.add( new _Replacement( memberDecl.beginToken.offset - 1, memberDecl.endToken.offset + 1, ), ); - what = "class constructor"; + what = "constructor"; shouldCompile = true; - } else if (child.isClassFields()) { - ClassFieldsEnd memberDecl = child.getClassFields(); + } else if (child.isFields()) { + FieldsEnd memberDecl = child.getFields(); helper.replacements.add( new _Replacement( memberDecl.beginToken.offset - 1, @@ -1767,147 +1769,25 @@ worlds: ); what = "class fields"; shouldCompile = true; - } else if (child.isClassMethod()) { - ClassMethodEnd memberDecl = child.getClassMethod(); + } else if (child.isMethod()) { + MethodEnd memberDecl = child.getMethod(); helper.replacements.add( new _Replacement( memberDecl.beginToken.offset - 1, memberDecl.endToken.offset + 1, ), ); - what = "class method"; + what = "method"; shouldCompile = true; - } else if (child.isClassFactoryMethod()) { - ClassFactoryMethodEnd memberDecl = child.getClassFactoryMethod(); + } else if (child.isFactory()) { + FactoryEnd memberDecl = child.getFactory(); helper.replacements.add( new _Replacement( memberDecl.beginToken.offset - 1, memberDecl.endToken.offset + 1, ), ); - what = "class factory method"; - shouldCompile = true; - } else if (child.isMixinConstructor()) { - MixinConstructorEnd memberDecl = child.getMixinConstructor(); - helper.replacements.add( - new _Replacement( - memberDecl.beginToken.offset - 1, - memberDecl.endToken.offset + 1, - ), - ); - what = "mixin constructor"; - shouldCompile = true; - } else if (child.isMixinFields()) { - MixinFieldsEnd memberDecl = child.getMixinFields(); - helper.replacements.add( - new _Replacement( - memberDecl.beginToken.offset - 1, - memberDecl.endToken.offset + 1, - ), - ); - what = "mixin fields"; - shouldCompile = true; - } else if (child.isMixinMethod()) { - MixinMethodEnd memberDecl = child.getMixinMethod(); - helper.replacements.add( - new _Replacement( - memberDecl.beginToken.offset - 1, - memberDecl.endToken.offset + 1, - ), - ); - what = "mixin method"; - shouldCompile = true; - } else if (child.isMixinFactoryMethod()) { - MixinFactoryMethodEnd memberDecl = child.getMixinFactoryMethod(); - helper.replacements.add( - new _Replacement( - memberDecl.beginToken.offset - 1, - memberDecl.endToken.offset + 1, - ), - ); - what = "mixin factory method"; - shouldCompile = true; - } else if (child.isExtensionTypeConstructor()) { - var memberDecl = child.getExtensionTypeConstructor(); - helper.replacements.add( - new _Replacement( - memberDecl.beginToken.offset - 1, - memberDecl.endToken.offset + 1, - ), - ); - what = "extension type constructor"; - shouldCompile = true; - } else if (child.isExtensionTypeFields()) { - ExtensionTypeFieldsEnd memberDecl = child.getExtensionTypeFields(); - helper.replacements.add( - new _Replacement( - memberDecl.beginToken.offset - 1, - memberDecl.endToken.offset + 1, - ), - ); - what = "extension type fields"; - shouldCompile = true; - } else if (child.isExtensionTypeMethod()) { - ExtensionTypeMethodEnd memberDecl = child.getExtensionTypeMethod(); - helper.replacements.add( - new _Replacement( - memberDecl.beginToken.offset - 1, - memberDecl.endToken.offset + 1, - ), - ); - what = "extension type method"; - shouldCompile = true; - } else if (child.isExtensionTypeFactoryMethod()) { - ExtensionTypeFactoryMethodEnd memberDecl = child - .getExtensionTypeFactoryMethod(); - helper.replacements.add( - new _Replacement( - memberDecl.beginToken.offset - 1, - memberDecl.endToken.offset + 1, - ), - ); - what = "extension type factory method"; - shouldCompile = true; - } else if (child.isExtensionConstructor()) { - var memberDecl = child.getExtensionConstructor(); - helper.replacements.add( - new _Replacement( - memberDecl.beginToken.offset - 1, - memberDecl.endToken.offset + 1, - ), - ); - what = "extension constructor"; - shouldCompile = true; - } else if (child.isExtensionFields()) { - ExtensionFieldsEnd memberDecl = child.getExtensionFields(); - helper.replacements.add( - new _Replacement( - memberDecl.beginToken.offset - 1, - memberDecl.endToken.offset + 1, - ), - ); - what = "extension fields"; - shouldCompile = true; - } else if (child.isExtensionMethod()) { - ExtensionMethodEnd memberDecl = child.getExtensionMethod(); - helper.replacements.add( - new _Replacement( - memberDecl.beginToken.offset - 1, - memberDecl.endToken.offset + 1, - ), - ); - what = "extension method"; - shouldCompile = true; - } else if (child.isExtensionFactoryMethod()) { - ExtensionFactoryMethodEnd memberDecl = child - .getExtensionFactoryMethod(); - helper.replacements.add( - new _Replacement( - memberDecl.beginToken.offset - 1, - memberDecl.endToken.offset + 1, - ), - ); - what = "extension factory method"; + what = "factory"; shouldCompile = true; } else { // throw "$child --- ${child.children}"; @@ -1938,10 +1818,10 @@ worlds: if (!success) { BlockFunctionBodyEnd? decl; if (child is MemberEnd) { - if (child.isClassMethod()) { - decl = child.getClassMethod().getBlockFunctionBody(); - } else if (child.isClassConstructor()) { - decl = child.getClassConstructor().getBlockFunctionBody(); + if (child.isMethod()) { + decl = child.getMethod().getBlockFunctionBody(); + } else if (child.isConstructor()) { + decl = child.getConstructor().getBlockFunctionBody(); } // TODO(jensj): The other ones too maybe? } diff --git a/pkg/front_end/test/lint_suite.dart b/pkg/front_end/test/lint_suite.dart index 48fc90dfc71..79c4cbe76fd 100644 --- a/pkg/front_end/test/lint_suite.dart +++ b/pkg/front_end/test/lint_suite.dart @@ -9,7 +9,7 @@ import 'package:_fe_analyzer_shared/src/parser/experimental_features.dart' show DefaultExperimentalFeatures; import 'package:_fe_analyzer_shared/src/parser/listener.dart' show Listener; import 'package:_fe_analyzer_shared/src/parser/parser.dart' - show FormalParameterKind, MemberKind, Parser; + show FormalParameterKind, MemberKind, Parser, DeclarationKind; import 'package:_fe_analyzer_shared/src/scanner/abstract_scanner.dart' show ScannerConfiguration; import 'package:_fe_analyzer_shared/src/scanner/token.dart' show Token; @@ -261,7 +261,8 @@ class ExplicitTypeLintListener extends LintListener { } @override - void endClassFields( + void endFields( + DeclarationKind kind, Token? abstractToken, Token? augmentToken, Token? externalToken, diff --git a/pkg/front_end/test/parser/parser_ast_test.dart b/pkg/front_end/test/parser/parser_ast_test.dart index 0995e2ca10e..361e816bd80 100644 --- a/pkg/front_end/test/parser/parser_ast_test.dart +++ b/pkg/front_end/test/parser/parser_ast_test.dart @@ -185,11 +185,11 @@ void testClassStuff() { expect(null, withClauseDecl); List members = cls.getClassOrMixinOrExtensionBody().getMembers(); expect(5, members.length); - expect(members[0].isClassConstructor(), true); - expect(members[1].isClassFactoryMethod(), true); - expect(members[2].isClassMethod(), true); - expect(members[3].isClassMethod(), true); - expect(members[4].isClassFields(), true); + expect(members[0].isConstructor(), true); + expect(members[1].isFactory(), true); + expect(members[2].isMethod(), true); + expect(members[3].isMethod(), true); + expect(members[4].isFields(), true); List chunks = splitIntoChunks( cls.getClassOrMixinOrExtensionBody(), @@ -209,25 +209,19 @@ void testClassStuff() { expect("int field1, field2 = 42;", chunks[4]); chunks = processItem( - members[0].getClassConstructor().getBlockFunctionBody()!, + members[0].getConstructor().getBlockFunctionBody()!, data, ); expect(1, chunks.length); expect("""{ // Constructor }""", chunks[0]); - chunks = processItem( - members[2].getClassMethod().getBlockFunctionBody()!, - data, - ); + chunks = processItem(members[2].getMethod().getBlockFunctionBody()!, data); expect(1, chunks.length); expect("""{ // instance method. }""", chunks[0]); - chunks = processItem( - members[3].getClassMethod().getBlockFunctionBody()!, - data, - ); + chunks = processItem(members[3].getMethod().getBlockFunctionBody()!, data); expect(1, chunks.length); expect("""{ // static method. @@ -235,10 +229,10 @@ void testClassStuff() { // TODO: Move (something like) this into the check-all-files-thing. for (MemberEnd member in cls.getClassOrMixinOrExtensionBody().getMembers()) { - if (member.isClassConstructor()) continue; - if (member.isClassFactoryMethod()) continue; - if (member.isClassFields()) continue; - if (member.isClassMethod()) continue; + if (member.isConstructor()) continue; + if (member.isFactory()) continue; + if (member.isFields()) continue; + if (member.isMethod()) continue; throw "$member --- ${member.children}"; } @@ -272,10 +266,10 @@ void testMixinStuff() { List members = mxn.getClassOrMixinOrExtensionBody().getMembers(); expect(4, members.length); - expect(members[0].isMixinFields(), true); - expect(members[1].isMixinMethod(), true); - expect(members[2].isMixinFactoryMethod(), true); - expect(members[3].isMixinConstructor(), true); + expect(members[0].isFields(), true); + expect(members[1].isMethod(), true); + expect(members[2].isFactory(), true); + expect(members[3].isConstructor(), true); List chunks = splitIntoChunks( mxn.getClassOrMixinOrExtensionBody(), @@ -484,8 +478,8 @@ List processItem(ParserAstNode item, List data) { ), ]; } else if (item is MemberEnd) { - if (item.isClassConstructor()) { - ClassConstructorEnd decl = item.getClassConstructor(); + if (item.isConstructor()) { + ConstructorEnd decl = item.getConstructor(); // Check that we can get the identifiers without throwing. decl.getIdentifiers(); return [ @@ -495,8 +489,8 @@ List processItem(ParserAstNode item, List data) { decl.endToken.offset + decl.endToken.length, ), ]; - } else if (item.isClassFactoryMethod()) { - ClassFactoryMethodEnd decl = item.getClassFactoryMethod(); + } else if (item.isFactory()) { + FactoryEnd decl = item.getFactory(); // Check that we can get the identifiers without throwing. decl.getIdentifiers(); return [ @@ -506,8 +500,8 @@ List processItem(ParserAstNode item, List data) { decl.endToken.offset + decl.endToken.length, ), ]; - } else if (item.isClassMethod()) { - ClassMethodEnd decl = item.getClassMethod(); + } else if (item.isMethod()) { + MethodEnd decl = item.getMethod(); // Check that we can get the identifier without throwing. decl.getNameIdentifier(); return [ @@ -517,8 +511,8 @@ List processItem(ParserAstNode item, List data) { decl.endToken.offset + decl.endToken.length, ), ]; - } else if (item.isClassFields()) { - ClassFieldsEnd decl = item.getClassFields(); + } else if (item.isFields()) { + FieldsEnd decl = item.getFields(); // Check that we can get the identifiers without throwing. decl.getFieldIdentifiers(); return [ @@ -528,182 +522,6 @@ List processItem(ParserAstNode item, List data) { decl.endToken.offset + decl.endToken.length, ), ]; - } else if (item.isMixinFields()) { - MixinFieldsEnd decl = item.getMixinFields(); - // Check that we can get the identifiers without throwing. - decl.getFieldIdentifiers(); - return [ - getCutContent( - data, - decl.beginToken.offset, - decl.endToken.offset + decl.endToken.length, - ), - ]; - } else if (item.isMixinMethod()) { - MixinMethodEnd decl = item.getMixinMethod(); - // Check that we can get the identifier without throwing. - decl.getNameIdentifier(); - return [ - getCutContent( - data, - decl.beginToken.offset, - decl.endToken.offset + decl.endToken.length, - ), - ]; - } else if (item.isMixinFactoryMethod()) { - MixinFactoryMethodEnd decl = item.getMixinFactoryMethod(); - // Check that we can get the identifiers without throwing. - decl.getIdentifiers(); - return [ - getCutContent( - data, - decl.beginToken.offset, - decl.endToken.offset + decl.endToken.length, - ), - ]; - } else if (item.isMixinConstructor()) { - MixinConstructorEnd decl = item.getMixinConstructor(); - // Check that we can get the identifiers without throwing. - decl.getIdentifiers(); - return [ - getCutContent( - data, - decl.beginToken.offset, - decl.endToken.offset + decl.endToken.length, - ), - ]; - } else if (item.isExtensionMethod()) { - ExtensionMethodEnd decl = item.getExtensionMethod(); - // Check that we can get the identifier without throwing. - decl.getNameIdentifier(); - return [ - getCutContent( - data, - decl.beginToken.offset, - decl.endToken.offset + decl.endToken.length, - ), - ]; - } else if (item.isExtensionFields()) { - ExtensionFieldsEnd decl = item.getExtensionFields(); - // Check that we can get the identifiers without throwing. - decl.getFieldIdentifiers(); - return [ - getCutContent( - data, - decl.beginToken.offset, - decl.endToken.offset + decl.endToken.length, - ), - ]; - } else if (item.isExtensionConstructor()) { - ExtensionConstructorEnd decl = item.getExtensionConstructor(); - // Check that we can get the identifiers without throwing. - decl.getIdentifiers(); - return [ - getCutContent( - data, - decl.beginToken.offset, - decl.endToken.offset + decl.endToken.length, - ), - ]; - } else if (item.isExtensionFactoryMethod()) { - ExtensionFactoryMethodEnd decl = item.getExtensionFactoryMethod(); - // Check that we can get the identifiers without throwing. - decl.getIdentifiers(); - return [ - getCutContent( - data, - decl.beginToken.offset, - decl.endToken.offset + decl.endToken.length, - ), - ]; - } else if (item.isExtensionTypeMethod()) { - ExtensionTypeMethodEnd decl = item.getExtensionTypeMethod(); - // Check that we can get the identifier without throwing. - decl.getNameIdentifier(); - return [ - getCutContent( - data, - decl.beginToken.offset, - decl.endToken.offset + decl.endToken.length, - ), - ]; - } else if (item.isExtensionTypeFields()) { - ExtensionTypeFieldsEnd decl = item.getExtensionTypeFields(); - // Check that we can get the identifiers without throwing. - decl.getFieldIdentifiers(); - return [ - getCutContent( - data, - decl.beginToken.offset, - decl.endToken.offset + decl.endToken.length, - ), - ]; - } else if (item.isExtensionTypeConstructor()) { - ExtensionTypeConstructorEnd decl = item.getExtensionTypeConstructor(); - // Check that we can get the identifiers without throwing. - decl.getIdentifiers(); - return [ - getCutContent( - data, - decl.beginToken.offset, - decl.endToken.offset + decl.endToken.length, - ), - ]; - } else if (item.isExtensionTypeFactoryMethod()) { - ExtensionTypeFactoryMethodEnd decl = item.getExtensionTypeFactoryMethod(); - // Check that we can get the identifiers without throwing. - decl.getIdentifiers(); - return [ - getCutContent( - data, - decl.beginToken.offset, - decl.endToken.offset + decl.endToken.length, - ), - ]; - } else if (item.isEnumMethod()) { - EnumMethodEnd decl = item.getEnumMethod(); - // Check that we can get the identifier without throwing. - decl.getNameIdentifier(); - return [ - getCutContent( - data, - decl.beginToken.offset, - decl.endToken.offset + decl.endToken.length, - ), - ]; - } else if (item.isEnumFields()) { - EnumFieldsEnd decl = item.getEnumFields(); - // Check that we can get the identifiers without throwing. - decl.getFieldIdentifiers(); - return [ - getCutContent( - data, - decl.beginToken.offset, - decl.endToken.offset + decl.endToken.length, - ), - ]; - } else if (item.isEnumConstructor()) { - EnumConstructorEnd decl = item.getEnumConstructor(); - // Check that we can get the identifiers without throwing. - decl.getIdentifiers(); - return [ - getCutContent( - data, - decl.beginToken.offset, - decl.endToken.offset + decl.endToken.length, - ), - ]; - } else if (item.isEnumFactoryMethod()) { - EnumFactoryMethodEnd decl = item.getEnumFactoryMethod(); - // Check that we can get the identifiers without throwing. - decl.getIdentifiers(); - return [ - getCutContent( - data, - decl.beginToken.offset, - decl.endToken.offset + decl.endToken.length, - ), - ]; } else if (item.isPrimaryConstructorBody()) { PrimaryConstructorBodyEnd decl = item.getPrimaryConstructorBody(); return [ diff --git a/pkg/front_end/test/parser_suite.dart b/pkg/front_end/test/parser_suite.dart index fcf36864bbc..cb8c9f2072c 100644 --- a/pkg/front_end/test/parser_suite.dart +++ b/pkg/front_end/test/parser_suite.dart @@ -231,10 +231,8 @@ class ExtractSomeMembers extends RecursiveParserAstVisitor { } @override - void visitClassMethodEnd(ClassMethodEnd node) { - sb.writeln( - "Class method: $currentContainerName.${node.getNameIdentifier()}", - ); + void visitMethodEnd(MethodEnd node) { + sb.writeln("Method: $currentContainerName.${node.getNameIdentifier()}"); } } diff --git a/pkg/front_end/test/parser_test_listener.dart b/pkg/front_end/test/parser_test_listener.dart index e4861c469d7..b8fb91da19f 100644 --- a/pkg/front_end/test/parser_test_listener.dart +++ b/pkg/front_end/test/parser_test_listener.dart @@ -841,27 +841,6 @@ class ParserTestListener implements Listener { ); } - @override - void endEnumConstructor( - Token beginToken, - Token beginParam, - Token? beginInitializers, - Token endToken, - ) { - indent--; - seen(beginToken); - seen(beginParam); - seen(beginInitializers); - seen(endToken); - doPrint( - 'endEnumConstructor(' - '$beginToken, ' - '$beginParam, ' - '$beginInitializers, ' - '$endToken)', - ); - } - @override void handleEnumElements(Token elementsEndToken, int elementsCount) { seen(elementsEndToken); @@ -922,24 +901,6 @@ class ParserTestListener implements Listener { ); } - @override - void endEnumFactoryMethod( - Token beginToken, - Token factoryKeyword, - Token endToken, - ) { - indent--; - seen(beginToken); - seen(factoryKeyword); - seen(endToken); - doPrint( - 'endEnumFactoryMethod(' - '$beginToken, ' - '$factoryKeyword, ' - '$endToken)', - ); - } - @override void beginExport(Token token) { seen(token); @@ -984,7 +945,7 @@ class ParserTestListener implements Listener { } @override - void beginFactoryMethod( + void beginFactory( DeclarationKind declarationKind, Token lastConsumed, Token? externalToken, @@ -994,7 +955,7 @@ class ParserTestListener implements Listener { seen(externalToken); seen(constToken); doPrint( - 'beginFactoryMethod(' + 'beginFactory(' '$declarationKind, ' '$lastConsumed, ' '$externalToken, ' @@ -1004,7 +965,8 @@ class ParserTestListener implements Listener { } @override - void endClassFactoryMethod( + void endFactory( + DeclarationKind kind, Token beginToken, Token factoryKeyword, Token endToken, @@ -1014,61 +976,8 @@ class ParserTestListener implements Listener { seen(factoryKeyword); seen(endToken); doPrint( - 'endClassFactoryMethod(' - '$beginToken, ' - '$factoryKeyword, ' - '$endToken)', - ); - } - - @override - void endMixinFactoryMethod( - Token beginToken, - Token factoryKeyword, - Token endToken, - ) { - indent--; - seen(beginToken); - seen(factoryKeyword); - seen(endToken); - doPrint( - 'endMixinFactoryMethod(' - '$beginToken, ' - '$factoryKeyword, ' - '$endToken)', - ); - } - - @override - void endExtensionFactoryMethod( - Token beginToken, - Token factoryKeyword, - Token endToken, - ) { - indent--; - seen(beginToken); - seen(factoryKeyword); - seen(endToken); - doPrint( - 'endExtensionFactoryMethod(' - '$beginToken, ' - '$factoryKeyword, ' - '$endToken)', - ); - } - - @override - void endExtensionTypeFactoryMethod( - Token beginToken, - Token factoryKeyword, - Token endToken, - ) { - indent--; - seen(beginToken); - seen(factoryKeyword); - seen(endToken); - doPrint( - 'endExtensionTypeFactoryMethod(' + 'endFactory(' + '$kind, ' '$beginToken, ' '$factoryKeyword, ' '$endToken)', @@ -1173,7 +1082,8 @@ class ParserTestListener implements Listener { } @override - void endClassFields( + void endFields( + DeclarationKind kind, Token? abstractToken, Token? augmentToken, Token? externalToken, @@ -1196,7 +1106,8 @@ class ParserTestListener implements Listener { seen(beginToken); seen(endToken); doPrint( - 'endClassFields(' + 'endFields(' + '$kind, ' '$abstractToken, ' '$augmentToken, ' '$externalToken, ' @@ -1210,182 +1121,6 @@ class ParserTestListener implements Listener { ); } - @override - void endMixinFields( - Token? abstractToken, - Token? augmentToken, - Token? externalToken, - Token? staticToken, - Token? covariantToken, - Token? lateToken, - Token? varFinalOrConst, - int count, - Token beginToken, - Token endToken, - ) { - indent--; - seen(abstractToken); - seen(augmentToken); - seen(externalToken); - seen(staticToken); - seen(covariantToken); - seen(lateToken); - seen(varFinalOrConst); - seen(beginToken); - seen(endToken); - doPrint( - 'endMixinFields(' - '$abstractToken, ' - '$augmentToken, ' - '$externalToken, ' - '$staticToken, ' - '$covariantToken, ' - '$lateToken, ' - '$varFinalOrConst, ' - '$count, ' - '$beginToken, ' - '$endToken)', - ); - } - - @override - void endExtensionFields( - Token? abstractToken, - Token? augmentToken, - Token? externalToken, - Token? staticToken, - Token? covariantToken, - Token? lateToken, - Token? varFinalOrConst, - int count, - Token beginToken, - Token endToken, - ) { - indent--; - seen(abstractToken); - seen(augmentToken); - seen(externalToken); - seen(staticToken); - seen(covariantToken); - seen(lateToken); - seen(varFinalOrConst); - seen(beginToken); - seen(endToken); - doPrint( - 'endExtensionFields(' - '$abstractToken, ' - '$augmentToken, ' - '$externalToken, ' - '$staticToken, ' - '$covariantToken, ' - '$lateToken, ' - '$varFinalOrConst, ' - '$count, ' - '$beginToken, ' - '$endToken)', - ); - } - - @override - void endExtensionTypeFields( - Token? abstractToken, - Token? augmentToken, - Token? externalToken, - Token? staticToken, - Token? covariantToken, - Token? lateToken, - Token? varFinalOrConst, - int count, - Token beginToken, - Token endToken, - ) { - indent--; - seen(abstractToken); - seen(augmentToken); - seen(externalToken); - seen(staticToken); - seen(covariantToken); - seen(lateToken); - seen(varFinalOrConst); - seen(beginToken); - seen(endToken); - doPrint( - 'endExtensionTypeFields(' - '$abstractToken, ' - '$augmentToken, ' - '$externalToken, ' - '$staticToken, ' - '$covariantToken, ' - '$lateToken, ' - '$varFinalOrConst, ' - '$count, ' - '$beginToken, ' - '$endToken)', - ); - } - - @override - void endEnumFields( - Token? abstractToken, - Token? augmentToken, - Token? externalToken, - Token? staticToken, - Token? covariantToken, - Token? lateToken, - Token? varFinalOrConst, - int count, - Token beginToken, - Token endToken, - ) { - indent--; - seen(abstractToken); - seen(augmentToken); - seen(externalToken); - seen(staticToken); - seen(covariantToken); - seen(lateToken); - seen(varFinalOrConst); - seen(beginToken); - seen(endToken); - doPrint( - 'endEnumFields(' - '$abstractToken, ' - '$augmentToken, ' - '$externalToken, ' - '$staticToken, ' - '$covariantToken, ' - '$lateToken, ' - '$varFinalOrConst, ' - '$count, ' - '$beginToken, ' - '$endToken)', - ); - } - - @override - void endEnumMethod( - Token? getOrSet, - Token beginToken, - Token beginParam, - Token? beginInitializers, - Token endToken, - ) { - indent--; - seen(getOrSet); - seen(beginToken); - seen(beginParam); - seen(beginInitializers); - seen(endToken); - doPrint( - 'endEnumMethod(' - '$getOrSet, ' - '$beginToken, ' - '$beginParam, ' - '$beginInitializers, ' - '$endToken)', - ); - } - @override void handleForInitializerEmptyStatement(Token token) { seen(token); @@ -2413,7 +2148,8 @@ class ParserTestListener implements Listener { } @override - void endClassMethod( + void endMethod( + DeclarationKind kind, Token? getOrSet, Token beginToken, Token beginParam, @@ -2427,7 +2163,8 @@ class ParserTestListener implements Listener { seen(beginInitializers); seen(endToken); doPrint( - 'endClassMethod(' + 'endMethod(' + '$kind, ' '$getOrSet, ' '$beginToken, ' '$beginParam, ' @@ -2437,79 +2174,8 @@ class ParserTestListener implements Listener { } @override - void endMixinMethod( - Token? getOrSet, - Token beginToken, - Token beginParam, - Token? beginInitializers, - Token endToken, - ) { - indent--; - seen(getOrSet); - seen(beginToken); - seen(beginParam); - seen(beginInitializers); - seen(endToken); - doPrint( - 'endMixinMethod(' - '$getOrSet, ' - '$beginToken, ' - '$beginParam, ' - '$beginInitializers, ' - '$endToken)', - ); - } - - @override - void endExtensionMethod( - Token? getOrSet, - Token beginToken, - Token beginParam, - Token? beginInitializers, - Token endToken, - ) { - indent--; - seen(getOrSet); - seen(beginToken); - seen(beginParam); - seen(beginInitializers); - seen(endToken); - doPrint( - 'endExtensionMethod(' - '$getOrSet, ' - '$beginToken, ' - '$beginParam, ' - '$beginInitializers, ' - '$endToken)', - ); - } - - @override - void endExtensionTypeMethod( - Token? getOrSet, - Token beginToken, - Token beginParam, - Token? beginInitializers, - Token endToken, - ) { - indent--; - seen(getOrSet); - seen(beginToken); - seen(beginParam); - seen(beginInitializers); - seen(endToken); - doPrint( - 'endExtensionTypeMethod(' - '$getOrSet, ' - '$beginToken, ' - '$beginParam, ' - '$beginInitializers, ' - '$endToken)', - ); - } - - @override - void endClassConstructor( + void endConstructor( + DeclarationKind kind, Token beginToken, Token beginParam, Token? beginInitializers, @@ -2521,70 +2187,8 @@ class ParserTestListener implements Listener { seen(beginInitializers); seen(endToken); doPrint( - 'endClassConstructor(' - '$beginToken, ' - '$beginParam, ' - '$beginInitializers, ' - '$endToken)', - ); - } - - @override - void endMixinConstructor( - Token beginToken, - Token beginParam, - Token? beginInitializers, - Token endToken, - ) { - indent--; - seen(beginToken); - seen(beginParam); - seen(beginInitializers); - seen(endToken); - doPrint( - 'endMixinConstructor(' - '$beginToken, ' - '$beginParam, ' - '$beginInitializers, ' - '$endToken)', - ); - } - - @override - void endExtensionConstructor( - Token beginToken, - Token beginParam, - Token? beginInitializers, - Token endToken, - ) { - indent--; - seen(beginToken); - seen(beginParam); - seen(beginInitializers); - seen(endToken); - doPrint( - 'endExtensionConstructor(' - '$beginToken, ' - '$beginParam, ' - '$beginInitializers, ' - '$endToken)', - ); - } - - @override - void endExtensionTypeConstructor( - Token beginToken, - Token beginParam, - Token? beginInitializers, - Token endToken, - ) { - indent--; - seen(beginToken); - seen(beginParam); - seen(beginInitializers); - seen(endToken); - doPrint( - 'endExtensionTypeConstructor(' + 'endConstructor(' + '$kind, ' '$beginToken, ' '$beginParam, ' '$beginInitializers, ' diff --git a/pkg/front_end/test/parser_test_listener_creator.dart b/pkg/front_end/test/parser_test_listener_creator.dart index ba42ddc25fd..9a6694f8c08 100644 --- a/pkg/front_end/test/parser_test_listener_creator.dart +++ b/pkg/front_end/test/parser_test_listener_creator.dart @@ -182,7 +182,8 @@ class ParserCreatorListener extends Listener { } @override - void endClassMethod( + void endMethod( + DeclarationKind kind, Token? getOrSet, Token beginToken, Token beginParam, diff --git a/pkg/front_end/test/parser_test_parser_creator.dart b/pkg/front_end/test/parser_test_parser_creator.dart index 81a5d640613..f7f7fffe65b 100644 --- a/pkg/front_end/test/parser_test_parser_creator.dart +++ b/pkg/front_end/test/parser_test_parser_creator.dart @@ -174,7 +174,8 @@ class ParserCreatorListener extends Listener { } @override - void endClassConstructor( + void endConstructor( + DeclarationKind kind, Token beginToken, Token beginParam, Token? beginInitializers, @@ -186,7 +187,8 @@ class ParserCreatorListener extends Listener { } @override - void endClassMethod( + void endMethod( + DeclarationKind kind, Token? getOrSet, Token beginToken, Token beginParam, diff --git a/pkg/front_end/tool/kernel_ast_file_rewriter.dart b/pkg/front_end/tool/kernel_ast_file_rewriter.dart index 1fc1775c7a9..316e6922156 100644 --- a/pkg/front_end/tool/kernel_ast_file_rewriter.dart +++ b/pkg/front_end/tool/kernel_ast_file_rewriter.dart @@ -65,8 +65,8 @@ void main(List args) { Set namedClassConstructors = {}; Set namedFields = {}; for (MemberEnd member in classOrMixinBody.getMembers()) { - if (member.isClassConstructor()) { - ClassConstructorEnd constructor = member.getClassConstructor(); + if (member.isConstructor()) { + ConstructorEnd constructor = member.getConstructor(); Token nameToken = constructor.beginToken; // String name = nameToken.lexeme; if (nameToken.next!.lexeme == ".") { @@ -77,9 +77,9 @@ void main(List args) { if (nameToken.next!.lexeme == ".") { throw "Unexpected"; } - } else if (member.isClassFields()) { - ClassFieldsEnd classFields = member.getClassFields(); - Token identifierToken = classFields.getFieldIdentifiers().single.token; + } else if (member.isFields()) { + FieldsEnd fields = member.getFields(); + Token identifierToken = fields.getFieldIdentifiers().single.token; String identifier = identifierToken.toString(); namedFields.add(identifier); } @@ -97,14 +97,14 @@ void main(List args) { } for (MemberEnd member in classOrMixinBody.getMembers()) { - if (member.isClassConstructor()) { + if (member.isConstructor()) { processConstructor( member, replacements, namedClassConstructors, namedFields, ); - } else if (member.isClassFields()) { + } else if (member.isFields()) { processField(member, entry, replacements); } } @@ -152,26 +152,26 @@ void processField( MapEntry entry, Map replacements, ) { - ClassFieldsEnd classFields = member.getClassFields(); + FieldsEnd fields = member.getFields(); - if (classFields.count != 1) { - throw "Notice ${classFields.count}"; + if (fields.count != 1) { + throw "Notice ${fields.count}"; } - Token identifierToken = classFields.getFieldIdentifiers().single.token; + Token identifierToken = fields.getFieldIdentifiers().single.token; String identifier = identifierToken.toString(); if (identifier == "frozen" && entry.key == "TreeNode") return; - if (classFields.staticToken != null) { + if (fields.staticToken != null) { return; } bool isFinal = false; - if (classFields.varFinalOrConst?.toString() == "final") { + if (fields.varFinalOrConst?.toString() == "final") { isFinal = true; } - TypeHandle? type = classFields.getFirstType(); + TypeHandle? type = fields.getFirstType(); String typeString = "dynamic"; if (type != null) { Token token = type.beginToken; @@ -183,7 +183,7 @@ void processField( typeString = typeString.trim(); } - FieldInitializerEnd? initializer = classFields.getFieldInitializer(); + FieldInitializerEnd? initializer = fields.getFieldInitializer(); String initializerString = ""; if (initializer != null) { Token token = initializer.assignment; @@ -195,8 +195,8 @@ void processField( initializerString = initializerString.trim(); } - Token beginToken = classFields.beginToken; - Token endToken = classFields.endToken; + Token beginToken = fields.beginToken; + Token endToken = fields.endToken; String frozenCheckCode = """if (frozen) throw "Trying to modify frozen node!";"""; @@ -247,7 +247,7 @@ void processConstructor( Set namedClassConstructors, Set namedFields, ) { - ClassConstructorEnd constructor = member.getClassConstructor(); + ConstructorEnd constructor = member.getConstructor(); FormalParametersEnd formalParameters = constructor.getFormalParameters(); List parameters = formalParameters.getFormalParameters(); diff --git a/pkg/front_end/tool/parser_ast_helper_creator.dart b/pkg/front_end/tool/parser_ast_helper_creator.dart index f3d2bf79c8a..a7205562ce6 100644 --- a/pkg/front_end/tool/parser_ast_helper_creator.dart +++ b/pkg/front_end/tool/parser_ast_helper_creator.dart @@ -244,7 +244,8 @@ class ParserCreatorListener extends Listener { } @override - void endClassMethod( + void endMethod( + DeclarationKind kind, Token? getOrSet, Token beginToken, Token beginParam, diff --git a/pkg/front_end/tool/parser_ast_indexer.dart b/pkg/front_end/tool/parser_ast_indexer.dart index 229e68264ea..85d0274e489 100644 --- a/pkg/front_end/tool/parser_ast_indexer.dart +++ b/pkg/front_end/tool/parser_ast_indexer.dart @@ -226,102 +226,22 @@ class AstIndexer extends IgnoreSomeForCompatibilityAstVisitor { } @override - void visitClassConstructorEnd(ClassConstructorEnd node) { + void visitConstructorEnd(ConstructorEnd node) { containerMethod(node, node.getIdentifiers().last.token.lexeme); } @override - void visitClassFactoryMethodEnd(ClassFactoryMethodEnd node) { + void visitFactoryEnd(FactoryEnd node) { containerMethod(node, node.getIdentifiers().last.token.lexeme); } @override - void visitClassFieldsEnd(ClassFieldsEnd node) { + void visitFieldsEnd(FieldsEnd node) { containerFields(node, node.getFieldIdentifiers()); } @override - void visitClassMethodEnd(ClassMethodEnd node) { - containerMethod(node, node.getNameIdentifier()); - } - - @override - void visitMixinConstructorEnd(MixinConstructorEnd node) { - containerMethod(node, node.getIdentifiers().last.token.lexeme); - } - - @override - void visitMixinFactoryMethodEnd(MixinFactoryMethodEnd node) { - containerMethod(node, node.getIdentifiers().last.token.lexeme); - } - - @override - void visitMixinFieldsEnd(MixinFieldsEnd node) { - containerFields(node, node.getFieldIdentifiers()); - } - - @override - void visitMixinMethodEnd(MixinMethodEnd node) { - containerMethod(node, node.getNameIdentifier()); - } - - @override - void visitEnumConstructorEnd(EnumConstructorEnd node) { - containerMethod(node, node.getIdentifiers().last.token.lexeme); - } - - @override - void visitEnumFactoryMethodEnd(EnumFactoryMethodEnd node) { - containerMethod(node, node.getIdentifiers().last.token.lexeme); - } - - @override - void visitEnumFieldsEnd(EnumFieldsEnd node) { - containerFields(node, node.getFieldIdentifiers()); - } - - @override - void visitEnumMethodEnd(EnumMethodEnd node) { - containerMethod(node, node.getNameIdentifier()); - } - - @override - void visitExtensionConstructorEnd(ExtensionConstructorEnd node) { - containerMethod(node, node.getIdentifiers().last.token.lexeme); - } - - @override - void visitExtensionFactoryMethodEnd(ExtensionFactoryMethodEnd node) { - containerMethod(node, node.getIdentifiers().last.token.lexeme); - } - - @override - void visitExtensionFieldsEnd(ExtensionFieldsEnd node) { - containerFields(node, node.getFieldIdentifiers()); - } - - @override - void visitExtensionMethodEnd(ExtensionMethodEnd node) { - containerMethod(node, node.getNameIdentifier()); - } - - @override - void visitExtensionTypeConstructorEnd(ExtensionTypeConstructorEnd node) { - containerMethod(node, node.getIdentifiers().last.token.lexeme); - } - - @override - void visitExtensionTypeFactoryMethodEnd(ExtensionTypeFactoryMethodEnd node) { - containerMethod(node, node.getIdentifiers().last.token.lexeme); - } - - @override - void visitExtensionTypeFieldsEnd(ExtensionTypeFieldsEnd node) { - containerFields(node, node.getFieldIdentifiers()); - } - - @override - void visitExtensionTypeMethodEnd(ExtensionTypeMethodEnd node) { + void visitMethodEnd(MethodEnd node) { containerMethod(node, node.getNameIdentifier()); } }