Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(248)

Side by Side Diff: pkg/analyzer/lib/src/generated/parser.dart

Issue 706283002: Fix remaining error code classes (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 6 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « no previous file | pkg/analyzer/lib/src/generated/resolver.dart » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2014, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2014, the Dart project authors. Please see the AUTHORS file
2 // for details. All rights reserved. Use of this source code is governed by a 2 // for details. All rights reserved. Use of this source code is governed by a
3 // BSD-style license that can be found in the LICENSE file. 3 // BSD-style license that can be found in the LICENSE file.
4 4
5 // This code was auto-generated, is not intended to be edited, and is subject to 5 // This code was auto-generated, is not intended to be edited, and is subject to
6 // significant change. Please see the README file for more information. 6 // significant change. Please see the README file for more information.
7 7
8 library engine.parser; 8 library engine.parser;
9 9
10 import 'dart:collection'; 10 import 'dart:collection';
(...skipping 7819 matching lines...) Expand 10 before | Expand all | Expand 10 after
7830 if (modifiers.finalKeyword != null) { 7830 if (modifiers.finalKeyword != null) {
7831 _reportErrorForToken(ParserErrorCode.FINAL_TYPEDEF, modifiers.finalKeyword , []); 7831 _reportErrorForToken(ParserErrorCode.FINAL_TYPEDEF, modifiers.finalKeyword , []);
7832 } 7832 }
7833 if (modifiers.varKeyword != null) { 7833 if (modifiers.varKeyword != null) {
7834 _reportErrorForToken(ParserErrorCode.VAR_TYPEDEF, modifiers.varKeyword, [] ); 7834 _reportErrorForToken(ParserErrorCode.VAR_TYPEDEF, modifiers.varKeyword, [] );
7835 } 7835 }
7836 } 7836 }
7837 } 7837 }
7838 7838
7839 /** 7839 /**
7840 * The enumeration `ParserErrorCode` defines the error codes used for errors det ected by the 7840 * The enumeration `ParserErrorCode` defines the error codes used for errors
7841 * parser. The convention for this class is for the name of the error code to in dicate the problem 7841 * detected by the parser. The convention for this class is for the name of the
7842 * that caused the error to be generated and for the error message to explain wh at is wrong and, 7842 * error code to indicate the problem that caused the error to be generated and
7843 * when appropriate, how the problem can be corrected. 7843 * for the error message to explain what is wrong and, when appropriate, how the
7844 * problem can be corrected.
7844 */ 7845 */
7845 class ParserErrorCode extends Enum<ParserErrorCode> implements ErrorCode { 7846 class ParserErrorCode extends ErrorCode {
7846 static const ParserErrorCode ABSTRACT_CLASS_MEMBER = const ParserErrorCode.con 3('ABSTRACT_CLASS_MEMBER', 0, "Members of classes cannot be declared to be 'abst ract'"); 7847 static const ParserErrorCode ABSTRACT_CLASS_MEMBER= const ParserErrorCode('ABS TRACT_CLASS_MEMBER', "Members of classes cannot be declared to be 'abstract'");
7847 7848
7848 static const ParserErrorCode ABSTRACT_ENUM = const ParserErrorCode.con3('ABSTR ACT_ENUM', 1, "Enums cannot be declared to be 'abstract'"); 7849 static const ParserErrorCode ABSTRACT_ENUM = const ParserErrorCode('ABSTRACT_E NUM', "Enums cannot be declared to be 'abstract'");
7849 7850
7850 static const ParserErrorCode ABSTRACT_STATIC_METHOD = const ParserErrorCode.co n3('ABSTRACT_STATIC_METHOD', 2, "Static methods cannot be declared to be 'abstra ct'"); 7851 static const ParserErrorCode ABSTRACT_STATIC_METHOD = const ParserErrorCode('A BSTRACT_STATIC_METHOD', "Static methods cannot be declared to be 'abstract'");
7851 7852
7852 static const ParserErrorCode ABSTRACT_TOP_LEVEL_FUNCTION = const ParserErrorCo de.con3('ABSTRACT_TOP_LEVEL_FUNCTION', 3, "Top-level functions cannot be declare d to be 'abstract'"); 7853 static const ParserErrorCode ABSTRACT_TOP_LEVEL_FUNCTION = const ParserErrorCo de('ABSTRACT_TOP_LEVEL_FUNCTION', "Top-level functions cannot be declared to be 'abstract'");
7853 7854
7854 static const ParserErrorCode ABSTRACT_TOP_LEVEL_VARIABLE = const ParserErrorCo de.con3('ABSTRACT_TOP_LEVEL_VARIABLE', 4, "Top-level variables cannot be declare d to be 'abstract'"); 7855 static const ParserErrorCode ABSTRACT_TOP_LEVEL_VARIABLE = const ParserErrorCo de('ABSTRACT_TOP_LEVEL_VARIABLE', "Top-level variables cannot be declared to be 'abstract'");
7855 7856
7856 static const ParserErrorCode ABSTRACT_TYPEDEF = const ParserErrorCode.con3('AB STRACT_TYPEDEF', 5, "Type aliases cannot be declared to be 'abstract'"); 7857 static const ParserErrorCode ABSTRACT_TYPEDEF = const ParserErrorCode('ABSTRAC T_TYPEDEF', "Type aliases cannot be declared to be 'abstract'");
7857 7858
7858 static const ParserErrorCode ASSERT_DOES_NOT_TAKE_ASSIGNMENT = const ParserErr orCode.con3('ASSERT_DOES_NOT_TAKE_ASSIGNMENT', 6, "Assert cannot be called on an assignment"); 7859 static const ParserErrorCode ASSERT_DOES_NOT_TAKE_ASSIGNMENT = const ParserErr orCode('ASSERT_DOES_NOT_TAKE_ASSIGNMENT', "Assert cannot be called on an assignm ent");
7859 7860
7860 static const ParserErrorCode ASSERT_DOES_NOT_TAKE_CASCADE = const ParserErrorC ode.con3('ASSERT_DOES_NOT_TAKE_CASCADE', 7, "Assert cannot be called on cascade" ); 7861 static const ParserErrorCode ASSERT_DOES_NOT_TAKE_CASCADE = const ParserErrorC ode('ASSERT_DOES_NOT_TAKE_CASCADE', "Assert cannot be called on cascade");
7861 7862
7862 static const ParserErrorCode ASSERT_DOES_NOT_TAKE_THROW = const ParserErrorCod e.con3('ASSERT_DOES_NOT_TAKE_THROW', 8, "Assert cannot be called on throws"); 7863 static const ParserErrorCode ASSERT_DOES_NOT_TAKE_THROW = const ParserErrorCod e('ASSERT_DOES_NOT_TAKE_THROW', "Assert cannot be called on throws");
7863 7864
7864 static const ParserErrorCode ASSERT_DOES_NOT_TAKE_RETHROW = const ParserErrorC ode.con3('ASSERT_DOES_NOT_TAKE_RETHROW', 9, "Assert cannot be called on rethrows "); 7865 static const ParserErrorCode ASSERT_DOES_NOT_TAKE_RETHROW = const ParserErrorC ode('ASSERT_DOES_NOT_TAKE_RETHROW', "Assert cannot be called on rethrows");
7865 7866
7866 static const ParserErrorCode BREAK_OUTSIDE_OF_LOOP = const ParserErrorCode.con 3('BREAK_OUTSIDE_OF_LOOP', 10, "A break statement cannot be used outside of a lo op or switch statement"); 7867 static const ParserErrorCode BREAK_OUTSIDE_OF_LOOP = const ParserErrorCode('BR EAK_OUTSIDE_OF_LOOP', "A break statement cannot be used outside of a loop or swi tch statement");
7867 7868
7868 static const ParserErrorCode CONST_AND_FINAL = const ParserErrorCode.con3('CON ST_AND_FINAL', 11, "Members cannot be declared to be both 'const' and 'final'"); 7869 static const ParserErrorCode CONST_AND_FINAL = const ParserErrorCode('CONST_AN D_FINAL', "Members cannot be declared to be both 'const' and 'final'");
7869 7870
7870 static const ParserErrorCode CONST_AND_VAR = const ParserErrorCode.con3('CONST _AND_VAR', 12, "Members cannot be declared to be both 'const' and 'var'"); 7871 static const ParserErrorCode CONST_AND_VAR = const ParserErrorCode('CONST_AND_ VAR', "Members cannot be declared to be both 'const' and 'var'");
7871 7872
7872 static const ParserErrorCode CONST_CLASS = const ParserErrorCode.con3('CONST_C LASS', 13, "Classes cannot be declared to be 'const'"); 7873 static const ParserErrorCode CONST_CLASS = const ParserErrorCode('CONST_CLASS' , "Classes cannot be declared to be 'const'");
7873 7874
7874 static const ParserErrorCode CONST_CONSTRUCTOR_WITH_BODY = const ParserErrorCo de.con3('CONST_CONSTRUCTOR_WITH_BODY', 14, "'const' constructors cannot have a b ody"); 7875 static const ParserErrorCode CONST_CONSTRUCTOR_WITH_BODY = const ParserErrorCo de('CONST_CONSTRUCTOR_WITH_BODY', "'const' constructors cannot have a body");
7875 7876
7876 static const ParserErrorCode CONST_ENUM = const ParserErrorCode.con3('CONST_EN UM', 15, "Enums cannot be declared to be 'const'"); 7877 static const ParserErrorCode CONST_ENUM = const ParserErrorCode('CONST_ENUM', "Enums cannot be declared to be 'const'");
7877 7878
7878 static const ParserErrorCode CONST_FACTORY = const ParserErrorCode.con3('CONST _FACTORY', 16, "Only redirecting factory constructors can be declared to be 'con st'"); 7879 static const ParserErrorCode CONST_FACTORY = const ParserErrorCode('CONST_FACT ORY', "Only redirecting factory constructors can be declared to be 'const'");
7879 7880
7880 static const ParserErrorCode CONST_METHOD = const ParserErrorCode.con3('CONST_ METHOD', 17, "Getters, setters and methods cannot be declared to be 'const'"); 7881 static const ParserErrorCode CONST_METHOD = const ParserErrorCode('CONST_METHO D', "Getters, setters and methods cannot be declared to be 'const'");
7881 7882
7882 static const ParserErrorCode CONST_TYPEDEF = const ParserErrorCode.con3('CONST _TYPEDEF', 18, "Type aliases cannot be declared to be 'const'"); 7883 static const ParserErrorCode CONST_TYPEDEF = const ParserErrorCode('CONST_TYPE DEF', "Type aliases cannot be declared to be 'const'");
7883 7884
7884 static const ParserErrorCode CONSTRUCTOR_WITH_RETURN_TYPE = const ParserErrorC ode.con3('CONSTRUCTOR_WITH_RETURN_TYPE', 19, "Constructors cannot have a return type"); 7885 static const ParserErrorCode CONSTRUCTOR_WITH_RETURN_TYPE = const ParserErrorC ode('CONSTRUCTOR_WITH_RETURN_TYPE', "Constructors cannot have a return type");
7885 7886
7886 static const ParserErrorCode CONTINUE_OUTSIDE_OF_LOOP = const ParserErrorCode. con3('CONTINUE_OUTSIDE_OF_LOOP', 20, "A continue statement cannot be used outsid e of a loop or switch statement"); 7887 static const ParserErrorCode CONTINUE_OUTSIDE_OF_LOOP = const ParserErrorCode( 'CONTINUE_OUTSIDE_OF_LOOP', "A continue statement cannot be used outside of a lo op or switch statement");
7887 7888
7888 static const ParserErrorCode CONTINUE_WITHOUT_LABEL_IN_CASE = const ParserErro rCode.con3('CONTINUE_WITHOUT_LABEL_IN_CASE', 21, "A continue statement in a swit ch statement must have a label as a target"); 7889 static const ParserErrorCode CONTINUE_WITHOUT_LABEL_IN_CASE = const ParserErro rCode('CONTINUE_WITHOUT_LABEL_IN_CASE', "A continue statement in a switch statem ent must have a label as a target");
7889 7890
7890 static const ParserErrorCode DEFERRED_IMPORTS_NOT_SUPPORTED = const ParserErro rCode.con3('DEFERRED_IMPORTS_NOT_SUPPORTED', 22, "Deferred imports are not suppo rted by default"); 7891 static const ParserErrorCode DEFERRED_IMPORTS_NOT_SUPPORTED = const ParserErro rCode('DEFERRED_IMPORTS_NOT_SUPPORTED', "Deferred imports are not supported by d efault");
7891 7892
7892 static const ParserErrorCode DEPRECATED_CLASS_TYPE_ALIAS = const ParserErrorCo de.con3('DEPRECATED_CLASS_TYPE_ALIAS', 23, "The 'typedef' mixin application was replaced with 'class'"); 7893 static const ParserErrorCode DEPRECATED_CLASS_TYPE_ALIAS = const ParserErrorCo de('DEPRECATED_CLASS_TYPE_ALIAS', "The 'typedef' mixin application was replaced with 'class'");
7893 7894
7894 static const ParserErrorCode DIRECTIVE_AFTER_DECLARATION = const ParserErrorCo de.con3('DIRECTIVE_AFTER_DECLARATION', 24, "Directives must appear before any de clarations"); 7895 static const ParserErrorCode DIRECTIVE_AFTER_DECLARATION = const ParserErrorCo de('DIRECTIVE_AFTER_DECLARATION', "Directives must appear before any declaration s");
7895 7896
7896 static const ParserErrorCode DUPLICATE_LABEL_IN_SWITCH_STATEMENT = const Parse rErrorCode.con3('DUPLICATE_LABEL_IN_SWITCH_STATEMENT', 25, "The label {0} was al ready used in this switch statement"); 7897 static const ParserErrorCode DUPLICATE_LABEL_IN_SWITCH_STATEMENT = const Parse rErrorCode('DUPLICATE_LABEL_IN_SWITCH_STATEMENT', "The label {0} was already use d in this switch statement");
7897 7898
7898 static const ParserErrorCode DUPLICATED_MODIFIER = const ParserErrorCode.con3( 'DUPLICATED_MODIFIER', 26, "The modifier '{0}' was already specified."); 7899 static const ParserErrorCode DUPLICATED_MODIFIER = const ParserErrorCode('DUPL ICATED_MODIFIER', "The modifier '{0}' was already specified.");
7899 7900
7900 static const ParserErrorCode EMPTY_ENUM_BODY = const ParserErrorCode.con3('EMP TY_ENUM_BODY', 27, "An enum must declare at least one constant name"); 7901 static const ParserErrorCode EMPTY_ENUM_BODY = const ParserErrorCode('EMPTY_EN UM_BODY', "An enum must declare at least one constant name");
7901 7902
7902 static const ParserErrorCode EQUALITY_CANNOT_BE_EQUALITY_OPERAND = const Parse rErrorCode.con3('EQUALITY_CANNOT_BE_EQUALITY_OPERAND', 28, "Equality expression cannot be operand of another equality expression."); 7903 static const ParserErrorCode EQUALITY_CANNOT_BE_EQUALITY_OPERAND = const Parse rErrorCode('EQUALITY_CANNOT_BE_EQUALITY_OPERAND', "Equality expression cannot be operand of another equality expression.");
7903 7904
7904 static const ParserErrorCode EXPECTED_CASE_OR_DEFAULT = const ParserErrorCode. con3('EXPECTED_CASE_OR_DEFAULT', 29, "Expected 'case' or 'default'"); 7905 static const ParserErrorCode EXPECTED_CASE_OR_DEFAULT = const ParserErrorCode( 'EXPECTED_CASE_OR_DEFAULT', "Expected 'case' or 'default'");
7905 7906
7906 static const ParserErrorCode EXPECTED_CLASS_MEMBER = const ParserErrorCode.con 3('EXPECTED_CLASS_MEMBER', 30, "Expected a class member"); 7907 static const ParserErrorCode EXPECTED_CLASS_MEMBER = const ParserErrorCode('EX PECTED_CLASS_MEMBER', "Expected a class member");
7907 7908
7908 static const ParserErrorCode EXPECTED_EXECUTABLE = const ParserErrorCode.con3( 'EXPECTED_EXECUTABLE', 31, "Expected a method, getter, setter or operator declar ation"); 7909 static const ParserErrorCode EXPECTED_EXECUTABLE = const ParserErrorCode('EXPE CTED_EXECUTABLE', "Expected a method, getter, setter or operator declaration");
7909 7910
7910 static const ParserErrorCode EXPECTED_LIST_OR_MAP_LITERAL = const ParserErrorC ode.con3('EXPECTED_LIST_OR_MAP_LITERAL', 32, "Expected a list or map literal"); 7911 static const ParserErrorCode EXPECTED_LIST_OR_MAP_LITERAL = const ParserErrorC ode('EXPECTED_LIST_OR_MAP_LITERAL', "Expected a list or map literal");
7911 7912
7912 static const ParserErrorCode EXPECTED_STRING_LITERAL = const ParserErrorCode.c on3('EXPECTED_STRING_LITERAL', 33, "Expected a string literal"); 7913 static const ParserErrorCode EXPECTED_STRING_LITERAL = const ParserErrorCode(' EXPECTED_STRING_LITERAL', "Expected a string literal");
7913 7914
7914 static const ParserErrorCode EXPECTED_TOKEN = const ParserErrorCode.con3('EXPE CTED_TOKEN', 34, "Expected to find '{0}'"); 7915 static const ParserErrorCode EXPECTED_TOKEN = const ParserErrorCode('EXPECTED_ TOKEN', "Expected to find '{0}'");
7915 7916
7916 static const ParserErrorCode EXPECTED_TYPE_NAME = const ParserErrorCode.con3(' EXPECTED_TYPE_NAME', 35, "Expected a type name"); 7917 static const ParserErrorCode EXPECTED_TYPE_NAME = const ParserErrorCode('EXPEC TED_TYPE_NAME', "Expected a type name");
7917 7918
7918 static const ParserErrorCode EXPORT_DIRECTIVE_AFTER_PART_DIRECTIVE = const Par serErrorCode.con3('EXPORT_DIRECTIVE_AFTER_PART_DIRECTIVE', 36, "Export directive s must preceed part directives"); 7919 static const ParserErrorCode EXPORT_DIRECTIVE_AFTER_PART_DIRECTIVE = const Par serErrorCode('EXPORT_DIRECTIVE_AFTER_PART_DIRECTIVE', "Export directives must pr eceed part directives");
7919 7920
7920 static const ParserErrorCode EXTERNAL_AFTER_CONST = const ParserErrorCode.con3 ('EXTERNAL_AFTER_CONST', 37, "The modifier 'external' should be before the modif ier 'const'"); 7921 static const ParserErrorCode EXTERNAL_AFTER_CONST = const ParserErrorCode('EXT ERNAL_AFTER_CONST', "The modifier 'external' should be before the modifier 'cons t'");
7921 7922
7922 static const ParserErrorCode EXTERNAL_AFTER_FACTORY = const ParserErrorCode.co n3('EXTERNAL_AFTER_FACTORY', 38, "The modifier 'external' should be before the m odifier 'factory'"); 7923 static const ParserErrorCode EXTERNAL_AFTER_FACTORY = const ParserErrorCode('E XTERNAL_AFTER_FACTORY', "The modifier 'external' should be before the modifier ' factory'");
7923 7924
7924 static const ParserErrorCode EXTERNAL_AFTER_STATIC = const ParserErrorCode.con 3('EXTERNAL_AFTER_STATIC', 39, "The modifier 'external' should be before the mod ifier 'static'"); 7925 static const ParserErrorCode EXTERNAL_AFTER_STATIC = const ParserErrorCode('EX TERNAL_AFTER_STATIC', "The modifier 'external' should be before the modifier 'st atic'");
7925 7926
7926 static const ParserErrorCode EXTERNAL_CLASS = const ParserErrorCode.con3('EXTE RNAL_CLASS', 40, "Classes cannot be declared to be 'external'"); 7927 static const ParserErrorCode EXTERNAL_CLASS = const ParserErrorCode('EXTERNAL_ CLASS', "Classes cannot be declared to be 'external'");
7927 7928
7928 static const ParserErrorCode EXTERNAL_CONSTRUCTOR_WITH_BODY = const ParserErro rCode.con3('EXTERNAL_CONSTRUCTOR_WITH_BODY', 41, "External constructors cannot h ave a body"); 7929 static const ParserErrorCode EXTERNAL_CONSTRUCTOR_WITH_BODY = const ParserErro rCode('EXTERNAL_CONSTRUCTOR_WITH_BODY', "External constructors cannot have a bod y");
7929 7930
7930 static const ParserErrorCode EXTERNAL_ENUM = const ParserErrorCode.con3('EXTER NAL_ENUM', 42, "Enums cannot be declared to be 'external'"); 7931 static const ParserErrorCode EXTERNAL_ENUM = const ParserErrorCode('EXTERNAL_E NUM', "Enums cannot be declared to be 'external'");
7931 7932
7932 static const ParserErrorCode EXTERNAL_FIELD = const ParserErrorCode.con3('EXTE RNAL_FIELD', 43, "Fields cannot be declared to be 'external'"); 7933 static const ParserErrorCode EXTERNAL_FIELD = const ParserErrorCode('EXTERNAL_ FIELD', "Fields cannot be declared to be 'external'");
7933 7934
7934 static const ParserErrorCode EXTERNAL_GETTER_WITH_BODY = const ParserErrorCode .con3('EXTERNAL_GETTER_WITH_BODY', 44, "External getters cannot have a body"); 7935 static const ParserErrorCode EXTERNAL_GETTER_WITH_BODY = const ParserErrorCode ('EXTERNAL_GETTER_WITH_BODY', "External getters cannot have a body");
7935 7936
7936 static const ParserErrorCode EXTERNAL_METHOD_WITH_BODY = const ParserErrorCode .con3('EXTERNAL_METHOD_WITH_BODY', 45, "External methods cannot have a body"); 7937 static const ParserErrorCode EXTERNAL_METHOD_WITH_BODY = const ParserErrorCode ('EXTERNAL_METHOD_WITH_BODY', "External methods cannot have a body");
7937 7938
7938 static const ParserErrorCode EXTERNAL_OPERATOR_WITH_BODY = const ParserErrorCo de.con3('EXTERNAL_OPERATOR_WITH_BODY', 46, "External operators cannot have a bod y"); 7939 static const ParserErrorCode EXTERNAL_OPERATOR_WITH_BODY = const ParserErrorCo de('EXTERNAL_OPERATOR_WITH_BODY', "External operators cannot have a body");
7939 7940
7940 static const ParserErrorCode EXTERNAL_SETTER_WITH_BODY = const ParserErrorCode .con3('EXTERNAL_SETTER_WITH_BODY', 47, "External setters cannot have a body"); 7941 static const ParserErrorCode EXTERNAL_SETTER_WITH_BODY = const ParserErrorCode ('EXTERNAL_SETTER_WITH_BODY', "External setters cannot have a body");
7941 7942
7942 static const ParserErrorCode EXTERNAL_TYPEDEF = const ParserErrorCode.con3('EX TERNAL_TYPEDEF', 48, "Type aliases cannot be declared to be 'external'"); 7943 static const ParserErrorCode EXTERNAL_TYPEDEF = const ParserErrorCode('EXTERNA L_TYPEDEF', "Type aliases cannot be declared to be 'external'");
7943 7944
7944 static const ParserErrorCode FACTORY_TOP_LEVEL_DECLARATION = const ParserError Code.con3('FACTORY_TOP_LEVEL_DECLARATION', 49, "Top-level declarations cannot be declared to be 'factory'"); 7945 static const ParserErrorCode FACTORY_TOP_LEVEL_DECLARATION = const ParserError Code('FACTORY_TOP_LEVEL_DECLARATION', "Top-level declarations cannot be declared to be 'factory'");
7945 7946
7946 static const ParserErrorCode FACTORY_WITHOUT_BODY = const ParserErrorCode.con3 ('FACTORY_WITHOUT_BODY', 50, "A non-redirecting 'factory' constructor must have a body"); 7947 static const ParserErrorCode FACTORY_WITHOUT_BODY = const ParserErrorCode('FAC TORY_WITHOUT_BODY', "A non-redirecting 'factory' constructor must have a body");
7947 7948
7948 static const ParserErrorCode FIELD_INITIALIZER_OUTSIDE_CONSTRUCTOR = const Par serErrorCode.con3('FIELD_INITIALIZER_OUTSIDE_CONSTRUCTOR', 51, "Field initialize rs can only be used in a constructor"); 7949 static const ParserErrorCode FIELD_INITIALIZER_OUTSIDE_CONSTRUCTOR = const Par serErrorCode('FIELD_INITIALIZER_OUTSIDE_CONSTRUCTOR', "Field initializers can on ly be used in a constructor");
7949 7950
7950 static const ParserErrorCode FINAL_AND_VAR = const ParserErrorCode.con3('FINAL _AND_VAR', 52, "Members cannot be declared to be both 'final' and 'var'"); 7951 static const ParserErrorCode FINAL_AND_VAR = const ParserErrorCode('FINAL_AND_ VAR', "Members cannot be declared to be both 'final' and 'var'");
7951 7952
7952 static const ParserErrorCode FINAL_CLASS = const ParserErrorCode.con3('FINAL_C LASS', 53, "Classes cannot be declared to be 'final'"); 7953 static const ParserErrorCode FINAL_CLASS = const ParserErrorCode('FINAL_CLASS' , "Classes cannot be declared to be 'final'");
7953 7954
7954 static const ParserErrorCode FINAL_CONSTRUCTOR = const ParserErrorCode.con3('F INAL_CONSTRUCTOR', 54, "A constructor cannot be declared to be 'final'"); 7955 static const ParserErrorCode FINAL_CONSTRUCTOR = const ParserErrorCode('FINAL_ CONSTRUCTOR', "A constructor cannot be declared to be 'final'");
7955 7956
7956 static const ParserErrorCode FINAL_ENUM = const ParserErrorCode.con3('FINAL_EN UM', 55, "Enums cannot be declared to be 'final'"); 7957 static const ParserErrorCode FINAL_ENUM = const ParserErrorCode('FINAL_ENUM', "Enums cannot be declared to be 'final'");
7957 7958
7958 static const ParserErrorCode FINAL_METHOD = const ParserErrorCode.con3('FINAL_ METHOD', 56, "Getters, setters and methods cannot be declared to be 'final'"); 7959 static const ParserErrorCode FINAL_METHOD = const ParserErrorCode('FINAL_METHO D', "Getters, setters and methods cannot be declared to be 'final'");
7959 7960
7960 static const ParserErrorCode FINAL_TYPEDEF = const ParserErrorCode.con3('FINAL _TYPEDEF', 57, "Type aliases cannot be declared to be 'final'"); 7961 static const ParserErrorCode FINAL_TYPEDEF = const ParserErrorCode('FINAL_TYPE DEF', "Type aliases cannot be declared to be 'final'");
7961 7962
7962 static const ParserErrorCode FUNCTION_TYPED_PARAMETER_VAR = const ParserErrorC ode.con3('FUNCTION_TYPED_PARAMETER_VAR', 58, "Function typed parameters cannot s pecify 'const', 'final' or 'var' instead of return type"); 7963 static const ParserErrorCode FUNCTION_TYPED_PARAMETER_VAR = const ParserErrorC ode('FUNCTION_TYPED_PARAMETER_VAR', "Function typed parameters cannot specify 'c onst', 'final' or 'var' instead of return type");
7963 7964
7964 static const ParserErrorCode GETTER_IN_FUNCTION = const ParserErrorCode.con3(' GETTER_IN_FUNCTION', 59, "Getters cannot be defined within methods or functions" ); 7965 static const ParserErrorCode GETTER_IN_FUNCTION = const ParserErrorCode('GETTE R_IN_FUNCTION', "Getters cannot be defined within methods or functions");
7965 7966
7966 static const ParserErrorCode GETTER_WITH_PARAMETERS = const ParserErrorCode.co n3('GETTER_WITH_PARAMETERS', 60, "Getter should be declared without a parameter list"); 7967 static const ParserErrorCode GETTER_WITH_PARAMETERS = const ParserErrorCode('G ETTER_WITH_PARAMETERS', "Getter should be declared without a parameter list");
7967 7968
7968 static const ParserErrorCode ILLEGAL_ASSIGNMENT_TO_NON_ASSIGNABLE = const Pars erErrorCode.con3('ILLEGAL_ASSIGNMENT_TO_NON_ASSIGNABLE', 61, "Illegal assignment to non-assignable expression"); 7969 static const ParserErrorCode ILLEGAL_ASSIGNMENT_TO_NON_ASSIGNABLE = const Pars erErrorCode('ILLEGAL_ASSIGNMENT_TO_NON_ASSIGNABLE', "Illegal assignment to non-a ssignable expression");
7969 7970
7970 static const ParserErrorCode IMPLEMENTS_BEFORE_EXTENDS = const ParserErrorCode .con3('IMPLEMENTS_BEFORE_EXTENDS', 62, "The extends clause must be before the im plements clause"); 7971 static const ParserErrorCode IMPLEMENTS_BEFORE_EXTENDS = const ParserErrorCode ('IMPLEMENTS_BEFORE_EXTENDS', "The extends clause must be before the implements clause");
7971 7972
7972 static const ParserErrorCode IMPLEMENTS_BEFORE_WITH = const ParserErrorCode.co n3('IMPLEMENTS_BEFORE_WITH', 63, "The with clause must be before the implements clause"); 7973 static const ParserErrorCode IMPLEMENTS_BEFORE_WITH = const ParserErrorCode('I MPLEMENTS_BEFORE_WITH', "The with clause must be before the implements clause");
7973 7974
7974 static const ParserErrorCode IMPORT_DIRECTIVE_AFTER_PART_DIRECTIVE = const Par serErrorCode.con3('IMPORT_DIRECTIVE_AFTER_PART_DIRECTIVE', 64, "Import directive s must preceed part directives"); 7975 static const ParserErrorCode IMPORT_DIRECTIVE_AFTER_PART_DIRECTIVE = const Par serErrorCode('IMPORT_DIRECTIVE_AFTER_PART_DIRECTIVE', "Import directives must pr eceed part directives");
7975 7976
7976 static const ParserErrorCode INITIALIZED_VARIABLE_IN_FOR_EACH = const ParserEr rorCode.con3('INITIALIZED_VARIABLE_IN_FOR_EACH', 65, "The loop variable in a for -each loop cannot be initialized"); 7977 static const ParserErrorCode INITIALIZED_VARIABLE_IN_FOR_EACH = const ParserEr rorCode('INITIALIZED_VARIABLE_IN_FOR_EACH', "The loop variable in a for-each loo p cannot be initialized");
7977 7978
7978 static const ParserErrorCode INVALID_AWAIT_IN_FOR = const ParserErrorCode.con4 ('INVALID_AWAIT_IN_FOR', 66, "The modifier 'await' is not allowed for a normal ' for' statement", "Remove the keyword or use a for-each statement."); 7979 static const ParserErrorCode INVALID_AWAIT_IN_FOR = const ParserErrorCode('INV ALID_AWAIT_IN_FOR', "The modifier 'await' is not allowed for a normal 'for' stat ement", "Remove the keyword or use a for-each statement.");
7979 7980
7980 static const ParserErrorCode INVALID_CODE_POINT = const ParserErrorCode.con3(' INVALID_CODE_POINT', 67, "The escape sequence '{0}' is not a valid code point"); 7981 static const ParserErrorCode INVALID_CODE_POINT = const ParserErrorCode('INVAL ID_CODE_POINT', "The escape sequence '{0}' is not a valid code point");
7981 7982
7982 static const ParserErrorCode INVALID_COMMENT_REFERENCE = const ParserErrorCode .con3('INVALID_COMMENT_REFERENCE', 68, "Comment references should contain a poss ibly prefixed identifier and can start with 'new', but should not contain anythi ng else"); 7983 static const ParserErrorCode INVALID_COMMENT_REFERENCE = const ParserErrorCode ('INVALID_COMMENT_REFERENCE', "Comment references should contain a possibly pref ixed identifier and can start with 'new', but should not contain anything else") ;
7983 7984
7984 static const ParserErrorCode INVALID_HEX_ESCAPE = const ParserErrorCode.con3(' INVALID_HEX_ESCAPE', 69, "An escape sequence starting with '\\x' must be followe d by 2 hexidecimal digits"); 7985 static const ParserErrorCode INVALID_HEX_ESCAPE = const ParserErrorCode('INVAL ID_HEX_ESCAPE', "An escape sequence starting with '\\x' must be followed by 2 he xidecimal digits");
7985 7986
7986 static const ParserErrorCode INVALID_OPERATOR = const ParserErrorCode.con3('IN VALID_OPERATOR', 70, "The string '{0}' is not a valid operator"); 7987 static const ParserErrorCode INVALID_OPERATOR = const ParserErrorCode('INVALID _OPERATOR', "The string '{0}' is not a valid operator");
7987 7988
7988 static const ParserErrorCode INVALID_OPERATOR_FOR_SUPER = const ParserErrorCod e.con3('INVALID_OPERATOR_FOR_SUPER', 71, "The operator '{0}' cannot be used with 'super'"); 7989 static const ParserErrorCode INVALID_OPERATOR_FOR_SUPER = const ParserErrorCod e('INVALID_OPERATOR_FOR_SUPER', "The operator '{0}' cannot be used with 'super'" );
7989 7990
7990 static const ParserErrorCode INVALID_STAR_AFTER_ASYNC = const ParserErrorCode. con4('INVALID_STAR_AFTER_ASYNC', 72, "The modifier 'async*' is not allowed for a n expression function body", "Convert the body to a block."); 7991 static const ParserErrorCode INVALID_STAR_AFTER_ASYNC = const ParserErrorCode( 'INVALID_STAR_AFTER_ASYNC', "The modifier 'async*' is not allowed for an express ion function body", "Convert the body to a block.");
7991 7992
7992 static const ParserErrorCode INVALID_SYNC = const ParserErrorCode.con4('INVALI D_SYNC', 73, "The modifier 'sync' is not allowed for an exrpression function bod y", "Convert the body to a block."); 7993 static const ParserErrorCode INVALID_SYNC = const ParserErrorCode('INVALID_SYN C', "The modifier 'sync' is not allowed for an exrpression function body", "Conv ert the body to a block.");
7993 7994
7994 static const ParserErrorCode INVALID_UNICODE_ESCAPE = const ParserErrorCode.co n3('INVALID_UNICODE_ESCAPE', 74, "An escape sequence starting with '\\u' must be followed by 4 hexidecimal digits or from 1 to 6 digits between '{' and '}'"); 7995 static const ParserErrorCode INVALID_UNICODE_ESCAPE = const ParserErrorCode('I NVALID_UNICODE_ESCAPE', "An escape sequence starting with '\\u' must be followed by 4 hexidecimal digits or from 1 to 6 digits between '{' and '}'");
7995 7996
7996 static const ParserErrorCode LIBRARY_DIRECTIVE_NOT_FIRST = const ParserErrorCo de.con3('LIBRARY_DIRECTIVE_NOT_FIRST', 75, "The library directive must appear be fore all other directives"); 7997 static const ParserErrorCode LIBRARY_DIRECTIVE_NOT_FIRST = const ParserErrorCo de('LIBRARY_DIRECTIVE_NOT_FIRST', "The library directive must appear before all other directives");
7997 7998
7998 static const ParserErrorCode LOCAL_FUNCTION_DECLARATION_MODIFIER = const Parse rErrorCode.con3('LOCAL_FUNCTION_DECLARATION_MODIFIER', 76, "Local function decla rations cannot specify any modifier"); 7999 static const ParserErrorCode LOCAL_FUNCTION_DECLARATION_MODIFIER = const Parse rErrorCode('LOCAL_FUNCTION_DECLARATION_MODIFIER', "Local function declarations c annot specify any modifier");
7999 8000
8000 static const ParserErrorCode MISSING_ASSIGNABLE_SELECTOR = const ParserErrorCo de.con3('MISSING_ASSIGNABLE_SELECTOR', 77, "Missing selector such as \".<identif ier>\" or \"[0]\""); 8001 static const ParserErrorCode MISSING_ASSIGNABLE_SELECTOR = const ParserErrorCo de('MISSING_ASSIGNABLE_SELECTOR', "Missing selector such as \".<identifier>\" or \"[0]\"");
8001 8002
8002 static const ParserErrorCode MISSING_CATCH_OR_FINALLY = const ParserErrorCode. con3('MISSING_CATCH_OR_FINALLY', 78, "A try statement must have either a catch o r finally clause"); 8003 static const ParserErrorCode MISSING_CATCH_OR_FINALLY = const ParserErrorCode( 'MISSING_CATCH_OR_FINALLY', "A try statement must have either a catch or finally clause");
8003 8004
8004 static const ParserErrorCode MISSING_CLASS_BODY = const ParserErrorCode.con3(' MISSING_CLASS_BODY', 79, "A class definition must have a body, even if it is emp ty"); 8005 static const ParserErrorCode MISSING_CLASS_BODY = const ParserErrorCode('MISSI NG_CLASS_BODY', "A class definition must have a body, even if it is empty");
8005 8006
8006 static const ParserErrorCode MISSING_CLOSING_PARENTHESIS = const ParserErrorCo de.con3('MISSING_CLOSING_PARENTHESIS', 80, "The closing parenthesis is missing") ; 8007 static const ParserErrorCode MISSING_CLOSING_PARENTHESIS = const ParserErrorCo de('MISSING_CLOSING_PARENTHESIS', "The closing parenthesis is missing");
8007 8008
8008 static const ParserErrorCode MISSING_CONST_FINAL_VAR_OR_TYPE = const ParserErr orCode.con3('MISSING_CONST_FINAL_VAR_OR_TYPE', 81, "Variables must be declared u sing the keywords 'const', 'final', 'var' or a type name"); 8009 static const ParserErrorCode MISSING_CONST_FINAL_VAR_OR_TYPE = const ParserErr orCode('MISSING_CONST_FINAL_VAR_OR_TYPE', "Variables must be declared using the keywords 'const', 'final', 'var' or a type name");
8009 8010
8010 static const ParserErrorCode MISSING_ENUM_BODY = const ParserErrorCode.con3('M ISSING_ENUM_BODY', 82, "An enum definition must have a body with at least one co nstant name"); 8011 static const ParserErrorCode MISSING_ENUM_BODY = const ParserErrorCode('MISSIN G_ENUM_BODY', "An enum definition must have a body with at least one constant na me");
8011 8012
8012 static const ParserErrorCode MISSING_EXPRESSION_IN_THROW = const ParserErrorCo de.con3('MISSING_EXPRESSION_IN_THROW', 83, "Throw expressions must compute the o bject to be thrown"); 8013 static const ParserErrorCode MISSING_EXPRESSION_IN_THROW = const ParserErrorCo de('MISSING_EXPRESSION_IN_THROW', "Throw expressions must compute the object to be thrown");
8013 8014
8014 static const ParserErrorCode MISSING_FUNCTION_BODY = const ParserErrorCode.con 3('MISSING_FUNCTION_BODY', 84, "A function body must be provided"); 8015 static const ParserErrorCode MISSING_FUNCTION_BODY = const ParserErrorCode('MI SSING_FUNCTION_BODY', "A function body must be provided");
8015 8016
8016 static const ParserErrorCode MISSING_FUNCTION_PARAMETERS = const ParserErrorCo de.con3('MISSING_FUNCTION_PARAMETERS', 85, "Functions must have an explicit list of parameters"); 8017 static const ParserErrorCode MISSING_FUNCTION_PARAMETERS = const ParserErrorCo de('MISSING_FUNCTION_PARAMETERS', "Functions must have an explicit list of param eters");
8017 8018
8018 static const ParserErrorCode MISSING_GET = const ParserErrorCode.con3('MISSING _GET', 86, "Getters must have the keyword 'get' before the getter name"); 8019 static const ParserErrorCode MISSING_GET = const ParserErrorCode('MISSING_GET' , "Getters must have the keyword 'get' before the getter name");
8019 8020
8020 static const ParserErrorCode MISSING_IDENTIFIER = const ParserErrorCode.con3(' MISSING_IDENTIFIER', 87, "Expected an identifier"); 8021 static const ParserErrorCode MISSING_IDENTIFIER = const ParserErrorCode('MISSI NG_IDENTIFIER', "Expected an identifier");
8021 8022
8022 static const ParserErrorCode MISSING_KEYWORD_OPERATOR = const ParserErrorCode. con3('MISSING_KEYWORD_OPERATOR', 88, "Operator declarations must be preceeded by the keyword 'operator'"); 8023 static const ParserErrorCode MISSING_KEYWORD_OPERATOR = const ParserErrorCode( 'MISSING_KEYWORD_OPERATOR', "Operator declarations must be preceeded by the keyw ord 'operator'");
8023 8024
8024 static const ParserErrorCode MISSING_NAME_IN_LIBRARY_DIRECTIVE = const ParserE rrorCode.con3('MISSING_NAME_IN_LIBRARY_DIRECTIVE', 89, "Library directives must include a library name"); 8025 static const ParserErrorCode MISSING_NAME_IN_LIBRARY_DIRECTIVE = const ParserE rrorCode('MISSING_NAME_IN_LIBRARY_DIRECTIVE', "Library directives must include a library name");
8025 8026
8026 static const ParserErrorCode MISSING_NAME_IN_PART_OF_DIRECTIVE = const ParserE rrorCode.con3('MISSING_NAME_IN_PART_OF_DIRECTIVE', 90, "Library directives must include a library name"); 8027 static const ParserErrorCode MISSING_NAME_IN_PART_OF_DIRECTIVE = const ParserE rrorCode('MISSING_NAME_IN_PART_OF_DIRECTIVE', "Library directives must include a library name");
8027 8028
8028 static const ParserErrorCode MISSING_PREFIX_IN_DEFERRED_IMPORT = const ParserE rrorCode.con3('MISSING_PREFIX_IN_DEFERRED_IMPORT', 91, "Deferred imports must ha ve a prefix"); 8029 static const ParserErrorCode MISSING_PREFIX_IN_DEFERRED_IMPORT = const ParserE rrorCode('MISSING_PREFIX_IN_DEFERRED_IMPORT', "Deferred imports must have a pref ix");
8029 8030
8030 static const ParserErrorCode MISSING_STAR_AFTER_SYNC = const ParserErrorCode.c on4('MISSING_STAR_AFTER_SYNC', 92, "The modifier 'sync' must be followed by a st ar ('*')", "Remove the modifier or add a star."); 8031 static const ParserErrorCode MISSING_STAR_AFTER_SYNC = const ParserErrorCode(' MISSING_STAR_AFTER_SYNC', "The modifier 'sync' must be followed by a star ('*')" , "Remove the modifier or add a star.");
8031 8032
8032 static const ParserErrorCode MISSING_STATEMENT = const ParserErrorCode.con3('M ISSING_STATEMENT', 93, "Expected a statement"); 8033 static const ParserErrorCode MISSING_STATEMENT = const ParserErrorCode('MISSIN G_STATEMENT', "Expected a statement");
8033 8034
8034 static const ParserErrorCode MISSING_TERMINATOR_FOR_PARAMETER_GROUP = const Pa rserErrorCode.con3('MISSING_TERMINATOR_FOR_PARAMETER_GROUP', 94, "There is no '{ 0}' to close the parameter group"); 8035 static const ParserErrorCode MISSING_TERMINATOR_FOR_PARAMETER_GROUP = const Pa rserErrorCode('MISSING_TERMINATOR_FOR_PARAMETER_GROUP', "There is no '{0}' to cl ose the parameter group");
8035 8036
8036 static const ParserErrorCode MISSING_TYPEDEF_PARAMETERS = const ParserErrorCod e.con3('MISSING_TYPEDEF_PARAMETERS', 95, "Type aliases for functions must have a n explicit list of parameters"); 8037 static const ParserErrorCode MISSING_TYPEDEF_PARAMETERS = const ParserErrorCod e('MISSING_TYPEDEF_PARAMETERS', "Type aliases for functions must have an explici t list of parameters");
8037 8038
8038 static const ParserErrorCode MISSING_VARIABLE_IN_FOR_EACH = const ParserErrorC ode.con3('MISSING_VARIABLE_IN_FOR_EACH', 96, "A loop variable must be declared i n a for-each loop before the 'in', but none were found"); 8039 static const ParserErrorCode MISSING_VARIABLE_IN_FOR_EACH = const ParserErrorC ode('MISSING_VARIABLE_IN_FOR_EACH', "A loop variable must be declared in a for-e ach loop before the 'in', but none were found");
8039 8040
8040 static const ParserErrorCode MIXED_PARAMETER_GROUPS = const ParserErrorCode.co n3('MIXED_PARAMETER_GROUPS', 97, "Cannot have both positional and named paramete rs in a single parameter list"); 8041 static const ParserErrorCode MIXED_PARAMETER_GROUPS = const ParserErrorCode('M IXED_PARAMETER_GROUPS', "Cannot have both positional and named parameters in a s ingle parameter list");
8041 8042
8042 static const ParserErrorCode MULTIPLE_EXTENDS_CLAUSES = const ParserErrorCode. con3('MULTIPLE_EXTENDS_CLAUSES', 98, "Each class definition can have at most one extends clause"); 8043 static const ParserErrorCode MULTIPLE_EXTENDS_CLAUSES = const ParserErrorCode( 'MULTIPLE_EXTENDS_CLAUSES', "Each class definition can have at most one extends clause");
8043 8044
8044 static const ParserErrorCode MULTIPLE_IMPLEMENTS_CLAUSES = const ParserErrorCo de.con3('MULTIPLE_IMPLEMENTS_CLAUSES', 99, "Each class definition can have at mo st one implements clause"); 8045 static const ParserErrorCode MULTIPLE_IMPLEMENTS_CLAUSES = const ParserErrorCo de('MULTIPLE_IMPLEMENTS_CLAUSES', "Each class definition can have at most one im plements clause");
8045 8046
8046 static const ParserErrorCode MULTIPLE_LIBRARY_DIRECTIVES = const ParserErrorCo de.con3('MULTIPLE_LIBRARY_DIRECTIVES', 100, "Only one library directive may be d eclared in a file"); 8047 static const ParserErrorCode MULTIPLE_LIBRARY_DIRECTIVES = const ParserErrorCo de('MULTIPLE_LIBRARY_DIRECTIVES', "Only one library directive may be declared in a file");
8047 8048
8048 static const ParserErrorCode MULTIPLE_NAMED_PARAMETER_GROUPS = const ParserErr orCode.con3('MULTIPLE_NAMED_PARAMETER_GROUPS', 101, "Cannot have multiple groups of named parameters in a single parameter list"); 8049 static const ParserErrorCode MULTIPLE_NAMED_PARAMETER_GROUPS = const ParserErr orCode('MULTIPLE_NAMED_PARAMETER_GROUPS', "Cannot have multiple groups of named parameters in a single parameter list");
8049 8050
8050 static const ParserErrorCode MULTIPLE_PART_OF_DIRECTIVES = const ParserErrorCo de.con3('MULTIPLE_PART_OF_DIRECTIVES', 102, "Only one part-of directive may be d eclared in a file"); 8051 static const ParserErrorCode MULTIPLE_PART_OF_DIRECTIVES = const ParserErrorCo de('MULTIPLE_PART_OF_DIRECTIVES', "Only one part-of directive may be declared in a file");
8051 8052
8052 static const ParserErrorCode MULTIPLE_POSITIONAL_PARAMETER_GROUPS = const Pars erErrorCode.con3('MULTIPLE_POSITIONAL_PARAMETER_GROUPS', 103, "Cannot have multi ple groups of positional parameters in a single parameter list"); 8053 static const ParserErrorCode MULTIPLE_POSITIONAL_PARAMETER_GROUPS = const Pars erErrorCode('MULTIPLE_POSITIONAL_PARAMETER_GROUPS', "Cannot have multiple groups of positional parameters in a single parameter list");
8053 8054
8054 static const ParserErrorCode MULTIPLE_VARIABLES_IN_FOR_EACH = const ParserErro rCode.con3('MULTIPLE_VARIABLES_IN_FOR_EACH', 104, "A single loop variable must b e declared in a for-each loop before the 'in', but {0} were found"); 8055 static const ParserErrorCode MULTIPLE_VARIABLES_IN_FOR_EACH = const ParserErro rCode('MULTIPLE_VARIABLES_IN_FOR_EACH', "A single loop variable must be declared in a for-each loop before the 'in', but {0} were found");
8055 8056
8056 static const ParserErrorCode MULTIPLE_WITH_CLAUSES = const ParserErrorCode.con 3('MULTIPLE_WITH_CLAUSES', 105, "Each class definition can have at most one with clause"); 8057 static const ParserErrorCode MULTIPLE_WITH_CLAUSES = const ParserErrorCode('MU LTIPLE_WITH_CLAUSES', "Each class definition can have at most one with clause");
8057 8058
8058 static const ParserErrorCode NAMED_FUNCTION_EXPRESSION = const ParserErrorCode .con3('NAMED_FUNCTION_EXPRESSION', 106, "Function expressions cannot be named"); 8059 static const ParserErrorCode NAMED_FUNCTION_EXPRESSION = const ParserErrorCode ('NAMED_FUNCTION_EXPRESSION', "Function expressions cannot be named");
8059 8060
8060 static const ParserErrorCode NAMED_PARAMETER_OUTSIDE_GROUP = const ParserError Code.con3('NAMED_PARAMETER_OUTSIDE_GROUP', 107, "Named parameters must be enclos ed in curly braces ('{' and '}')"); 8061 static const ParserErrorCode NAMED_PARAMETER_OUTSIDE_GROUP = const ParserError Code('NAMED_PARAMETER_OUTSIDE_GROUP', "Named parameters must be enclosed in curl y braces ('{' and '}')");
8061 8062
8062 static const ParserErrorCode NATIVE_CLAUSE_IN_NON_SDK_CODE = const ParserError Code.con3('NATIVE_CLAUSE_IN_NON_SDK_CODE', 108, "Native clause can only be used in the SDK and code that is loaded through native extensions"); 8063 static const ParserErrorCode NATIVE_CLAUSE_IN_NON_SDK_CODE = const ParserError Code('NATIVE_CLAUSE_IN_NON_SDK_CODE', "Native clause can only be used in the SDK and code that is loaded through native extensions");
8063 8064
8064 static const ParserErrorCode NATIVE_FUNCTION_BODY_IN_NON_SDK_CODE = const Pars erErrorCode.con3('NATIVE_FUNCTION_BODY_IN_NON_SDK_CODE', 109, "Native functions can only be declared in the SDK and code that is loaded through native extension s"); 8065 static const ParserErrorCode NATIVE_FUNCTION_BODY_IN_NON_SDK_CODE = const Pars erErrorCode('NATIVE_FUNCTION_BODY_IN_NON_SDK_CODE', "Native functions can only b e declared in the SDK and code that is loaded through native extensions");
8065 8066
8066 static const ParserErrorCode NON_CONSTRUCTOR_FACTORY = const ParserErrorCode.c on3('NON_CONSTRUCTOR_FACTORY', 110, "Only constructors can be declared to be a ' factory'"); 8067 static const ParserErrorCode NON_CONSTRUCTOR_FACTORY = const ParserErrorCode(' NON_CONSTRUCTOR_FACTORY', "Only constructors can be declared to be a 'factory'") ;
8067 8068
8068 static const ParserErrorCode NON_IDENTIFIER_LIBRARY_NAME = const ParserErrorCo de.con3('NON_IDENTIFIER_LIBRARY_NAME', 111, "The name of a library must be an id entifier"); 8069 static const ParserErrorCode NON_IDENTIFIER_LIBRARY_NAME = const ParserErrorCo de('NON_IDENTIFIER_LIBRARY_NAME', "The name of a library must be an identifier") ;
8069 8070
8070 static const ParserErrorCode NON_PART_OF_DIRECTIVE_IN_PART = const ParserError Code.con3('NON_PART_OF_DIRECTIVE_IN_PART', 112, "The part-of directive must be t he only directive in a part"); 8071 static const ParserErrorCode NON_PART_OF_DIRECTIVE_IN_PART = const ParserError Code('NON_PART_OF_DIRECTIVE_IN_PART', "The part-of directive must be the only di rective in a part");
8071 8072
8072 static const ParserErrorCode NON_USER_DEFINABLE_OPERATOR = const ParserErrorCo de.con3('NON_USER_DEFINABLE_OPERATOR', 113, "The operator '{0}' is not user defi nable"); 8073 static const ParserErrorCode NON_USER_DEFINABLE_OPERATOR = const ParserErrorCo de('NON_USER_DEFINABLE_OPERATOR', "The operator '{0}' is not user definable");
8073 8074
8074 static const ParserErrorCode NORMAL_BEFORE_OPTIONAL_PARAMETERS = const ParserE rrorCode.con3('NORMAL_BEFORE_OPTIONAL_PARAMETERS', 114, "Normal parameters must occur before optional parameters"); 8075 static const ParserErrorCode NORMAL_BEFORE_OPTIONAL_PARAMETERS = const ParserE rrorCode('NORMAL_BEFORE_OPTIONAL_PARAMETERS', "Normal parameters must occur befo re optional parameters");
8075 8076
8076 static const ParserErrorCode POSITIONAL_AFTER_NAMED_ARGUMENT = const ParserErr orCode.con3('POSITIONAL_AFTER_NAMED_ARGUMENT', 115, "Positional arguments must o ccur before named arguments"); 8077 static const ParserErrorCode POSITIONAL_AFTER_NAMED_ARGUMENT = const ParserErr orCode('POSITIONAL_AFTER_NAMED_ARGUMENT', "Positional arguments must occur befor e named arguments");
8077 8078
8078 static const ParserErrorCode POSITIONAL_PARAMETER_OUTSIDE_GROUP = const Parser ErrorCode.con3('POSITIONAL_PARAMETER_OUTSIDE_GROUP', 116, "Positional parameters must be enclosed in square brackets ('[' and ']')"); 8079 static const ParserErrorCode POSITIONAL_PARAMETER_OUTSIDE_GROUP = const Parser ErrorCode('POSITIONAL_PARAMETER_OUTSIDE_GROUP', "Positional parameters must be e nclosed in square brackets ('[' and ']')");
8079 8080
8080 static const ParserErrorCode REDIRECTION_IN_NON_FACTORY_CONSTRUCTOR = const Pa rserErrorCode.con3('REDIRECTION_IN_NON_FACTORY_CONSTRUCTOR', 117, "Only factory constructor can specify '=' redirection."); 8081 static const ParserErrorCode REDIRECTION_IN_NON_FACTORY_CONSTRUCTOR = const Pa rserErrorCode('REDIRECTION_IN_NON_FACTORY_CONSTRUCTOR', "Only factory constructo r can specify '=' redirection.");
8081 8082
8082 static const ParserErrorCode SETTER_IN_FUNCTION = const ParserErrorCode.con3(' SETTER_IN_FUNCTION', 118, "Setters cannot be defined within methods or functions "); 8083 static const ParserErrorCode SETTER_IN_FUNCTION = const ParserErrorCode('SETTE R_IN_FUNCTION', "Setters cannot be defined within methods or functions");
8083 8084
8084 static const ParserErrorCode STATIC_AFTER_CONST = const ParserErrorCode.con3(' STATIC_AFTER_CONST', 119, "The modifier 'static' should be before the modifier ' const'"); 8085 static const ParserErrorCode STATIC_AFTER_CONST = const ParserErrorCode('STATI C_AFTER_CONST', "The modifier 'static' should be before the modifier 'const'");
8085 8086
8086 static const ParserErrorCode STATIC_AFTER_FINAL = const ParserErrorCode.con3(' STATIC_AFTER_FINAL', 120, "The modifier 'static' should be before the modifier ' final'"); 8087 static const ParserErrorCode STATIC_AFTER_FINAL = const ParserErrorCode('STATI C_AFTER_FINAL', "The modifier 'static' should be before the modifier 'final'");
8087 8088
8088 static const ParserErrorCode STATIC_AFTER_VAR = const ParserErrorCode.con3('ST ATIC_AFTER_VAR', 121, "The modifier 'static' should be before the modifier 'var' "); 8089 static const ParserErrorCode STATIC_AFTER_VAR = const ParserErrorCode('STATIC_ AFTER_VAR', "The modifier 'static' should be before the modifier 'var'");
8089 8090
8090 static const ParserErrorCode STATIC_CONSTRUCTOR = const ParserErrorCode.con3(' STATIC_CONSTRUCTOR', 122, "Constructors cannot be static"); 8091 static const ParserErrorCode STATIC_CONSTRUCTOR = const ParserErrorCode('STATI C_CONSTRUCTOR', "Constructors cannot be static");
8091 8092
8092 static const ParserErrorCode STATIC_GETTER_WITHOUT_BODY = const ParserErrorCod e.con3('STATIC_GETTER_WITHOUT_BODY', 123, "A 'static' getter must have a body"); 8093 static const ParserErrorCode STATIC_GETTER_WITHOUT_BODY = const ParserErrorCod e('STATIC_GETTER_WITHOUT_BODY', "A 'static' getter must have a body");
8093 8094
8094 static const ParserErrorCode STATIC_OPERATOR = const ParserErrorCode.con3('STA TIC_OPERATOR', 124, "Operators cannot be static"); 8095 static const ParserErrorCode STATIC_OPERATOR = const ParserErrorCode('STATIC_O PERATOR', "Operators cannot be static");
8095 8096
8096 static const ParserErrorCode STATIC_SETTER_WITHOUT_BODY = const ParserErrorCod e.con3('STATIC_SETTER_WITHOUT_BODY', 125, "A 'static' setter must have a body"); 8097 static const ParserErrorCode STATIC_SETTER_WITHOUT_BODY = const ParserErrorCod e('STATIC_SETTER_WITHOUT_BODY', "A 'static' setter must have a body");
8097 8098
8098 static const ParserErrorCode STATIC_TOP_LEVEL_DECLARATION = const ParserErrorC ode.con3('STATIC_TOP_LEVEL_DECLARATION', 126, "Top-level declarations cannot be declared to be 'static'"); 8099 static const ParserErrorCode STATIC_TOP_LEVEL_DECLARATION = const ParserErrorC ode('STATIC_TOP_LEVEL_DECLARATION', "Top-level declarations cannot be declared t o be 'static'");
8099 8100
8100 static const ParserErrorCode SWITCH_HAS_CASE_AFTER_DEFAULT_CASE = const Parser ErrorCode.con3('SWITCH_HAS_CASE_AFTER_DEFAULT_CASE', 127, "The 'default' case sh ould be the last case in a switch statement"); 8101 static const ParserErrorCode SWITCH_HAS_CASE_AFTER_DEFAULT_CASE = const Parser ErrorCode('SWITCH_HAS_CASE_AFTER_DEFAULT_CASE', "The 'default' case should be th e last case in a switch statement");
8101 8102
8102 static const ParserErrorCode SWITCH_HAS_MULTIPLE_DEFAULT_CASES = const ParserE rrorCode.con3('SWITCH_HAS_MULTIPLE_DEFAULT_CASES', 128, "The 'default' case can only be declared once"); 8103 static const ParserErrorCode SWITCH_HAS_MULTIPLE_DEFAULT_CASES = const ParserE rrorCode('SWITCH_HAS_MULTIPLE_DEFAULT_CASES', "The 'default' case can only be de clared once");
8103 8104
8104 static const ParserErrorCode TOP_LEVEL_OPERATOR = const ParserErrorCode.con3(' TOP_LEVEL_OPERATOR', 129, "Operators must be declared within a class"); 8105 static const ParserErrorCode TOP_LEVEL_OPERATOR = const ParserErrorCode('TOP_L EVEL_OPERATOR', "Operators must be declared within a class");
8105 8106
8106 static const ParserErrorCode UNEXPECTED_TERMINATOR_FOR_PARAMETER_GROUP = const ParserErrorCode.con3('UNEXPECTED_TERMINATOR_FOR_PARAMETER_GROUP', 130, "There i s no '{0}' to open a parameter group"); 8107 static const ParserErrorCode UNEXPECTED_TERMINATOR_FOR_PARAMETER_GROUP = const ParserErrorCode('UNEXPECTED_TERMINATOR_FOR_PARAMETER_GROUP', "There is no '{0}' to open a parameter group");
8107 8108
8108 static const ParserErrorCode UNEXPECTED_TOKEN = const ParserErrorCode.con3('UN EXPECTED_TOKEN', 131, "Unexpected token '{0}'"); 8109 static const ParserErrorCode UNEXPECTED_TOKEN = const ParserErrorCode('UNEXPEC TED_TOKEN', "Unexpected token '{0}'");
8109 8110
8110 static const ParserErrorCode WITH_BEFORE_EXTENDS = const ParserErrorCode.con3( 'WITH_BEFORE_EXTENDS', 132, "The extends clause must be before the with clause") ; 8111 static const ParserErrorCode WITH_BEFORE_EXTENDS = const ParserErrorCode('WITH _BEFORE_EXTENDS', "The extends clause must be before the with clause");
8111 8112
8112 static const ParserErrorCode WITH_WITHOUT_EXTENDS = const ParserErrorCode.con3 ('WITH_WITHOUT_EXTENDS', 133, "The with clause cannot be used without an extends clause"); 8113 static const ParserErrorCode WITH_WITHOUT_EXTENDS = const ParserErrorCode('WIT H_WITHOUT_EXTENDS', "The with clause cannot be used without an extends clause");
8113 8114
8114 static const ParserErrorCode WRONG_SEPARATOR_FOR_NAMED_PARAMETER = const Parse rErrorCode.con3('WRONG_SEPARATOR_FOR_NAMED_PARAMETER', 134, "The default value o f a named parameter should be preceeded by ':'"); 8115 static const ParserErrorCode WRONG_SEPARATOR_FOR_NAMED_PARAMETER = const Parse rErrorCode('WRONG_SEPARATOR_FOR_NAMED_PARAMETER', "The default value of a named parameter should be preceeded by ':'");
8115 8116
8116 static const ParserErrorCode WRONG_SEPARATOR_FOR_POSITIONAL_PARAMETER = const ParserErrorCode.con3('WRONG_SEPARATOR_FOR_POSITIONAL_PARAMETER', 135, "The defau lt value of a positional parameter should be preceeded by '='"); 8117 static const ParserErrorCode WRONG_SEPARATOR_FOR_POSITIONAL_PARAMETER = const ParserErrorCode('WRONG_SEPARATOR_FOR_POSITIONAL_PARAMETER', "The default value o f a positional parameter should be preceeded by '='");
8117 8118
8118 static const ParserErrorCode WRONG_TERMINATOR_FOR_PARAMETER_GROUP = const Pars erErrorCode.con3('WRONG_TERMINATOR_FOR_PARAMETER_GROUP', 136, "Expected '{0}' to close parameter group"); 8119 static const ParserErrorCode WRONG_TERMINATOR_FOR_PARAMETER_GROUP = const Pars erErrorCode('WRONG_TERMINATOR_FOR_PARAMETER_GROUP', "Expected '{0}' to close par ameter group");
8119 8120
8120 static const ParserErrorCode VAR_AND_TYPE = const ParserErrorCode.con3('VAR_AN D_TYPE', 137, "Variables cannot be declared using both 'var' and a type name; re move the 'var'"); 8121 static const ParserErrorCode VAR_AND_TYPE = const ParserErrorCode('VAR_AND_TYP E', "Variables cannot be declared using both 'var' and a type name; remove the ' var'");
8121 8122
8122 static const ParserErrorCode VAR_AS_TYPE_NAME = const ParserErrorCode.con3('VA R_AS_TYPE_NAME', 138, "The keyword 'var' cannot be used as a type name"); 8123 static const ParserErrorCode VAR_AS_TYPE_NAME = const ParserErrorCode('VAR_AS_ TYPE_NAME', "The keyword 'var' cannot be used as a type name");
8123 8124
8124 static const ParserErrorCode VAR_CLASS = const ParserErrorCode.con3('VAR_CLASS ', 139, "Classes cannot be declared to be 'var'"); 8125 static const ParserErrorCode VAR_CLASS = const ParserErrorCode('VAR_CLASS', "C lasses cannot be declared to be 'var'");
8125 8126
8126 static const ParserErrorCode VAR_ENUM = const ParserErrorCode.con3('VAR_ENUM', 140, "Enums cannot be declared to be 'var'"); 8127 static const ParserErrorCode VAR_ENUM = const ParserErrorCode('VAR_ENUM', "Enu ms cannot be declared to be 'var'");
8127 8128
8128 static const ParserErrorCode VAR_RETURN_TYPE = const ParserErrorCode.con3('VAR _RETURN_TYPE', 141, "The return type cannot be 'var'"); 8129 static const ParserErrorCode VAR_RETURN_TYPE = const ParserErrorCode('VAR_RETU RN_TYPE', "The return type cannot be 'var'");
8129 8130
8130 static const ParserErrorCode VAR_TYPEDEF = const ParserErrorCode.con3('VAR_TYP EDEF', 142, "Type aliases cannot be declared to be 'var'"); 8131 static const ParserErrorCode VAR_TYPEDEF = const ParserErrorCode('VAR_TYPEDEF' , "Type aliases cannot be declared to be 'var'");
8131 8132
8132 static const ParserErrorCode VOID_PARAMETER = const ParserErrorCode.con3('VOID _PARAMETER', 143, "Parameters cannot have a type of 'void'"); 8133 static const ParserErrorCode VOID_PARAMETER = const ParserErrorCode('VOID_PARA METER', "Parameters cannot have a type of 'void'");
8133 8134
8134 static const ParserErrorCode VOID_VARIABLE = const ParserErrorCode.con3('VOID_ VARIABLE', 144, "Variables cannot have a type of 'void'"); 8135 static const ParserErrorCode VOID_VARIABLE = const ParserErrorCode('VOID_VARIA BLE', "Variables cannot have a type of 'void'");
8135
8136 static const List<ParserErrorCode> values = const [
8137 ABSTRACT_CLASS_MEMBER,
8138 ABSTRACT_ENUM,
8139 ABSTRACT_STATIC_METHOD,
8140 ABSTRACT_TOP_LEVEL_FUNCTION,
8141 ABSTRACT_TOP_LEVEL_VARIABLE,
8142 ABSTRACT_TYPEDEF,
8143 ASSERT_DOES_NOT_TAKE_ASSIGNMENT,
8144 ASSERT_DOES_NOT_TAKE_CASCADE,
8145 ASSERT_DOES_NOT_TAKE_THROW,
8146 ASSERT_DOES_NOT_TAKE_RETHROW,
8147 BREAK_OUTSIDE_OF_LOOP,
8148 CONST_AND_FINAL,
8149 CONST_AND_VAR,
8150 CONST_CLASS,
8151 CONST_CONSTRUCTOR_WITH_BODY,
8152 CONST_ENUM,
8153 CONST_FACTORY,
8154 CONST_METHOD,
8155 CONST_TYPEDEF,
8156 CONSTRUCTOR_WITH_RETURN_TYPE,
8157 CONTINUE_OUTSIDE_OF_LOOP,
8158 CONTINUE_WITHOUT_LABEL_IN_CASE,
8159 DEFERRED_IMPORTS_NOT_SUPPORTED,
8160 DEPRECATED_CLASS_TYPE_ALIAS,
8161 DIRECTIVE_AFTER_DECLARATION,
8162 DUPLICATE_LABEL_IN_SWITCH_STATEMENT,
8163 DUPLICATED_MODIFIER,
8164 EMPTY_ENUM_BODY,
8165 EQUALITY_CANNOT_BE_EQUALITY_OPERAND,
8166 EXPECTED_CASE_OR_DEFAULT,
8167 EXPECTED_CLASS_MEMBER,
8168 EXPECTED_EXECUTABLE,
8169 EXPECTED_LIST_OR_MAP_LITERAL,
8170 EXPECTED_STRING_LITERAL,
8171 EXPECTED_TOKEN,
8172 EXPECTED_TYPE_NAME,
8173 EXPORT_DIRECTIVE_AFTER_PART_DIRECTIVE,
8174 EXTERNAL_AFTER_CONST,
8175 EXTERNAL_AFTER_FACTORY,
8176 EXTERNAL_AFTER_STATIC,
8177 EXTERNAL_CLASS,
8178 EXTERNAL_CONSTRUCTOR_WITH_BODY,
8179 EXTERNAL_ENUM,
8180 EXTERNAL_FIELD,
8181 EXTERNAL_GETTER_WITH_BODY,
8182 EXTERNAL_METHOD_WITH_BODY,
8183 EXTERNAL_OPERATOR_WITH_BODY,
8184 EXTERNAL_SETTER_WITH_BODY,
8185 EXTERNAL_TYPEDEF,
8186 FACTORY_TOP_LEVEL_DECLARATION,
8187 FACTORY_WITHOUT_BODY,
8188 FIELD_INITIALIZER_OUTSIDE_CONSTRUCTOR,
8189 FINAL_AND_VAR,
8190 FINAL_CLASS,
8191 FINAL_CONSTRUCTOR,
8192 FINAL_ENUM,
8193 FINAL_METHOD,
8194 FINAL_TYPEDEF,
8195 FUNCTION_TYPED_PARAMETER_VAR,
8196 GETTER_IN_FUNCTION,
8197 GETTER_WITH_PARAMETERS,
8198 ILLEGAL_ASSIGNMENT_TO_NON_ASSIGNABLE,
8199 IMPLEMENTS_BEFORE_EXTENDS,
8200 IMPLEMENTS_BEFORE_WITH,
8201 IMPORT_DIRECTIVE_AFTER_PART_DIRECTIVE,
8202 INITIALIZED_VARIABLE_IN_FOR_EACH,
8203 INVALID_AWAIT_IN_FOR,
8204 INVALID_CODE_POINT,
8205 INVALID_COMMENT_REFERENCE,
8206 INVALID_HEX_ESCAPE,
8207 INVALID_OPERATOR,
8208 INVALID_OPERATOR_FOR_SUPER,
8209 INVALID_STAR_AFTER_ASYNC,
8210 INVALID_SYNC,
8211 INVALID_UNICODE_ESCAPE,
8212 LIBRARY_DIRECTIVE_NOT_FIRST,
8213 LOCAL_FUNCTION_DECLARATION_MODIFIER,
8214 MISSING_ASSIGNABLE_SELECTOR,
8215 MISSING_CATCH_OR_FINALLY,
8216 MISSING_CLASS_BODY,
8217 MISSING_CLOSING_PARENTHESIS,
8218 MISSING_CONST_FINAL_VAR_OR_TYPE,
8219 MISSING_ENUM_BODY,
8220 MISSING_EXPRESSION_IN_THROW,
8221 MISSING_FUNCTION_BODY,
8222 MISSING_FUNCTION_PARAMETERS,
8223 MISSING_GET,
8224 MISSING_IDENTIFIER,
8225 MISSING_KEYWORD_OPERATOR,
8226 MISSING_NAME_IN_LIBRARY_DIRECTIVE,
8227 MISSING_NAME_IN_PART_OF_DIRECTIVE,
8228 MISSING_PREFIX_IN_DEFERRED_IMPORT,
8229 MISSING_STAR_AFTER_SYNC,
8230 MISSING_STATEMENT,
8231 MISSING_TERMINATOR_FOR_PARAMETER_GROUP,
8232 MISSING_TYPEDEF_PARAMETERS,
8233 MISSING_VARIABLE_IN_FOR_EACH,
8234 MIXED_PARAMETER_GROUPS,
8235 MULTIPLE_EXTENDS_CLAUSES,
8236 MULTIPLE_IMPLEMENTS_CLAUSES,
8237 MULTIPLE_LIBRARY_DIRECTIVES,
8238 MULTIPLE_NAMED_PARAMETER_GROUPS,
8239 MULTIPLE_PART_OF_DIRECTIVES,
8240 MULTIPLE_POSITIONAL_PARAMETER_GROUPS,
8241 MULTIPLE_VARIABLES_IN_FOR_EACH,
8242 MULTIPLE_WITH_CLAUSES,
8243 NAMED_FUNCTION_EXPRESSION,
8244 NAMED_PARAMETER_OUTSIDE_GROUP,
8245 NATIVE_CLAUSE_IN_NON_SDK_CODE,
8246 NATIVE_FUNCTION_BODY_IN_NON_SDK_CODE,
8247 NON_CONSTRUCTOR_FACTORY,
8248 NON_IDENTIFIER_LIBRARY_NAME,
8249 NON_PART_OF_DIRECTIVE_IN_PART,
8250 NON_USER_DEFINABLE_OPERATOR,
8251 NORMAL_BEFORE_OPTIONAL_PARAMETERS,
8252 POSITIONAL_AFTER_NAMED_ARGUMENT,
8253 POSITIONAL_PARAMETER_OUTSIDE_GROUP,
8254 REDIRECTION_IN_NON_FACTORY_CONSTRUCTOR,
8255 SETTER_IN_FUNCTION,
8256 STATIC_AFTER_CONST,
8257 STATIC_AFTER_FINAL,
8258 STATIC_AFTER_VAR,
8259 STATIC_CONSTRUCTOR,
8260 STATIC_GETTER_WITHOUT_BODY,
8261 STATIC_OPERATOR,
8262 STATIC_SETTER_WITHOUT_BODY,
8263 STATIC_TOP_LEVEL_DECLARATION,
8264 SWITCH_HAS_CASE_AFTER_DEFAULT_CASE,
8265 SWITCH_HAS_MULTIPLE_DEFAULT_CASES,
8266 TOP_LEVEL_OPERATOR,
8267 UNEXPECTED_TERMINATOR_FOR_PARAMETER_GROUP,
8268 UNEXPECTED_TOKEN,
8269 WITH_BEFORE_EXTENDS,
8270 WITH_WITHOUT_EXTENDS,
8271 WRONG_SEPARATOR_FOR_NAMED_PARAMETER,
8272 WRONG_SEPARATOR_FOR_POSITIONAL_PARAMETER,
8273 WRONG_TERMINATOR_FOR_PARAMETER_GROUP,
8274 VAR_AND_TYPE,
8275 VAR_AS_TYPE_NAME,
8276 VAR_CLASS,
8277 VAR_ENUM,
8278 VAR_RETURN_TYPE,
8279 VAR_TYPEDEF,
8280 VOID_PARAMETER,
8281 VOID_VARIABLE];
8282 8136
8283 /** 8137 /**
8284 * The severity of this error. 8138 * Initialize a newly created error code to have the given [name]. The message
8139 * associated with the error will be created from the given [message]
8140 * template. The correction associated with the error will be created from the
8141 * given [correction] template.
8285 */ 8142 */
8286 final ErrorSeverity errorSeverity; 8143 const ParserErrorCode(String name, String message, [String correction])
8287 8144 : super(name, message, correction);
8288 /** 8145
8289 * The template used to create the message to be displayed for this error. 8146 @override
8290 */ 8147 ErrorSeverity get errorSeverity => ErrorSeverity.ERROR;
8291 final String message;
8292
8293 /**
8294 * The template used to create the correction to be displayed for this error, or `null` if
8295 * there is no correction information for this error.
8296 */
8297 final String correction;
8298
8299 /**
8300 * Initialize a newly created error code to have the given severity and messag e.
8301 *
8302 * @param errorSeverity the severity of the error
8303 * @param message the message template used to create the message to be displa yed for the error
8304 */
8305 const ParserErrorCode.con1(String name, int ordinal, ErrorSeverity errorSeveri ty, String message) : this.con2(name, ordinal, errorSeverity, message, null);
8306
8307 /**
8308 * Initialize a newly created error code to have the given severity, message a nd correction.
8309 *
8310 * @param errorSeverity the severity of the error
8311 * @param message the template used to create the message to be displayed for the error
8312 * @param correction the template used to create the correction to be displaye d for the error
8313 */
8314 const ParserErrorCode.con2(String name, int ordinal, this.errorSeverity, this. message, this.correction) : super(name, ordinal);
8315
8316 /**
8317 * Initialize a newly created error code to have the given message and a sever ity of ERROR.
8318 *
8319 * @param message the message template used to create the message to be displa yed for the error
8320 */
8321 const ParserErrorCode.con3(String name, int ordinal, String message) : this.co n2(name, ordinal, ErrorSeverity.ERROR, message, null);
8322
8323 /**
8324 * Initialize a newly created error code to have the given message and a sever ity of ERROR.
8325 *
8326 * @param message the message template used to create the message to be displa yed for the error
8327 * @param correction the template used to create the correction to be displaye d for the error
8328 */
8329 const ParserErrorCode.con4(String name, int ordinal, String message, String co rrection) : this.con2(name, ordinal, ErrorSeverity.ERROR, message, correction);
8330 8148
8331 @override 8149 @override
8332 ErrorType get type => ErrorType.SYNTACTIC_ERROR; 8150 ErrorType get type => ErrorType.SYNTACTIC_ERROR;
8333
8334 @override
8335 String get uniqueName => "$runtimeType.$name";
8336 } 8151 }
8337 8152
8338 /** 8153 /**
8339 * Instances of the class `SyntheticKeywordToken` implement a synthetic keyword token. 8154 * Instances of the class `SyntheticKeywordToken` implement a synthetic keyword token.
8340 */ 8155 */
8341 class Parser_SyntheticKeywordToken extends KeywordToken { 8156 class Parser_SyntheticKeywordToken extends KeywordToken {
8342 /** 8157 /**
8343 * Initialize a newly created token to represent the given keyword. 8158 * Initialize a newly created token to represent the given keyword.
8344 * 8159 *
8345 * @param keyword the keyword being represented by this token 8160 * @param keyword the keyword being represented by this token
(...skipping 1611 matching lines...) Expand 10 before | Expand all | Expand 10 after
9957 return trampoline(target, arguments[0], arguments[1]); 9772 return trampoline(target, arguments[0], arguments[1]);
9958 case 3: 9773 case 3:
9959 return trampoline(target, arguments[0], arguments[1], arguments[2]); 9774 return trampoline(target, arguments[0], arguments[1], arguments[2]);
9960 case 4: 9775 case 4:
9961 return trampoline(target, arguments[0], arguments[1], arguments[2], argu ments[3]); 9776 return trampoline(target, arguments[0], arguments[1], arguments[2], argu ments[3]);
9962 default: 9777 default:
9963 throw new IllegalArgumentException("Not implemented for > 4 arguments"); 9778 throw new IllegalArgumentException("Not implemented for > 4 arguments");
9964 } 9779 }
9965 } 9780 }
9966 } 9781 }
OLDNEW
« no previous file with comments | « no previous file | pkg/analyzer/lib/src/generated/resolver.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698