| OLD | NEW |
| 1 // This code was auto-generated, is not intended to be edited, and is subject to | 1 // This code was auto-generated, is not intended to be edited, and is subject to |
| 2 // significant change. Please see the README file for more information. | 2 // significant change. Please see the README file for more information. |
| 3 library engine.error; | 3 library engine.error; |
| 4 import 'java_core.dart'; | 4 import 'java_core.dart'; |
| 5 import 'source.dart'; | 5 import 'source.dart'; |
| 6 import 'ast.dart' show ASTNode; | 6 import 'ast.dart' show ASTNode; |
| 7 import 'scanner.dart' show Token; | 7 import 'scanner.dart' show Token; |
| 8 /** | 8 /** |
| 9 * Instances of the enumeration `ErrorSeverity` represent the severity of an [Er
rorCode] | 9 * Instances of the enumeration `ErrorSeverity` represent the severity of an [Er
rorCode] |
| 10 * . | 10 * . |
| (...skipping 302 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 313 this.source = source; | 313 this.source = source; |
| 314 this.offset = offset; | 314 this.offset = offset; |
| 315 this.length = length; | 315 this.length = length; |
| 316 this.errorCode = errorCode; | 316 this.errorCode = errorCode; |
| 317 this.message = JavaString.format(errorCode.message, arguments); | 317 this.message = JavaString.format(errorCode.message, arguments); |
| 318 String correctionTemplate = errorCode.correction; | 318 String correctionTemplate = errorCode.correction; |
| 319 if (correctionTemplate != null) { | 319 if (correctionTemplate != null) { |
| 320 this.correction = JavaString.format(correctionTemplate, arguments); | 320 this.correction = JavaString.format(correctionTemplate, arguments); |
| 321 } | 321 } |
| 322 } | 322 } |
| 323 bool operator ==(Object obj) { |
| 324 if (identical(obj, this)) { |
| 325 return true; |
| 326 } |
| 327 if (obj is! AnalysisError) { |
| 328 return false; |
| 329 } |
| 330 AnalysisError other = obj as AnalysisError; |
| 331 if (errorCode != other.errorCode) { |
| 332 return false; |
| 333 } |
| 334 if (offset != other.offset || length != other.length) { |
| 335 return false; |
| 336 } |
| 337 if (isStaticOnly != other.isStaticOnly) { |
| 338 return false; |
| 339 } |
| 340 if (message == null && other.message != null || message != other.message) { |
| 341 return false; |
| 342 } |
| 343 if (source == null && other.source != null || source != other.source) { |
| 344 return false; |
| 345 } |
| 346 return true; |
| 347 } |
| 323 | 348 |
| 324 /** | 349 /** |
| 325 * Return the value of the given property, or `null` if the given property is
not defined | 350 * Return the value of the given property, or `null` if the given property is
not defined |
| 326 * for this error. | 351 * for this error. |
| 327 * | 352 * |
| 328 * @param property the property whose value is to be returned | 353 * @param property the property whose value is to be returned |
| 329 * @return the value of the given property | 354 * @return the value of the given property |
| 330 */ | 355 */ |
| 331 Object getProperty(ErrorProperty property) => null; | 356 Object getProperty(ErrorProperty property) => null; |
| 332 int get hashCode { | 357 int get hashCode { |
| (...skipping 659 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 992 static final CompileTimeErrorCode DEFAULT_VALUE_IN_FUNCTION_TYPE_ALIAS = new C
ompileTimeErrorCode.con1('DEFAULT_VALUE_IN_FUNCTION_TYPE_ALIAS', 36, "Default va
lues aren't allowed in typedefs"); | 1017 static final CompileTimeErrorCode DEFAULT_VALUE_IN_FUNCTION_TYPE_ALIAS = new C
ompileTimeErrorCode.con1('DEFAULT_VALUE_IN_FUNCTION_TYPE_ALIAS', 36, "Default va
lues aren't allowed in typedefs"); |
| 993 | 1018 |
| 994 /** | 1019 /** |
| 995 * 6.2.1 Required Formals: By means of a function signature that names the par
ameter and describes | 1020 * 6.2.1 Required Formals: By means of a function signature that names the par
ameter and describes |
| 996 * its type as a function type. It is a compile-time error if any default valu
es are specified in | 1021 * its type as a function type. It is a compile-time error if any default valu
es are specified in |
| 997 * the signature of such a function type. | 1022 * the signature of such a function type. |
| 998 */ | 1023 */ |
| 999 static final CompileTimeErrorCode DEFAULT_VALUE_IN_FUNCTION_TYPED_PARAMETER =
new CompileTimeErrorCode.con1('DEFAULT_VALUE_IN_FUNCTION_TYPED_PARAMETER', 37, "
Default values aren't allowed in function type parameters"); | 1024 static final CompileTimeErrorCode DEFAULT_VALUE_IN_FUNCTION_TYPED_PARAMETER =
new CompileTimeErrorCode.con1('DEFAULT_VALUE_IN_FUNCTION_TYPED_PARAMETER', 37, "
Default values aren't allowed in function type parameters"); |
| 1000 | 1025 |
| 1001 /** | 1026 /** |
| 1027 * 7.6.2 Factories: It is a compile-time error if <i>k</i> explicitly specifie
s a default value |
| 1028 * for an optional parameter. |
| 1029 */ |
| 1030 static final CompileTimeErrorCode DEFAULT_VALUE_IN_REDIRECTING_FACTORY_CONSTRU
CTOR = new CompileTimeErrorCode.con1('DEFAULT_VALUE_IN_REDIRECTING_FACTORY_CONST
RUCTOR', 38, "Default values aren't allowed in factory constructors that redirec
t to another constructor"); |
| 1031 |
| 1032 /** |
| 1002 * 3.1 Scoping: It is a compile-time error if there is more than one entity wi
th the same name | 1033 * 3.1 Scoping: It is a compile-time error if there is more than one entity wi
th the same name |
| 1003 * declared in the same scope. | 1034 * declared in the same scope. |
| 1004 */ | 1035 */ |
| 1005 static final CompileTimeErrorCode DUPLICATE_CONSTRUCTOR_DEFAULT = new CompileT
imeErrorCode.con1('DUPLICATE_CONSTRUCTOR_DEFAULT', 38, "The default constructor
is already defined"); | 1036 static final CompileTimeErrorCode DUPLICATE_CONSTRUCTOR_DEFAULT = new CompileT
imeErrorCode.con1('DUPLICATE_CONSTRUCTOR_DEFAULT', 39, "The default constructor
is already defined"); |
| 1006 | 1037 |
| 1007 /** | 1038 /** |
| 1008 * 3.1 Scoping: It is a compile-time error if there is more than one entity wi
th the same name | 1039 * 3.1 Scoping: It is a compile-time error if there is more than one entity wi
th the same name |
| 1009 * declared in the same scope. | 1040 * declared in the same scope. |
| 1010 * | 1041 * |
| 1011 * @param duplicateName the name of the duplicate entity | 1042 * @param duplicateName the name of the duplicate entity |
| 1012 */ | 1043 */ |
| 1013 static final CompileTimeErrorCode DUPLICATE_CONSTRUCTOR_NAME = new CompileTime
ErrorCode.con1('DUPLICATE_CONSTRUCTOR_NAME', 39, "The constructor with name '%s'
is already defined"); | 1044 static final CompileTimeErrorCode DUPLICATE_CONSTRUCTOR_NAME = new CompileTime
ErrorCode.con1('DUPLICATE_CONSTRUCTOR_NAME', 40, "The constructor with name '%s'
is already defined"); |
| 1014 | 1045 |
| 1015 /** | 1046 /** |
| 1016 * 3.1 Scoping: It is a compile-time error if there is more than one entity wi
th the same name | 1047 * 3.1 Scoping: It is a compile-time error if there is more than one entity wi
th the same name |
| 1017 * declared in the same scope. | 1048 * declared in the same scope. |
| 1018 * | 1049 * |
| 1019 * 7 Classes: It is a compile-time error if a class declares two members of th
e same name. | 1050 * 7 Classes: It is a compile-time error if a class declares two members of th
e same name. |
| 1020 * | 1051 * |
| 1021 * 7 Classes: It is a compile-time error if a class has an instance member and
a static member | 1052 * 7 Classes: It is a compile-time error if a class has an instance member and
a static member |
| 1022 * with the same name. | 1053 * with the same name. |
| 1023 * | 1054 * |
| 1024 * @param duplicateName the name of the duplicate entity | 1055 * @param duplicateName the name of the duplicate entity |
| 1025 */ | 1056 */ |
| 1026 static final CompileTimeErrorCode DUPLICATE_DEFINITION = new CompileTimeErrorC
ode.con1('DUPLICATE_DEFINITION', 40, "The name '%s' is already defined"); | 1057 static final CompileTimeErrorCode DUPLICATE_DEFINITION = new CompileTimeErrorC
ode.con1('DUPLICATE_DEFINITION', 41, "The name '%s' is already defined"); |
| 1027 | 1058 |
| 1028 /** | 1059 /** |
| 1029 * 7. Classes: It is a compile-time error if a class has an instance member an
d a static member | 1060 * 7. Classes: It is a compile-time error if a class has an instance member an
d a static member |
| 1030 * with the same name. | 1061 * with the same name. |
| 1031 * | 1062 * |
| 1032 * This covers the additional duplicate definition cases where inheritance has
to be considered. | 1063 * This covers the additional duplicate definition cases where inheritance has
to be considered. |
| 1033 * | 1064 * |
| 1034 * @param className the name of the class that has conflicting instance/static
members | 1065 * @param className the name of the class that has conflicting instance/static
members |
| 1035 * @param name the name of the conflicting members | 1066 * @param name the name of the conflicting members |
| 1036 * @see #DUPLICATE_DEFINITION | 1067 * @see #DUPLICATE_DEFINITION |
| 1037 */ | 1068 */ |
| 1038 static final CompileTimeErrorCode DUPLICATE_DEFINITION_INHERITANCE = new Compi
leTimeErrorCode.con1('DUPLICATE_DEFINITION_INHERITANCE', 41, "The name '%s' is a
lready defined in '%s'"); | 1069 static final CompileTimeErrorCode DUPLICATE_DEFINITION_INHERITANCE = new Compi
leTimeErrorCode.con1('DUPLICATE_DEFINITION_INHERITANCE', 42, "The name '%s' is a
lready defined in '%s'"); |
| 1039 | 1070 |
| 1040 /** | 1071 /** |
| 1041 * 12.14.2 Binding Actuals to Formals: It is a compile-time error if <i>q<sub>
i</sub> = | 1072 * 12.14.2 Binding Actuals to Formals: It is a compile-time error if <i>q<sub>
i</sub> = |
| 1042 * q<sub>j</sub></i> for any <i>i != j</i> [where <i>q<sub>i</sub></i> is the
label for a named | 1073 * q<sub>j</sub></i> for any <i>i != j</i> [where <i>q<sub>i</sub></i> is the
label for a named |
| 1043 * argument]. | 1074 * argument]. |
| 1044 */ | 1075 */ |
| 1045 static final CompileTimeErrorCode DUPLICATE_NAMED_ARGUMENT = new CompileTimeEr
rorCode.con1('DUPLICATE_NAMED_ARGUMENT', 42, "The argument for the named paramet
er '%s' was already specified"); | 1076 static final CompileTimeErrorCode DUPLICATE_NAMED_ARGUMENT = new CompileTimeEr
rorCode.con1('DUPLICATE_NAMED_ARGUMENT', 43, "The argument for the named paramet
er '%s' was already specified"); |
| 1046 | 1077 |
| 1047 /** | 1078 /** |
| 1048 * SDK implementation libraries can be exported only by other SDK libraries. | 1079 * SDK implementation libraries can be exported only by other SDK libraries. |
| 1049 * | 1080 * |
| 1050 * @param uri the uri pointing to a library | 1081 * @param uri the uri pointing to a library |
| 1051 */ | 1082 */ |
| 1052 static final CompileTimeErrorCode EXPORT_INTERNAL_LIBRARY = new CompileTimeErr
orCode.con1('EXPORT_INTERNAL_LIBRARY', 43, "The library '%s' is internal and can
not be exported"); | 1083 static final CompileTimeErrorCode EXPORT_INTERNAL_LIBRARY = new CompileTimeErr
orCode.con1('EXPORT_INTERNAL_LIBRARY', 44, "The library '%s' is internal and can
not be exported"); |
| 1053 | 1084 |
| 1054 /** | 1085 /** |
| 1055 * 14.2 Exports: It is a compile-time error if the compilation unit found at t
he specified URI is | 1086 * 14.2 Exports: It is a compile-time error if the compilation unit found at t
he specified URI is |
| 1056 * not a library declaration. | 1087 * not a library declaration. |
| 1057 * | 1088 * |
| 1058 * @param uri the uri pointing to a non-library declaration | 1089 * @param uri the uri pointing to a non-library declaration |
| 1059 */ | 1090 */ |
| 1060 static final CompileTimeErrorCode EXPORT_OF_NON_LIBRARY = new CompileTimeError
Code.con1('EXPORT_OF_NON_LIBRARY', 44, "The exported library '%s' must not have
a part-of directive"); | 1091 static final CompileTimeErrorCode EXPORT_OF_NON_LIBRARY = new CompileTimeError
Code.con1('EXPORT_OF_NON_LIBRARY', 45, "The exported library '%s' must not have
a part-of directive"); |
| 1061 | 1092 |
| 1062 /** | 1093 /** |
| 1063 * 7.9 Superclasses: It is a compile-time error if the extends clause of a cla
ss <i>C</i> includes | 1094 * 7.9 Superclasses: It is a compile-time error if the extends clause of a cla
ss <i>C</i> includes |
| 1064 * a type expression that does not denote a class available in the lexical sco
pe of <i>C</i>. | 1095 * a type expression that does not denote a class available in the lexical sco
pe of <i>C</i>. |
| 1065 * | 1096 * |
| 1066 * @param typeName the name of the superclass that was not found | 1097 * @param typeName the name of the superclass that was not found |
| 1067 */ | 1098 */ |
| 1068 static final CompileTimeErrorCode EXTENDS_NON_CLASS = new CompileTimeErrorCode
.con1('EXTENDS_NON_CLASS', 45, "Classes can only extend other classes"); | 1099 static final CompileTimeErrorCode EXTENDS_NON_CLASS = new CompileTimeErrorCode
.con1('EXTENDS_NON_CLASS', 46, "Classes can only extend other classes"); |
| 1069 | 1100 |
| 1070 /** | 1101 /** |
| 1071 * 12.2 Null: It is a compile-time error for a class to attempt to extend or i
mplement Null. | 1102 * 12.2 Null: It is a compile-time error for a class to attempt to extend or i
mplement Null. |
| 1072 * | 1103 * |
| 1073 * 12.3 Numbers: It is a compile-time error for a class to attempt to extend o
r implement int. | 1104 * 12.3 Numbers: It is a compile-time error for a class to attempt to extend o
r implement int. |
| 1074 * | 1105 * |
| 1075 * 12.3 Numbers: It is a compile-time error for a class to attempt to extend o
r implement double. | 1106 * 12.3 Numbers: It is a compile-time error for a class to attempt to extend o
r implement double. |
| 1076 * | 1107 * |
| 1077 * 12.3 Numbers: It is a compile-time error for any type other than the types
int and double to | 1108 * 12.3 Numbers: It is a compile-time error for any type other than the types
int and double to |
| 1078 * attempt to extend or implement num. | 1109 * attempt to extend or implement num. |
| 1079 * | 1110 * |
| 1080 * 12.4 Booleans: It is a compile-time error for a class to attempt to extend
or implement bool. | 1111 * 12.4 Booleans: It is a compile-time error for a class to attempt to extend
or implement bool. |
| 1081 * | 1112 * |
| 1082 * 12.5 Strings: It is a compile-time error for a class to attempt to extend o
r implement String. | 1113 * 12.5 Strings: It is a compile-time error for a class to attempt to extend o
r implement String. |
| 1083 * | 1114 * |
| 1084 * @param typeName the name of the type that cannot be extended | 1115 * @param typeName the name of the type that cannot be extended |
| 1085 * @see #IMPLEMENTS_DISALLOWED_CLASS | 1116 * @see #IMPLEMENTS_DISALLOWED_CLASS |
| 1086 */ | 1117 */ |
| 1087 static final CompileTimeErrorCode EXTENDS_DISALLOWED_CLASS = new CompileTimeEr
rorCode.con1('EXTENDS_DISALLOWED_CLASS', 46, "Classes cannot extend '%s'"); | 1118 static final CompileTimeErrorCode EXTENDS_DISALLOWED_CLASS = new CompileTimeEr
rorCode.con1('EXTENDS_DISALLOWED_CLASS', 47, "Classes cannot extend '%s'"); |
| 1088 | 1119 |
| 1089 /** | 1120 /** |
| 1090 * 12.14.2 Binding Actuals to Formals: It is a static warning if <i>m < h</
i> or if <i>m > | 1121 * 12.14.2 Binding Actuals to Formals: It is a static warning if <i>m < h</
i> or if <i>m > |
| 1091 * n</i>. | 1122 * n</i>. |
| 1092 * | 1123 * |
| 1093 * 12.11.2 Const: It is a compile-time error if evaluation of a constant objec
t results in an | 1124 * 12.11.2 Const: It is a compile-time error if evaluation of a constant objec
t results in an |
| 1094 * uncaught exception being thrown. | 1125 * uncaught exception being thrown. |
| 1095 * | 1126 * |
| 1096 * @param requiredCount the maximum number of positional arguments | 1127 * @param requiredCount the maximum number of positional arguments |
| 1097 * @param argumentCount the actual number of positional arguments given | 1128 * @param argumentCount the actual number of positional arguments given |
| 1098 */ | 1129 */ |
| 1099 static final CompileTimeErrorCode EXTRA_POSITIONAL_ARGUMENTS = new CompileTime
ErrorCode.con1('EXTRA_POSITIONAL_ARGUMENTS', 47, "%d positional arguments expect
ed, but %d found"); | 1130 static final CompileTimeErrorCode EXTRA_POSITIONAL_ARGUMENTS = new CompileTime
ErrorCode.con1('EXTRA_POSITIONAL_ARGUMENTS', 48, "%d positional arguments expect
ed, but %d found"); |
| 1100 | 1131 |
| 1101 /** | 1132 /** |
| 1102 * 7.6.1 Generative Constructors: Let <i>k</i> be a generative constructor. It
is a compile time | 1133 * 7.6.1 Generative Constructors: Let <i>k</i> be a generative constructor. It
is a compile time |
| 1103 * error if more than one initializer corresponding to a given instance variab
le appears in | 1134 * error if more than one initializer corresponding to a given instance variab
le appears in |
| 1104 * <i>k</i>'s list. | 1135 * <i>k</i>'s list. |
| 1105 */ | 1136 */ |
| 1106 static final CompileTimeErrorCode FIELD_INITIALIZED_BY_MULTIPLE_INITIALIZERS =
new CompileTimeErrorCode.con1('FIELD_INITIALIZED_BY_MULTIPLE_INITIALIZERS', 48,
"The field '%s' cannot be initialized twice in the same constructor"); | 1137 static final CompileTimeErrorCode FIELD_INITIALIZED_BY_MULTIPLE_INITIALIZERS =
new CompileTimeErrorCode.con1('FIELD_INITIALIZED_BY_MULTIPLE_INITIALIZERS', 49,
"The field '%s' cannot be initialized twice in the same constructor"); |
| 1107 | 1138 |
| 1108 /** | 1139 /** |
| 1109 * 7.6.1 Generative Constructors: Let <i>k</i> be a generative constructor. It
is a compile time | 1140 * 7.6.1 Generative Constructors: Let <i>k</i> be a generative constructor. It
is a compile time |
| 1110 * error if <i>k</i>'s initializer list contains an initializer for a variable
that is initialized | 1141 * error if <i>k</i>'s initializer list contains an initializer for a variable
that is initialized |
| 1111 * by means of an initializing formal of <i>k</i>. | 1142 * by means of an initializing formal of <i>k</i>. |
| 1112 */ | 1143 */ |
| 1113 static final CompileTimeErrorCode FIELD_INITIALIZED_IN_PARAMETER_AND_INITIALIZ
ER = new CompileTimeErrorCode.con1('FIELD_INITIALIZED_IN_PARAMETER_AND_INITIALIZ
ER', 49, "Fields cannot be initialized in both the parameter list and the initia
lizers"); | 1144 static final CompileTimeErrorCode FIELD_INITIALIZED_IN_PARAMETER_AND_INITIALIZ
ER = new CompileTimeErrorCode.con1('FIELD_INITIALIZED_IN_PARAMETER_AND_INITIALIZ
ER', 50, "Fields cannot be initialized in both the parameter list and the initia
lizers"); |
| 1114 | 1145 |
| 1115 /** | 1146 /** |
| 1116 * 5 Variables: It is a compile-time error if a final instance variable that h
as is initialized by | 1147 * 5 Variables: It is a compile-time error if a final instance variable that h
as is initialized by |
| 1117 * means of an initializing formal of a constructor is also initialized elsewh
ere in the same | 1148 * means of an initializing formal of a constructor is also initialized elsewh
ere in the same |
| 1118 * constructor. | 1149 * constructor. |
| 1119 * | 1150 * |
| 1120 * @param name the name of the field in question | 1151 * @param name the name of the field in question |
| 1121 */ | 1152 */ |
| 1122 static final CompileTimeErrorCode FINAL_INITIALIZED_MULTIPLE_TIMES = new Compi
leTimeErrorCode.con1('FINAL_INITIALIZED_MULTIPLE_TIMES', 50, "'%s' is a final fi
eld and so can only be set once"); | 1153 static final CompileTimeErrorCode FINAL_INITIALIZED_MULTIPLE_TIMES = new Compi
leTimeErrorCode.con1('FINAL_INITIALIZED_MULTIPLE_TIMES', 51, "'%s' is a final fi
eld and so can only be set once"); |
| 1123 | 1154 |
| 1124 /** | 1155 /** |
| 1125 * 7.6.1 Generative Constructors: It is a compile-time error if an initializin
g formal is used by | 1156 * 7.6.1 Generative Constructors: It is a compile-time error if an initializin
g formal is used by |
| 1126 * a function other than a non-redirecting generative constructor. | 1157 * a function other than a non-redirecting generative constructor. |
| 1127 */ | 1158 */ |
| 1128 static final CompileTimeErrorCode FIELD_INITIALIZER_FACTORY_CONSTRUCTOR = new
CompileTimeErrorCode.con1('FIELD_INITIALIZER_FACTORY_CONSTRUCTOR', 51, "Initiali
zing formal fields cannot be used in factory constructors"); | 1159 static final CompileTimeErrorCode FIELD_INITIALIZER_FACTORY_CONSTRUCTOR = new
CompileTimeErrorCode.con1('FIELD_INITIALIZER_FACTORY_CONSTRUCTOR', 52, "Initiali
zing formal fields cannot be used in factory constructors"); |
| 1129 | 1160 |
| 1130 /** | 1161 /** |
| 1131 * 7.6.1 Generative Constructors: It is a compile-time error if an initializin
g formal is used by | 1162 * 7.6.1 Generative Constructors: It is a compile-time error if an initializin
g formal is used by |
| 1132 * a function other than a non-redirecting generative constructor. | 1163 * a function other than a non-redirecting generative constructor. |
| 1133 */ | 1164 */ |
| 1134 static final CompileTimeErrorCode FIELD_INITIALIZER_OUTSIDE_CONSTRUCTOR = new
CompileTimeErrorCode.con1('FIELD_INITIALIZER_OUTSIDE_CONSTRUCTOR', 52, "Initiali
zing formal fields can only be used in constructors"); | 1165 static final CompileTimeErrorCode FIELD_INITIALIZER_OUTSIDE_CONSTRUCTOR = new
CompileTimeErrorCode.con1('FIELD_INITIALIZER_OUTSIDE_CONSTRUCTOR', 53, "Initiali
zing formal fields can only be used in constructors"); |
| 1135 | 1166 |
| 1136 /** | 1167 /** |
| 1137 * 7.6.1 Generative Constructors: A generative constructor may be redirecting,
in which case its | 1168 * 7.6.1 Generative Constructors: A generative constructor may be redirecting,
in which case its |
| 1138 * only action is to invoke another generative constructor. | 1169 * only action is to invoke another generative constructor. |
| 1139 * | 1170 * |
| 1140 * 7.6.1 Generative Constructors: It is a compile-time error if an initializin
g formal is used by | 1171 * 7.6.1 Generative Constructors: It is a compile-time error if an initializin
g formal is used by |
| 1141 * a function other than a non-redirecting generative constructor. | 1172 * a function other than a non-redirecting generative constructor. |
| 1142 */ | 1173 */ |
| 1143 static final CompileTimeErrorCode FIELD_INITIALIZER_REDIRECTING_CONSTRUCTOR =
new CompileTimeErrorCode.con1('FIELD_INITIALIZER_REDIRECTING_CONSTRUCTOR', 53, "
The redirecting constructor cannot have a field initializer"); | 1174 static final CompileTimeErrorCode FIELD_INITIALIZER_REDIRECTING_CONSTRUCTOR =
new CompileTimeErrorCode.con1('FIELD_INITIALIZER_REDIRECTING_CONSTRUCTOR', 54, "
The redirecting constructor cannot have a field initializer"); |
| 1144 | 1175 |
| 1145 /** | 1176 /** |
| 1146 * 7.2 Getters: It is a compile-time error if a class has both a getter and a
method with the same | 1177 * 7.2 Getters: It is a compile-time error if a class has both a getter and a
method with the same |
| 1147 * name. | 1178 * name. |
| 1148 * | 1179 * |
| 1149 * @param name the conflicting name of the getter and method | 1180 * @param name the conflicting name of the getter and method |
| 1150 */ | 1181 */ |
| 1151 static final CompileTimeErrorCode GETTER_AND_METHOD_WITH_SAME_NAME = new Compi
leTimeErrorCode.con1('GETTER_AND_METHOD_WITH_SAME_NAME', 54, "'%s' cannot be use
d to name a getter, there is already a method with the same name"); | 1182 static final CompileTimeErrorCode GETTER_AND_METHOD_WITH_SAME_NAME = new Compi
leTimeErrorCode.con1('GETTER_AND_METHOD_WITH_SAME_NAME', 55, "'%s' cannot be use
d to name a getter, there is already a method with the same name"); |
| 1152 | 1183 |
| 1153 /** | 1184 /** |
| 1154 * 12.2 Null: It is a compile-time error for a class to attempt to extend or i
mplement Null. | 1185 * 12.2 Null: It is a compile-time error for a class to attempt to extend or i
mplement Null. |
| 1155 * | 1186 * |
| 1156 * 12.3 Numbers: It is a compile-time error for a class to attempt to extend o
r implement int. | 1187 * 12.3 Numbers: It is a compile-time error for a class to attempt to extend o
r implement int. |
| 1157 * | 1188 * |
| 1158 * 12.3 Numbers: It is a compile-time error for a class to attempt to extend o
r implement double. | 1189 * 12.3 Numbers: It is a compile-time error for a class to attempt to extend o
r implement double. |
| 1159 * | 1190 * |
| 1160 * 12.3 Numbers: It is a compile-time error for any type other than the types
int and double to | 1191 * 12.3 Numbers: It is a compile-time error for any type other than the types
int and double to |
| 1161 * attempt to extend or implement num. | 1192 * attempt to extend or implement num. |
| 1162 * | 1193 * |
| 1163 * 12.4 Booleans: It is a compile-time error for a class to attempt to extend
or implement bool. | 1194 * 12.4 Booleans: It is a compile-time error for a class to attempt to extend
or implement bool. |
| 1164 * | 1195 * |
| 1165 * 12.5 Strings: It is a compile-time error for a class to attempt to extend o
r implement String. | 1196 * 12.5 Strings: It is a compile-time error for a class to attempt to extend o
r implement String. |
| 1166 * | 1197 * |
| 1167 * @param typeName the name of the type that cannot be implemented | 1198 * @param typeName the name of the type that cannot be implemented |
| 1168 * @see #EXTENDS_DISALLOWED_CLASS | 1199 * @see #EXTENDS_DISALLOWED_CLASS |
| 1169 */ | 1200 */ |
| 1170 static final CompileTimeErrorCode IMPLEMENTS_DISALLOWED_CLASS = new CompileTim
eErrorCode.con1('IMPLEMENTS_DISALLOWED_CLASS', 55, "Classes cannot implement '%s
'"); | 1201 static final CompileTimeErrorCode IMPLEMENTS_DISALLOWED_CLASS = new CompileTim
eErrorCode.con1('IMPLEMENTS_DISALLOWED_CLASS', 56, "Classes cannot implement '%s
'"); |
| 1171 | 1202 |
| 1172 /** | 1203 /** |
| 1173 * 7.10 Superinterfaces: It is a compile-time error if the implements clause o
f a class includes | 1204 * 7.10 Superinterfaces: It is a compile-time error if the implements clause o
f a class includes |
| 1174 * type dynamic. | 1205 * type dynamic. |
| 1175 */ | 1206 */ |
| 1176 static final CompileTimeErrorCode IMPLEMENTS_DYNAMIC = new CompileTimeErrorCod
e.con1('IMPLEMENTS_DYNAMIC', 56, "Classes cannot implement 'dynamic'"); | 1207 static final CompileTimeErrorCode IMPLEMENTS_DYNAMIC = new CompileTimeErrorCod
e.con1('IMPLEMENTS_DYNAMIC', 57, "Classes cannot implement 'dynamic'"); |
| 1177 | 1208 |
| 1178 /** | 1209 /** |
| 1179 * 7.10 Superinterfaces: It is a compile-time error if the implements clause o
f a class <i>C</i> | 1210 * 7.10 Superinterfaces: It is a compile-time error if the implements clause o
f a class <i>C</i> |
| 1180 * includes a type expression that does not denote a class available in the le
xical scope of | 1211 * includes a type expression that does not denote a class available in the le
xical scope of |
| 1181 * <i>C</i>. | 1212 * <i>C</i>. |
| 1182 * | 1213 * |
| 1183 * @param typeName the name of the interface that was not found | 1214 * @param typeName the name of the interface that was not found |
| 1184 */ | 1215 */ |
| 1185 static final CompileTimeErrorCode IMPLEMENTS_NON_CLASS = new CompileTimeErrorC
ode.con1('IMPLEMENTS_NON_CLASS', 57, "Classes can only implement other classes")
; | 1216 static final CompileTimeErrorCode IMPLEMENTS_NON_CLASS = new CompileTimeErrorC
ode.con1('IMPLEMENTS_NON_CLASS', 58, "Classes can only implement other classes")
; |
| 1186 | 1217 |
| 1187 /** | 1218 /** |
| 1188 * 7.10 Superinterfaces: It is a compile-time error if a type <i>T</i> appears
more than once in | 1219 * 7.10 Superinterfaces: It is a compile-time error if a type <i>T</i> appears
more than once in |
| 1189 * the implements clause of a class. | 1220 * the implements clause of a class. |
| 1190 * | 1221 * |
| 1191 * @param className the name of the class that is implemented more than once | 1222 * @param className the name of the class that is implemented more than once |
| 1192 */ | 1223 */ |
| 1193 static final CompileTimeErrorCode IMPLEMENTS_REPEATED = new CompileTimeErrorCo
de.con1('IMPLEMENTS_REPEATED', 58, "'%s' can only be implemented once"); | 1224 static final CompileTimeErrorCode IMPLEMENTS_REPEATED = new CompileTimeErrorCo
de.con1('IMPLEMENTS_REPEATED', 59, "'%s' can only be implemented once"); |
| 1194 | 1225 |
| 1195 /** | 1226 /** |
| 1196 * 7.10 Superinterfaces: It is a compile-time error if the superclass of a cla
ss <i>C</i> appears | 1227 * 7.10 Superinterfaces: It is a compile-time error if the superclass of a cla
ss <i>C</i> appears |
| 1197 * in the implements clause of <i>C</i>. | 1228 * in the implements clause of <i>C</i>. |
| 1198 * | 1229 * |
| 1199 * @param className the name of the class that appears in both "extends" and "
implements" clauses | 1230 * @param className the name of the class that appears in both "extends" and "
implements" clauses |
| 1200 */ | 1231 */ |
| 1201 static final CompileTimeErrorCode IMPLEMENTS_SUPER_CLASS = new CompileTimeErro
rCode.con1('IMPLEMENTS_SUPER_CLASS', 59, "'%s' cannot be used in both 'extends'
and 'implements' clauses"); | 1232 static final CompileTimeErrorCode IMPLEMENTS_SUPER_CLASS = new CompileTimeErro
rCode.con1('IMPLEMENTS_SUPER_CLASS', 60, "'%s' cannot be used in both 'extends'
and 'implements' clauses"); |
| 1202 | 1233 |
| 1203 /** | 1234 /** |
| 1204 * 7.6.1 Generative Constructors: Note that <b>this</b> is not in scope on the
right hand side of | 1235 * 7.6.1 Generative Constructors: Note that <b>this</b> is not in scope on the
right hand side of |
| 1205 * an initializer. | 1236 * an initializer. |
| 1206 * | 1237 * |
| 1207 * 12.10 This: It is a compile-time error if this appears in a top-level funct
ion or variable | 1238 * 12.10 This: It is a compile-time error if this appears in a top-level funct
ion or variable |
| 1208 * initializer, in a factory constructor, or in a static method or variable in
itializer, or in the | 1239 * initializer, in a factory constructor, or in a static method or variable in
itializer, or in the |
| 1209 * initializer of an instance variable. | 1240 * initializer of an instance variable. |
| 1210 * | 1241 * |
| 1211 * @param name the name of the type in question | 1242 * @param name the name of the type in question |
| 1212 */ | 1243 */ |
| 1213 static final CompileTimeErrorCode IMPLICIT_THIS_REFERENCE_IN_INITIALIZER = new
CompileTimeErrorCode.con1('IMPLICIT_THIS_REFERENCE_IN_INITIALIZER', 60, "Only s
tatic members can be accessed in initializers"); | 1244 static final CompileTimeErrorCode IMPLICIT_THIS_REFERENCE_IN_INITIALIZER = new
CompileTimeErrorCode.con1('IMPLICIT_THIS_REFERENCE_IN_INITIALIZER', 61, "Only s
tatic members can be accessed in initializers"); |
| 1214 | 1245 |
| 1215 /** | 1246 /** |
| 1216 * SDK implementation libraries can be imported only by other SDK libraries. | 1247 * SDK implementation libraries can be imported only by other SDK libraries. |
| 1217 * | 1248 * |
| 1218 * @param uri the uri pointing to a library | 1249 * @param uri the uri pointing to a library |
| 1219 */ | 1250 */ |
| 1220 static final CompileTimeErrorCode IMPORT_INTERNAL_LIBRARY = new CompileTimeErr
orCode.con1('IMPORT_INTERNAL_LIBRARY', 61, "The library '%s' is internal and can
not be imported"); | 1251 static final CompileTimeErrorCode IMPORT_INTERNAL_LIBRARY = new CompileTimeErr
orCode.con1('IMPORT_INTERNAL_LIBRARY', 62, "The library '%s' is internal and can
not be imported"); |
| 1221 | 1252 |
| 1222 /** | 1253 /** |
| 1223 * 14.1 Imports: It is a compile-time error if the compilation unit found at t
he specified URI is | 1254 * 14.1 Imports: It is a compile-time error if the compilation unit found at t
he specified URI is |
| 1224 * not a library declaration. | 1255 * not a library declaration. |
| 1225 * | 1256 * |
| 1226 * @param uri the uri pointing to a non-library declaration | 1257 * @param uri the uri pointing to a non-library declaration |
| 1227 */ | 1258 */ |
| 1228 static final CompileTimeErrorCode IMPORT_OF_NON_LIBRARY = new CompileTimeError
Code.con1('IMPORT_OF_NON_LIBRARY', 62, "The imported library '%s' must not have
a part-of directive"); | 1259 static final CompileTimeErrorCode IMPORT_OF_NON_LIBRARY = new CompileTimeError
Code.con1('IMPORT_OF_NON_LIBRARY', 63, "The imported library '%s' must not have
a part-of directive"); |
| 1229 | 1260 |
| 1230 /** | 1261 /** |
| 1231 * 13.9 Switch: It is a compile-time error if values of the expressions <i>e<s
ub>k</sub></i> are | 1262 * 13.9 Switch: It is a compile-time error if values of the expressions <i>e<s
ub>k</sub></i> are |
| 1232 * not instances of the same class <i>C</i>, for all <i>1 <= k <= n</i>. | 1263 * not instances of the same class <i>C</i>, for all <i>1 <= k <= n</i>. |
| 1233 * | 1264 * |
| 1234 * @param expressionSource the expression source code that is the unexpected t
ype | 1265 * @param expressionSource the expression source code that is the unexpected t
ype |
| 1235 * @param expectedType the name of the expected type | 1266 * @param expectedType the name of the expected type |
| 1236 */ | 1267 */ |
| 1237 static final CompileTimeErrorCode INCONSISTENT_CASE_EXPRESSION_TYPES = new Com
pileTimeErrorCode.con1('INCONSISTENT_CASE_EXPRESSION_TYPES', 63, "Case expressio
ns must have the same types, '%s' is not a %s'"); | 1268 static final CompileTimeErrorCode INCONSISTENT_CASE_EXPRESSION_TYPES = new Com
pileTimeErrorCode.con1('INCONSISTENT_CASE_EXPRESSION_TYPES', 64, "Case expressio
ns must have the same types, '%s' is not a %s'"); |
| 1238 | 1269 |
| 1239 /** | 1270 /** |
| 1240 * 7.6.1 Generative Constructors: Let <i>k</i> be a generative constructor. It
is a compile-time | 1271 * 7.6.1 Generative Constructors: Let <i>k</i> be a generative constructor. It
is a compile-time |
| 1241 * error if <i>k</i>'s initializer list contains an initializer for a variable
that is not an | 1272 * error if <i>k</i>'s initializer list contains an initializer for a variable
that is not an |
| 1242 * instance variable declared in the immediately surrounding class. | 1273 * instance variable declared in the immediately surrounding class. |
| 1243 * | 1274 * |
| 1244 * @param id the name of the initializing formal that is not an instance varia
ble in the | 1275 * @param id the name of the initializing formal that is not an instance varia
ble in the |
| 1245 * immediately enclosing class | 1276 * immediately enclosing class |
| 1246 * @see #INITIALIZING_FORMAL_FOR_NON_EXISTANT_FIELD | 1277 * @see #INITIALIZING_FORMAL_FOR_NON_EXISTANT_FIELD |
| 1247 */ | 1278 */ |
| 1248 static final CompileTimeErrorCode INITIALIZER_FOR_NON_EXISTANT_FIELD = new Com
pileTimeErrorCode.con1('INITIALIZER_FOR_NON_EXISTANT_FIELD', 64, "'%s' is not a
variable in the enclosing class"); | 1279 static final CompileTimeErrorCode INITIALIZER_FOR_NON_EXISTANT_FIELD = new Com
pileTimeErrorCode.con1('INITIALIZER_FOR_NON_EXISTANT_FIELD', 65, "'%s' is not a
variable in the enclosing class"); |
| 1249 | 1280 |
| 1250 /** | 1281 /** |
| 1251 * 7.6.1 Generative Constructors: Let <i>k</i> be a generative constructor. It
is a compile-time | 1282 * 7.6.1 Generative Constructors: Let <i>k</i> be a generative constructor. It
is a compile-time |
| 1252 * error if <i>k</i>'s initializer list contains an initializer for a variable
that is not an | 1283 * error if <i>k</i>'s initializer list contains an initializer for a variable
that is not an |
| 1253 * instance variable declared in the immediately surrounding class. | 1284 * instance variable declared in the immediately surrounding class. |
| 1254 * | 1285 * |
| 1255 * @param id the name of the initializing formal that is a static variable in
the immediately | 1286 * @param id the name of the initializing formal that is a static variable in
the immediately |
| 1256 * enclosing class | 1287 * enclosing class |
| 1257 * @see #INITIALIZING_FORMAL_FOR_STATIC_FIELD | 1288 * @see #INITIALIZING_FORMAL_FOR_STATIC_FIELD |
| 1258 */ | 1289 */ |
| 1259 static final CompileTimeErrorCode INITIALIZER_FOR_STATIC_FIELD = new CompileTi
meErrorCode.con1('INITIALIZER_FOR_STATIC_FIELD', 65, "'%s' is a static variable
in the enclosing class, variables initialized in a constructor cannot be static"
); | 1290 static final CompileTimeErrorCode INITIALIZER_FOR_STATIC_FIELD = new CompileTi
meErrorCode.con1('INITIALIZER_FOR_STATIC_FIELD', 66, "'%s' is a static variable
in the enclosing class, variables initialized in a constructor cannot be static"
); |
| 1260 | 1291 |
| 1261 /** | 1292 /** |
| 1262 * 7.6.1 Generative Constructors: An initializing formal has the form <i>this.
id</i>. It is a | 1293 * 7.6.1 Generative Constructors: An initializing formal has the form <i>this.
id</i>. It is a |
| 1263 * compile-time error if <i>id</i> is not the name of an instance variable of
the immediately | 1294 * compile-time error if <i>id</i> is not the name of an instance variable of
the immediately |
| 1264 * enclosing class. | 1295 * enclosing class. |
| 1265 * | 1296 * |
| 1266 * @param id the name of the initializing formal that is not an instance varia
ble in the | 1297 * @param id the name of the initializing formal that is not an instance varia
ble in the |
| 1267 * immediately enclosing class | 1298 * immediately enclosing class |
| 1268 * @see #INITIALIZING_FORMAL_FOR_STATIC_FIELD | 1299 * @see #INITIALIZING_FORMAL_FOR_STATIC_FIELD |
| 1269 * @see #INITIALIZER_FOR_NON_EXISTANT_FIELD | 1300 * @see #INITIALIZER_FOR_NON_EXISTANT_FIELD |
| 1270 */ | 1301 */ |
| 1271 static final CompileTimeErrorCode INITIALIZING_FORMAL_FOR_NON_EXISTANT_FIELD =
new CompileTimeErrorCode.con1('INITIALIZING_FORMAL_FOR_NON_EXISTANT_FIELD', 66,
"'%s' is not a variable in the enclosing class"); | 1302 static final CompileTimeErrorCode INITIALIZING_FORMAL_FOR_NON_EXISTANT_FIELD =
new CompileTimeErrorCode.con1('INITIALIZING_FORMAL_FOR_NON_EXISTANT_FIELD', 67,
"'%s' is not a variable in the enclosing class"); |
| 1272 | 1303 |
| 1273 /** | 1304 /** |
| 1274 * 7.6.1 Generative Constructors: An initializing formal has the form <i>this.
id</i>. It is a | 1305 * 7.6.1 Generative Constructors: An initializing formal has the form <i>this.
id</i>. It is a |
| 1275 * compile-time error if <i>id</i> is not the name of an instance variable of
the immediately | 1306 * compile-time error if <i>id</i> is not the name of an instance variable of
the immediately |
| 1276 * enclosing class. | 1307 * enclosing class. |
| 1277 * | 1308 * |
| 1278 * @param id the name of the initializing formal that is a static variable in
the immediately | 1309 * @param id the name of the initializing formal that is a static variable in
the immediately |
| 1279 * enclosing class | 1310 * enclosing class |
| 1280 * @see #INITIALIZER_FOR_STATIC_FIELD | 1311 * @see #INITIALIZER_FOR_STATIC_FIELD |
| 1281 */ | 1312 */ |
| 1282 static final CompileTimeErrorCode INITIALIZING_FORMAL_FOR_STATIC_FIELD = new C
ompileTimeErrorCode.con1('INITIALIZING_FORMAL_FOR_STATIC_FIELD', 67, "'%s' is a
static variable in the enclosing class, variables initialized in a constructor c
annot be static"); | 1313 static final CompileTimeErrorCode INITIALIZING_FORMAL_FOR_STATIC_FIELD = new C
ompileTimeErrorCode.con1('INITIALIZING_FORMAL_FOR_STATIC_FIELD', 68, "'%s' is a
static variable in the enclosing class, variables initialized in a constructor c
annot be static"); |
| 1283 | 1314 |
| 1284 /** | 1315 /** |
| 1285 * 12.30 Identifier Reference: Otherwise, e is equivalent to the property extr
action | 1316 * 12.30 Identifier Reference: Otherwise, e is equivalent to the property extr
action |
| 1286 * <b>this</b>.<i>id</i>. | 1317 * <b>this</b>.<i>id</i>. |
| 1287 */ | 1318 */ |
| 1288 static final CompileTimeErrorCode INSTANCE_MEMBER_ACCESS_FROM_STATIC = new Com
pileTimeErrorCode.con1('INSTANCE_MEMBER_ACCESS_FROM_STATIC', 68, "Instance membe
r cannot be accessed from static method"); | 1319 static final CompileTimeErrorCode INSTANCE_MEMBER_ACCESS_FROM_STATIC = new Com
pileTimeErrorCode.con1('INSTANCE_MEMBER_ACCESS_FROM_STATIC', 69, "Instance membe
r cannot be accessed from static method"); |
| 1289 | 1320 |
| 1290 /** | 1321 /** |
| 1291 * 11 Metadata: Metadata consists of a series of annotations, each of which be
gin with the | 1322 * 11 Metadata: Metadata consists of a series of annotations, each of which be
gin with the |
| 1292 * character @, followed by a constant expression that must be either a refere
nce to a | 1323 * character @, followed by a constant expression that must be either a refere
nce to a |
| 1293 * compile-time constant variable, or a call to a constant constructor. | 1324 * compile-time constant variable, or a call to a constant constructor. |
| 1294 */ | 1325 */ |
| 1295 static final CompileTimeErrorCode INVALID_ANNOTATION = new CompileTimeErrorCod
e.con1('INVALID_ANNOTATION', 69, "Annotation can be only constant variable or co
nstant constructor invocation"); | 1326 static final CompileTimeErrorCode INVALID_ANNOTATION = new CompileTimeErrorCod
e.con1('INVALID_ANNOTATION', 70, "Annotation can be only constant variable or co
nstant constructor invocation"); |
| 1296 | 1327 |
| 1297 /** | 1328 /** |
| 1298 * TODO(brianwilkerson) Remove this when we have decided on how to report erro
rs in compile-time | 1329 * TODO(brianwilkerson) Remove this when we have decided on how to report erro
rs in compile-time |
| 1299 * constants. Until then, this acts as a placeholder for more informative erro
rs. | 1330 * constants. Until then, this acts as a placeholder for more informative erro
rs. |
| 1300 * | 1331 * |
| 1301 * See TODOs in ConstantVisitor | 1332 * See TODOs in ConstantVisitor |
| 1302 */ | 1333 */ |
| 1303 static final CompileTimeErrorCode INVALID_CONSTANT = new CompileTimeErrorCode.
con1('INVALID_CONSTANT', 70, "Invalid constant value"); | 1334 static final CompileTimeErrorCode INVALID_CONSTANT = new CompileTimeErrorCode.
con1('INVALID_CONSTANT', 71, "Invalid constant value"); |
| 1304 | 1335 |
| 1305 /** | 1336 /** |
| 1306 * 7.6 Constructors: It is a compile-time error if the name of a constructor i
s not a constructor | 1337 * 7.6 Constructors: It is a compile-time error if the name of a constructor i
s not a constructor |
| 1307 * name. | 1338 * name. |
| 1308 */ | 1339 */ |
| 1309 static final CompileTimeErrorCode INVALID_CONSTRUCTOR_NAME = new CompileTimeEr
rorCode.con1('INVALID_CONSTRUCTOR_NAME', 71, "Invalid constructor name"); | 1340 static final CompileTimeErrorCode INVALID_CONSTRUCTOR_NAME = new CompileTimeEr
rorCode.con1('INVALID_CONSTRUCTOR_NAME', 72, "Invalid constructor name"); |
| 1310 | 1341 |
| 1311 /** | 1342 /** |
| 1312 * 7.6.2 Factories: It is a compile-time error if <i>M</i> is not the name of
the immediately | 1343 * 7.6.2 Factories: It is a compile-time error if <i>M</i> is not the name of
the immediately |
| 1313 * enclosing class. | 1344 * enclosing class. |
| 1314 */ | 1345 */ |
| 1315 static final CompileTimeErrorCode INVALID_FACTORY_NAME_NOT_A_CLASS = new Compi
leTimeErrorCode.con1('INVALID_FACTORY_NAME_NOT_A_CLASS', 72, "The name of the im
mediately enclosing class expected"); | 1346 static final CompileTimeErrorCode INVALID_FACTORY_NAME_NOT_A_CLASS = new Compi
leTimeErrorCode.con1('INVALID_FACTORY_NAME_NOT_A_CLASS', 73, "The name of the im
mediately enclosing class expected"); |
| 1316 | 1347 |
| 1317 /** | 1348 /** |
| 1318 * 12.10 This: It is a compile-time error if this appears in a top-level funct
ion or variable | 1349 * 12.10 This: It is a compile-time error if this appears in a top-level funct
ion or variable |
| 1319 * initializer, in a factory constructor, or in a static method or variable in
itializer, or in the | 1350 * initializer, in a factory constructor, or in a static method or variable in
itializer, or in the |
| 1320 * initializer of an instance variable. | 1351 * initializer of an instance variable. |
| 1321 */ | 1352 */ |
| 1322 static final CompileTimeErrorCode INVALID_REFERENCE_TO_THIS = new CompileTimeE
rrorCode.con1('INVALID_REFERENCE_TO_THIS', 73, "Invalid reference to 'this' expr
ession"); | 1353 static final CompileTimeErrorCode INVALID_REFERENCE_TO_THIS = new CompileTimeE
rrorCode.con1('INVALID_REFERENCE_TO_THIS', 74, "Invalid reference to 'this' expr
ession"); |
| 1323 | 1354 |
| 1324 /** | 1355 /** |
| 1325 * 12.6 Lists: It is a compile time error if the type argument of a constant l
ist literal includes | 1356 * 12.6 Lists: It is a compile time error if the type argument of a constant l
ist literal includes |
| 1326 * a type parameter. | 1357 * a type parameter. |
| 1327 * | 1358 * |
| 1328 * @name the name of the type parameter | 1359 * @name the name of the type parameter |
| 1329 */ | 1360 */ |
| 1330 static final CompileTimeErrorCode INVALID_TYPE_ARGUMENT_IN_CONST_LIST = new Co
mpileTimeErrorCode.con1('INVALID_TYPE_ARGUMENT_IN_CONST_LIST', 74, "Constant lis
t literals cannot include a type parameter as a type argument, such as '%s'"); | 1361 static final CompileTimeErrorCode INVALID_TYPE_ARGUMENT_IN_CONST_LIST = new Co
mpileTimeErrorCode.con1('INVALID_TYPE_ARGUMENT_IN_CONST_LIST', 75, "Constant lis
t literals cannot include a type parameter as a type argument, such as '%s'"); |
| 1331 | 1362 |
| 1332 /** | 1363 /** |
| 1333 * 12.7 Maps: It is a compile time error if the type arguments of a constant m
ap literal include a | 1364 * 12.7 Maps: It is a compile time error if the type arguments of a constant m
ap literal include a |
| 1334 * type parameter. | 1365 * type parameter. |
| 1335 * | 1366 * |
| 1336 * @name the name of the type parameter | 1367 * @name the name of the type parameter |
| 1337 */ | 1368 */ |
| 1338 static final CompileTimeErrorCode INVALID_TYPE_ARGUMENT_IN_CONST_MAP = new Com
pileTimeErrorCode.con1('INVALID_TYPE_ARGUMENT_IN_CONST_MAP', 75, "Constant map l
iterals cannot include a type parameter as a type argument, such as '%s'"); | 1369 static final CompileTimeErrorCode INVALID_TYPE_ARGUMENT_IN_CONST_MAP = new Com
pileTimeErrorCode.con1('INVALID_TYPE_ARGUMENT_IN_CONST_MAP', 76, "Constant map l
iterals cannot include a type parameter as a type argument, such as '%s'"); |
| 1339 | 1370 |
| 1340 /** | 1371 /** |
| 1341 * 14.2 Exports: It is a compile-time error if the compilation unit found at t
he specified URI is | 1372 * 14.2 Exports: It is a compile-time error if the compilation unit found at t
he specified URI is |
| 1342 * not a library declaration. | 1373 * not a library declaration. |
| 1343 * | 1374 * |
| 1344 * 14.1 Imports: It is a compile-time error if the compilation unit found at t
he specified URI is | 1375 * 14.1 Imports: It is a compile-time error if the compilation unit found at t
he specified URI is |
| 1345 * not a library declaration. | 1376 * not a library declaration. |
| 1346 * | 1377 * |
| 1347 * 14.3 Parts: It is a compile time error if the contents of the URI are not a
valid part | 1378 * 14.3 Parts: It is a compile time error if the contents of the URI are not a
valid part |
| 1348 * declaration. | 1379 * declaration. |
| 1349 * | 1380 * |
| 1350 * @param uri the URI that is invalid | 1381 * @param uri the URI that is invalid |
| 1351 * @see #URI_DOES_NOT_EXIST | 1382 * @see #URI_DOES_NOT_EXIST |
| 1352 */ | 1383 */ |
| 1353 static final CompileTimeErrorCode INVALID_URI = new CompileTimeErrorCode.con1(
'INVALID_URI', 76, "Invalid URI syntax: '%s'"); | 1384 static final CompileTimeErrorCode INVALID_URI = new CompileTimeErrorCode.con1(
'INVALID_URI', 77, "Invalid URI syntax: '%s'"); |
| 1354 | 1385 |
| 1355 /** | 1386 /** |
| 1356 * 13.13 Break: It is a compile-time error if no such statement <i>s<sub>E</su
b></i> exists within | 1387 * 13.13 Break: It is a compile-time error if no such statement <i>s<sub>E</su
b></i> exists within |
| 1357 * the innermost function in which <i>s<sub>b</sub></i> occurs. | 1388 * the innermost function in which <i>s<sub>b</sub></i> occurs. |
| 1358 * | 1389 * |
| 1359 * 13.14 Continue: It is a compile-time error if no such statement or case cla
use | 1390 * 13.14 Continue: It is a compile-time error if no such statement or case cla
use |
| 1360 * <i>s<sub>E</sub></i> exists within the innermost function in which <i>s<sub
>c</sub></i> occurs. | 1391 * <i>s<sub>E</sub></i> exists within the innermost function in which <i>s<sub
>c</sub></i> occurs. |
| 1361 * | 1392 * |
| 1362 * @param labelName the name of the unresolvable label | 1393 * @param labelName the name of the unresolvable label |
| 1363 */ | 1394 */ |
| 1364 static final CompileTimeErrorCode LABEL_IN_OUTER_SCOPE = new CompileTimeErrorC
ode.con1('LABEL_IN_OUTER_SCOPE', 77, "Cannot reference label '%s' declared in an
outer method"); | 1395 static final CompileTimeErrorCode LABEL_IN_OUTER_SCOPE = new CompileTimeErrorC
ode.con1('LABEL_IN_OUTER_SCOPE', 78, "Cannot reference label '%s' declared in an
outer method"); |
| 1365 | 1396 |
| 1366 /** | 1397 /** |
| 1367 * 13.13 Break: It is a compile-time error if no such statement <i>s<sub>E</su
b></i> exists within | 1398 * 13.13 Break: It is a compile-time error if no such statement <i>s<sub>E</su
b></i> exists within |
| 1368 * the innermost function in which <i>s<sub>b</sub></i> occurs. | 1399 * the innermost function in which <i>s<sub>b</sub></i> occurs. |
| 1369 * | 1400 * |
| 1370 * 13.14 Continue: It is a compile-time error if no such statement or case cla
use | 1401 * 13.14 Continue: It is a compile-time error if no such statement or case cla
use |
| 1371 * <i>s<sub>E</sub></i> exists within the innermost function in which <i>s<sub
>c</sub></i> occurs. | 1402 * <i>s<sub>E</sub></i> exists within the innermost function in which <i>s<sub
>c</sub></i> occurs. |
| 1372 * | 1403 * |
| 1373 * @param labelName the name of the unresolvable label | 1404 * @param labelName the name of the unresolvable label |
| 1374 */ | 1405 */ |
| 1375 static final CompileTimeErrorCode LABEL_UNDEFINED = new CompileTimeErrorCode.c
on1('LABEL_UNDEFINED', 78, "Cannot reference undefined label '%s'"); | 1406 static final CompileTimeErrorCode LABEL_UNDEFINED = new CompileTimeErrorCode.c
on1('LABEL_UNDEFINED', 79, "Cannot reference undefined label '%s'"); |
| 1376 | 1407 |
| 1377 /** | 1408 /** |
| 1378 * 12.6 Lists: A run-time list literal <<i>E</i>> [<i>e<sub>1</sub></i>
... | 1409 * 12.6 Lists: A run-time list literal <<i>E</i>> [<i>e<sub>1</sub></i>
... |
| 1379 * <i>e<sub>n</sub></i>] is evaluated as follows: | 1410 * <i>e<sub>n</sub></i>] is evaluated as follows: |
| 1380 * | 1411 * |
| 1381 * * The operator []= is invoked on <i>a</i> with first argument <i>i</i> and
second argument | 1412 * * The operator []= is invoked on <i>a</i> with first argument <i>i</i> and
second argument |
| 1382 * <i>o<sub>i+1</sub></i><i>, 1 <= i <= n</i> | 1413 * <i>o<sub>i+1</sub></i><i>, 1 <= i <= n</i> |
| 1383 * | 1414 * |
| 1384 * | 1415 * |
| 1385 * 12.14.2 Binding Actuals to Formals: Let <i>T<sub>i</sub></i> be the static
type of | 1416 * 12.14.2 Binding Actuals to Formals: Let <i>T<sub>i</sub></i> be the static
type of |
| 1386 * <i>a<sub>i</sub></i>, let <i>S<sub>i</sub></i> be the type of <i>p<sub>i</s
ub>, 1 <= i <= | 1417 * <i>a<sub>i</sub></i>, let <i>S<sub>i</sub></i> be the type of <i>p<sub>i</s
ub>, 1 <= i <= |
| 1387 * n+k</i> and let <i>S<sub>q</sub></i> be the type of the named parameter <i>
q</i> of <i>f</i>. | 1418 * n+k</i> and let <i>S<sub>q</sub></i> be the type of the named parameter <i>
q</i> of <i>f</i>. |
| 1388 * It is a static warning if <i>T<sub>j</sub></i> may not be assigned to <i>S<
sub>j</sub>, 1 <= | 1419 * It is a static warning if <i>T<sub>j</sub></i> may not be assigned to <i>S<
sub>j</sub>, 1 <= |
| 1389 * j <= m</i>. | 1420 * j <= m</i>. |
| 1390 */ | 1421 */ |
| 1391 static final CompileTimeErrorCode LIST_ELEMENT_TYPE_NOT_ASSIGNABLE = new Compi
leTimeErrorCode.con1('LIST_ELEMENT_TYPE_NOT_ASSIGNABLE', 79, "The element type '
%s' cannot be assigned to the list type '%s'"); | 1422 static final CompileTimeErrorCode LIST_ELEMENT_TYPE_NOT_ASSIGNABLE = new Compi
leTimeErrorCode.con1('LIST_ELEMENT_TYPE_NOT_ASSIGNABLE', 80, "The element type '
%s' cannot be assigned to the list type '%s'"); |
| 1392 | 1423 |
| 1393 /** | 1424 /** |
| 1394 * 12.7 Map: A run-time map literal <<i>K</i>, <i>V</i>> [<i>k<sub>1</su
b></i> : | 1425 * 12.7 Map: A run-time map literal <<i>K</i>, <i>V</i>> [<i>k<sub>1</su
b></i> : |
| 1395 * <i>e<sub>1</sub></i> ... <i>k<sub>n</sub></i> : <i>e<sub>n</sub></i>] is ev
aluated as follows: | 1426 * <i>e<sub>1</sub></i> ... <i>k<sub>n</sub></i> : <i>e<sub>n</sub></i>] is ev
aluated as follows: |
| 1396 * | 1427 * |
| 1397 * * The operator []= is invoked on <i>m</i> with first argument <i>k<sub>i</s
ub></i> and second | 1428 * * The operator []= is invoked on <i>m</i> with first argument <i>k<sub>i</s
ub></i> and second |
| 1398 * argument <i>e<sub>i</sub></i><i>, 1 <= i <= n</i> | 1429 * argument <i>e<sub>i</sub></i><i>, 1 <= i <= n</i> |
| 1399 * | 1430 * |
| 1400 * | 1431 * |
| 1401 * 12.14.2 Binding Actuals to Formals: Let <i>T<sub>i</sub></i> be the static
type of | 1432 * 12.14.2 Binding Actuals to Formals: Let <i>T<sub>i</sub></i> be the static
type of |
| 1402 * <i>a<sub>i</sub></i>, let <i>S<sub>i</sub></i> be the type of <i>p<sub>i</s
ub>, 1 <= i <= | 1433 * <i>a<sub>i</sub></i>, let <i>S<sub>i</sub></i> be the type of <i>p<sub>i</s
ub>, 1 <= i <= |
| 1403 * n+k</i> and let <i>S<sub>q</sub></i> be the type of the named parameter <i>
q</i> of <i>f</i>. | 1434 * n+k</i> and let <i>S<sub>q</sub></i> be the type of the named parameter <i>
q</i> of <i>f</i>. |
| 1404 * It is a static warning if <i>T<sub>j</sub></i> may not be assigned to <i>S<
sub>j</sub>, 1 <= | 1435 * It is a static warning if <i>T<sub>j</sub></i> may not be assigned to <i>S<
sub>j</sub>, 1 <= |
| 1405 * j <= m</i>. | 1436 * j <= m</i>. |
| 1406 */ | 1437 */ |
| 1407 static final CompileTimeErrorCode MAP_KEY_TYPE_NOT_ASSIGNABLE = new CompileTim
eErrorCode.con1('MAP_KEY_TYPE_NOT_ASSIGNABLE', 80, "The element type '%s' cannot
be assigned to the map key type '%s'"); | 1438 static final CompileTimeErrorCode MAP_KEY_TYPE_NOT_ASSIGNABLE = new CompileTim
eErrorCode.con1('MAP_KEY_TYPE_NOT_ASSIGNABLE', 81, "The element type '%s' cannot
be assigned to the map key type '%s'"); |
| 1408 | 1439 |
| 1409 /** | 1440 /** |
| 1410 * 12.7 Map: A run-time map literal <<i>K</i>, <i>V</i>> [<i>k<sub>1</su
b></i> : | 1441 * 12.7 Map: A run-time map literal <<i>K</i>, <i>V</i>> [<i>k<sub>1</su
b></i> : |
| 1411 * <i>e<sub>1</sub></i> ... <i>k<sub>n</sub></i> : <i>e<sub>n</sub></i>] is ev
aluated as follows: | 1442 * <i>e<sub>1</sub></i> ... <i>k<sub>n</sub></i> : <i>e<sub>n</sub></i>] is ev
aluated as follows: |
| 1412 * | 1443 * |
| 1413 * * The operator []= is invoked on <i>m</i> with first argument <i>k<sub>i</s
ub></i> and second | 1444 * * The operator []= is invoked on <i>m</i> with first argument <i>k<sub>i</s
ub></i> and second |
| 1414 * argument <i>e<sub>i</sub></i><i>, 1 <= i <= n</i> | 1445 * argument <i>e<sub>i</sub></i><i>, 1 <= i <= n</i> |
| 1415 * | 1446 * |
| 1416 * | 1447 * |
| 1417 * 12.14.2 Binding Actuals to Formals: Let <i>T<sub>i</sub></i> be the static
type of | 1448 * 12.14.2 Binding Actuals to Formals: Let <i>T<sub>i</sub></i> be the static
type of |
| 1418 * <i>a<sub>i</sub></i>, let <i>S<sub>i</sub></i> be the type of <i>p<sub>i</s
ub>, 1 <= i <= | 1449 * <i>a<sub>i</sub></i>, let <i>S<sub>i</sub></i> be the type of <i>p<sub>i</s
ub>, 1 <= i <= |
| 1419 * n+k</i> and let <i>S<sub>q</sub></i> be the type of the named parameter <i>
q</i> of <i>f</i>. | 1450 * n+k</i> and let <i>S<sub>q</sub></i> be the type of the named parameter <i>
q</i> of <i>f</i>. |
| 1420 * It is a static warning if <i>T<sub>j</sub></i> may not be assigned to <i>S<
sub>j</sub>, 1 <= | 1451 * It is a static warning if <i>T<sub>j</sub></i> may not be assigned to <i>S<
sub>j</sub>, 1 <= |
| 1421 * j <= m</i>. | 1452 * j <= m</i>. |
| 1422 */ | 1453 */ |
| 1423 static final CompileTimeErrorCode MAP_VALUE_TYPE_NOT_ASSIGNABLE = new CompileT
imeErrorCode.con1('MAP_VALUE_TYPE_NOT_ASSIGNABLE', 81, "The element type '%s' ca
nnot be assigned to the map value type '%s'"); | 1454 static final CompileTimeErrorCode MAP_VALUE_TYPE_NOT_ASSIGNABLE = new CompileT
imeErrorCode.con1('MAP_VALUE_TYPE_NOT_ASSIGNABLE', 82, "The element type '%s' ca
nnot be assigned to the map value type '%s'"); |
| 1424 | 1455 |
| 1425 /** | 1456 /** |
| 1426 * 7 Classes: It is a compile time error if a class <i>C</i> declares a member
with the same name | 1457 * 7 Classes: It is a compile time error if a class <i>C</i> declares a member
with the same name |
| 1427 * as <i>C</i>. | 1458 * as <i>C</i>. |
| 1428 */ | 1459 */ |
| 1429 static final CompileTimeErrorCode MEMBER_WITH_CLASS_NAME = new CompileTimeErro
rCode.con1('MEMBER_WITH_CLASS_NAME', 82, "Class members cannot have the same nam
e as the enclosing class"); | 1460 static final CompileTimeErrorCode MEMBER_WITH_CLASS_NAME = new CompileTimeErro
rCode.con1('MEMBER_WITH_CLASS_NAME', 83, "Class members cannot have the same nam
e as the enclosing class"); |
| 1430 | 1461 |
| 1431 /** | 1462 /** |
| 1432 * 7.2 Getters: It is a compile-time error if a class has both a getter and a
method with the same | 1463 * 7.2 Getters: It is a compile-time error if a class has both a getter and a
method with the same |
| 1433 * name. | 1464 * name. |
| 1434 * | 1465 * |
| 1435 * @param name the conflicting name of the getter and method | 1466 * @param name the conflicting name of the getter and method |
| 1436 */ | 1467 */ |
| 1437 static final CompileTimeErrorCode METHOD_AND_GETTER_WITH_SAME_NAME = new Compi
leTimeErrorCode.con1('METHOD_AND_GETTER_WITH_SAME_NAME', 83, "'%s' cannot be use
d to name a method, there is already a getter with the same name"); | 1468 static final CompileTimeErrorCode METHOD_AND_GETTER_WITH_SAME_NAME = new Compi
leTimeErrorCode.con1('METHOD_AND_GETTER_WITH_SAME_NAME', 84, "'%s' cannot be use
d to name a method, there is already a getter with the same name"); |
| 1438 | 1469 |
| 1439 /** | 1470 /** |
| 1440 * 12.1 Constants: A constant expression is ... a constant list literal. | 1471 * 12.1 Constants: A constant expression is ... a constant list literal. |
| 1441 */ | 1472 */ |
| 1442 static final CompileTimeErrorCode MISSING_CONST_IN_LIST_LITERAL = new CompileT
imeErrorCode.con1('MISSING_CONST_IN_LIST_LITERAL', 84, "List literals must be pr
efixed with 'const' when used as a constant expression"); | 1473 static final CompileTimeErrorCode MISSING_CONST_IN_LIST_LITERAL = new CompileT
imeErrorCode.con1('MISSING_CONST_IN_LIST_LITERAL', 85, "List literals must be pr
efixed with 'const' when used as a constant expression"); |
| 1443 | 1474 |
| 1444 /** | 1475 /** |
| 1445 * 12.1 Constants: A constant expression is ... a constant map literal. | 1476 * 12.1 Constants: A constant expression is ... a constant map literal. |
| 1446 */ | 1477 */ |
| 1447 static final CompileTimeErrorCode MISSING_CONST_IN_MAP_LITERAL = new CompileTi
meErrorCode.con1('MISSING_CONST_IN_MAP_LITERAL', 85, "Map literals must be prefi
xed with 'const' when used as a constant expression"); | 1478 static final CompileTimeErrorCode MISSING_CONST_IN_MAP_LITERAL = new CompileTi
meErrorCode.con1('MISSING_CONST_IN_MAP_LITERAL', 86, "Map literals must be prefi
xed with 'const' when used as a constant expression"); |
| 1448 | 1479 |
| 1449 /** | 1480 /** |
| 1450 * 9 Mixins: It is a compile-time error if a declared or derived mixin explici
tly declares a | 1481 * 9 Mixins: It is a compile-time error if a declared or derived mixin explici
tly declares a |
| 1451 * constructor. | 1482 * constructor. |
| 1452 * | 1483 * |
| 1453 * @param typeName the name of the mixin that is invalid | 1484 * @param typeName the name of the mixin that is invalid |
| 1454 */ | 1485 */ |
| 1455 static final CompileTimeErrorCode MIXIN_DECLARES_CONSTRUCTOR = new CompileTime
ErrorCode.con1('MIXIN_DECLARES_CONSTRUCTOR', 86, "The class '%s' cannot be used
as a mixin because it declares a constructor"); | 1486 static final CompileTimeErrorCode MIXIN_DECLARES_CONSTRUCTOR = new CompileTime
ErrorCode.con1('MIXIN_DECLARES_CONSTRUCTOR', 87, "The class '%s' cannot be used
as a mixin because it declares a constructor"); |
| 1456 | 1487 |
| 1457 /** | 1488 /** |
| 1458 * 9 Mixins: It is a compile-time error if a mixin is derived from a class who
se superclass is not | 1489 * 9 Mixins: It is a compile-time error if a mixin is derived from a class who
se superclass is not |
| 1459 * Object. | 1490 * Object. |
| 1460 * | 1491 * |
| 1461 * @param typeName the name of the mixin that is invalid | 1492 * @param typeName the name of the mixin that is invalid |
| 1462 */ | 1493 */ |
| 1463 static final CompileTimeErrorCode MIXIN_INHERITS_FROM_NOT_OBJECT = new Compile
TimeErrorCode.con1('MIXIN_INHERITS_FROM_NOT_OBJECT', 87, "The class '%s' cannot
be used as a mixin because it extends a class other than Object"); | 1494 static final CompileTimeErrorCode MIXIN_INHERITS_FROM_NOT_OBJECT = new Compile
TimeErrorCode.con1('MIXIN_INHERITS_FROM_NOT_OBJECT', 88, "The class '%s' cannot
be used as a mixin because it extends a class other than Object"); |
| 1464 | 1495 |
| 1465 /** | 1496 /** |
| 1466 * 12.2 Null: It is a compile-time error for a class to attempt to extend or i
mplement Null. | 1497 * 12.2 Null: It is a compile-time error for a class to attempt to extend or i
mplement Null. |
| 1467 * | 1498 * |
| 1468 * 12.3 Numbers: It is a compile-time error for a class to attempt to extend o
r implement int. | 1499 * 12.3 Numbers: It is a compile-time error for a class to attempt to extend o
r implement int. |
| 1469 * | 1500 * |
| 1470 * 12.3 Numbers: It is a compile-time error for a class to attempt to extend o
r implement double. | 1501 * 12.3 Numbers: It is a compile-time error for a class to attempt to extend o
r implement double. |
| 1471 * | 1502 * |
| 1472 * 12.3 Numbers: It is a compile-time error for any type other than the types
int and double to | 1503 * 12.3 Numbers: It is a compile-time error for any type other than the types
int and double to |
| 1473 * attempt to extend or implement num. | 1504 * attempt to extend or implement num. |
| 1474 * | 1505 * |
| 1475 * 12.4 Booleans: It is a compile-time error for a class to attempt to extend
or implement bool. | 1506 * 12.4 Booleans: It is a compile-time error for a class to attempt to extend
or implement bool. |
| 1476 * | 1507 * |
| 1477 * 12.5 Strings: It is a compile-time error for a class to attempt to extend o
r implement String. | 1508 * 12.5 Strings: It is a compile-time error for a class to attempt to extend o
r implement String. |
| 1478 * | 1509 * |
| 1479 * @param typeName the name of the type that cannot be extended | 1510 * @param typeName the name of the type that cannot be extended |
| 1480 * @see #IMPLEMENTS_DISALLOWED_CLASS | 1511 * @see #IMPLEMENTS_DISALLOWED_CLASS |
| 1481 */ | 1512 */ |
| 1482 static final CompileTimeErrorCode MIXIN_OF_DISALLOWED_CLASS = new CompileTimeE
rrorCode.con1('MIXIN_OF_DISALLOWED_CLASS', 88, "Classes cannot mixin '%s'"); | 1513 static final CompileTimeErrorCode MIXIN_OF_DISALLOWED_CLASS = new CompileTimeE
rrorCode.con1('MIXIN_OF_DISALLOWED_CLASS', 89, "Classes cannot mixin '%s'"); |
| 1483 | 1514 |
| 1484 /** | 1515 /** |
| 1485 * 9.1 Mixin Application: It is a compile-time error if <i>M</i> does not deno
te a class or mixin | 1516 * 9.1 Mixin Application: It is a compile-time error if <i>M</i> does not deno
te a class or mixin |
| 1486 * available in the immediately enclosing scope. | 1517 * available in the immediately enclosing scope. |
| 1487 */ | 1518 */ |
| 1488 static final CompileTimeErrorCode MIXIN_OF_NON_CLASS = new CompileTimeErrorCod
e.con1('MIXIN_OF_NON_CLASS', 89, "Classes can only mixin other classes"); | 1519 static final CompileTimeErrorCode MIXIN_OF_NON_CLASS = new CompileTimeErrorCod
e.con1('MIXIN_OF_NON_CLASS', 90, "Classes can only mixin other classes"); |
| 1489 | 1520 |
| 1490 /** | 1521 /** |
| 1491 * 9 Mixins: It is a compile-time error if a declared or derived mixin refers
to super. | 1522 * 9 Mixins: It is a compile-time error if a declared or derived mixin refers
to super. |
| 1492 */ | 1523 */ |
| 1493 static final CompileTimeErrorCode MIXIN_REFERENCES_SUPER = new CompileTimeErro
rCode.con1('MIXIN_REFERENCES_SUPER', 90, "The class '%s' cannot be used as a mix
in because it references 'super'"); | 1524 static final CompileTimeErrorCode MIXIN_REFERENCES_SUPER = new CompileTimeErro
rCode.con1('MIXIN_REFERENCES_SUPER', 91, "The class '%s' cannot be used as a mix
in because it references 'super'"); |
| 1494 | 1525 |
| 1495 /** | 1526 /** |
| 1496 * 9.1 Mixin Application: It is a compile-time error if <i>S</i> does not deno
te a class available | 1527 * 9.1 Mixin Application: It is a compile-time error if <i>S</i> does not deno
te a class available |
| 1497 * in the immediately enclosing scope. | 1528 * in the immediately enclosing scope. |
| 1498 */ | 1529 */ |
| 1499 static final CompileTimeErrorCode MIXIN_WITH_NON_CLASS_SUPERCLASS = new Compil
eTimeErrorCode.con1('MIXIN_WITH_NON_CLASS_SUPERCLASS', 91, "Mixin can only be ap
plied to class"); | 1530 static final CompileTimeErrorCode MIXIN_WITH_NON_CLASS_SUPERCLASS = new Compil
eTimeErrorCode.con1('MIXIN_WITH_NON_CLASS_SUPERCLASS', 92, "Mixin can only be ap
plied to class"); |
| 1500 | 1531 |
| 1501 /** | 1532 /** |
| 1502 * 7.6.1 Generative Constructors: A generative constructor may be redirecting,
in which case its | 1533 * 7.6.1 Generative Constructors: A generative constructor may be redirecting,
in which case its |
| 1503 * only action is to invoke another generative constructor. | 1534 * only action is to invoke another generative constructor. |
| 1504 */ | 1535 */ |
| 1505 static final CompileTimeErrorCode MULTIPLE_REDIRECTING_CONSTRUCTOR_INVOCATIONS
= new CompileTimeErrorCode.con1('MULTIPLE_REDIRECTING_CONSTRUCTOR_INVOCATIONS',
92, "Constructor may have at most one 'this' redirection"); | 1536 static final CompileTimeErrorCode MULTIPLE_REDIRECTING_CONSTRUCTOR_INVOCATIONS
= new CompileTimeErrorCode.con1('MULTIPLE_REDIRECTING_CONSTRUCTOR_INVOCATIONS',
93, "Constructor may have at most one 'this' redirection"); |
| 1506 | 1537 |
| 1507 /** | 1538 /** |
| 1508 * 7.6.1 Generative Constructors: Let <i>k</i> be a generative constructor. Th
en <i>k</i> may | 1539 * 7.6.1 Generative Constructors: Let <i>k</i> be a generative constructor. Th
en <i>k</i> may |
| 1509 * include at most one superinitializer in its initializer list or a compile t
ime error occurs. | 1540 * include at most one superinitializer in its initializer list or a compile t
ime error occurs. |
| 1510 */ | 1541 */ |
| 1511 static final CompileTimeErrorCode MULTIPLE_SUPER_INITIALIZERS = new CompileTim
eErrorCode.con1('MULTIPLE_SUPER_INITIALIZERS', 93, "Constructor may have at most
one 'super' initializer"); | 1542 static final CompileTimeErrorCode MULTIPLE_SUPER_INITIALIZERS = new CompileTim
eErrorCode.con1('MULTIPLE_SUPER_INITIALIZERS', 94, "Constructor may have at most
one 'super' initializer"); |
| 1512 | 1543 |
| 1513 /** | 1544 /** |
| 1514 * 11 Metadata: Metadata consists of a series of annotations, each of which be
gin with the | 1545 * 11 Metadata: Metadata consists of a series of annotations, each of which be
gin with the |
| 1515 * character @, followed by a constant expression that must be either a refere
nce to a | 1546 * character @, followed by a constant expression that must be either a refere
nce to a |
| 1516 * compile-time constant variable, or a call to a constant constructor. | 1547 * compile-time constant variable, or a call to a constant constructor. |
| 1517 */ | 1548 */ |
| 1518 static final CompileTimeErrorCode NO_ANNOTATION_CONSTRUCTOR_ARGUMENTS = new Co
mpileTimeErrorCode.con1('NO_ANNOTATION_CONSTRUCTOR_ARGUMENTS', 94, "Annotation c
reation must have arguments"); | 1549 static final CompileTimeErrorCode NO_ANNOTATION_CONSTRUCTOR_ARGUMENTS = new Co
mpileTimeErrorCode.con1('NO_ANNOTATION_CONSTRUCTOR_ARGUMENTS', 95, "Annotation c
reation must have arguments"); |
| 1519 | 1550 |
| 1520 /** | 1551 /** |
| 1521 * 7.6.1 Generative Constructors: If no superinitializer is provided, an impli
cit superinitializer | 1552 * 7.6.1 Generative Constructors: If no superinitializer is provided, an impli
cit superinitializer |
| 1522 * of the form <b>super</b>() is added at the end of <i>k</i>'s initializer li
st, unless the | 1553 * of the form <b>super</b>() is added at the end of <i>k</i>'s initializer li
st, unless the |
| 1523 * enclosing class is class <i>Object</i>. | 1554 * enclosing class is class <i>Object</i>. |
| 1524 * | 1555 * |
| 1525 * 7.6.1 Generative constructors. It is a compile-time error if class <i>S</i>
does not declare a | 1556 * 7.6.1 Generative constructors. It is a compile-time error if class <i>S</i>
does not declare a |
| 1526 * generative constructor named <i>S</i> (respectively <i>S.id</i>) | 1557 * generative constructor named <i>S</i> (respectively <i>S.id</i>) |
| 1527 */ | 1558 */ |
| 1528 static final CompileTimeErrorCode NO_DEFAULT_SUPER_CONSTRUCTOR_EXPLICIT = new
CompileTimeErrorCode.con1('NO_DEFAULT_SUPER_CONSTRUCTOR_EXPLICIT', 95, "The clas
s '%s' does not have a default constructor"); | 1559 static final CompileTimeErrorCode NO_DEFAULT_SUPER_CONSTRUCTOR_EXPLICIT = new
CompileTimeErrorCode.con1('NO_DEFAULT_SUPER_CONSTRUCTOR_EXPLICIT', 96, "The clas
s '%s' does not have a default constructor"); |
| 1529 | 1560 |
| 1530 /** | 1561 /** |
| 1531 * 7.6 Constructors: Iff no constructor is specified for a class <i>C</i>, it
implicitly has a | 1562 * 7.6 Constructors: Iff no constructor is specified for a class <i>C</i>, it
implicitly has a |
| 1532 * default constructor C() : <b>super<b>() {}, unless <i>C</i> is class <i>Obj
ect</i>. | 1563 * default constructor C() : <b>super<b>() {}, unless <i>C</i> is class <i>Obj
ect</i>. |
| 1533 * | 1564 * |
| 1534 * 7.6.1 Generative constructors. It is a compile-time error if class <i>S</i>
does not declare a | 1565 * 7.6.1 Generative constructors. It is a compile-time error if class <i>S</i>
does not declare a |
| 1535 * generative constructor named <i>S</i> (respectively <i>S.id</i>) | 1566 * generative constructor named <i>S</i> (respectively <i>S.id</i>) |
| 1536 */ | 1567 */ |
| 1537 static final CompileTimeErrorCode NO_DEFAULT_SUPER_CONSTRUCTOR_IMPLICIT = new
CompileTimeErrorCode.con1('NO_DEFAULT_SUPER_CONSTRUCTOR_IMPLICIT', 96, "The clas
s '%s' does not have a default constructor"); | 1568 static final CompileTimeErrorCode NO_DEFAULT_SUPER_CONSTRUCTOR_IMPLICIT = new
CompileTimeErrorCode.con1('NO_DEFAULT_SUPER_CONSTRUCTOR_IMPLICIT', 97, "The clas
s '%s' does not have a default constructor"); |
| 1538 | 1569 |
| 1539 /** | 1570 /** |
| 1540 * 13.2 Expression Statements: It is a compile-time error if a non-constant ma
p literal that has | 1571 * 13.2 Expression Statements: It is a compile-time error if a non-constant ma
p literal that has |
| 1541 * no explicit type arguments appears in a place where a statement is expected
. | 1572 * no explicit type arguments appears in a place where a statement is expected
. |
| 1542 */ | 1573 */ |
| 1543 static final CompileTimeErrorCode NON_CONST_MAP_AS_EXPRESSION_STATEMENT = new
CompileTimeErrorCode.con1('NON_CONST_MAP_AS_EXPRESSION_STATEMENT', 97, "A non-co
nstant map literal without type arguments cannot be used as an expression statem
ent"); | 1574 static final CompileTimeErrorCode NON_CONST_MAP_AS_EXPRESSION_STATEMENT = new
CompileTimeErrorCode.con1('NON_CONST_MAP_AS_EXPRESSION_STATEMENT', 98, "A non-co
nstant map literal without type arguments cannot be used as an expression statem
ent"); |
| 1544 | 1575 |
| 1545 /** | 1576 /** |
| 1546 * 13.9 Switch: Given a switch statement of the form <i>switch (e) { label<sub
>11</sub> … | 1577 * 13.9 Switch: Given a switch statement of the form <i>switch (e) { label<sub
>11</sub> … |
| 1547 * label<sub>1j1</sub> case e<sub>1</sub>: s<sub>1</sub> … label<sub>n1
</sub> … | 1578 * label<sub>1j1</sub> case e<sub>1</sub>: s<sub>1</sub> … label<sub>n1
</sub> … |
| 1548 * label<sub>njn</sub> case e<sub>n</sub>: s<sub>n</sub> default: s<sub>n+1</s
ub>}</i> or the form | 1579 * label<sub>njn</sub> case e<sub>n</sub>: s<sub>n</sub> default: s<sub>n+1</s
ub>}</i> or the form |
| 1549 * <i>switch (e) { label<sub>11</sub> … label<sub>1j1</sub> case e<sub>
1</sub>: | 1580 * <i>switch (e) { label<sub>11</sub> … label<sub>1j1</sub> case e<sub>
1</sub>: |
| 1550 * s<sub>1</sub> … label<sub>n1</sub> … label<sub>njn</sub> case
e<sub>n</sub>: | 1581 * s<sub>1</sub> … label<sub>n1</sub> … label<sub>njn</sub> case
e<sub>n</sub>: |
| 1551 * s<sub>n</sub>}</i>, it is a compile-time error if the expressions <i>e<sub>
k</sub></i> are not | 1582 * s<sub>n</sub>}</i>, it is a compile-time error if the expressions <i>e<sub>
k</sub></i> are not |
| 1552 * compile-time constants, for all <i>1 <= k <= n</i>. | 1583 * compile-time constants, for all <i>1 <= k <= n</i>. |
| 1553 */ | 1584 */ |
| 1554 static final CompileTimeErrorCode NON_CONSTANT_CASE_EXPRESSION = new CompileTi
meErrorCode.con1('NON_CONSTANT_CASE_EXPRESSION', 98, "Case expressions must be c
onstant"); | 1585 static final CompileTimeErrorCode NON_CONSTANT_CASE_EXPRESSION = new CompileTi
meErrorCode.con1('NON_CONSTANT_CASE_EXPRESSION', 99, "Case expressions must be c
onstant"); |
| 1555 | 1586 |
| 1556 /** | 1587 /** |
| 1557 * 6.2.2 Optional Formals: It is a compile-time error if the default value of
an optional | 1588 * 6.2.2 Optional Formals: It is a compile-time error if the default value of
an optional |
| 1558 * parameter is not a compile-time constant. | 1589 * parameter is not a compile-time constant. |
| 1559 */ | 1590 */ |
| 1560 static final CompileTimeErrorCode NON_CONSTANT_DEFAULT_VALUE = new CompileTime
ErrorCode.con1('NON_CONSTANT_DEFAULT_VALUE', 99, "Default values of an optional
parameter must be constant"); | 1591 static final CompileTimeErrorCode NON_CONSTANT_DEFAULT_VALUE = new CompileTime
ErrorCode.con1('NON_CONSTANT_DEFAULT_VALUE', 100, "Default values of an optional
parameter must be constant"); |
| 1561 | 1592 |
| 1562 /** | 1593 /** |
| 1563 * 12.6 Lists: It is a compile time error if an element of a constant list lit
eral is not a | 1594 * 12.6 Lists: It is a compile time error if an element of a constant list lit
eral is not a |
| 1564 * compile-time constant. | 1595 * compile-time constant. |
| 1565 */ | 1596 */ |
| 1566 static final CompileTimeErrorCode NON_CONSTANT_LIST_ELEMENT = new CompileTimeE
rrorCode.con1('NON_CONSTANT_LIST_ELEMENT', 100, "'const' lists must have all con
stant values"); | 1597 static final CompileTimeErrorCode NON_CONSTANT_LIST_ELEMENT = new CompileTimeE
rrorCode.con1('NON_CONSTANT_LIST_ELEMENT', 101, "'const' lists must have all con
stant values"); |
| 1567 | 1598 |
| 1568 /** | 1599 /** |
| 1569 * 12.7 Maps: It is a compile time error if either a key or a value of an entr
y in a constant map | 1600 * 12.7 Maps: It is a compile time error if either a key or a value of an entr
y in a constant map |
| 1570 * literal is not a compile-time constant. | 1601 * literal is not a compile-time constant. |
| 1571 */ | 1602 */ |
| 1572 static final CompileTimeErrorCode NON_CONSTANT_MAP_KEY = new CompileTimeErrorC
ode.con1('NON_CONSTANT_MAP_KEY', 101, "The keys in a map must be constant"); | 1603 static final CompileTimeErrorCode NON_CONSTANT_MAP_KEY = new CompileTimeErrorC
ode.con1('NON_CONSTANT_MAP_KEY', 102, "The keys in a map must be constant"); |
| 1573 | 1604 |
| 1574 /** | 1605 /** |
| 1575 * 12.7 Maps: It is a compile time error if either a key or a value of an entr
y in a constant map | 1606 * 12.7 Maps: It is a compile time error if either a key or a value of an entr
y in a constant map |
| 1576 * literal is not a compile-time constant. | 1607 * literal is not a compile-time constant. |
| 1577 */ | 1608 */ |
| 1578 static final CompileTimeErrorCode NON_CONSTANT_MAP_VALUE = new CompileTimeErro
rCode.con1('NON_CONSTANT_MAP_VALUE', 102, "The values in a 'const' map must be c
onstant"); | 1609 static final CompileTimeErrorCode NON_CONSTANT_MAP_VALUE = new CompileTimeErro
rCode.con1('NON_CONSTANT_MAP_VALUE', 103, "The values in a 'const' map must be c
onstant"); |
| 1579 | 1610 |
| 1580 /** | 1611 /** |
| 1581 * 11 Metadata: Metadata consists of a series of annotations, each of which be
gin with the | 1612 * 11 Metadata: Metadata consists of a series of annotations, each of which be
gin with the |
| 1582 * character @, followed by a constant expression that must be either a refere
nce to a | 1613 * character @, followed by a constant expression that must be either a refere
nce to a |
| 1583 * compile-time constant variable, or a call to a constant constructor. | 1614 * compile-time constant variable, or a call to a constant constructor. |
| 1584 */ | 1615 */ |
| 1585 static final CompileTimeErrorCode NON_CONSTANT_ANNOTATION_CONSTRUCTOR = new Co
mpileTimeErrorCode.con1('NON_CONSTANT_ANNOTATION_CONSTRUCTOR', 103, "Annotation
creation can use only 'const' constructor"); | 1616 static final CompileTimeErrorCode NON_CONSTANT_ANNOTATION_CONSTRUCTOR = new Co
mpileTimeErrorCode.con1('NON_CONSTANT_ANNOTATION_CONSTRUCTOR', 104, "Annotation
creation can use only 'const' constructor"); |
| 1586 | 1617 |
| 1587 /** | 1618 /** |
| 1588 * 7.6.3 Constant Constructors: Any expression that appears within the initial
izer list of a | 1619 * 7.6.3 Constant Constructors: Any expression that appears within the initial
izer list of a |
| 1589 * constant constructor must be a potentially constant expression, or a compil
e-time error occurs. | 1620 * constant constructor must be a potentially constant expression, or a compil
e-time error occurs. |
| 1590 */ | 1621 */ |
| 1591 static final CompileTimeErrorCode NON_CONSTANT_VALUE_IN_INITIALIZER = new Comp
ileTimeErrorCode.con1('NON_CONSTANT_VALUE_IN_INITIALIZER', 104, "Initializer exp
ressions in constant constructors must be constants"); | 1622 static final CompileTimeErrorCode NON_CONSTANT_VALUE_IN_INITIALIZER = new Comp
ileTimeErrorCode.con1('NON_CONSTANT_VALUE_IN_INITIALIZER', 105, "Initializer exp
ressions in constant constructors must be constants"); |
| 1592 | 1623 |
| 1593 /** | 1624 /** |
| 1594 * 12.14.2 Binding Actuals to Formals: It is a static warning if <i>m < h</i>
or if <i>m > n</i>. | 1625 * 12.14.2 Binding Actuals to Formals: It is a static warning if <i>m < h</i>
or if <i>m > n</i>. |
| 1595 * | 1626 * |
| 1596 * 12.11.2 Const: It is a compile-time error if evaluation of a constant objec
t results in an | 1627 * 12.11.2 Const: It is a compile-time error if evaluation of a constant objec
t results in an |
| 1597 * uncaught exception being thrown. | 1628 * uncaught exception being thrown. |
| 1598 * | 1629 * |
| 1599 * @param requiredCount the expected number of required arguments | 1630 * @param requiredCount the expected number of required arguments |
| 1600 * @param argumentCount the actual number of positional arguments given | 1631 * @param argumentCount the actual number of positional arguments given |
| 1601 */ | 1632 */ |
| 1602 static final CompileTimeErrorCode NOT_ENOUGH_REQUIRED_ARGUMENTS = new CompileT
imeErrorCode.con1('NOT_ENOUGH_REQUIRED_ARGUMENTS', 105, "%d required argument(s)
expected, but %d found"); | 1633 static final CompileTimeErrorCode NOT_ENOUGH_REQUIRED_ARGUMENTS = new CompileT
imeErrorCode.con1('NOT_ENOUGH_REQUIRED_ARGUMENTS', 106, "%d required argument(s)
expected, but %d found"); |
| 1603 | 1634 |
| 1604 /** | 1635 /** |
| 1605 * 7.6.1 Generative Constructors: Let <i>C</i> be the class in which the super
initializer appears | 1636 * 7.6.1 Generative Constructors: Let <i>C</i> be the class in which the super
initializer appears |
| 1606 * and let <i>S</i> be the superclass of <i>C</i>. Let <i>k</i> be a generativ
e constructor. It is | 1637 * and let <i>S</i> be the superclass of <i>C</i>. Let <i>k</i> be a generativ
e constructor. It is |
| 1607 * a compile-time error if class <i>S</i> does not declare a generative constr
uctor named <i>S</i> | 1638 * a compile-time error if class <i>S</i> does not declare a generative constr
uctor named <i>S</i> |
| 1608 * (respectively <i>S.id</i>) | 1639 * (respectively <i>S.id</i>) |
| 1609 */ | 1640 */ |
| 1610 static final CompileTimeErrorCode NON_GENERATIVE_CONSTRUCTOR = new CompileTime
ErrorCode.con1('NON_GENERATIVE_CONSTRUCTOR', 106, "The generative constructor '%
s' expected, but factory found"); | 1641 static final CompileTimeErrorCode NON_GENERATIVE_CONSTRUCTOR = new CompileTime
ErrorCode.con1('NON_GENERATIVE_CONSTRUCTOR', 107, "The generative constructor '%
s' expected, but factory found"); |
| 1611 | 1642 |
| 1612 /** | 1643 /** |
| 1613 * 7.9 Superclasses: It is a compile-time error to specify an extends clause f
or class Object. | 1644 * 7.9 Superclasses: It is a compile-time error to specify an extends clause f
or class Object. |
| 1614 */ | 1645 */ |
| 1615 static final CompileTimeErrorCode OBJECT_CANNOT_EXTEND_ANOTHER_CLASS = new Com
pileTimeErrorCode.con1('OBJECT_CANNOT_EXTEND_ANOTHER_CLASS', 107, ""); | 1646 static final CompileTimeErrorCode OBJECT_CANNOT_EXTEND_ANOTHER_CLASS = new Com
pileTimeErrorCode.con1('OBJECT_CANNOT_EXTEND_ANOTHER_CLASS', 108, ""); |
| 1616 | 1647 |
| 1617 /** | 1648 /** |
| 1618 * 7.1.1 Operators: It is a compile-time error to declare an optional paramete
r in an operator. | 1649 * 7.1.1 Operators: It is a compile-time error to declare an optional paramete
r in an operator. |
| 1619 */ | 1650 */ |
| 1620 static final CompileTimeErrorCode OPTIONAL_PARAMETER_IN_OPERATOR = new Compile
TimeErrorCode.con1('OPTIONAL_PARAMETER_IN_OPERATOR', 108, "Optional parameters a
re not allowed when defining an operator"); | 1651 static final CompileTimeErrorCode OPTIONAL_PARAMETER_IN_OPERATOR = new Compile
TimeErrorCode.con1('OPTIONAL_PARAMETER_IN_OPERATOR', 109, "Optional parameters a
re not allowed when defining an operator"); |
| 1621 | 1652 |
| 1622 /** | 1653 /** |
| 1623 * 14.3 Parts: It is a compile time error if the contents of the URI are not a
valid part | 1654 * 14.3 Parts: It is a compile time error if the contents of the URI are not a
valid part |
| 1624 * declaration. | 1655 * declaration. |
| 1625 * | 1656 * |
| 1626 * @param uri the uri pointing to a non-library declaration | 1657 * @param uri the uri pointing to a non-library declaration |
| 1627 */ | 1658 */ |
| 1628 static final CompileTimeErrorCode PART_OF_NON_PART = new CompileTimeErrorCode.
con1('PART_OF_NON_PART', 109, "The included part '%s' must have a part-of direct
ive"); | 1659 static final CompileTimeErrorCode PART_OF_NON_PART = new CompileTimeErrorCode.
con1('PART_OF_NON_PART', 110, "The included part '%s' must have a part-of direct
ive"); |
| 1629 | 1660 |
| 1630 /** | 1661 /** |
| 1631 * 14.1 Imports: It is a compile-time error if the current library declares a
top-level member | 1662 * 14.1 Imports: It is a compile-time error if the current library declares a
top-level member |
| 1632 * named <i>p</i>. | 1663 * named <i>p</i>. |
| 1633 */ | 1664 */ |
| 1634 static final CompileTimeErrorCode PREFIX_COLLIDES_WITH_TOP_LEVEL_MEMBER = new
CompileTimeErrorCode.con1('PREFIX_COLLIDES_WITH_TOP_LEVEL_MEMBER', 110, "The nam
e '%s' is already used as an import prefix and cannot be used to name a top-leve
l element"); | 1665 static final CompileTimeErrorCode PREFIX_COLLIDES_WITH_TOP_LEVEL_MEMBER = new
CompileTimeErrorCode.con1('PREFIX_COLLIDES_WITH_TOP_LEVEL_MEMBER', 111, "The nam
e '%s' is already used as an import prefix and cannot be used to name a top-leve
l element"); |
| 1635 | 1666 |
| 1636 /** | 1667 /** |
| 1637 * 6.2.2 Optional Formals: It is a compile-time error if the name of a named o
ptional parameter | 1668 * 6.2.2 Optional Formals: It is a compile-time error if the name of a named o
ptional parameter |
| 1638 * begins with an '_' character. | 1669 * begins with an '_' character. |
| 1639 */ | 1670 */ |
| 1640 static final CompileTimeErrorCode PRIVATE_OPTIONAL_PARAMETER = new CompileTime
ErrorCode.con1('PRIVATE_OPTIONAL_PARAMETER', 111, "Named optional parameters can
not start with an underscore"); | 1671 static final CompileTimeErrorCode PRIVATE_OPTIONAL_PARAMETER = new CompileTime
ErrorCode.con1('PRIVATE_OPTIONAL_PARAMETER', 112, "Named optional parameters can
not start with an underscore"); |
| 1641 | 1672 |
| 1642 /** | 1673 /** |
| 1643 * 12.1 Constants: It is a compile-time error if the value of a compile-time c
onstant expression | 1674 * 12.1 Constants: It is a compile-time error if the value of a compile-time c
onstant expression |
| 1644 * depends on itself. | 1675 * depends on itself. |
| 1645 */ | 1676 */ |
| 1646 static final CompileTimeErrorCode RECURSIVE_COMPILE_TIME_CONSTANT = new Compil
eTimeErrorCode.con1('RECURSIVE_COMPILE_TIME_CONSTANT', 112, ""); | 1677 static final CompileTimeErrorCode RECURSIVE_COMPILE_TIME_CONSTANT = new Compil
eTimeErrorCode.con1('RECURSIVE_COMPILE_TIME_CONSTANT', 113, ""); |
| 1647 | 1678 |
| 1648 /** | 1679 /** |
| 1649 * 7.6.1 Generative Constructors: A generative constructor may be redirecting,
in which case its | 1680 * 7.6.1 Generative Constructors: A generative constructor may be redirecting,
in which case its |
| 1650 * only action is to invoke another generative constructor. | 1681 * only action is to invoke another generative constructor. |
| 1651 * | 1682 * |
| 1652 * TODO(scheglov) review this later, there are no explicit "it is a compile-ti
me error" in | 1683 * TODO(scheglov) review this later, there are no explicit "it is a compile-ti
me error" in |
| 1653 * specification. But it was added to the co19 and there is same error for fac
tories. | 1684 * specification. But it was added to the co19 and there is same error for fac
tories. |
| 1654 * | 1685 * |
| 1655 * https://code.google.com/p/dart/issues/detail?id=954 | 1686 * https://code.google.com/p/dart/issues/detail?id=954 |
| 1656 */ | 1687 */ |
| 1657 static final CompileTimeErrorCode RECURSIVE_CONSTRUCTOR_REDIRECT = new Compile
TimeErrorCode.con1('RECURSIVE_CONSTRUCTOR_REDIRECT', 113, "Cycle in redirecting
generative constructors"); | 1688 static final CompileTimeErrorCode RECURSIVE_CONSTRUCTOR_REDIRECT = new Compile
TimeErrorCode.con1('RECURSIVE_CONSTRUCTOR_REDIRECT', 114, "Cycle in redirecting
generative constructors"); |
| 1658 | 1689 |
| 1659 /** | 1690 /** |
| 1660 * 7.6.2 Factories: It is a compile-time error if a redirecting factory constr
uctor redirects to | 1691 * 7.6.2 Factories: It is a compile-time error if a redirecting factory constr
uctor redirects to |
| 1661 * itself, either directly or indirectly via a sequence of redirections. | 1692 * itself, either directly or indirectly via a sequence of redirections. |
| 1662 */ | 1693 */ |
| 1663 static final CompileTimeErrorCode RECURSIVE_FACTORY_REDIRECT = new CompileTime
ErrorCode.con1('RECURSIVE_FACTORY_REDIRECT', 114, "Cycle in redirecting factory
constructors"); | 1694 static final CompileTimeErrorCode RECURSIVE_FACTORY_REDIRECT = new CompileTime
ErrorCode.con1('RECURSIVE_FACTORY_REDIRECT', 115, "Cycle in redirecting factory
constructors"); |
| 1664 | 1695 |
| 1665 /** | 1696 /** |
| 1666 * 7.10 Superinterfaces: It is a compile-time error if the interface of a clas
s <i>C</i> is a | 1697 * 7.10 Superinterfaces: It is a compile-time error if the interface of a clas
s <i>C</i> is a |
| 1667 * superinterface of itself. | 1698 * superinterface of itself. |
| 1668 * | 1699 * |
| 1669 * 8.1 Superinterfaces: It is a compile-time error if an interface is a superi
nterface of itself. | 1700 * 8.1 Superinterfaces: It is a compile-time error if an interface is a superi
nterface of itself. |
| 1670 * | 1701 * |
| 1671 * 7.9 Superclasses: It is a compile-time error if a class <i>C</i> is a super
class of itself. | 1702 * 7.9 Superclasses: It is a compile-time error if a class <i>C</i> is a super
class of itself. |
| 1672 * | 1703 * |
| 1673 * @param className the name of the class that implements itself recursively | 1704 * @param className the name of the class that implements itself recursively |
| 1674 * @param strImplementsPath a string representation of the implements loop | 1705 * @param strImplementsPath a string representation of the implements loop |
| 1675 */ | 1706 */ |
| 1676 static final CompileTimeErrorCode RECURSIVE_INTERFACE_INHERITANCE = new Compil
eTimeErrorCode.con1('RECURSIVE_INTERFACE_INHERITANCE', 115, "'%s' cannot be a su
perinterface of itself: %s"); | 1707 static final CompileTimeErrorCode RECURSIVE_INTERFACE_INHERITANCE = new Compil
eTimeErrorCode.con1('RECURSIVE_INTERFACE_INHERITANCE', 116, "'%s' cannot be a su
perinterface of itself: %s"); |
| 1677 | 1708 |
| 1678 /** | 1709 /** |
| 1679 * 7.10 Superinterfaces: It is a compile-time error if the interface of a clas
s <i>C</i> is a | 1710 * 7.10 Superinterfaces: It is a compile-time error if the interface of a clas
s <i>C</i> is a |
| 1680 * superinterface of itself. | 1711 * superinterface of itself. |
| 1681 * | 1712 * |
| 1682 * 8.1 Superinterfaces: It is a compile-time error if an interface is a superi
nterface of itself. | 1713 * 8.1 Superinterfaces: It is a compile-time error if an interface is a superi
nterface of itself. |
| 1683 * | 1714 * |
| 1684 * 7.9 Superclasses: It is a compile-time error if a class <i>C</i> is a super
class of itself. | 1715 * 7.9 Superclasses: It is a compile-time error if a class <i>C</i> is a super
class of itself. |
| 1685 * | 1716 * |
| 1686 * @param className the name of the class that implements itself recursively | 1717 * @param className the name of the class that implements itself recursively |
| 1687 */ | 1718 */ |
| 1688 static final CompileTimeErrorCode RECURSIVE_INTERFACE_INHERITANCE_BASE_CASE_EX
TENDS = new CompileTimeErrorCode.con1('RECURSIVE_INTERFACE_INHERITANCE_BASE_CASE
_EXTENDS', 116, "'%s' cannot extend itself"); | 1719 static final CompileTimeErrorCode RECURSIVE_INTERFACE_INHERITANCE_BASE_CASE_EX
TENDS = new CompileTimeErrorCode.con1('RECURSIVE_INTERFACE_INHERITANCE_BASE_CASE
_EXTENDS', 117, "'%s' cannot extend itself"); |
| 1689 | 1720 |
| 1690 /** | 1721 /** |
| 1691 * 7.10 Superinterfaces: It is a compile-time error if the interface of a clas
s <i>C</i> is a | 1722 * 7.10 Superinterfaces: It is a compile-time error if the interface of a clas
s <i>C</i> is a |
| 1692 * superinterface of itself. | 1723 * superinterface of itself. |
| 1693 * | 1724 * |
| 1694 * 8.1 Superinterfaces: It is a compile-time error if an interface is a superi
nterface of itself. | 1725 * 8.1 Superinterfaces: It is a compile-time error if an interface is a superi
nterface of itself. |
| 1695 * | 1726 * |
| 1696 * 7.9 Superclasses: It is a compile-time error if a class <i>C</i> is a super
class of itself. | 1727 * 7.9 Superclasses: It is a compile-time error if a class <i>C</i> is a super
class of itself. |
| 1697 * | 1728 * |
| 1698 * @param className the name of the class that implements itself recursively | 1729 * @param className the name of the class that implements itself recursively |
| 1699 */ | 1730 */ |
| 1700 static final CompileTimeErrorCode RECURSIVE_INTERFACE_INHERITANCE_BASE_CASE_IM
PLEMENTS = new CompileTimeErrorCode.con1('RECURSIVE_INTERFACE_INHERITANCE_BASE_C
ASE_IMPLEMENTS', 117, "'%s' cannot implement itself"); | 1731 static final CompileTimeErrorCode RECURSIVE_INTERFACE_INHERITANCE_BASE_CASE_IM
PLEMENTS = new CompileTimeErrorCode.con1('RECURSIVE_INTERFACE_INHERITANCE_BASE_C
ASE_IMPLEMENTS', 118, "'%s' cannot implement itself"); |
| 1701 | 1732 |
| 1702 /** | 1733 /** |
| 1703 * 7.6.2 Factories: It is a compile-time error if <i>k</i> is prefixed with th
e const modifier but | 1734 * 7.6.2 Factories: It is a compile-time error if <i>k</i> is prefixed with th
e const modifier but |
| 1704 * <i>k'</i> is not a constant constructor. | 1735 * <i>k'</i> is not a constant constructor. |
| 1705 */ | 1736 */ |
| 1706 static final CompileTimeErrorCode REDIRECT_TO_NON_CONST_CONSTRUCTOR = new Comp
ileTimeErrorCode.con1('REDIRECT_TO_NON_CONST_CONSTRUCTOR', 118, "Constant factor
y constructor cannot delegate to a non-constant constructor"); | 1737 static final CompileTimeErrorCode REDIRECT_TO_NON_CONST_CONSTRUCTOR = new Comp
ileTimeErrorCode.con1('REDIRECT_TO_NON_CONST_CONSTRUCTOR', 119, "Constant factor
y constructor cannot delegate to a non-constant constructor"); |
| 1707 | 1738 |
| 1708 /** | 1739 /** |
| 1709 * 13.3 Local Variable Declaration: It is a compile-time error if <i>e</i> ref
ers to the name | 1740 * 13.3 Local Variable Declaration: It is a compile-time error if <i>e</i> ref
ers to the name |
| 1710 * <i>v</i> or the name <i>v=</i>. | 1741 * <i>v</i> or the name <i>v=</i>. |
| 1711 */ | 1742 */ |
| 1712 static final CompileTimeErrorCode REFERENCE_TO_DECLARED_VARIABLE_IN_INITIALIZE
R = new CompileTimeErrorCode.con1('REFERENCE_TO_DECLARED_VARIABLE_IN_INITIALIZER
', 119, "The name '%s' cannot be referenced in the initializer of a variable wit
h the same name"); | 1743 static final CompileTimeErrorCode REFERENCE_TO_DECLARED_VARIABLE_IN_INITIALIZE
R = new CompileTimeErrorCode.con1('REFERENCE_TO_DECLARED_VARIABLE_IN_INITIALIZER
', 120, "The name '%s' cannot be referenced in the initializer of a variable wit
h the same name"); |
| 1744 |
| 1745 /** |
| 1746 * 5 Variables: A local variable may only be referenced at a source code locat
ion that is after |
| 1747 * its initializer, if any, is complete, or a compile-time error occurs. |
| 1748 */ |
| 1749 static final CompileTimeErrorCode REFERENCED_BEFORE_DECLARATION = new CompileT
imeErrorCode.con1('REFERENCED_BEFORE_DECLARATION', 121, "Local variables cannot
be referenced before they are declared"); |
| 1713 | 1750 |
| 1714 /** | 1751 /** |
| 1715 * 12.8.1 Rethrow: It is a compile-time error if an expression of the form <i>
rethrow;</i> is not | 1752 * 12.8.1 Rethrow: It is a compile-time error if an expression of the form <i>
rethrow;</i> is not |
| 1716 * enclosed within a on-catch clause. | 1753 * enclosed within a on-catch clause. |
| 1717 */ | 1754 */ |
| 1718 static final CompileTimeErrorCode RETHROW_OUTSIDE_CATCH = new CompileTimeError
Code.con1('RETHROW_OUTSIDE_CATCH', 120, "rethrow must be inside of a catch claus
e"); | 1755 static final CompileTimeErrorCode RETHROW_OUTSIDE_CATCH = new CompileTimeError
Code.con1('RETHROW_OUTSIDE_CATCH', 122, "rethrow must be inside of a catch claus
e"); |
| 1719 | 1756 |
| 1720 /** | 1757 /** |
| 1721 * 13.11 Return: It is a compile-time error if a return statement of the form
<i>return e;</i> | 1758 * 13.11 Return: It is a compile-time error if a return statement of the form
<i>return e;</i> |
| 1722 * appears in a generative constructor. | 1759 * appears in a generative constructor. |
| 1723 */ | 1760 */ |
| 1724 static final CompileTimeErrorCode RETURN_IN_GENERATIVE_CONSTRUCTOR = new Compi
leTimeErrorCode.con1('RETURN_IN_GENERATIVE_CONSTRUCTOR', 121, "Constructors cann
ot return a value"); | 1761 static final CompileTimeErrorCode RETURN_IN_GENERATIVE_CONSTRUCTOR = new Compi
leTimeErrorCode.con1('RETURN_IN_GENERATIVE_CONSTRUCTOR', 123, "Constructors cann
ot return a value"); |
| 1725 | 1762 |
| 1726 /** | 1763 /** |
| 1727 * 12.15.4 Super Invocation: A super method invocation <i>i</i> has the form | 1764 * 12.15.4 Super Invocation: A super method invocation <i>i</i> has the form |
| 1728 * <i>super.m(a<sub>1</sub>, …, a<sub>n</sub>, x<sub>n+1</sub>: a<sub>n
+1</sub>, … | 1765 * <i>super.m(a<sub>1</sub>, …, a<sub>n</sub>, x<sub>n+1</sub>: a<sub>n
+1</sub>, … |
| 1729 * x<sub>n+k</sub>: a<sub>n+k</sub>)</i>. It is a compile-time error if a supe
r method invocation | 1766 * x<sub>n+k</sub>: a<sub>n+k</sub>)</i>. It is a compile-time error if a supe
r method invocation |
| 1730 * occurs in a top-level function or variable initializer, in an instance vari
able initializer or | 1767 * occurs in a top-level function or variable initializer, in an instance vari
able initializer or |
| 1731 * initializer list, in class Object, in a factory constructor, or in a static
method or variable | 1768 * initializer list, in class Object, in a factory constructor, or in a static
method or variable |
| 1732 * initializer. | 1769 * initializer. |
| 1733 */ | 1770 */ |
| 1734 static final CompileTimeErrorCode SUPER_IN_INVALID_CONTEXT = new CompileTimeEr
rorCode.con1('SUPER_IN_INVALID_CONTEXT', 122, "Invalid context for 'super' invoc
ation"); | 1771 static final CompileTimeErrorCode SUPER_IN_INVALID_CONTEXT = new CompileTimeEr
rorCode.con1('SUPER_IN_INVALID_CONTEXT', 124, "Invalid context for 'super' invoc
ation"); |
| 1735 | 1772 |
| 1736 /** | 1773 /** |
| 1737 * 7.6.1 Generative Constructors: A generative constructor may be redirecting,
in which case its | 1774 * 7.6.1 Generative Constructors: A generative constructor may be redirecting,
in which case its |
| 1738 * only action is to invoke another generative constructor. | 1775 * only action is to invoke another generative constructor. |
| 1739 */ | 1776 */ |
| 1740 static final CompileTimeErrorCode SUPER_IN_REDIRECTING_CONSTRUCTOR = new Compi
leTimeErrorCode.con1('SUPER_IN_REDIRECTING_CONSTRUCTOR', 123, "The redirecting c
onstructor cannot have a 'super' initializer"); | 1777 static final CompileTimeErrorCode SUPER_IN_REDIRECTING_CONSTRUCTOR = new Compi
leTimeErrorCode.con1('SUPER_IN_REDIRECTING_CONSTRUCTOR', 125, "The redirecting c
onstructor cannot have a 'super' initializer"); |
| 1741 | 1778 |
| 1742 /** | 1779 /** |
| 1743 * 7.6.1 Generative Constructors: Let <i>k</i> be a generative constructor. It
is a compile-time | 1780 * 7.6.1 Generative Constructors: Let <i>k</i> be a generative constructor. It
is a compile-time |
| 1744 * error if a generative constructor of class Object includes a superinitializ
er. | 1781 * error if a generative constructor of class Object includes a superinitializ
er. |
| 1745 */ | 1782 */ |
| 1746 static final CompileTimeErrorCode SUPER_INITIALIZER_IN_OBJECT = new CompileTim
eErrorCode.con1('SUPER_INITIALIZER_IN_OBJECT', 124, ""); | 1783 static final CompileTimeErrorCode SUPER_INITIALIZER_IN_OBJECT = new CompileTim
eErrorCode.con1('SUPER_INITIALIZER_IN_OBJECT', 126, ""); |
| 1747 | 1784 |
| 1748 /** | 1785 /** |
| 1749 * 12.11 Instance Creation: It is a static type warning if any of the type arg
uments to a | 1786 * 12.11 Instance Creation: It is a static type warning if any of the type arg
uments to a |
| 1750 * constructor of a generic type <i>G</i> invoked by a new expression or a con
stant object | 1787 * constructor of a generic type <i>G</i> invoked by a new expression or a con
stant object |
| 1751 * expression are not subtypes of the bounds of the corresponding formal type
parameters of | 1788 * expression are not subtypes of the bounds of the corresponding formal type
parameters of |
| 1752 * <i>G</i>. | 1789 * <i>G</i>. |
| 1753 * | 1790 * |
| 1754 * 12.11.1 New: If T is malformed a dynamic error occurs. In checked mode, if
T is mal-bounded a | 1791 * 12.11.1 New: If T is malformed a dynamic error occurs. In checked mode, if
T is mal-bounded a |
| 1755 * dynamic error occurs. | 1792 * dynamic error occurs. |
| 1756 * | 1793 * |
| 1757 * 12.1 Constants: It is a compile-time error if evaluation of a compile-time
constant would raise | 1794 * 12.1 Constants: It is a compile-time error if evaluation of a compile-time
constant would raise |
| 1758 * an exception. | 1795 * an exception. |
| 1759 * | 1796 * |
| 1760 * @param boundedTypeName the name of the type used in the instance creation t
hat should be | 1797 * @param boundedTypeName the name of the type used in the instance creation t
hat should be |
| 1761 * limited by the bound as specified in the class declaration | 1798 * limited by the bound as specified in the class declaration |
| 1762 * @param boundingTypeName the name of the bounding type | 1799 * @param boundingTypeName the name of the bounding type |
| 1763 * @see StaticTypeWarningCode#TYPE_ARGUMENT_NOT_MATCHING_BOUNDS | 1800 * @see StaticTypeWarningCode#TYPE_ARGUMENT_NOT_MATCHING_BOUNDS |
| 1764 */ | 1801 */ |
| 1765 static final CompileTimeErrorCode TYPE_ARGUMENT_NOT_MATCHING_BOUNDS = new Comp
ileTimeErrorCode.con1('TYPE_ARGUMENT_NOT_MATCHING_BOUNDS', 125, "'%s' does not e
xtend '%s'"); | 1802 static final CompileTimeErrorCode TYPE_ARGUMENT_NOT_MATCHING_BOUNDS = new Comp
ileTimeErrorCode.con1('TYPE_ARGUMENT_NOT_MATCHING_BOUNDS', 127, "'%s' does not e
xtend '%s'"); |
| 1766 | 1803 |
| 1767 /** | 1804 /** |
| 1768 * 15.3.1 Typedef: It is a compile-time error if a typedef refers to itself vi
a a chain of | 1805 * 15.3.1 Typedef: Any self reference, either directly, or recursively via ano
ther typedef, is a |
| 1769 * references that does not include a class declaration. | 1806 * compile time error. |
| 1770 */ | 1807 */ |
| 1771 static final CompileTimeErrorCode TYPE_ALIAS_CANNOT_REFERENCE_ITSELF = new Com
pileTimeErrorCode.con1('TYPE_ALIAS_CANNOT_REFERENCE_ITSELF', 126, "Type alias ca
n reference itself only via the bounds of its generic parameters"); | 1808 static final CompileTimeErrorCode TYPE_ALIAS_CANNOT_REFERENCE_ITSELF = new Com
pileTimeErrorCode.con1('TYPE_ALIAS_CANNOT_REFERENCE_ITSELF', 128, "Type alias ca
nnot reference itself directly or recursively via another typedef"); |
| 1772 | 1809 |
| 1773 /** | 1810 /** |
| 1774 * 12.11.2 Const: It is a compile-time error if <i>T</i> is not a class access
ible in the current | 1811 * 12.11.2 Const: It is a compile-time error if <i>T</i> is not a class access
ible in the current |
| 1775 * scope, optionally followed by type arguments. | 1812 * scope, optionally followed by type arguments. |
| 1776 */ | 1813 */ |
| 1777 static final CompileTimeErrorCode UNDEFINED_CLASS = new CompileTimeErrorCode.c
on1('UNDEFINED_CLASS', 127, "Undefined class '%s'"); | 1814 static final CompileTimeErrorCode UNDEFINED_CLASS = new CompileTimeErrorCode.c
on1('UNDEFINED_CLASS', 129, "Undefined class '%s'"); |
| 1778 | 1815 |
| 1779 /** | 1816 /** |
| 1780 * 7.6.1 Generative Constructors: Let <i>C</i> be the class in which the super
initializer appears | 1817 * 7.6.1 Generative Constructors: Let <i>C</i> be the class in which the super
initializer appears |
| 1781 * and let <i>S</i> be the superclass of <i>C</i>. Let <i>k</i> be a generativ
e constructor. It is | 1818 * and let <i>S</i> be the superclass of <i>C</i>. Let <i>k</i> be a generativ
e constructor. It is |
| 1782 * a compile-time error if class <i>S</i> does not declare a generative constr
uctor named <i>S</i> | 1819 * a compile-time error if class <i>S</i> does not declare a generative constr
uctor named <i>S</i> |
| 1783 * (respectively <i>S.id</i>) | 1820 * (respectively <i>S.id</i>) |
| 1784 */ | 1821 */ |
| 1785 static final CompileTimeErrorCode UNDEFINED_CONSTRUCTOR_IN_INITIALIZER = new C
ompileTimeErrorCode.con1('UNDEFINED_CONSTRUCTOR_IN_INITIALIZER', 128, "The class
'%s' does not have a generative constructor '%s'"); | 1822 static final CompileTimeErrorCode UNDEFINED_CONSTRUCTOR_IN_INITIALIZER = new C
ompileTimeErrorCode.con1('UNDEFINED_CONSTRUCTOR_IN_INITIALIZER', 130, "The class
'%s' does not have a generative constructor '%s'"); |
| 1786 | 1823 |
| 1787 /** | 1824 /** |
| 1788 * 7.6.1 Generative Constructors: Let <i>C</i> be the class in which the super
initializer appears | 1825 * 7.6.1 Generative Constructors: Let <i>C</i> be the class in which the super
initializer appears |
| 1789 * and let <i>S</i> be the superclass of <i>C</i>. Let <i>k</i> be a generativ
e constructor. It is | 1826 * and let <i>S</i> be the superclass of <i>C</i>. Let <i>k</i> be a generativ
e constructor. It is |
| 1790 * a compile-time error if class <i>S</i> does not declare a generative constr
uctor named <i>S</i> | 1827 * a compile-time error if class <i>S</i> does not declare a generative constr
uctor named <i>S</i> |
| 1791 * (respectively <i>S.id</i>) | 1828 * (respectively <i>S.id</i>) |
| 1792 */ | 1829 */ |
| 1793 static final CompileTimeErrorCode UNDEFINED_CONSTRUCTOR_IN_INITIALIZER_DEFAULT
= new CompileTimeErrorCode.con1('UNDEFINED_CONSTRUCTOR_IN_INITIALIZER_DEFAULT',
129, "The class '%s' does not have a default generative constructor"); | 1830 static final CompileTimeErrorCode UNDEFINED_CONSTRUCTOR_IN_INITIALIZER_DEFAULT
= new CompileTimeErrorCode.con1('UNDEFINED_CONSTRUCTOR_IN_INITIALIZER_DEFAULT',
131, "The class '%s' does not have a default generative constructor"); |
| 1794 | 1831 |
| 1795 /** | 1832 /** |
| 1796 * 12.14.3 Unqualified Invocation: If there exists a lexically visible declara
tion named | 1833 * 12.14.3 Unqualified Invocation: If there exists a lexically visible declara
tion named |
| 1797 * <i>id</i>, let <i>f<sub>id</sub></i> be the innermost such declaration. The
n: [skip]. | 1834 * <i>id</i>, let <i>f<sub>id</sub></i> be the innermost such declaration. The
n: [skip]. |
| 1798 * Otherwise, <i>i</i> is equivalent to <b>this</b>.<i>id</i>(<i>a<sub>1</sub>
</i>; ... | 1835 * Otherwise, <i>i</i> is equivalent to <b>this</b>.<i>id</i>(<i>a<sub>1</sub>
</i>; ... |
| 1799 * <i>x<sub>n+k</sub></i> : <i>a<sub>n+k</sub></i>). | 1836 * <i>x<sub>n+k</sub></i> : <i>a<sub>n+k</sub></i>). |
| 1800 * | 1837 * |
| 1801 * @param methodName the name of the method that is undefined | 1838 * @param methodName the name of the method that is undefined |
| 1802 */ | 1839 */ |
| 1803 static final CompileTimeErrorCode UNDEFINED_FUNCTION = new CompileTimeErrorCod
e.con1('UNDEFINED_FUNCTION', 130, "The function '%s' is not defined"); | 1840 static final CompileTimeErrorCode UNDEFINED_FUNCTION = new CompileTimeErrorCod
e.con1('UNDEFINED_FUNCTION', 132, "The function '%s' is not defined"); |
| 1804 | 1841 |
| 1805 /** | 1842 /** |
| 1806 * 12.14.2 Binding Actuals to Formals: Furthermore, each <i>q<sub>i</sub></i>,
<i>1<=i<=l</i>, | 1843 * 12.14.2 Binding Actuals to Formals: Furthermore, each <i>q<sub>i</sub></i>,
<i>1<=i<=l</i>, |
| 1807 * must have a corresponding named parameter in the set {<i>p<sub>n+1</sub></i
> ... | 1844 * must have a corresponding named parameter in the set {<i>p<sub>n+1</sub></i
> ... |
| 1808 * <i>p<sub>n+k</sub></i>} or a static warning occurs. | 1845 * <i>p<sub>n+k</sub></i>} or a static warning occurs. |
| 1809 * | 1846 * |
| 1810 * 12.11.2 Const: It is a compile-time error if evaluation of a constant objec
t results in an | 1847 * 12.11.2 Const: It is a compile-time error if evaluation of a constant objec
t results in an |
| 1811 * uncaught exception being thrown. | 1848 * uncaught exception being thrown. |
| 1812 * | 1849 * |
| 1813 * @param name the name of the requested named parameter | 1850 * @param name the name of the requested named parameter |
| 1814 */ | 1851 */ |
| 1815 static final CompileTimeErrorCode UNDEFINED_NAMED_PARAMETER = new CompileTimeE
rrorCode.con1('UNDEFINED_NAMED_PARAMETER', 131, "The named parameter '%s' is not
defined"); | 1852 static final CompileTimeErrorCode UNDEFINED_NAMED_PARAMETER = new CompileTimeE
rrorCode.con1('UNDEFINED_NAMED_PARAMETER', 133, "The named parameter '%s' is not
defined"); |
| 1816 | 1853 |
| 1817 /** | 1854 /** |
| 1818 * 14.2 Exports: It is a compile-time error if the compilation unit found at t
he specified URI is | 1855 * 14.2 Exports: It is a compile-time error if the compilation unit found at t
he specified URI is |
| 1819 * not a library declaration. | 1856 * not a library declaration. |
| 1820 * | 1857 * |
| 1821 * 14.1 Imports: It is a compile-time error if the compilation unit found at t
he specified URI is | 1858 * 14.1 Imports: It is a compile-time error if the compilation unit found at t
he specified URI is |
| 1822 * not a library declaration. | 1859 * not a library declaration. |
| 1823 * | 1860 * |
| 1824 * 14.3 Parts: It is a compile time error if the contents of the URI are not a
valid part | 1861 * 14.3 Parts: It is a compile time error if the contents of the URI are not a
valid part |
| 1825 * declaration. | 1862 * declaration. |
| 1826 * | 1863 * |
| 1827 * @param uri the URI pointing to a non-existent file | 1864 * @param uri the URI pointing to a non-existent file |
| 1828 * @see #INVALID_URI | 1865 * @see #INVALID_URI |
| 1829 */ | 1866 */ |
| 1830 static final CompileTimeErrorCode URI_DOES_NOT_EXIST = new CompileTimeErrorCod
e.con1('URI_DOES_NOT_EXIST', 132, "Target of URI does not exist: '%s'"); | 1867 static final CompileTimeErrorCode URI_DOES_NOT_EXIST = new CompileTimeErrorCod
e.con1('URI_DOES_NOT_EXIST', 134, "Target of URI does not exist: '%s'"); |
| 1831 | 1868 |
| 1832 /** | 1869 /** |
| 1833 * 14.1 Imports: It is a compile-time error if <i>x</i> is not a compile-time
constant, or if | 1870 * 14.1 Imports: It is a compile-time error if <i>x</i> is not a compile-time
constant, or if |
| 1834 * <i>x</i> involves string interpolation. | 1871 * <i>x</i> involves string interpolation. |
| 1835 * | 1872 * |
| 1836 * 14.3 Parts: It is a compile-time error if <i>s</i> is not a compile-time co
nstant, or if | 1873 * 14.3 Parts: It is a compile-time error if <i>s</i> is not a compile-time co
nstant, or if |
| 1837 * <i>s</i> involves string interpolation. | 1874 * <i>s</i> involves string interpolation. |
| 1838 * | 1875 * |
| 1839 * 14.5 URIs: It is a compile-time error if the string literal <i>x</i> that d
escribes a URI is | 1876 * 14.5 URIs: It is a compile-time error if the string literal <i>x</i> that d
escribes a URI is |
| 1840 * not a compile-time constant, or if <i>x</i> involves string interpolation. | 1877 * not a compile-time constant, or if <i>x</i> involves string interpolation. |
| 1841 */ | 1878 */ |
| 1842 static final CompileTimeErrorCode URI_WITH_INTERPOLATION = new CompileTimeErro
rCode.con1('URI_WITH_INTERPOLATION', 133, "URIs cannot use string interpolation"
); | 1879 static final CompileTimeErrorCode URI_WITH_INTERPOLATION = new CompileTimeErro
rCode.con1('URI_WITH_INTERPOLATION', 135, "URIs cannot use string interpolation"
); |
| 1843 | 1880 |
| 1844 /** | 1881 /** |
| 1845 * 7.1.1 Operators: It is a compile-time error if the arity of the user-declar
ed operator []= is | 1882 * 7.1.1 Operators: It is a compile-time error if the arity of the user-declar
ed operator []= is |
| 1846 * not 2. It is a compile time error if the arity of a user-declared operator
with one of the | 1883 * not 2. It is a compile time error if the arity of a user-declared operator
with one of the |
| 1847 * names: <, >, <=, >=, ==, +, /, ~/, *, %, |, ^, &, <<, >
;>, [] is not 1. | 1884 * names: <, >, <=, >=, ==, +, /, ~/, *, %, |, ^, &, <<, >
;>, [] is not 1. |
| 1848 * It is a compile time error if the arity of the user-declared operator - is
not 0 or 1. It is a | 1885 * It is a compile time error if the arity of the user-declared operator - is
not 0 or 1. It is a |
| 1849 * compile time error if the arity of the user-declared operator ~ is not 0. | 1886 * compile time error if the arity of the user-declared operator ~ is not 0. |
| 1850 * | 1887 * |
| 1851 * @param operatorName the name of the declared operator | 1888 * @param operatorName the name of the declared operator |
| 1852 * @param expectedNumberOfParameters the number of parameters expected | 1889 * @param expectedNumberOfParameters the number of parameters expected |
| 1853 * @param actualNumberOfParameters the number of parameters found in the opera
tor declaration | 1890 * @param actualNumberOfParameters the number of parameters found in the opera
tor declaration |
| 1854 */ | 1891 */ |
| 1855 static final CompileTimeErrorCode WRONG_NUMBER_OF_PARAMETERS_FOR_OPERATOR = ne
w CompileTimeErrorCode.con1('WRONG_NUMBER_OF_PARAMETERS_FOR_OPERATOR', 134, "Ope
rator '%s' should declare exactly %d parameter(s), but %d found"); | 1892 static final CompileTimeErrorCode WRONG_NUMBER_OF_PARAMETERS_FOR_OPERATOR = ne
w CompileTimeErrorCode.con1('WRONG_NUMBER_OF_PARAMETERS_FOR_OPERATOR', 136, "Ope
rator '%s' should declare exactly %d parameter(s), but %d found"); |
| 1856 | 1893 |
| 1857 /** | 1894 /** |
| 1858 * 7.1.1 Operators: It is a compile time error if the arity of the user-declar
ed operator - is not | 1895 * 7.1.1 Operators: It is a compile time error if the arity of the user-declar
ed operator - is not |
| 1859 * 0 or 1. | 1896 * 0 or 1. |
| 1860 * | 1897 * |
| 1861 * @param actualNumberOfParameters the number of parameters found in the opera
tor declaration | 1898 * @param actualNumberOfParameters the number of parameters found in the opera
tor declaration |
| 1862 */ | 1899 */ |
| 1863 static final CompileTimeErrorCode WRONG_NUMBER_OF_PARAMETERS_FOR_OPERATOR_MINU
S = new CompileTimeErrorCode.con1('WRONG_NUMBER_OF_PARAMETERS_FOR_OPERATOR_MINUS
', 135, "Operator '-' should declare 0 or 1 parameter, but %d found"); | 1900 static final CompileTimeErrorCode WRONG_NUMBER_OF_PARAMETERS_FOR_OPERATOR_MINU
S = new CompileTimeErrorCode.con1('WRONG_NUMBER_OF_PARAMETERS_FOR_OPERATOR_MINUS
', 137, "Operator '-' should declare 0 or 1 parameter, but %d found"); |
| 1864 | 1901 |
| 1865 /** | 1902 /** |
| 1866 * 7.3 Setters: It is a compile-time error if a setter's formal parameter list
does not include | 1903 * 7.3 Setters: It is a compile-time error if a setter's formal parameter list
does not include |
| 1867 * exactly one required formal parameter <i>p</i>. | 1904 * exactly one required formal parameter <i>p</i>. |
| 1868 */ | 1905 */ |
| 1869 static final CompileTimeErrorCode WRONG_NUMBER_OF_PARAMETERS_FOR_SETTER = new
CompileTimeErrorCode.con1('WRONG_NUMBER_OF_PARAMETERS_FOR_SETTER', 136, "Setters
should declare exactly one required parameter"); | 1906 static final CompileTimeErrorCode WRONG_NUMBER_OF_PARAMETERS_FOR_SETTER = new
CompileTimeErrorCode.con1('WRONG_NUMBER_OF_PARAMETERS_FOR_SETTER', 138, "Setters
should declare exactly one required parameter"); |
| 1870 static final List<CompileTimeErrorCode> values = [ | 1907 static final List<CompileTimeErrorCode> values = [ |
| 1871 AMBIGUOUS_EXPORT, | 1908 AMBIGUOUS_EXPORT, |
| 1872 ARGUMENT_DEFINITION_TEST_NON_PARAMETER, | 1909 ARGUMENT_DEFINITION_TEST_NON_PARAMETER, |
| 1873 BUILT_IN_IDENTIFIER_AS_TYPE, | 1910 BUILT_IN_IDENTIFIER_AS_TYPE, |
| 1874 BUILT_IN_IDENTIFIER_AS_TYPE_NAME, | 1911 BUILT_IN_IDENTIFIER_AS_TYPE_NAME, |
| 1875 BUILT_IN_IDENTIFIER_AS_TYPEDEF_NAME, | 1912 BUILT_IN_IDENTIFIER_AS_TYPEDEF_NAME, |
| 1876 BUILT_IN_IDENTIFIER_AS_TYPE_PARAMETER_NAME, | 1913 BUILT_IN_IDENTIFIER_AS_TYPE_PARAMETER_NAME, |
| 1877 CASE_EXPRESSION_TYPE_IMPLEMENTS_EQUALS, | 1914 CASE_EXPRESSION_TYPE_IMPLEMENTS_EQUALS, |
| 1878 COMPILE_TIME_CONSTANT_RAISES_EXCEPTION, | 1915 COMPILE_TIME_CONSTANT_RAISES_EXCEPTION, |
| 1879 CONFLICTING_GETTER_AND_METHOD, | 1916 CONFLICTING_GETTER_AND_METHOD, |
| (...skipping 19 matching lines...) Expand all Loading... |
| 1899 CONST_EVAL_THROWS_IDBZE, | 1936 CONST_EVAL_THROWS_IDBZE, |
| 1900 CONST_WITH_INVALID_TYPE_PARAMETERS, | 1937 CONST_WITH_INVALID_TYPE_PARAMETERS, |
| 1901 CONST_WITH_NON_CONST, | 1938 CONST_WITH_NON_CONST, |
| 1902 CONST_WITH_NON_CONSTANT_ARGUMENT, | 1939 CONST_WITH_NON_CONSTANT_ARGUMENT, |
| 1903 CONST_WITH_NON_TYPE, | 1940 CONST_WITH_NON_TYPE, |
| 1904 CONST_WITH_TYPE_PARAMETERS, | 1941 CONST_WITH_TYPE_PARAMETERS, |
| 1905 CONST_WITH_UNDEFINED_CONSTRUCTOR, | 1942 CONST_WITH_UNDEFINED_CONSTRUCTOR, |
| 1906 CONST_WITH_UNDEFINED_CONSTRUCTOR_DEFAULT, | 1943 CONST_WITH_UNDEFINED_CONSTRUCTOR_DEFAULT, |
| 1907 DEFAULT_VALUE_IN_FUNCTION_TYPE_ALIAS, | 1944 DEFAULT_VALUE_IN_FUNCTION_TYPE_ALIAS, |
| 1908 DEFAULT_VALUE_IN_FUNCTION_TYPED_PARAMETER, | 1945 DEFAULT_VALUE_IN_FUNCTION_TYPED_PARAMETER, |
| 1946 DEFAULT_VALUE_IN_REDIRECTING_FACTORY_CONSTRUCTOR, |
| 1909 DUPLICATE_CONSTRUCTOR_DEFAULT, | 1947 DUPLICATE_CONSTRUCTOR_DEFAULT, |
| 1910 DUPLICATE_CONSTRUCTOR_NAME, | 1948 DUPLICATE_CONSTRUCTOR_NAME, |
| 1911 DUPLICATE_DEFINITION, | 1949 DUPLICATE_DEFINITION, |
| 1912 DUPLICATE_DEFINITION_INHERITANCE, | 1950 DUPLICATE_DEFINITION_INHERITANCE, |
| 1913 DUPLICATE_NAMED_ARGUMENT, | 1951 DUPLICATE_NAMED_ARGUMENT, |
| 1914 EXPORT_INTERNAL_LIBRARY, | 1952 EXPORT_INTERNAL_LIBRARY, |
| 1915 EXPORT_OF_NON_LIBRARY, | 1953 EXPORT_OF_NON_LIBRARY, |
| 1916 EXTENDS_NON_CLASS, | 1954 EXTENDS_NON_CLASS, |
| 1917 EXTENDS_DISALLOWED_CLASS, | 1955 EXTENDS_DISALLOWED_CLASS, |
| 1918 EXTRA_POSITIONAL_ARGUMENTS, | 1956 EXTRA_POSITIONAL_ARGUMENTS, |
| (...skipping 62 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1981 PREFIX_COLLIDES_WITH_TOP_LEVEL_MEMBER, | 2019 PREFIX_COLLIDES_WITH_TOP_LEVEL_MEMBER, |
| 1982 PRIVATE_OPTIONAL_PARAMETER, | 2020 PRIVATE_OPTIONAL_PARAMETER, |
| 1983 RECURSIVE_COMPILE_TIME_CONSTANT, | 2021 RECURSIVE_COMPILE_TIME_CONSTANT, |
| 1984 RECURSIVE_CONSTRUCTOR_REDIRECT, | 2022 RECURSIVE_CONSTRUCTOR_REDIRECT, |
| 1985 RECURSIVE_FACTORY_REDIRECT, | 2023 RECURSIVE_FACTORY_REDIRECT, |
| 1986 RECURSIVE_INTERFACE_INHERITANCE, | 2024 RECURSIVE_INTERFACE_INHERITANCE, |
| 1987 RECURSIVE_INTERFACE_INHERITANCE_BASE_CASE_EXTENDS, | 2025 RECURSIVE_INTERFACE_INHERITANCE_BASE_CASE_EXTENDS, |
| 1988 RECURSIVE_INTERFACE_INHERITANCE_BASE_CASE_IMPLEMENTS, | 2026 RECURSIVE_INTERFACE_INHERITANCE_BASE_CASE_IMPLEMENTS, |
| 1989 REDIRECT_TO_NON_CONST_CONSTRUCTOR, | 2027 REDIRECT_TO_NON_CONST_CONSTRUCTOR, |
| 1990 REFERENCE_TO_DECLARED_VARIABLE_IN_INITIALIZER, | 2028 REFERENCE_TO_DECLARED_VARIABLE_IN_INITIALIZER, |
| 2029 REFERENCED_BEFORE_DECLARATION, |
| 1991 RETHROW_OUTSIDE_CATCH, | 2030 RETHROW_OUTSIDE_CATCH, |
| 1992 RETURN_IN_GENERATIVE_CONSTRUCTOR, | 2031 RETURN_IN_GENERATIVE_CONSTRUCTOR, |
| 1993 SUPER_IN_INVALID_CONTEXT, | 2032 SUPER_IN_INVALID_CONTEXT, |
| 1994 SUPER_IN_REDIRECTING_CONSTRUCTOR, | 2033 SUPER_IN_REDIRECTING_CONSTRUCTOR, |
| 1995 SUPER_INITIALIZER_IN_OBJECT, | 2034 SUPER_INITIALIZER_IN_OBJECT, |
| 1996 TYPE_ARGUMENT_NOT_MATCHING_BOUNDS, | 2035 TYPE_ARGUMENT_NOT_MATCHING_BOUNDS, |
| 1997 TYPE_ALIAS_CANNOT_REFERENCE_ITSELF, | 2036 TYPE_ALIAS_CANNOT_REFERENCE_ITSELF, |
| 1998 UNDEFINED_CLASS, | 2037 UNDEFINED_CLASS, |
| 1999 UNDEFINED_CONSTRUCTOR_IN_INITIALIZER, | 2038 UNDEFINED_CONSTRUCTOR_IN_INITIALIZER, |
| 2000 UNDEFINED_CONSTRUCTOR_IN_INITIALIZER_DEFAULT, | 2039 UNDEFINED_CONSTRUCTOR_IN_INITIALIZER_DEFAULT, |
| (...skipping 187 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2188 */ | 2227 */ |
| 2189 static final StaticWarningCode CASE_BLOCK_NOT_TERMINATED = new StaticWarningCo
de.con1('CASE_BLOCK_NOT_TERMINATED', 5, "The last statement of the 'case' should
be 'break', 'continue', 'return' or 'throw'"); | 2228 static final StaticWarningCode CASE_BLOCK_NOT_TERMINATED = new StaticWarningCo
de.con1('CASE_BLOCK_NOT_TERMINATED', 5, "The last statement of the 'case' should
be 'break', 'continue', 'return' or 'throw'"); |
| 2190 | 2229 |
| 2191 /** | 2230 /** |
| 2192 * 12.32 Type Cast: It is a static warning if <i>T</i> does not denote a type
available in the | 2231 * 12.32 Type Cast: It is a static warning if <i>T</i> does not denote a type
available in the |
| 2193 * current lexical scope. | 2232 * current lexical scope. |
| 2194 */ | 2233 */ |
| 2195 static final StaticWarningCode CAST_TO_NON_TYPE = new StaticWarningCode.con1('
CAST_TO_NON_TYPE', 6, "The name '%s' is not a type and cannot be used in an 'as'
expression"); | 2234 static final StaticWarningCode CAST_TO_NON_TYPE = new StaticWarningCode.con1('
CAST_TO_NON_TYPE', 6, "The name '%s' is not a type and cannot be used in an 'as'
expression"); |
| 2196 | 2235 |
| 2197 /** | 2236 /** |
| 2198 * 16.1.2 Comments: A token of the form <i>[new c](uri)</i> will be replaced b
y a link in the | |
| 2199 * formatted output. The link will point at the constructor named <i>c</i> in
<i>L</i>. The title | |
| 2200 * of the link will be <i>c</i>. It is a static warning if uri is not the URI
of a dart library | |
| 2201 * <i>L</i>, or if <i>c</i> is not the name of a constructor of a class declar
ed in the exported | |
| 2202 * namespace of <i>L</i>. | |
| 2203 */ | |
| 2204 static final StaticWarningCode COMMENT_REFERENCE_CONSTRUCTOR_NOT_VISIBLE = new
StaticWarningCode.con1('COMMENT_REFERENCE_CONSTRUCTOR_NOT_VISIBLE', 7, ""); | |
| 2205 | |
| 2206 /** | |
| 2207 * 16.1.2 Comments: A token of the form <i>[id](uri)</i> will be replaced by a
link in the | |
| 2208 * formatted output. The link will point at the declaration named <i>id</i> in
<i>L</i>. The title | |
| 2209 * of the link will be <i>id</i>. It is a static warning if uri is not the URI
of a dart library | |
| 2210 * <i>L</i>, or if <i>id</i> is not a name declared in the exported namespace
of <i>L</i>. | |
| 2211 */ | |
| 2212 static final StaticWarningCode COMMENT_REFERENCE_IDENTIFIER_NOT_VISIBLE = new
StaticWarningCode.con1('COMMENT_REFERENCE_IDENTIFIER_NOT_VISIBLE', 8, ""); | |
| 2213 | |
| 2214 /** | |
| 2215 * 16.1.2 Comments: It is a static warning if <i>c</i> does not denote a const
ructor that | |
| 2216 * available in the scope of the documentation comment. | |
| 2217 */ | |
| 2218 static final StaticWarningCode COMMENT_REFERENCE_UNDECLARED_CONSTRUCTOR = new
StaticWarningCode.con1('COMMENT_REFERENCE_UNDECLARED_CONSTRUCTOR', 9, ""); | |
| 2219 | |
| 2220 /** | |
| 2221 * 16.1.2 Comments: It is a static warning if <i>id</i> does not denote a decl
aration that | |
| 2222 * available in the scope of the documentation comment. | |
| 2223 */ | |
| 2224 static final StaticWarningCode COMMENT_REFERENCE_UNDECLARED_IDENTIFIER = new S
taticWarningCode.con1('COMMENT_REFERENCE_UNDECLARED_IDENTIFIER', 10, ""); | |
| 2225 | |
| 2226 /** | |
| 2227 * 16.1.2 Comments: A token of the form <i>[id](uri)</i> will be replaced by a
link in the | |
| 2228 * formatted output. The link will point at the declaration named <i>id</i> in
<i>L</i>. The title | |
| 2229 * of the link will be <i>id</i>. It is a static warning if uri is not the URI
of a dart library | |
| 2230 * <i>L</i>, or if <i>id</i> is not a name declared in the exported namespace
of <i>L</i>. | |
| 2231 */ | |
| 2232 static final StaticWarningCode COMMENT_REFERENCE_URI_NOT_LIBRARY = new StaticW
arningCode.con1('COMMENT_REFERENCE_URI_NOT_LIBRARY', 11, ""); | |
| 2233 | |
| 2234 /** | |
| 2235 * 7.4 Abstract Instance Members: It is a static warning if an abstract member
is declared or | 2237 * 7.4 Abstract Instance Members: It is a static warning if an abstract member
is declared or |
| 2236 * inherited in a concrete class. | 2238 * inherited in a concrete class. |
| 2237 */ | 2239 */ |
| 2238 static final StaticWarningCode CONCRETE_CLASS_WITH_ABSTRACT_MEMBER = new Stati
cWarningCode.con1('CONCRETE_CLASS_WITH_ABSTRACT_MEMBER', 12, "'%s' must have a m
ethod body because '%s' is not abstract"); | 2240 static final StaticWarningCode CONCRETE_CLASS_WITH_ABSTRACT_MEMBER = new Stati
cWarningCode.con1('CONCRETE_CLASS_WITH_ABSTRACT_MEMBER', 7, "'%s' must have a me
thod body because '%s' is not abstract"); |
| 2239 | 2241 |
| 2240 /** | 2242 /** |
| 2241 * 14.1 Imports: If a name <i>N</i> is referenced by a library <i>L</i> and <i
>N</i> would be | 2243 * 14.1 Imports: If a name <i>N</i> is referenced by a library <i>L</i> and <i
>N</i> would be |
| 2242 * introduced into the top level scope of <i>L</i> by an import from a library
whose URI begins | 2244 * introduced into the top level scope of <i>L</i> by an import from a library
whose URI begins |
| 2243 * with <i>dart:</i> and an import from a library whose URI does not begin wit
h <i>dart:</i>: | 2245 * with <i>dart:</i> and an import from a library whose URI does not begin wit
h <i>dart:</i>: |
| 2244 * | 2246 * |
| 2245 * * The import from <i>dart:</i> is implicitly extended by a hide N clause. | 2247 * * The import from <i>dart:</i> is implicitly extended by a hide N clause. |
| 2246 * * A static warning is issued. | 2248 * * A static warning is issued. |
| 2247 * | 2249 * |
| 2248 * | 2250 * |
| 2249 * @param ambiguousName the ambiguous name | 2251 * @param ambiguousName the ambiguous name |
| 2250 * @param sdkLibraryName the name of the dart: library that the element is fou
nd | 2252 * @param sdkLibraryName the name of the dart: library that the element is fou
nd |
| 2251 * @param otherLibraryName the name of the non-dart: library that the element
is found | 2253 * @param otherLibraryName the name of the non-dart: library that the element
is found |
| 2252 */ | 2254 */ |
| 2253 static final StaticWarningCode CONFLICTING_DART_IMPORT = new StaticWarningCode
.con1('CONFLICTING_DART_IMPORT', 13, "Element '%s' from SDK library '%s' is impl
icitly hidden by '%s'"); | 2255 static final StaticWarningCode CONFLICTING_DART_IMPORT = new StaticWarningCode
.con1('CONFLICTING_DART_IMPORT', 8, "Element '%s' from SDK library '%s' is impli
citly hidden by '%s'"); |
| 2254 | 2256 |
| 2255 /** | 2257 /** |
| 2256 * 7.2 Getters: It is a static warning if a class <i>C</i> declares an instanc
e getter named | 2258 * 7.2 Getters: It is a static warning if a class <i>C</i> declares an instanc
e getter named |
| 2257 * <i>v</i> and an accessible static member named <i>v</i> or <i>v=</i> is dec
lared in a | 2259 * <i>v</i> and an accessible static member named <i>v</i> or <i>v=</i> is dec
lared in a |
| 2258 * superclass of <i>C</i>. | 2260 * superclass of <i>C</i>. |
| 2259 * | 2261 * |
| 2260 * @param superName the name of the super class declaring a static member | 2262 * @param superName the name of the super class declaring a static member |
| 2261 */ | 2263 */ |
| 2262 static final StaticWarningCode CONFLICTING_INSTANCE_GETTER_AND_SUPERCLASS_MEMB
ER = new StaticWarningCode.con1('CONFLICTING_INSTANCE_GETTER_AND_SUPERCLASS_MEMB
ER', 14, "Superclass '%s' declares static member with the same name"); | 2264 static final StaticWarningCode CONFLICTING_INSTANCE_GETTER_AND_SUPERCLASS_MEMB
ER = new StaticWarningCode.con1('CONFLICTING_INSTANCE_GETTER_AND_SUPERCLASS_MEMB
ER', 9, "Superclass '%s' declares static member with the same name"); |
| 2263 | 2265 |
| 2264 /** | 2266 /** |
| 2265 * 7.3 Setters: It is a static warning if a class <i>C</i> declares an instanc
e setter named | 2267 * 7.3 Setters: It is a static warning if a class <i>C</i> declares an instanc
e setter named |
| 2266 * <i>v=</i> and an accessible static member named <i>v=</i> or <i>v</i> is de
clared in a | 2268 * <i>v=</i> and an accessible static member named <i>v=</i> or <i>v</i> is de
clared in a |
| 2267 * superclass of <i>C</i>. | 2269 * superclass of <i>C</i>. |
| 2268 * | 2270 * |
| 2269 * @param superName the name of the super class declaring a static member | 2271 * @param superName the name of the super class declaring a static member |
| 2270 */ | 2272 */ |
| 2271 static final StaticWarningCode CONFLICTING_INSTANCE_SETTER_AND_SUPERCLASS_MEMB
ER = new StaticWarningCode.con1('CONFLICTING_INSTANCE_SETTER_AND_SUPERCLASS_MEMB
ER', 15, "Superclass '%s' declares static member with the same name"); | 2273 static final StaticWarningCode CONFLICTING_INSTANCE_SETTER_AND_SUPERCLASS_MEMB
ER = new StaticWarningCode.con1('CONFLICTING_INSTANCE_SETTER_AND_SUPERCLASS_MEMB
ER', 10, "Superclass '%s' declares static member with the same name"); |
| 2272 | 2274 |
| 2273 /** | 2275 /** |
| 2274 * 7.2 Getters: It is a static warning if a class declares a static getter nam
ed <i>v</i> and also | 2276 * 7.2 Getters: It is a static warning if a class declares a static getter nam
ed <i>v</i> and also |
| 2275 * has a non-static setter named <i>v=</i>. | 2277 * has a non-static setter named <i>v=</i>. |
| 2276 */ | 2278 */ |
| 2277 static final StaticWarningCode CONFLICTING_STATIC_GETTER_AND_INSTANCE_SETTER =
new StaticWarningCode.con1('CONFLICTING_STATIC_GETTER_AND_INSTANCE_SETTER', 16,
"Class '%s' declares non-static setter with the same name"); | 2279 static final StaticWarningCode CONFLICTING_STATIC_GETTER_AND_INSTANCE_SETTER =
new StaticWarningCode.con1('CONFLICTING_STATIC_GETTER_AND_INSTANCE_SETTER', 11,
"Class '%s' declares non-static setter with the same name"); |
| 2278 | 2280 |
| 2279 /** | 2281 /** |
| 2280 * 7.3 Setters: It is a static warning if a class declares a static setter nam
ed <i>v=</i> and | 2282 * 7.3 Setters: It is a static warning if a class declares a static setter nam
ed <i>v=</i> and |
| 2281 * also has a non-static member named <i>v</i>. | 2283 * also has a non-static member named <i>v</i>. |
| 2282 */ | 2284 */ |
| 2283 static final StaticWarningCode CONFLICTING_STATIC_SETTER_AND_INSTANCE_MEMBER =
new StaticWarningCode.con1('CONFLICTING_STATIC_SETTER_AND_INSTANCE_MEMBER', 17,
"Class '%s' declares non-static member with the same name"); | 2285 static final StaticWarningCode CONFLICTING_STATIC_SETTER_AND_INSTANCE_MEMBER =
new StaticWarningCode.con1('CONFLICTING_STATIC_SETTER_AND_INSTANCE_MEMBER', 12,
"Class '%s' declares non-static member with the same name"); |
| 2284 | 2286 |
| 2285 /** | 2287 /** |
| 2286 * 12.11.2 Const: Given an instance creation expression of the form <i>const q
(a<sub>1</sub>, | 2288 * 12.11.2 Const: Given an instance creation expression of the form <i>const q
(a<sub>1</sub>, |
| 2287 * … a<sub>n</sub>)</i> it is a static warning if <i>q</i> is the const
ructor of an | 2289 * … a<sub>n</sub>)</i> it is a static warning if <i>q</i> is the const
ructor of an |
| 2288 * abstract class but <i>q</i> is not a factory constructor. | 2290 * abstract class but <i>q</i> is not a factory constructor. |
| 2289 */ | 2291 */ |
| 2290 static final StaticWarningCode CONST_WITH_ABSTRACT_CLASS = new StaticWarningCo
de.con1('CONST_WITH_ABSTRACT_CLASS', 18, "Abstract classes cannot be created wit
h a 'const' expression"); | 2292 static final StaticWarningCode CONST_WITH_ABSTRACT_CLASS = new StaticWarningCo
de.con1('CONST_WITH_ABSTRACT_CLASS', 13, "Abstract classes cannot be created wit
h a 'const' expression"); |
| 2291 | 2293 |
| 2292 /** | 2294 /** |
| 2293 * 12.7 Maps: It is a static warning if the values of any two keys in a map li
teral are equal. | 2295 * 12.7 Maps: It is a static warning if the values of any two keys in a map li
teral are equal. |
| 2294 */ | 2296 */ |
| 2295 static final StaticWarningCode EQUAL_KEYS_IN_MAP = new StaticWarningCode.con1(
'EQUAL_KEYS_IN_MAP', 19, "Keys in a map cannot be equal"); | 2297 static final StaticWarningCode EQUAL_KEYS_IN_MAP = new StaticWarningCode.con1(
'EQUAL_KEYS_IN_MAP', 14, "Keys in a map cannot be equal"); |
| 2296 | 2298 |
| 2297 /** | 2299 /** |
| 2298 * 14.2 Exports: It is a static warning to export two different libraries with
the same name. | 2300 * 14.2 Exports: It is a static warning to export two different libraries with
the same name. |
| 2299 * | 2301 * |
| 2300 * @param uri1 the uri pointing to a first library | 2302 * @param uri1 the uri pointing to a first library |
| 2301 * @param uri2 the uri pointing to a second library | 2303 * @param uri2 the uri pointing to a second library |
| 2302 * @param name the shared name of the exported libraries | 2304 * @param name the shared name of the exported libraries |
| 2303 */ | 2305 */ |
| 2304 static final StaticWarningCode EXPORT_DUPLICATED_LIBRARY_NAME = new StaticWarn
ingCode.con1('EXPORT_DUPLICATED_LIBRARY_NAME', 20, "The exported libraries '%s'
and '%s' should not have the same name '%s'"); | 2306 static final StaticWarningCode EXPORT_DUPLICATED_LIBRARY_NAME = new StaticWarn
ingCode.con1('EXPORT_DUPLICATED_LIBRARY_NAME', 15, "The exported libraries '%s'
and '%s' should not have the same name '%s'"); |
| 2305 | 2307 |
| 2306 /** | 2308 /** |
| 2307 * 12.14.2 Binding Actuals to Formals: It is a static warning if <i>m < h</
i> or if <i>m > | 2309 * 12.14.2 Binding Actuals to Formals: It is a static warning if <i>m < h</
i> or if <i>m > |
| 2308 * n</i>. | 2310 * n</i>. |
| 2309 * | 2311 * |
| 2310 * @param requiredCount the maximum number of positional arguments | 2312 * @param requiredCount the maximum number of positional arguments |
| 2311 * @param argumentCount the actual number of positional arguments given | 2313 * @param argumentCount the actual number of positional arguments given |
| 2312 * @see #NOT_ENOUGH_REQUIRED_ARGUMENTS | 2314 * @see #NOT_ENOUGH_REQUIRED_ARGUMENTS |
| 2313 */ | 2315 */ |
| 2314 static final StaticWarningCode EXTRA_POSITIONAL_ARGUMENTS = new StaticWarningC
ode.con1('EXTRA_POSITIONAL_ARGUMENTS', 21, "%d positional arguments expected, bu
t %d found"); | 2316 static final StaticWarningCode EXTRA_POSITIONAL_ARGUMENTS = new StaticWarningC
ode.con1('EXTRA_POSITIONAL_ARGUMENTS', 16, "%d positional arguments expected, bu
t %d found"); |
| 2315 | 2317 |
| 2316 /** | 2318 /** |
| 2317 * 5. Variables: It is a static warning if a final instance variable that has
been initialized at | 2319 * 5. Variables: It is a static warning if a final instance variable that has
been initialized at |
| 2318 * its point of declaration is also initialized in a constructor. | 2320 * its point of declaration is also initialized in a constructor. |
| 2319 */ | 2321 */ |
| 2320 static final StaticWarningCode FIELD_INITIALIZED_IN_INITIALIZER_AND_DECLARATIO
N = new StaticWarningCode.con1('FIELD_INITIALIZED_IN_INITIALIZER_AND_DECLARATION
', 22, "Values cannot be set in the constructor if they are final, and have alre
ady been set"); | 2322 static final StaticWarningCode FIELD_INITIALIZED_IN_INITIALIZER_AND_DECLARATIO
N = new StaticWarningCode.con1('FIELD_INITIALIZED_IN_INITIALIZER_AND_DECLARATION
', 17, "Values cannot be set in the constructor if they are final, and have alre
ady been set"); |
| 2321 | 2323 |
| 2322 /** | 2324 /** |
| 2323 * 5. Variables: It is a static warning if a final instance variable that has
been initialized at | 2325 * 5. Variables: It is a static warning if a final instance variable that has
been initialized at |
| 2324 * its point of declaration is also initialized in a constructor. | 2326 * its point of declaration is also initialized in a constructor. |
| 2325 * | 2327 * |
| 2326 * @param name the name of the field in question | 2328 * @param name the name of the field in question |
| 2327 */ | 2329 */ |
| 2328 static final StaticWarningCode FINAL_INITIALIZED_IN_DECLARATION_AND_CONSTRUCTO
R = new StaticWarningCode.con1('FINAL_INITIALIZED_IN_DECLARATION_AND_CONSTRUCTOR
', 23, "'%s' is final and was given a value when it was declared, so it cannot b
e set to a new value"); | 2330 static final StaticWarningCode FINAL_INITIALIZED_IN_DECLARATION_AND_CONSTRUCTO
R = new StaticWarningCode.con1('FINAL_INITIALIZED_IN_DECLARATION_AND_CONSTRUCTOR
', 18, "'%s' is final and was given a value when it was declared, so it cannot b
e set to a new value"); |
| 2329 | 2331 |
| 2330 /** | 2332 /** |
| 2331 * 7.6.1 Generative Constructors: Execution of an initializer of the form <b>t
his</b>.<i>v</i> = | 2333 * 7.6.1 Generative Constructors: Execution of an initializer of the form <b>t
his</b>.<i>v</i> = |
| 2332 * <i>e</i> proceeds as follows: First, the expression <i>e</i> is evaluated t
o an object | 2334 * <i>e</i> proceeds as follows: First, the expression <i>e</i> is evaluated t
o an object |
| 2333 * <i>o</i>. Then, the instance variable <i>v</i> of the object denoted by thi
s is bound to | 2335 * <i>o</i>. Then, the instance variable <i>v</i> of the object denoted by thi
s is bound to |
| 2334 * <i>o</i>. | 2336 * <i>o</i>. |
| 2335 * | 2337 * |
| 2336 * 12.14.2 Binding Actuals to Formals: Let <i>T<sub>i</sub></i> be the static
type of | 2338 * 12.14.2 Binding Actuals to Formals: Let <i>T<sub>i</sub></i> be the static
type of |
| 2337 * <i>a<sub>i</sub></i>, let <i>S<sub>i</sub></i> be the type of <i>p<sub>i</s
ub>, 1 <= i <= | 2339 * <i>a<sub>i</sub></i>, let <i>S<sub>i</sub></i> be the type of <i>p<sub>i</s
ub>, 1 <= i <= |
| 2338 * n+k</i> and let <i>S<sub>q</sub></i> be the type of the named parameter <i>
q</i> of <i>f</i>. | 2340 * n+k</i> and let <i>S<sub>q</sub></i> be the type of the named parameter <i>
q</i> of <i>f</i>. |
| 2339 * It is a static warning if <i>T<sub>j</sub></i> may not be assigned to <i>S<
sub>j</sub>, 1 <= | 2341 * It is a static warning if <i>T<sub>j</sub></i> may not be assigned to <i>S<
sub>j</sub>, 1 <= |
| 2340 * j <= m</i>. | 2342 * j <= m</i>. |
| 2341 * | 2343 * |
| 2342 * @param initializerType the name of the type of the initializer expression | 2344 * @param initializerType the name of the type of the initializer expression |
| 2343 * @param fieldType the name of the type of the field | 2345 * @param fieldType the name of the type of the field |
| 2344 */ | 2346 */ |
| 2345 static final StaticWarningCode FIELD_INITIALIZER_NOT_ASSIGNABLE = new StaticWa
rningCode.con1('FIELD_INITIALIZER_NOT_ASSIGNABLE', 24, "The initializer type '%s
' cannot be assigned to the field type '%s'"); | 2347 static final StaticWarningCode FIELD_INITIALIZER_NOT_ASSIGNABLE = new StaticWa
rningCode.con1('FIELD_INITIALIZER_NOT_ASSIGNABLE', 19, "The initializer type '%s
' cannot be assigned to the field type '%s'"); |
| 2346 | 2348 |
| 2347 /** | 2349 /** |
| 2348 * 7.6.1 Generative Constructors: An initializing formal has the form <i>this.
id</i>. It is a | 2350 * 7.6.1 Generative Constructors: An initializing formal has the form <i>this.
id</i>. It is a |
| 2349 * static warning if the static type of <i>id</i> is not assignable to <i>T<su
b>id</sub></i>. | 2351 * static warning if the static type of <i>id</i> is not assignable to <i>T<su
b>id</sub></i>. |
| 2350 * | 2352 * |
| 2351 * @param parameterType the name of the type of the field formal parameter | 2353 * @param parameterType the name of the type of the field formal parameter |
| 2352 * @param fieldType the name of the type of the field | 2354 * @param fieldType the name of the type of the field |
| 2353 */ | 2355 */ |
| 2354 static final StaticWarningCode FIELD_INITIALIZING_FORMAL_NOT_ASSIGNABLE = new
StaticWarningCode.con1('FIELD_INITIALIZING_FORMAL_NOT_ASSIGNABLE', 25, "The para
meter type '%s' is incompatable with the field type '%s'"); | 2356 static final StaticWarningCode FIELD_INITIALIZING_FORMAL_NOT_ASSIGNABLE = new
StaticWarningCode.con1('FIELD_INITIALIZING_FORMAL_NOT_ASSIGNABLE', 20, "The para
meter type '%s' is incompatable with the field type '%s'"); |
| 2355 | 2357 |
| 2356 /** | 2358 /** |
| 2357 * 5 Variables: It is a static warning if a library, static or local variable
<i>v</i> is final | 2359 * 5 Variables: It is a static warning if a library, static or local variable
<i>v</i> is final |
| 2358 * and <i>v</i> is not initialized at its point of declaration. | 2360 * and <i>v</i> is not initialized at its point of declaration. |
| 2359 * | 2361 * |
| 2360 * 7.6.1 Generative Constructors: Each final instance variable <i>f</i> declar
ed in the | 2362 * 7.6.1 Generative Constructors: Each final instance variable <i>f</i> declar
ed in the |
| 2361 * immediately enclosing class must have an initializer in <i>k</i>'s initiali
zer list unless it | 2363 * immediately enclosing class must have an initializer in <i>k</i>'s initiali
zer list unless it |
| 2362 * has already been initialized by one of the following means: | 2364 * has already been initialized by one of the following means: |
| 2363 * | 2365 * |
| 2364 * * Initialization at the declaration of <i>f</i>. | 2366 * * Initialization at the declaration of <i>f</i>. |
| 2365 * * Initialization by means of an initializing formal of <i>k</i>. | 2367 * * Initialization by means of an initializing formal of <i>k</i>. |
| 2366 * | 2368 * |
| 2367 * or a static warning occurs. | 2369 * or a static warning occurs. |
| 2368 * | 2370 * |
| 2369 * @param name the name of the uninitialized final variable | 2371 * @param name the name of the uninitialized final variable |
| 2370 */ | 2372 */ |
| 2371 static final StaticWarningCode FINAL_NOT_INITIALIZED = new StaticWarningCode.c
on1('FINAL_NOT_INITIALIZED', 26, "The final variable '%s' must be initialized"); | 2373 static final StaticWarningCode FINAL_NOT_INITIALIZED = new StaticWarningCode.c
on1('FINAL_NOT_INITIALIZED', 21, "The final variable '%s' must be initialized"); |
| 2372 | 2374 |
| 2373 /** | 2375 /** |
| 2374 * 15.5 Function Types: It is a static warning if a concrete class implements
Function and does | 2376 * 15.5 Function Types: It is a static warning if a concrete class implements
Function and does |
| 2375 * not have a concrete method named call(). | 2377 * not have a concrete method named call(). |
| 2376 */ | 2378 */ |
| 2377 static final StaticWarningCode FUNCTION_WITHOUT_CALL = new StaticWarningCode.c
on1('FUNCTION_WITHOUT_CALL', 27, "Concrete classes that implement Function must
implement the method call()"); | 2379 static final StaticWarningCode FUNCTION_WITHOUT_CALL = new StaticWarningCode.c
on1('FUNCTION_WITHOUT_CALL', 22, "Concrete classes that implement Function must
implement the method call()"); |
| 2378 | 2380 |
| 2379 /** | 2381 /** |
| 2380 * 14.1 Imports: It is a static warning to import two different libraries with
the same name. | 2382 * 14.1 Imports: It is a static warning to import two different libraries with
the same name. |
| 2381 * | 2383 * |
| 2382 * @param uri1 the uri pointing to a first library | 2384 * @param uri1 the uri pointing to a first library |
| 2383 * @param uri2 the uri pointing to a second library | 2385 * @param uri2 the uri pointing to a second library |
| 2384 * @param name the shared name of the imported libraries | 2386 * @param name the shared name of the imported libraries |
| 2385 */ | 2387 */ |
| 2386 static final StaticWarningCode IMPORT_DUPLICATED_LIBRARY_NAME = new StaticWarn
ingCode.con1('IMPORT_DUPLICATED_LIBRARY_NAME', 28, "The imported libraries '%s'
and '%s' should not have the same name '%s'"); | 2388 static final StaticWarningCode IMPORT_DUPLICATED_LIBRARY_NAME = new StaticWarn
ingCode.con1('IMPORT_DUPLICATED_LIBRARY_NAME', 23, "The imported libraries '%s'
and '%s' should not have the same name '%s'"); |
| 2387 | 2389 |
| 2388 /** | 2390 /** |
| 2389 * 8.1.1 Inheritance and Overriding: However, if there are multiple members <i
>m<sub>1</sub>, | 2391 * 8.1.1 Inheritance and Overriding: However, if there are multiple members <i
>m<sub>1</sub>, |
| 2390 * … m<sub>k</sub></i> with the same name <i>n</i> that would be inheri
ted (because | 2392 * … m<sub>k</sub></i> with the same name <i>n</i> that would be inheri
ted (because |
| 2391 * identically named members existed in several superinterfaces) then at most
one member is | 2393 * identically named members existed in several superinterfaces) then at most
one member is |
| 2392 * inherited. | 2394 * inherited. |
| 2393 * | 2395 * |
| 2394 * If some but not all of the <i>m<sub>i</sub>, 1 <= i <= k</i>, are get
ters, or if some but | 2396 * If some but not all of the <i>m<sub>i</sub>, 1 <= i <= k</i>, are get
ters, or if some but |
| 2395 * not all of the <i>m<sub>i</sub></i> are setters, none of the <i>m<sub>i</su
b></i> are | 2397 * not all of the <i>m<sub>i</sub></i> are setters, none of the <i>m<sub>i</su
b></i> are |
| 2396 * inherited, and a static warning is issued. | 2398 * inherited, and a static warning is issued. |
| 2397 */ | 2399 */ |
| 2398 static final StaticWarningCode INCONSISTENT_METHOD_INHERITANCE_GETTER_AND_METH
OD = new StaticWarningCode.con1('INCONSISTENT_METHOD_INHERITANCE_GETTER_AND_METH
OD', 29, "'%s' is inherited as a getter and also a method"); | 2400 static final StaticWarningCode INCONSISTENT_METHOD_INHERITANCE_GETTER_AND_METH
OD = new StaticWarningCode.con1('INCONSISTENT_METHOD_INHERITANCE_GETTER_AND_METH
OD', 24, "'%s' is inherited as a getter and also a method"); |
| 2399 | 2401 |
| 2400 /** | 2402 /** |
| 2401 * 7.1 Instance Methods: It is a static warning if a class <i>C</i> declares a
n instance method | 2403 * 7.1 Instance Methods: It is a static warning if a class <i>C</i> declares a
n instance method |
| 2402 * named <i>n</i> and an accessible static member named <i>n</i> is declared i
n a superclass of | 2404 * named <i>n</i> and an accessible static member named <i>n</i> is declared i
n a superclass of |
| 2403 * <i>C</i>. | 2405 * <i>C</i>. |
| 2404 * | 2406 * |
| 2405 * @param memberName the name of the member with the name conflict | 2407 * @param memberName the name of the member with the name conflict |
| 2406 * @param superclassName the name of the enclosing class that has the static m
ember | 2408 * @param superclassName the name of the enclosing class that has the static m
ember |
| 2407 */ | 2409 */ |
| 2408 static final StaticWarningCode INSTANCE_METHOD_NAME_COLLIDES_WITH_SUPERCLASS_S
TATIC = new StaticWarningCode.con1('INSTANCE_METHOD_NAME_COLLIDES_WITH_SUPERCLAS
S_STATIC', 30, "'%s' collides with a static member in the superclass '%s'"); | 2410 static final StaticWarningCode INSTANCE_METHOD_NAME_COLLIDES_WITH_SUPERCLASS_S
TATIC = new StaticWarningCode.con1('INSTANCE_METHOD_NAME_COLLIDES_WITH_SUPERCLAS
S_STATIC', 25, "'%s' collides with a static member in the superclass '%s'"); |
| 2409 | 2411 |
| 2410 /** | 2412 /** |
| 2411 * 7.2 Getters: It is a static warning if a getter <i>m1</i> overrides a gette
r <i>m2</i> and the | 2413 * 7.2 Getters: It is a static warning if a getter <i>m1</i> overrides a gette
r <i>m2</i> and the |
| 2412 * type of <i>m1</i> is not a subtype of the type of <i>m2</i>. | 2414 * type of <i>m1</i> is not a subtype of the type of <i>m2</i>. |
| 2413 * | 2415 * |
| 2414 * @param actualReturnTypeName the name of the expected return type | 2416 * @param actualReturnTypeName the name of the expected return type |
| 2415 * @param expectedReturnType the name of the actual return type, not assignabl
e to the | 2417 * @param expectedReturnType the name of the actual return type, not assignabl
e to the |
| 2416 * actualReturnTypeName | 2418 * actualReturnTypeName |
| 2417 * @param className the name of the class where the overridden getter is decla
red | 2419 * @param className the name of the class where the overridden getter is decla
red |
| 2418 * @see #INVALID_METHOD_OVERRIDE_RETURN_TYPE | 2420 * @see #INVALID_METHOD_OVERRIDE_RETURN_TYPE |
| 2419 */ | 2421 */ |
| 2420 static final StaticWarningCode INVALID_GETTER_OVERRIDE_RETURN_TYPE = new Stati
cWarningCode.con1('INVALID_GETTER_OVERRIDE_RETURN_TYPE', 31, "The return type '%
s' is not assignable to '%s' as required by the getter it is overriding from '%s
'"); | 2422 static final StaticWarningCode INVALID_GETTER_OVERRIDE_RETURN_TYPE = new Stati
cWarningCode.con1('INVALID_GETTER_OVERRIDE_RETURN_TYPE', 26, "The return type '%
s' is not assignable to '%s' as required by the getter it is overriding from '%s
'"); |
| 2421 | 2423 |
| 2422 /** | 2424 /** |
| 2423 * 7.1 Instance Methods: It is a static warning if an instance method <i>m1</i
> overrides an | 2425 * 7.1 Instance Methods: It is a static warning if an instance method <i>m1</i
> overrides an |
| 2424 * instance method <i>m2</i> and the type of <i>m1</i> is not a subtype of the
type of <i>m2</i>. | 2426 * instance method <i>m2</i> and the type of <i>m1</i> is not a subtype of the
type of <i>m2</i>. |
| 2425 * | 2427 * |
| 2426 * @param actualParamTypeName the name of the expected parameter type | 2428 * @param actualParamTypeName the name of the expected parameter type |
| 2427 * @param expectedParamType the name of the actual parameter type, not assigna
ble to the | 2429 * @param expectedParamType the name of the actual parameter type, not assigna
ble to the |
| 2428 * actualParamTypeName | 2430 * actualParamTypeName |
| 2429 * @param className the name of the class where the overridden method is decla
red | 2431 * @param className the name of the class where the overridden method is decla
red |
| 2430 */ | 2432 */ |
| 2431 static final StaticWarningCode INVALID_METHOD_OVERRIDE_NAMED_PARAM_TYPE = new
StaticWarningCode.con1('INVALID_METHOD_OVERRIDE_NAMED_PARAM_TYPE', 32, "The para
meter type '%s' is not assignable to '%s' as required by the method it is overri
ding from '%s'"); | 2433 static final StaticWarningCode INVALID_METHOD_OVERRIDE_NAMED_PARAM_TYPE = new
StaticWarningCode.con1('INVALID_METHOD_OVERRIDE_NAMED_PARAM_TYPE', 27, "The para
meter type '%s' is not assignable to '%s' as required by the method it is overri
ding from '%s'"); |
| 2432 | 2434 |
| 2433 /** | 2435 /** |
| 2434 * 7.1 Instance Methods: It is a static warning if an instance method <i>m1</i
> overrides an | 2436 * 7.1 Instance Methods: It is a static warning if an instance method <i>m1</i
> overrides an |
| 2435 * instance method <i>m2</i> and the type of <i>m1</i> is not a subtype of the
type of <i>m2</i>. | 2437 * instance method <i>m2</i> and the type of <i>m1</i> is not a subtype of the
type of <i>m2</i>. |
| 2436 * | 2438 * |
| 2437 * @param actualParamTypeName the name of the expected parameter type | 2439 * @param actualParamTypeName the name of the expected parameter type |
| 2438 * @param expectedParamType the name of the actual parameter type, not assigna
ble to the | 2440 * @param expectedParamType the name of the actual parameter type, not assigna
ble to the |
| 2439 * actualParamTypeName | 2441 * actualParamTypeName |
| 2440 * @param className the name of the class where the overridden method is decla
red | 2442 * @param className the name of the class where the overridden method is decla
red |
| 2441 * @see #INVALID_SETTER_OVERRIDE_NORMAL_PARAM_TYPE | 2443 * @see #INVALID_SETTER_OVERRIDE_NORMAL_PARAM_TYPE |
| 2442 */ | 2444 */ |
| 2443 static final StaticWarningCode INVALID_METHOD_OVERRIDE_NORMAL_PARAM_TYPE = new
StaticWarningCode.con1('INVALID_METHOD_OVERRIDE_NORMAL_PARAM_TYPE', 33, "The pa
rameter type '%s' is not assignable to '%s' as required by the method it is over
riding from '%s'"); | 2445 static final StaticWarningCode INVALID_METHOD_OVERRIDE_NORMAL_PARAM_TYPE = new
StaticWarningCode.con1('INVALID_METHOD_OVERRIDE_NORMAL_PARAM_TYPE', 28, "The pa
rameter type '%s' is not assignable to '%s' as required by the method it is over
riding from '%s'"); |
| 2444 | 2446 |
| 2445 /** | 2447 /** |
| 2446 * 7.1 Instance Methods: It is a static warning if an instance method <i>m1</i
> overrides an | 2448 * 7.1 Instance Methods: It is a static warning if an instance method <i>m1</i
> overrides an |
| 2447 * instance method <i>m2</i> and the type of <i>m1</i> is not a subtype of the
type of <i>m2</i>. | 2449 * instance method <i>m2</i> and the type of <i>m1</i> is not a subtype of the
type of <i>m2</i>. |
| 2448 * | 2450 * |
| 2449 * @param actualParamTypeName the name of the expected parameter type | 2451 * @param actualParamTypeName the name of the expected parameter type |
| 2450 * @param expectedParamType the name of the actual parameter type, not assigna
ble to the | 2452 * @param expectedParamType the name of the actual parameter type, not assigna
ble to the |
| 2451 * actualParamTypeName | 2453 * actualParamTypeName |
| 2452 * @param className the name of the class where the overridden method is decla
red | 2454 * @param className the name of the class where the overridden method is decla
red |
| 2453 */ | 2455 */ |
| 2454 static final StaticWarningCode INVALID_METHOD_OVERRIDE_OPTIONAL_PARAM_TYPE = n
ew StaticWarningCode.con1('INVALID_METHOD_OVERRIDE_OPTIONAL_PARAM_TYPE', 34, "Th
e parameter type '%s' is not assignable to '%s' as required by the method it is
overriding from '%s'"); | 2456 static final StaticWarningCode INVALID_METHOD_OVERRIDE_OPTIONAL_PARAM_TYPE = n
ew StaticWarningCode.con1('INVALID_METHOD_OVERRIDE_OPTIONAL_PARAM_TYPE', 29, "Th
e parameter type '%s' is not assignable to '%s' as required by the method it is
overriding from '%s'"); |
| 2455 | 2457 |
| 2456 /** | 2458 /** |
| 2457 * 7.1 Instance Methods: It is a static warning if an instance method <i>m1</i
> overrides an | 2459 * 7.1 Instance Methods: It is a static warning if an instance method <i>m1</i
> overrides an |
| 2458 * instance method <i>m2</i> and the type of <i>m1</i> is not a subtype of the
type of <i>m2</i>. | 2460 * instance method <i>m2</i> and the type of <i>m1</i> is not a subtype of the
type of <i>m2</i>. |
| 2459 * | 2461 * |
| 2460 * @param actualReturnTypeName the name of the expected return type | 2462 * @param actualReturnTypeName the name of the expected return type |
| 2461 * @param expectedReturnType the name of the actual return type, not assignabl
e to the | 2463 * @param expectedReturnType the name of the actual return type, not assignabl
e to the |
| 2462 * actualReturnTypeName | 2464 * actualReturnTypeName |
| 2463 * @param className the name of the class where the overridden method is decla
red | 2465 * @param className the name of the class where the overridden method is decla
red |
| 2464 * @see #INVALID_GETTER_OVERRIDE_RETURN_TYPE | 2466 * @see #INVALID_GETTER_OVERRIDE_RETURN_TYPE |
| 2465 */ | 2467 */ |
| 2466 static final StaticWarningCode INVALID_METHOD_OVERRIDE_RETURN_TYPE = new Stati
cWarningCode.con1('INVALID_METHOD_OVERRIDE_RETURN_TYPE', 35, "The return type '%
s' is not assignable to '%s' as required by the method it is overriding from '%s
'"); | 2468 static final StaticWarningCode INVALID_METHOD_OVERRIDE_RETURN_TYPE = new Stati
cWarningCode.con1('INVALID_METHOD_OVERRIDE_RETURN_TYPE', 30, "The return type '%
s' is not assignable to '%s' as required by the method it is overriding from '%s
'"); |
| 2467 | 2469 |
| 2468 /** | 2470 /** |
| 2469 * 7.1 Instance Methods: It is a static warning if an instance method <i>m1</i
> overrides an | 2471 * 7.1 Instance Methods: It is a static warning if an instance method <i>m1</i
> overrides an |
| 2470 * instance member <i>m2</i>, the signature of <i>m2</i> explicitly specifies
a default value for | 2472 * instance member <i>m2</i>, the signature of <i>m2</i> explicitly specifies
a default value for |
| 2471 * a formal parameter <i>p</i> and the signature of <i>m1</i> specifies a diff
erent default value | 2473 * a formal parameter <i>p</i> and the signature of <i>m1</i> specifies a diff
erent default value |
| 2472 * for <i>p</i>. | 2474 * for <i>p</i>. |
| 2473 */ | 2475 */ |
| 2474 static final StaticWarningCode INVALID_OVERRIDE_DIFFERENT_DEFAULT_VALUES_NAMED
= new StaticWarningCode.con1('INVALID_OVERRIDE_DIFFERENT_DEFAULT_VALUES_NAMED',
36, "Parameters cannot override default values, this method overrides '%s.%s' w
here '%s' has a different value"); | 2476 static final StaticWarningCode INVALID_OVERRIDE_DIFFERENT_DEFAULT_VALUES_NAMED
= new StaticWarningCode.con1('INVALID_OVERRIDE_DIFFERENT_DEFAULT_VALUES_NAMED',
31, "Parameters cannot override default values, this method overrides '%s.%s' w
here '%s' has a different value"); |
| 2475 | 2477 |
| 2476 /** | 2478 /** |
| 2477 * 7.1 Instance Methods: It is a static warning if an instance method <i>m1</i
> overrides an | 2479 * 7.1 Instance Methods: It is a static warning if an instance method <i>m1</i
> overrides an |
| 2478 * instance member <i>m2</i>, the signature of <i>m2</i> explicitly specifies
a default value for | 2480 * instance member <i>m2</i>, the signature of <i>m2</i> explicitly specifies
a default value for |
| 2479 * a formal parameter <i>p</i> and the signature of <i>m1</i> specifies a diff
erent default value | 2481 * a formal parameter <i>p</i> and the signature of <i>m1</i> specifies a diff
erent default value |
| 2480 * for <i>p</i>. | 2482 * for <i>p</i>. |
| 2481 */ | 2483 */ |
| 2482 static final StaticWarningCode INVALID_OVERRIDE_DIFFERENT_DEFAULT_VALUES_POSIT
IONAL = new StaticWarningCode.con1('INVALID_OVERRIDE_DIFFERENT_DEFAULT_VALUES_PO
SITIONAL', 37, "Parameters cannot override default values, this method overrides
'%s.%s' where this positional parameter has a different value"); | 2484 static final StaticWarningCode INVALID_OVERRIDE_DIFFERENT_DEFAULT_VALUES_POSIT
IONAL = new StaticWarningCode.con1('INVALID_OVERRIDE_DIFFERENT_DEFAULT_VALUES_PO
SITIONAL', 32, "Parameters cannot override default values, this method overrides
'%s.%s' where this positional parameter has a different value"); |
| 2483 | 2485 |
| 2484 /** | 2486 /** |
| 2485 * 7.1 Instance Methods: It is a static warning if an instance method <i>m1</i
> overrides an | 2487 * 7.1 Instance Methods: It is a static warning if an instance method <i>m1</i
> overrides an |
| 2486 * instance member <i>m2</i> and <i>m1</i> does not declare all the named para
meters declared by | 2488 * instance member <i>m2</i> and <i>m1</i> does not declare all the named para
meters declared by |
| 2487 * <i>m2</i>. | 2489 * <i>m2</i>. |
| 2488 * | 2490 * |
| 2489 * @param paramCount the number of named parameters in the overridden member | 2491 * @param paramCount the number of named parameters in the overridden member |
| 2490 * @param className the name of the class from the overridden method | 2492 * @param className the name of the class from the overridden method |
| 2491 */ | 2493 */ |
| 2492 static final StaticWarningCode INVALID_OVERRIDE_NAMED = new StaticWarningCode.
con1('INVALID_OVERRIDE_NAMED', 38, "Missing the named parameter '%s' to match th
e overridden method from '%s'"); | 2494 static final StaticWarningCode INVALID_OVERRIDE_NAMED = new StaticWarningCode.
con1('INVALID_OVERRIDE_NAMED', 33, "Missing the named parameter '%s' to match th
e overridden method from '%s'"); |
| 2493 | 2495 |
| 2494 /** | 2496 /** |
| 2495 * 7.1 Instance Methods: It is a static warning if an instance method <i>m1</i
> overrides an | 2497 * 7.1 Instance Methods: It is a static warning if an instance method <i>m1</i
> overrides an |
| 2496 * instance member <i>m2</i> and <i>m1</i> has fewer positional parameters tha
n <i>m2</i>. | 2498 * instance member <i>m2</i> and <i>m1</i> has fewer positional parameters tha
n <i>m2</i>. |
| 2497 * | 2499 * |
| 2498 * @param paramCount the number of positional parameters in the overridden mem
ber | 2500 * @param paramCount the number of positional parameters in the overridden mem
ber |
| 2499 * @param className the name of the class from the overridden method | 2501 * @param className the name of the class from the overridden method |
| 2500 */ | 2502 */ |
| 2501 static final StaticWarningCode INVALID_OVERRIDE_POSITIONAL = new StaticWarning
Code.con1('INVALID_OVERRIDE_POSITIONAL', 39, "Must have at least %d parameters t
o match the overridden method from '%s'"); | 2503 static final StaticWarningCode INVALID_OVERRIDE_POSITIONAL = new StaticWarning
Code.con1('INVALID_OVERRIDE_POSITIONAL', 34, "Must have at least %d parameters t
o match the overridden method from '%s'"); |
| 2502 | 2504 |
| 2503 /** | 2505 /** |
| 2504 * 7.1 Instance Methods: It is a static warning if an instance method <i>m1</i
> overrides an | 2506 * 7.1 Instance Methods: It is a static warning if an instance method <i>m1</i
> overrides an |
| 2505 * instance member <i>m2</i> and <i>m1</i> has a greater number of required pa
rameters than | 2507 * instance member <i>m2</i> and <i>m1</i> has a greater number of required pa
rameters than |
| 2506 * <i>m2</i>. | 2508 * <i>m2</i>. |
| 2507 * | 2509 * |
| 2508 * @param paramCount the number of required parameters in the overridden membe
r | 2510 * @param paramCount the number of required parameters in the overridden membe
r |
| 2509 * @param className the name of the class from the overridden method | 2511 * @param className the name of the class from the overridden method |
| 2510 */ | 2512 */ |
| 2511 static final StaticWarningCode INVALID_OVERRIDE_REQUIRED = new StaticWarningCo
de.con1('INVALID_OVERRIDE_REQUIRED', 40, "Must have %d required parameters or le
ss to match the overridden method from '%s'"); | 2513 static final StaticWarningCode INVALID_OVERRIDE_REQUIRED = new StaticWarningCo
de.con1('INVALID_OVERRIDE_REQUIRED', 35, "Must have %d required parameters or le
ss to match the overridden method from '%s'"); |
| 2512 | 2514 |
| 2513 /** | 2515 /** |
| 2514 * 7.3 Setters: It is a static warning if a setter <i>m1</i> overrides a sette
r <i>m2</i> and the | 2516 * 7.3 Setters: It is a static warning if a setter <i>m1</i> overrides a sette
r <i>m2</i> and the |
| 2515 * type of <i>m1</i> is not a subtype of the type of <i>m2</i>. | 2517 * type of <i>m1</i> is not a subtype of the type of <i>m2</i>. |
| 2516 * | 2518 * |
| 2517 * @param actualParamTypeName the name of the expected parameter type | 2519 * @param actualParamTypeName the name of the expected parameter type |
| 2518 * @param expectedParamType the name of the actual parameter type, not assigna
ble to the | 2520 * @param expectedParamType the name of the actual parameter type, not assigna
ble to the |
| 2519 * actualParamTypeName | 2521 * actualParamTypeName |
| 2520 * @param className the name of the class where the overridden setter is decla
red | 2522 * @param className the name of the class where the overridden setter is decla
red |
| 2521 * @see #INVALID_METHOD_OVERRIDE_NORMAL_PARAM_TYPE | 2523 * @see #INVALID_METHOD_OVERRIDE_NORMAL_PARAM_TYPE |
| 2522 */ | 2524 */ |
| 2523 static final StaticWarningCode INVALID_SETTER_OVERRIDE_NORMAL_PARAM_TYPE = new
StaticWarningCode.con1('INVALID_SETTER_OVERRIDE_NORMAL_PARAM_TYPE', 41, "The pa
rameter type '%s' is not assignable to '%s' as required by the setter it is over
riding from '%s'"); | 2525 static final StaticWarningCode INVALID_SETTER_OVERRIDE_NORMAL_PARAM_TYPE = new
StaticWarningCode.con1('INVALID_SETTER_OVERRIDE_NORMAL_PARAM_TYPE', 36, "The pa
rameter type '%s' is not assignable to '%s' as required by the setter it is over
riding from '%s'"); |
| 2524 | 2526 |
| 2525 /** | 2527 /** |
| 2526 * 12.6 Lists: A run-time list literal <<i>E</i>> [<i>e<sub>1</sub></i>
... | 2528 * 12.6 Lists: A run-time list literal <<i>E</i>> [<i>e<sub>1</sub></i>
... |
| 2527 * <i>e<sub>n</sub></i>] is evaluated as follows: | 2529 * <i>e<sub>n</sub></i>] is evaluated as follows: |
| 2528 * | 2530 * |
| 2529 * * The operator []= is invoked on <i>a</i> with first argument <i>i</i> and
second argument | 2531 * * The operator []= is invoked on <i>a</i> with first argument <i>i</i> and
second argument |
| 2530 * <i>o<sub>i+1</sub></i><i>, 1 <= i <= n</i> | 2532 * <i>o<sub>i+1</sub></i><i>, 1 <= i <= n</i> |
| 2531 * | 2533 * |
| 2532 * | 2534 * |
| 2533 * 12.14.2 Binding Actuals to Formals: Let <i>T<sub>i</sub></i> be the static
type of | 2535 * 12.14.2 Binding Actuals to Formals: Let <i>T<sub>i</sub></i> be the static
type of |
| 2534 * <i>a<sub>i</sub></i>, let <i>S<sub>i</sub></i> be the type of <i>p<sub>i</s
ub>, 1 <= i <= | 2536 * <i>a<sub>i</sub></i>, let <i>S<sub>i</sub></i> be the type of <i>p<sub>i</s
ub>, 1 <= i <= |
| 2535 * n+k</i> and let <i>S<sub>q</sub></i> be the type of the named parameter <i>
q</i> of <i>f</i>. | 2537 * n+k</i> and let <i>S<sub>q</sub></i> be the type of the named parameter <i>
q</i> of <i>f</i>. |
| 2536 * It is a static warning if <i>T<sub>j</sub></i> may not be assigned to <i>S<
sub>j</sub>, 1 <= | 2538 * It is a static warning if <i>T<sub>j</sub></i> may not be assigned to <i>S<
sub>j</sub>, 1 <= |
| 2537 * j <= m</i>. | 2539 * j <= m</i>. |
| 2538 */ | 2540 */ |
| 2539 static final StaticWarningCode LIST_ELEMENT_TYPE_NOT_ASSIGNABLE = new StaticWa
rningCode.con1('LIST_ELEMENT_TYPE_NOT_ASSIGNABLE', 42, "The element type '%s' ca
nnot be assigned to the list type '%s'"); | 2541 static final StaticWarningCode LIST_ELEMENT_TYPE_NOT_ASSIGNABLE = new StaticWa
rningCode.con1('LIST_ELEMENT_TYPE_NOT_ASSIGNABLE', 37, "The element type '%s' ca
nnot be assigned to the list type '%s'"); |
| 2540 | 2542 |
| 2541 /** | 2543 /** |
| 2542 * 12.7 Map: A run-time map literal <<i>K</i>, <i>V</i>> [<i>k<sub>1</su
b></i> : | 2544 * 12.7 Map: A run-time map literal <<i>K</i>, <i>V</i>> [<i>k<sub>1</su
b></i> : |
| 2543 * <i>e<sub>1</sub></i> ... <i>k<sub>n</sub></i> : <i>e<sub>n</sub></i>] is ev
aluated as follows: | 2545 * <i>e<sub>1</sub></i> ... <i>k<sub>n</sub></i> : <i>e<sub>n</sub></i>] is ev
aluated as follows: |
| 2544 * | 2546 * |
| 2545 * * The operator []= is invoked on <i>m</i> with first argument <i>k<sub>i</s
ub></i> and second | 2547 * * The operator []= is invoked on <i>m</i> with first argument <i>k<sub>i</s
ub></i> and second |
| 2546 * argument <i>e<sub>i</sub></i><i>, 1 <= i <= n</i> | 2548 * argument <i>e<sub>i</sub></i><i>, 1 <= i <= n</i> |
| 2547 * | 2549 * |
| 2548 * | 2550 * |
| 2549 * 12.14.2 Binding Actuals to Formals: Let <i>T<sub>i</sub></i> be the static
type of | 2551 * 12.14.2 Binding Actuals to Formals: Let <i>T<sub>i</sub></i> be the static
type of |
| 2550 * <i>a<sub>i</sub></i>, let <i>S<sub>i</sub></i> be the type of <i>p<sub>i</s
ub>, 1 <= i <= | 2552 * <i>a<sub>i</sub></i>, let <i>S<sub>i</sub></i> be the type of <i>p<sub>i</s
ub>, 1 <= i <= |
| 2551 * n+k</i> and let <i>S<sub>q</sub></i> be the type of the named parameter <i>
q</i> of <i>f</i>. | 2553 * n+k</i> and let <i>S<sub>q</sub></i> be the type of the named parameter <i>
q</i> of <i>f</i>. |
| 2552 * It is a static warning if <i>T<sub>j</sub></i> may not be assigned to <i>S<
sub>j</sub>, 1 <= | 2554 * It is a static warning if <i>T<sub>j</sub></i> may not be assigned to <i>S<
sub>j</sub>, 1 <= |
| 2553 * j <= m</i>. | 2555 * j <= m</i>. |
| 2554 */ | 2556 */ |
| 2555 static final StaticWarningCode MAP_KEY_TYPE_NOT_ASSIGNABLE = new StaticWarning
Code.con1('MAP_KEY_TYPE_NOT_ASSIGNABLE', 43, "The element type '%s' cannot be as
signed to the map key type '%s'"); | 2557 static final StaticWarningCode MAP_KEY_TYPE_NOT_ASSIGNABLE = new StaticWarning
Code.con1('MAP_KEY_TYPE_NOT_ASSIGNABLE', 38, "The element type '%s' cannot be as
signed to the map key type '%s'"); |
| 2556 | 2558 |
| 2557 /** | 2559 /** |
| 2558 * 12.7 Map: A run-time map literal <<i>K</i>, <i>V</i>> [<i>k<sub>1</su
b></i> : | 2560 * 12.7 Map: A run-time map literal <<i>K</i>, <i>V</i>> [<i>k<sub>1</su
b></i> : |
| 2559 * <i>e<sub>1</sub></i> ... <i>k<sub>n</sub></i> : <i>e<sub>n</sub></i>] is ev
aluated as follows: | 2561 * <i>e<sub>1</sub></i> ... <i>k<sub>n</sub></i> : <i>e<sub>n</sub></i>] is ev
aluated as follows: |
| 2560 * | 2562 * |
| 2561 * * The operator []= is invoked on <i>m</i> with first argument <i>k<sub>i</s
ub></i> and second | 2563 * * The operator []= is invoked on <i>m</i> with first argument <i>k<sub>i</s
ub></i> and second |
| 2562 * argument <i>e<sub>i</sub></i><i>, 1 <= i <= n</i> | 2564 * argument <i>e<sub>i</sub></i><i>, 1 <= i <= n</i> |
| 2563 * | 2565 * |
| 2564 * | 2566 * |
| 2565 * 12.14.2 Binding Actuals to Formals: Let <i>T<sub>i</sub></i> be the static
type of | 2567 * 12.14.2 Binding Actuals to Formals: Let <i>T<sub>i</sub></i> be the static
type of |
| 2566 * <i>a<sub>i</sub></i>, let <i>S<sub>i</sub></i> be the type of <i>p<sub>i</s
ub>, 1 <= i <= | 2568 * <i>a<sub>i</sub></i>, let <i>S<sub>i</sub></i> be the type of <i>p<sub>i</s
ub>, 1 <= i <= |
| 2567 * n+k</i> and let <i>S<sub>q</sub></i> be the type of the named parameter <i>
q</i> of <i>f</i>. | 2569 * n+k</i> and let <i>S<sub>q</sub></i> be the type of the named parameter <i>
q</i> of <i>f</i>. |
| 2568 * It is a static warning if <i>T<sub>j</sub></i> may not be assigned to <i>S<
sub>j</sub>, 1 <= | 2570 * It is a static warning if <i>T<sub>j</sub></i> may not be assigned to <i>S<
sub>j</sub>, 1 <= |
| 2569 * j <= m</i>. | 2571 * j <= m</i>. |
| 2570 */ | 2572 */ |
| 2571 static final StaticWarningCode MAP_VALUE_TYPE_NOT_ASSIGNABLE = new StaticWarni
ngCode.con1('MAP_VALUE_TYPE_NOT_ASSIGNABLE', 44, "The element type '%s' cannot b
e assigned to the map value type '%s'"); | 2573 static final StaticWarningCode MAP_VALUE_TYPE_NOT_ASSIGNABLE = new StaticWarni
ngCode.con1('MAP_VALUE_TYPE_NOT_ASSIGNABLE', 39, "The element type '%s' cannot b
e assigned to the map value type '%s'"); |
| 2572 | 2574 |
| 2573 /** | 2575 /** |
| 2574 * 7.3 Setters: It is a static warning if a class has a setter named <i>v=</i>
with argument type | 2576 * 7.3 Setters: It is a static warning if a class has a setter named <i>v=</i>
with argument type |
| 2575 * <i>T</i> and a getter named <i>v</i> with return type <i>S</i>, and <i>T</i
> may not be | 2577 * <i>T</i> and a getter named <i>v</i> with return type <i>S</i>, and <i>T</i
> may not be |
| 2576 * assigned to <i>S</i>. | 2578 * assigned to <i>S</i>. |
| 2577 */ | 2579 */ |
| 2578 static final StaticWarningCode MISMATCHED_GETTER_AND_SETTER_TYPES = new Static
WarningCode.con1('MISMATCHED_GETTER_AND_SETTER_TYPES', 45, "The parameter type f
or setter '%s' is '%s' which is not assignable to its getter (of type '%s')"); | 2580 static final StaticWarningCode MISMATCHED_GETTER_AND_SETTER_TYPES = new Static
WarningCode.con1('MISMATCHED_GETTER_AND_SETTER_TYPES', 40, "The parameter type f
or setter '%s' is '%s' which is not assignable to its getter (of type '%s')"); |
| 2581 |
| 2582 /** |
| 2583 * 7.3 Setters: It is a static warning if a class has a setter named <i>v=</i>
with argument type |
| 2584 * <i>T</i> and a getter named <i>v</i> with return type <i>S</i>, and <i>T</i
> may not be |
| 2585 * assigned to <i>S</i>. |
| 2586 */ |
| 2587 static final StaticWarningCode MISMATCHED_GETTER_AND_SETTER_TYPES_FROM_SUPERTY
PE = new StaticWarningCode.con1('MISMATCHED_GETTER_AND_SETTER_TYPES_FROM_SUPERTY
PE', 41, "The parameter type for setter '%s' is '%s' which is not assignable to
its getter (of type '%s'), from superclass '%s'"); |
| 2588 |
| 2589 /** |
| 2590 * 13.12 Return: It is a static warning if a function contains both one or mor
e return statements |
| 2591 * of the form <i>return;</i> and one or more return statements of the form <i
>return e;</i>. |
| 2592 */ |
| 2593 static final StaticWarningCode MIXED_RETURN_TYPES = new StaticWarningCode.con1
('MIXED_RETURN_TYPES', 42, "Methods and functions cannot use return both with an
d without values"); |
| 2579 | 2594 |
| 2580 /** | 2595 /** |
| 2581 * 12.11.1 New: It is a static warning if <i>q</i> is a constructor of an abst
ract class and | 2596 * 12.11.1 New: It is a static warning if <i>q</i> is a constructor of an abst
ract class and |
| 2582 * <i>q</i> is not a factory constructor. | 2597 * <i>q</i> is not a factory constructor. |
| 2583 */ | 2598 */ |
| 2584 static final StaticWarningCode NEW_WITH_ABSTRACT_CLASS = new StaticWarningCode
.con1('NEW_WITH_ABSTRACT_CLASS', 46, "Abstract classes cannot be created with a
'new' expression"); | 2599 static final StaticWarningCode NEW_WITH_ABSTRACT_CLASS = new StaticWarningCode
.con1('NEW_WITH_ABSTRACT_CLASS', 43, "Abstract classes cannot be created with a
'new' expression"); |
| 2585 | 2600 |
| 2586 /** | 2601 /** |
| 2587 * 15.8 Parameterized Types: Any use of a malbounded type gives rise to a stat
ic warning. | 2602 * 15.8 Parameterized Types: Any use of a malbounded type gives rise to a stat
ic warning. |
| 2588 * | 2603 * |
| 2589 * @param typeName the name of the type being referenced (<i>S</i>) | 2604 * @param typeName the name of the type being referenced (<i>S</i>) |
| 2590 * @param parameterCount the number of type parameters that were declared | 2605 * @param parameterCount the number of type parameters that were declared |
| 2591 * @param argumentCount the number of type arguments provided | 2606 * @param argumentCount the number of type arguments provided |
| 2592 * @see CompileTimeErrorCode#CONST_WITH_INVALID_TYPE_PARAMETERS | 2607 * @see CompileTimeErrorCode#CONST_WITH_INVALID_TYPE_PARAMETERS |
| 2593 * @see StaticTypeWarningCode#WRONG_NUMBER_OF_TYPE_ARGUMENTS | 2608 * @see StaticTypeWarningCode#WRONG_NUMBER_OF_TYPE_ARGUMENTS |
| 2594 */ | 2609 */ |
| 2595 static final StaticWarningCode NEW_WITH_INVALID_TYPE_PARAMETERS = new StaticWa
rningCode.con1('NEW_WITH_INVALID_TYPE_PARAMETERS', 47, "The type '%s' is declare
d with %d type parameters, but %d type arguments were given"); | 2610 static final StaticWarningCode NEW_WITH_INVALID_TYPE_PARAMETERS = new StaticWa
rningCode.con1('NEW_WITH_INVALID_TYPE_PARAMETERS', 44, "The type '%s' is declare
d with %d type parameters, but %d type arguments were given"); |
| 2596 | 2611 |
| 2597 /** | 2612 /** |
| 2598 * 12.11.1 New: It is a static warning if <i>T</i> is not a class accessible i
n the current scope, | 2613 * 12.11.1 New: It is a static warning if <i>T</i> is not a class accessible i
n the current scope, |
| 2599 * optionally followed by type arguments. | 2614 * optionally followed by type arguments. |
| 2600 * | 2615 * |
| 2601 * @param name the name of the non-type element | 2616 * @param name the name of the non-type element |
| 2602 */ | 2617 */ |
| 2603 static final StaticWarningCode NEW_WITH_NON_TYPE = new StaticWarningCode.con1(
'NEW_WITH_NON_TYPE', 48, "The name '%s' is not a class"); | 2618 static final StaticWarningCode NEW_WITH_NON_TYPE = new StaticWarningCode.con1(
'NEW_WITH_NON_TYPE', 45, "The name '%s' is not a class"); |
| 2604 | 2619 |
| 2605 /** | 2620 /** |
| 2606 * 12.11.1 New: If <i>T</i> is a class or parameterized type accessible in the
current scope then: | 2621 * 12.11.1 New: If <i>T</i> is a class or parameterized type accessible in the
current scope then: |
| 2607 * 1. If <i>e</i> is of the form <i>new T.id(a<sub>1</sub>, …, a<sub>n<
/sub>, | 2622 * 1. If <i>e</i> is of the form <i>new T.id(a<sub>1</sub>, …, a<sub>n<
/sub>, |
| 2608 * x<sub>n+1</sub>: a<sub>n+1</sub>, …, x<sub>n+k</sub>: a<sub>n+k</sub
>)</i> it is a | 2623 * x<sub>n+1</sub>: a<sub>n+1</sub>, …, x<sub>n+k</sub>: a<sub>n+k</sub
>)</i> it is a |
| 2609 * static warning if <i>T.id</i> is not the name of a constructor declared by
the type <i>T</i>. | 2624 * static warning if <i>T.id</i> is not the name of a constructor declared by
the type <i>T</i>. |
| 2610 * If <i>e</i> of the form <i>new T(a<sub>1</sub>, …, a<sub>n</sub>, x<
sub>n+1</sub>: | 2625 * If <i>e</i> of the form <i>new T(a<sub>1</sub>, …, a<sub>n</sub>, x<
sub>n+1</sub>: |
| 2611 * a<sub>n+1</sub>, … x<sub>n+k</sub>: a<sub>n+kM/sub>)</i> it is a sta
tic warning if the | 2626 * a<sub>n+1</sub>, … x<sub>n+k</sub>: a<sub>n+kM/sub>)</i> it is a sta
tic warning if the |
| 2612 * type <i>T</i> does not declare a constructor with the same name as the decl
aration of <i>T</i>. | 2627 * type <i>T</i> does not declare a constructor with the same name as the decl
aration of <i>T</i>. |
| 2613 */ | 2628 */ |
| 2614 static final StaticWarningCode NEW_WITH_UNDEFINED_CONSTRUCTOR = new StaticWarn
ingCode.con1('NEW_WITH_UNDEFINED_CONSTRUCTOR', 49, "The class '%s' does not have
a constructor '%s'"); | 2629 static final StaticWarningCode NEW_WITH_UNDEFINED_CONSTRUCTOR = new StaticWarn
ingCode.con1('NEW_WITH_UNDEFINED_CONSTRUCTOR', 46, "The class '%s' does not have
a constructor '%s'"); |
| 2615 | 2630 |
| 2616 /** | 2631 /** |
| 2617 * 12.11.1 New: If <i>T</i> is a class or parameterized type accessible in the
current scope then: | 2632 * 12.11.1 New: If <i>T</i> is a class or parameterized type accessible in the
current scope then: |
| 2618 * 1. If <i>e</i> is of the form <i>new T.id(a<sub>1</sub>, …, a<sub>n<
/sub>, | 2633 * 1. If <i>e</i> is of the form <i>new T.id(a<sub>1</sub>, …, a<sub>n<
/sub>, |
| 2619 * x<sub>n+1</sub>: a<sub>n+1</sub>, …, x<sub>n+k</sub>: a<sub>n+k</sub
>)</i> it is a | 2634 * x<sub>n+1</sub>: a<sub>n+1</sub>, …, x<sub>n+k</sub>: a<sub>n+k</sub
>)</i> it is a |
| 2620 * static warning if <i>T.id</i> is not the name of a constructor declared by
the type <i>T</i>. | 2635 * static warning if <i>T.id</i> is not the name of a constructor declared by
the type <i>T</i>. |
| 2621 * If <i>e</i> of the form <i>new T(a<sub>1</sub>, …, a<sub>n</sub>, x<
sub>n+1</sub>: | 2636 * If <i>e</i> of the form <i>new T(a<sub>1</sub>, …, a<sub>n</sub>, x<
sub>n+1</sub>: |
| 2622 * a<sub>n+1</sub>, … x<sub>n+k</sub>: a<sub>n+kM/sub>)</i> it is a sta
tic warning if the | 2637 * a<sub>n+1</sub>, … x<sub>n+k</sub>: a<sub>n+kM/sub>)</i> it is a sta
tic warning if the |
| 2623 * type <i>T</i> does not declare a constructor with the same name as the decl
aration of <i>T</i>. | 2638 * type <i>T</i> does not declare a constructor with the same name as the decl
aration of <i>T</i>. |
| 2624 */ | 2639 */ |
| 2625 static final StaticWarningCode NEW_WITH_UNDEFINED_CONSTRUCTOR_DEFAULT = new St
aticWarningCode.con1('NEW_WITH_UNDEFINED_CONSTRUCTOR_DEFAULT', 50, "The class '%
s' does not have a default constructor"); | 2640 static final StaticWarningCode NEW_WITH_UNDEFINED_CONSTRUCTOR_DEFAULT = new St
aticWarningCode.con1('NEW_WITH_UNDEFINED_CONSTRUCTOR_DEFAULT', 47, "The class '%
s' does not have a default constructor"); |
| 2626 | 2641 |
| 2627 /** | 2642 /** |
| 2628 * 7.9.1 Inheritance and Overriding: It is a static warning if a non-abstract
class inherits an | 2643 * 7.9.1 Inheritance and Overriding: It is a static warning if a non-abstract
class inherits an |
| 2629 * abstract method. | 2644 * abstract method. |
| 2630 * | 2645 * |
| 2631 * 7.10 Superinterfaces: Let <i>C</i> be a concrete class that does not declar
e its own | 2646 * 7.10 Superinterfaces: Let <i>C</i> be a concrete class that does not declar
e its own |
| 2632 * <i>noSuchMethod()</i> method. It is a static warning if the implicit interf
ace of <i>C</i> | 2647 * <i>noSuchMethod()</i> method. It is a static warning if the implicit interf
ace of <i>C</i> |
| 2633 * includes an instance member <i>m</i> of type <i>F</i> and <i>C</i> does not
declare or inherit | 2648 * includes an instance member <i>m</i> of type <i>F</i> and <i>C</i> does not
declare or inherit |
| 2634 * a corresponding instance member <i>m</i> of type <i>F'</i> such that <i>F'
<: F</i>. | 2649 * a corresponding instance member <i>m</i> of type <i>F'</i> such that <i>F'
<: F</i>. |
| 2635 * | 2650 * |
| 2636 * 7.4 Abstract Instance Members: It is a static warning if an abstract member
is declared or | 2651 * 7.4 Abstract Instance Members: It is a static warning if an abstract member
is declared or |
| 2637 * inherited in a concrete class unless that member overrides a concrete one. | 2652 * inherited in a concrete class unless that member overrides a concrete one. |
| 2638 * | 2653 * |
| 2639 * @param memberName the name of the first member | 2654 * @param memberName the name of the first member |
| 2640 * @param memberName the name of the second member | 2655 * @param memberName the name of the second member |
| 2641 * @param memberName the name of the third member | 2656 * @param memberName the name of the third member |
| 2642 * @param memberName the name of the fourth member | 2657 * @param memberName the name of the fourth member |
| 2643 * @param additionalCount the number of additional missing members that aren't
listed | 2658 * @param additionalCount the number of additional missing members that aren't
listed |
| 2644 */ | 2659 */ |
| 2645 static final StaticWarningCode NON_ABSTRACT_CLASS_INHERITS_ABSTRACT_MEMBER_FIV
E_PLUS = new StaticWarningCode.con1('NON_ABSTRACT_CLASS_INHERITS_ABSTRACT_MEMBER
_FIVE_PLUS', 51, "Missing inherited members: '%s', '%s', '%s', '%s' and %d more"
); | 2660 static final StaticWarningCode NON_ABSTRACT_CLASS_INHERITS_ABSTRACT_MEMBER_FIV
E_PLUS = new StaticWarningCode.con1('NON_ABSTRACT_CLASS_INHERITS_ABSTRACT_MEMBER
_FIVE_PLUS', 48, "Missing inherited members: '%s', '%s', '%s', '%s' and %d more"
); |
| 2646 | 2661 |
| 2647 /** | 2662 /** |
| 2648 * 7.9.1 Inheritance and Overriding: It is a static warning if a non-abstract
class inherits an | 2663 * 7.9.1 Inheritance and Overriding: It is a static warning if a non-abstract
class inherits an |
| 2649 * abstract method. | 2664 * abstract method. |
| 2650 * | 2665 * |
| 2651 * 7.10 Superinterfaces: Let <i>C</i> be a concrete class that does not declar
e its own | 2666 * 7.10 Superinterfaces: Let <i>C</i> be a concrete class that does not declar
e its own |
| 2652 * <i>noSuchMethod()</i> method. It is a static warning if the implicit interf
ace of <i>C</i> | 2667 * <i>noSuchMethod()</i> method. It is a static warning if the implicit interf
ace of <i>C</i> |
| 2653 * includes an instance member <i>m</i> of type <i>F</i> and <i>C</i> does not
declare or inherit | 2668 * includes an instance member <i>m</i> of type <i>F</i> and <i>C</i> does not
declare or inherit |
| 2654 * a corresponding instance member <i>m</i> of type <i>F'</i> such that <i>F'
<: F</i>. | 2669 * a corresponding instance member <i>m</i> of type <i>F'</i> such that <i>F'
<: F</i>. |
| 2655 * | 2670 * |
| 2656 * 7.4 Abstract Instance Members: It is a static warning if an abstract member
is declared or | 2671 * 7.4 Abstract Instance Members: It is a static warning if an abstract member
is declared or |
| 2657 * inherited in a concrete class unless that member overrides a concrete one. | 2672 * inherited in a concrete class unless that member overrides a concrete one. |
| 2658 * | 2673 * |
| 2659 * @param memberName the name of the first member | 2674 * @param memberName the name of the first member |
| 2660 * @param memberName the name of the second member | 2675 * @param memberName the name of the second member |
| 2661 * @param memberName the name of the third member | 2676 * @param memberName the name of the third member |
| 2662 * @param memberName the name of the fourth member | 2677 * @param memberName the name of the fourth member |
| 2663 */ | 2678 */ |
| 2664 static final StaticWarningCode NON_ABSTRACT_CLASS_INHERITS_ABSTRACT_MEMBER_FOU
R = new StaticWarningCode.con1('NON_ABSTRACT_CLASS_INHERITS_ABSTRACT_MEMBER_FOUR
', 52, "Missing inherited members: '%s', '%s', '%s' and '%s'"); | 2679 static final StaticWarningCode NON_ABSTRACT_CLASS_INHERITS_ABSTRACT_MEMBER_FOU
R = new StaticWarningCode.con1('NON_ABSTRACT_CLASS_INHERITS_ABSTRACT_MEMBER_FOUR
', 49, "Missing inherited members: '%s', '%s', '%s' and '%s'"); |
| 2665 | 2680 |
| 2666 /** | 2681 /** |
| 2667 * 7.9.1 Inheritance and Overriding: It is a static warning if a non-abstract
class inherits an | 2682 * 7.9.1 Inheritance and Overriding: It is a static warning if a non-abstract
class inherits an |
| 2668 * abstract method. | 2683 * abstract method. |
| 2669 * | 2684 * |
| 2670 * 7.10 Superinterfaces: Let <i>C</i> be a concrete class that does not declar
e its own | 2685 * 7.10 Superinterfaces: Let <i>C</i> be a concrete class that does not declar
e its own |
| 2671 * <i>noSuchMethod()</i> method. It is a static warning if the implicit interf
ace of <i>C</i> | 2686 * <i>noSuchMethod()</i> method. It is a static warning if the implicit interf
ace of <i>C</i> |
| 2672 * includes an instance member <i>m</i> of type <i>F</i> and <i>C</i> does not
declare or inherit | 2687 * includes an instance member <i>m</i> of type <i>F</i> and <i>C</i> does not
declare or inherit |
| 2673 * a corresponding instance member <i>m</i> of type <i>F'</i> such that <i>F'
<: F</i>. | 2688 * a corresponding instance member <i>m</i> of type <i>F'</i> such that <i>F'
<: F</i>. |
| 2674 * | 2689 * |
| 2675 * 7.4 Abstract Instance Members: It is a static warning if an abstract member
is declared or | 2690 * 7.4 Abstract Instance Members: It is a static warning if an abstract member
is declared or |
| 2676 * inherited in a concrete class unless that member overrides a concrete one. | 2691 * inherited in a concrete class unless that member overrides a concrete one. |
| 2677 * | 2692 * |
| 2678 * @param memberName the name of the member | 2693 * @param memberName the name of the member |
| 2679 */ | 2694 */ |
| 2680 static final StaticWarningCode NON_ABSTRACT_CLASS_INHERITS_ABSTRACT_MEMBER_ONE
= new StaticWarningCode.con1('NON_ABSTRACT_CLASS_INHERITS_ABSTRACT_MEMBER_ONE',
53, "Missing inherited member '%s'"); | 2695 static final StaticWarningCode NON_ABSTRACT_CLASS_INHERITS_ABSTRACT_MEMBER_ONE
= new StaticWarningCode.con1('NON_ABSTRACT_CLASS_INHERITS_ABSTRACT_MEMBER_ONE',
50, "Missing inherited member '%s'"); |
| 2681 | 2696 |
| 2682 /** | 2697 /** |
| 2683 * 7.9.1 Inheritance and Overriding: It is a static warning if a non-abstract
class inherits an | 2698 * 7.9.1 Inheritance and Overriding: It is a static warning if a non-abstract
class inherits an |
| 2684 * abstract method. | 2699 * abstract method. |
| 2685 * | 2700 * |
| 2686 * 7.10 Superinterfaces: Let <i>C</i> be a concrete class that does not declar
e its own | 2701 * 7.10 Superinterfaces: Let <i>C</i> be a concrete class that does not declar
e its own |
| 2687 * <i>noSuchMethod()</i> method. It is a static warning if the implicit interf
ace of <i>C</i> | 2702 * <i>noSuchMethod()</i> method. It is a static warning if the implicit interf
ace of <i>C</i> |
| 2688 * includes an instance member <i>m</i> of type <i>F</i> and <i>C</i> does not
declare or inherit | 2703 * includes an instance member <i>m</i> of type <i>F</i> and <i>C</i> does not
declare or inherit |
| 2689 * a corresponding instance member <i>m</i> of type <i>F'</i> such that <i>F'
<: F</i>. | 2704 * a corresponding instance member <i>m</i> of type <i>F'</i> such that <i>F'
<: F</i>. |
| 2690 * | 2705 * |
| 2691 * 7.4 Abstract Instance Members: It is a static warning if an abstract member
is declared or | 2706 * 7.4 Abstract Instance Members: It is a static warning if an abstract member
is declared or |
| 2692 * inherited in a concrete class unless that member overrides a concrete one. | 2707 * inherited in a concrete class unless that member overrides a concrete one. |
| 2693 * | 2708 * |
| 2694 * @param memberName the name of the first member | 2709 * @param memberName the name of the first member |
| 2695 * @param memberName the name of the second member | 2710 * @param memberName the name of the second member |
| 2696 * @param memberName the name of the third member | 2711 * @param memberName the name of the third member |
| 2697 */ | 2712 */ |
| 2698 static final StaticWarningCode NON_ABSTRACT_CLASS_INHERITS_ABSTRACT_MEMBER_THR
EE = new StaticWarningCode.con1('NON_ABSTRACT_CLASS_INHERITS_ABSTRACT_MEMBER_THR
EE', 54, "Missing inherited members: '%s', '%s' and '%s'"); | 2713 static final StaticWarningCode NON_ABSTRACT_CLASS_INHERITS_ABSTRACT_MEMBER_THR
EE = new StaticWarningCode.con1('NON_ABSTRACT_CLASS_INHERITS_ABSTRACT_MEMBER_THR
EE', 51, "Missing inherited members: '%s', '%s' and '%s'"); |
| 2699 | 2714 |
| 2700 /** | 2715 /** |
| 2701 * 7.9.1 Inheritance and Overriding: It is a static warning if a non-abstract
class inherits an | 2716 * 7.9.1 Inheritance and Overriding: It is a static warning if a non-abstract
class inherits an |
| 2702 * abstract method. | 2717 * abstract method. |
| 2703 * | 2718 * |
| 2704 * 7.10 Superinterfaces: Let <i>C</i> be a concrete class that does not declar
e its own | 2719 * 7.10 Superinterfaces: Let <i>C</i> be a concrete class that does not declar
e its own |
| 2705 * <i>noSuchMethod()</i> method. It is a static warning if the implicit interf
ace of <i>C</i> | 2720 * <i>noSuchMethod()</i> method. It is a static warning if the implicit interf
ace of <i>C</i> |
| 2706 * includes an instance member <i>m</i> of type <i>F</i> and <i>C</i> does not
declare or inherit | 2721 * includes an instance member <i>m</i> of type <i>F</i> and <i>C</i> does not
declare or inherit |
| 2707 * a corresponding instance member <i>m</i> of type <i>F'</i> such that <i>F'
<: F</i>. | 2722 * a corresponding instance member <i>m</i> of type <i>F'</i> such that <i>F'
<: F</i>. |
| 2708 * | 2723 * |
| 2709 * 7.4 Abstract Instance Members: It is a static warning if an abstract member
is declared or | 2724 * 7.4 Abstract Instance Members: It is a static warning if an abstract member
is declared or |
| 2710 * inherited in a concrete class unless that member overrides a concrete one. | 2725 * inherited in a concrete class unless that member overrides a concrete one. |
| 2711 * | 2726 * |
| 2712 * @param memberName the name of the first member | 2727 * @param memberName the name of the first member |
| 2713 * @param memberName the name of the second member | 2728 * @param memberName the name of the second member |
| 2714 */ | 2729 */ |
| 2715 static final StaticWarningCode NON_ABSTRACT_CLASS_INHERITS_ABSTRACT_MEMBER_TWO
= new StaticWarningCode.con1('NON_ABSTRACT_CLASS_INHERITS_ABSTRACT_MEMBER_TWO',
55, "Missing inherited members: '%s' and '%s'"); | 2730 static final StaticWarningCode NON_ABSTRACT_CLASS_INHERITS_ABSTRACT_MEMBER_TWO
= new StaticWarningCode.con1('NON_ABSTRACT_CLASS_INHERITS_ABSTRACT_MEMBER_TWO',
52, "Missing inherited members: '%s' and '%s'"); |
| 2716 | 2731 |
| 2717 /** | 2732 /** |
| 2718 * 13.11 Try: An on-catch clause of the form <i>on T catch (p<sub>1</sub>, p<s
ub>2</sub>) s</i> or | 2733 * 13.11 Try: An on-catch clause of the form <i>on T catch (p<sub>1</sub>, p<s
ub>2</sub>) s</i> or |
| 2719 * <i>on T s</i> matches an object <i>o</i> if the type of <i>o</i> is a subty
pe of <i>T</i>. It | 2734 * <i>on T s</i> matches an object <i>o</i> if the type of <i>o</i> is a subty
pe of <i>T</i>. It |
| 2720 * is a static warning if <i>T</i> does not denote a type available in the lex
ical scope of the | 2735 * is a static warning if <i>T</i> does not denote a type available in the lex
ical scope of the |
| 2721 * catch clause. | 2736 * catch clause. |
| 2722 * | 2737 * |
| 2723 * @param name the name of the non-type element | 2738 * @param name the name of the non-type element |
| 2724 */ | 2739 */ |
| 2725 static final StaticWarningCode NON_TYPE_IN_CATCH_CLAUSE = new StaticWarningCod
e.con1('NON_TYPE_IN_CATCH_CLAUSE', 56, "The name '%s' is not a type and cannot b
e used in an on-catch clause"); | 2740 static final StaticWarningCode NON_TYPE_IN_CATCH_CLAUSE = new StaticWarningCod
e.con1('NON_TYPE_IN_CATCH_CLAUSE', 53, "The name '%s' is not a type and cannot b
e used in an on-catch clause"); |
| 2726 | 2741 |
| 2727 /** | 2742 /** |
| 2728 * 7.1.1 Operators: It is a static warning if the return type of the user-decl
ared operator []= is | 2743 * 7.1.1 Operators: It is a static warning if the return type of the user-decl
ared operator []= is |
| 2729 * explicitly declared and not void. | 2744 * explicitly declared and not void. |
| 2730 */ | 2745 */ |
| 2731 static final StaticWarningCode NON_VOID_RETURN_FOR_OPERATOR = new StaticWarnin
gCode.con1('NON_VOID_RETURN_FOR_OPERATOR', 57, "The return type of the operator
[]= must be 'void'"); | 2746 static final StaticWarningCode NON_VOID_RETURN_FOR_OPERATOR = new StaticWarnin
gCode.con1('NON_VOID_RETURN_FOR_OPERATOR', 54, "The return type of the operator
[]= must be 'void'"); |
| 2732 | 2747 |
| 2733 /** | 2748 /** |
| 2734 * 7.3 Setters: It is a static warning if a setter declares a return type othe
r than void. | 2749 * 7.3 Setters: It is a static warning if a setter declares a return type othe
r than void. |
| 2735 */ | 2750 */ |
| 2736 static final StaticWarningCode NON_VOID_RETURN_FOR_SETTER = new StaticWarningC
ode.con1('NON_VOID_RETURN_FOR_SETTER', 58, "The return type of the setter must b
e 'void'"); | 2751 static final StaticWarningCode NON_VOID_RETURN_FOR_SETTER = new StaticWarningC
ode.con1('NON_VOID_RETURN_FOR_SETTER', 55, "The return type of the setter must b
e 'void'"); |
| 2737 | 2752 |
| 2738 /** | 2753 /** |
| 2739 * 15.1 Static Types: A type <i>T</i> is malformed iff: * <i>T</i> has the for
m <i>id</i> or the | 2754 * 15.1 Static Types: A type <i>T</i> is malformed iff: * <i>T</i> has the for
m <i>id</i> or the |
| 2740 * form <i>prefix.id</i>, and in the enclosing lexical scope, the name <i>id</
i> (respectively | 2755 * form <i>prefix.id</i>, and in the enclosing lexical scope, the name <i>id</
i> (respectively |
| 2741 * <i>prefix.id</i>) does not denote a type. * <i>T</i> denotes a type paramet
er in the | 2756 * <i>prefix.id</i>) does not denote a type. * <i>T</i> denotes a type paramet
er in the |
| 2742 * enclosing lexical scope, but occurs in the signature or body of a static me
mber. * | 2757 * enclosing lexical scope, but occurs in the signature or body of a static me
mber. * |
| 2743 * <i>T</i> is a parameterized type of the form <i>G<S<sub>1</sub>, .., S<s
ub>n</sub>></i>, | 2758 * <i>T</i> is a parameterized type of the form <i>G<S<sub>1</sub>, .., S<s
ub>n</sub>></i>, |
| 2744 * and <i>G</i> is malformed. | 2759 * and <i>G</i> is malformed. |
| 2745 * | 2760 * |
| 2746 * Any use of a malformed type gives rise to a static warning. | 2761 * Any use of a malformed type gives rise to a static warning. |
| 2747 * | 2762 * |
| 2748 * @param nonTypeName the name that is not a type | 2763 * @param nonTypeName the name that is not a type |
| 2749 */ | 2764 */ |
| 2750 static final StaticWarningCode NOT_A_TYPE = new StaticWarningCode.con1('NOT_A_
TYPE', 59, "%s is not a type"); | 2765 static final StaticWarningCode NOT_A_TYPE = new StaticWarningCode.con1('NOT_A_
TYPE', 56, "%s is not a type"); |
| 2751 | 2766 |
| 2752 /** | 2767 /** |
| 2753 * 12.14.2 Binding Actuals to Formals: It is a static warning if <i>m < h</
i> or if <i>m > | 2768 * 12.14.2 Binding Actuals to Formals: It is a static warning if <i>m < h</
i> or if <i>m > |
| 2754 * n</i>. | 2769 * n</i>. |
| 2755 * | 2770 * |
| 2756 * @param requiredCount the expected number of required arguments | 2771 * @param requiredCount the expected number of required arguments |
| 2757 * @param argumentCount the actual number of positional arguments given | 2772 * @param argumentCount the actual number of positional arguments given |
| 2758 * @see #EXTRA_POSITIONAL_ARGUMENTS | 2773 * @see #EXTRA_POSITIONAL_ARGUMENTS |
| 2759 */ | 2774 */ |
| 2760 static final StaticWarningCode NOT_ENOUGH_REQUIRED_ARGUMENTS = new StaticWarni
ngCode.con1('NOT_ENOUGH_REQUIRED_ARGUMENTS', 60, "%d required argument(s) expect
ed, but %d found"); | 2775 static final StaticWarningCode NOT_ENOUGH_REQUIRED_ARGUMENTS = new StaticWarni
ngCode.con1('NOT_ENOUGH_REQUIRED_ARGUMENTS', 57, "%d required argument(s) expect
ed, but %d found"); |
| 2761 | 2776 |
| 2762 /** | 2777 /** |
| 2763 * 14.3 Parts: It is a static warning if the referenced part declaration <i>p<
/i> names a library | 2778 * 14.3 Parts: It is a static warning if the referenced part declaration <i>p<
/i> names a library |
| 2764 * other than the current library as the library to which <i>p</i> belongs. | 2779 * other than the current library as the library to which <i>p</i> belongs. |
| 2765 * | 2780 * |
| 2766 * @param expectedLibraryName the name of expected library name | 2781 * @param expectedLibraryName the name of expected library name |
| 2767 * @param actualLibraryName the non-matching actual library name from the "par
t of" declaration | 2782 * @param actualLibraryName the non-matching actual library name from the "par
t of" declaration |
| 2768 */ | 2783 */ |
| 2769 static final StaticWarningCode PART_OF_DIFFERENT_LIBRARY = new StaticWarningCo
de.con1('PART_OF_DIFFERENT_LIBRARY', 61, "Expected this library to be part of '%
s', not '%s'"); | 2784 static final StaticWarningCode PART_OF_DIFFERENT_LIBRARY = new StaticWarningCo
de.con1('PART_OF_DIFFERENT_LIBRARY', 58, "Expected this library to be part of '%
s', not '%s'"); |
| 2770 | 2785 |
| 2771 /** | 2786 /** |
| 2772 * 7.6.2 Factories: It is a static warning if the function type of <i>k'</i> i
s not a subtype of | 2787 * 7.6.2 Factories: It is a static warning if the function type of <i>k'</i> i
s not a subtype of |
| 2773 * the type of <i>k</i>. | 2788 * the type of <i>k</i>. |
| 2774 * | 2789 * |
| 2775 * @param redirectedName the name of the redirected constructor | 2790 * @param redirectedName the name of the redirected constructor |
| 2776 * @param redirectingName the name of the redirecting constructor | 2791 * @param redirectingName the name of the redirecting constructor |
| 2777 */ | 2792 */ |
| 2778 static final StaticWarningCode REDIRECT_TO_INVALID_FUNCTION_TYPE = new StaticW
arningCode.con1('REDIRECT_TO_INVALID_FUNCTION_TYPE', 62, "The redirected constru
ctor '%s' has incompatible parameters with '%s'"); | 2793 static final StaticWarningCode REDIRECT_TO_INVALID_FUNCTION_TYPE = new StaticW
arningCode.con1('REDIRECT_TO_INVALID_FUNCTION_TYPE', 59, "The redirected constru
ctor '%s' has incompatible parameters with '%s'"); |
| 2779 | 2794 |
| 2780 /** | 2795 /** |
| 2781 * 7.6.2 Factories: It is a static warning if the function type of <i>k'</i> i
s not a subtype of | 2796 * 7.6.2 Factories: It is a static warning if the function type of <i>k'</i> i
s not a subtype of |
| 2782 * the type of <i>k</i>. | 2797 * the type of <i>k</i>. |
| 2783 * | 2798 * |
| 2784 * @param redirectedName the name of the redirected constructor return type | 2799 * @param redirectedName the name of the redirected constructor return type |
| 2785 * @param redirectingName the name of the redirecting constructor return type | 2800 * @param redirectingName the name of the redirecting constructor return type |
| 2786 */ | 2801 */ |
| 2787 static final StaticWarningCode REDIRECT_TO_INVALID_RETURN_TYPE = new StaticWar
ningCode.con1('REDIRECT_TO_INVALID_RETURN_TYPE', 63, "The return type '%s' of th
e redirected constructor is not assignable to '%s'"); | 2802 static final StaticWarningCode REDIRECT_TO_INVALID_RETURN_TYPE = new StaticWar
ningCode.con1('REDIRECT_TO_INVALID_RETURN_TYPE', 60, "The return type '%s' of th
e redirected constructor is not assignable to '%s'"); |
| 2788 | 2803 |
| 2789 /** | 2804 /** |
| 2790 * 7.6.2 Factories: It is a static warning if type does not denote a class acc
essible in the | 2805 * 7.6.2 Factories: It is a static warning if type does not denote a class acc
essible in the |
| 2791 * current scope; if type does denote such a class <i>C</i> it is a static war
ning if the | 2806 * current scope; if type does denote such a class <i>C</i> it is a static war
ning if the |
| 2792 * referenced constructor (be it <i>type</i> or <i>type.id</i>) is not a const
ructor of <i>C</i>. | 2807 * referenced constructor (be it <i>type</i> or <i>type.id</i>) is not a const
ructor of <i>C</i>. |
| 2793 */ | 2808 */ |
| 2794 static final StaticWarningCode REDIRECT_TO_MISSING_CONSTRUCTOR = new StaticWar
ningCode.con1('REDIRECT_TO_MISSING_CONSTRUCTOR', 64, "The constructor '%s' could
not be found in '%s'"); | 2809 static final StaticWarningCode REDIRECT_TO_MISSING_CONSTRUCTOR = new StaticWar
ningCode.con1('REDIRECT_TO_MISSING_CONSTRUCTOR', 61, "The constructor '%s' could
not be found in '%s'"); |
| 2795 | 2810 |
| 2796 /** | 2811 /** |
| 2797 * 7.6.2 Factories: It is a static warning if type does not denote a class acc
essible in the | 2812 * 7.6.2 Factories: It is a static warning if type does not denote a class acc
essible in the |
| 2798 * current scope; if type does denote such a class <i>C</i> it is a static war
ning if the | 2813 * current scope; if type does denote such a class <i>C</i> it is a static war
ning if the |
| 2799 * referenced constructor (be it <i>type</i> or <i>type.id</i>) is not a const
ructor of <i>C</i>. | 2814 * referenced constructor (be it <i>type</i> or <i>type.id</i>) is not a const
ructor of <i>C</i>. |
| 2800 */ | 2815 */ |
| 2801 static final StaticWarningCode REDIRECT_TO_NON_CLASS = new StaticWarningCode.c
on1('REDIRECT_TO_NON_CLASS', 65, "The name '%s' is not a type and cannot be used
in a redirected constructor"); | 2816 static final StaticWarningCode REDIRECT_TO_NON_CLASS = new StaticWarningCode.c
on1('REDIRECT_TO_NON_CLASS', 62, "The name '%s' is not a type and cannot be used
in a redirected constructor"); |
| 2802 | 2817 |
| 2803 /** | 2818 /** |
| 2804 * 13.11 Return: Let <i>f</i> be the function immediately enclosing a return s
tatement of the form | 2819 * 13.11 Return: Let <i>f</i> be the function immediately enclosing a return s
tatement of the form |
| 2805 * <i>return;</i> It is a static warning if both of the following conditions h
old: | 2820 * <i>return;</i> It is a static warning if both of the following conditions h
old: |
| 2806 * <ol> | 2821 * <ol> |
| 2807 * * <i>f</i> is not a generative constructor. | 2822 * * <i>f</i> is not a generative constructor. |
| 2808 * * The return type of <i>f</i> may not be assigned to void. | 2823 * * The return type of <i>f</i> may not be assigned to void. |
| 2809 * </ol> | 2824 * </ol> |
| 2810 */ | 2825 */ |
| 2811 static final StaticWarningCode RETURN_WITHOUT_VALUE = new StaticWarningCode.co
n1('RETURN_WITHOUT_VALUE', 66, "Missing return value after 'return'"); | 2826 static final StaticWarningCode RETURN_WITHOUT_VALUE = new StaticWarningCode.co
n1('RETURN_WITHOUT_VALUE', 63, "Missing return value after 'return'"); |
| 2812 | 2827 |
| 2813 /** | 2828 /** |
| 2814 * 12.15.3 Static Invocation: It is a static warning if <i>C</i> does not decl
are a static method | 2829 * 12.15.3 Static Invocation: It is a static warning if <i>C</i> does not decl
are a static method |
| 2815 * or getter <i>m</i>. | 2830 * or getter <i>m</i>. |
| 2816 * | 2831 * |
| 2817 * @param memberName the name of the instance member | 2832 * @param memberName the name of the instance member |
| 2818 */ | 2833 */ |
| 2819 static final StaticWarningCode STATIC_ACCESS_TO_INSTANCE_MEMBER = new StaticWa
rningCode.con1('STATIC_ACCESS_TO_INSTANCE_MEMBER', 67, "Instance member '%s' can
not be accessed using static access"); | 2834 static final StaticWarningCode STATIC_ACCESS_TO_INSTANCE_MEMBER = new StaticWa
rningCode.con1('STATIC_ACCESS_TO_INSTANCE_MEMBER', 64, "Instance member '%s' can
not be accessed using static access"); |
| 2820 | 2835 |
| 2821 /** | 2836 /** |
| 2822 * 13.9 Switch: It is a static warning if the type of <i>e</i> may not be assi
gned to the type of | 2837 * 13.9 Switch: It is a static warning if the type of <i>e</i> may not be assi
gned to the type of |
| 2823 * <i>e<sub>k</sub></i>. | 2838 * <i>e<sub>k</sub></i>. |
| 2824 */ | 2839 */ |
| 2825 static final StaticWarningCode SWITCH_EXPRESSION_NOT_ASSIGNABLE = new StaticWa
rningCode.con1('SWITCH_EXPRESSION_NOT_ASSIGNABLE', 68, "Type '%s' of the switch
expression is not assignable to the type '%s' of case expressions"); | 2840 static final StaticWarningCode SWITCH_EXPRESSION_NOT_ASSIGNABLE = new StaticWa
rningCode.con1('SWITCH_EXPRESSION_NOT_ASSIGNABLE', 65, "Type '%s' of the switch
expression is not assignable to the type '%s' of case expressions"); |
| 2826 | 2841 |
| 2827 /** | 2842 /** |
| 2828 * 12.31 Type Test: It is a static warning if <i>T</i> does not denote a type
available in the | 2843 * 12.31 Type Test: It is a static warning if <i>T</i> does not denote a type
available in the |
| 2829 * current lexical scope. | 2844 * current lexical scope. |
| 2830 */ | 2845 */ |
| 2831 static final StaticWarningCode TYPE_TEST_NON_TYPE = new StaticWarningCode.con1
('TYPE_TEST_NON_TYPE', 69, "The name '%s' is not a type and cannot be used in an
'is' expression"); | 2846 static final StaticWarningCode TYPE_TEST_NON_TYPE = new StaticWarningCode.con1
('TYPE_TEST_NON_TYPE', 66, "The name '%s' is not a type and cannot be used in an
'is' expression"); |
| 2832 | 2847 |
| 2833 /** | 2848 /** |
| 2834 * 10 Generics: However, a type parameter is considered to be a malformed type
when referenced by | 2849 * 10 Generics: However, a type parameter is considered to be a malformed type
when referenced by |
| 2835 * a static member. | 2850 * a static member. |
| 2836 * | 2851 * |
| 2837 * 15.1 Static Types: Any use of a malformed type gives rise to a static warni
ng. A malformed type | 2852 * 15.1 Static Types: Any use of a malformed type gives rise to a static warni
ng. A malformed type |
| 2838 * is then interpreted as dynamic by the static type checker and the runtime. | 2853 * is then interpreted as dynamic by the static type checker and the runtime. |
| 2839 */ | 2854 */ |
| 2840 static final StaticWarningCode TYPE_PARAMETER_REFERENCED_BY_STATIC = new Stati
cWarningCode.con1('TYPE_PARAMETER_REFERENCED_BY_STATIC', 70, "Static members can
not reference type parameters"); | 2855 static final StaticWarningCode TYPE_PARAMETER_REFERENCED_BY_STATIC = new Stati
cWarningCode.con1('TYPE_PARAMETER_REFERENCED_BY_STATIC', 67, "Static members can
not reference type parameters"); |
| 2841 | 2856 |
| 2842 /** | 2857 /** |
| 2843 * 12.15.3 Static Invocation: A static method invocation <i>i</i> has the form | 2858 * 12.15.3 Static Invocation: A static method invocation <i>i</i> has the form |
| 2844 * <i>C.m(a<sub>1</sub>, …, a<sub>n</sub>, x<sub>n+1</sub>: a<sub>n+1</
sub>, … | 2859 * <i>C.m(a<sub>1</sub>, …, a<sub>n</sub>, x<sub>n+1</sub>: a<sub>n+1</
sub>, … |
| 2845 * x<sub>n+k</sub>: a<sub>n+k</sub>)</i>. It is a static warning if <i>C</i> d
oes not denote a | 2860 * x<sub>n+k</sub>: a<sub>n+k</sub>)</i>. It is a static warning if <i>C</i> d
oes not denote a |
| 2846 * class in the current scope. | 2861 * class in the current scope. |
| 2847 * | 2862 * |
| 2848 * @param undefinedClassName the name of the undefined class | 2863 * @param undefinedClassName the name of the undefined class |
| 2849 */ | 2864 */ |
| 2850 static final StaticWarningCode UNDEFINED_CLASS = new StaticWarningCode.con1('U
NDEFINED_CLASS', 71, "Undefined class '%s'"); | 2865 static final StaticWarningCode UNDEFINED_CLASS = new StaticWarningCode.con1('U
NDEFINED_CLASS', 68, "Undefined class '%s'"); |
| 2851 | 2866 |
| 2852 /** | 2867 /** |
| 2853 * Same as [UNDEFINED_CLASS], but to catch using "boolean" instead of "bool". | 2868 * Same as [UNDEFINED_CLASS], but to catch using "boolean" instead of "bool". |
| 2854 */ | 2869 */ |
| 2855 static final StaticWarningCode UNDEFINED_CLASS_BOOLEAN = new StaticWarningCode
.con1('UNDEFINED_CLASS_BOOLEAN', 72, "Undefined class 'boolean'; did you mean 'b
ool'?"); | 2870 static final StaticWarningCode UNDEFINED_CLASS_BOOLEAN = new StaticWarningCode
.con1('UNDEFINED_CLASS_BOOLEAN', 69, "Undefined class 'boolean'; did you mean 'b
ool'?"); |
| 2856 | 2871 |
| 2857 /** | 2872 /** |
| 2858 * 12.17 Getter Invocation: It is a static warning if there is no class <i>C</
i> in the enclosing | 2873 * 12.17 Getter Invocation: It is a static warning if there is no class <i>C</
i> in the enclosing |
| 2859 * lexical scope of <i>i</i>, or if <i>C</i> does not declare, implicitly or e
xplicitly, a getter | 2874 * lexical scope of <i>i</i>, or if <i>C</i> does not declare, implicitly or e
xplicitly, a getter |
| 2860 * named <i>m</i>. | 2875 * named <i>m</i>. |
| 2861 * | 2876 * |
| 2862 * @param getterName the name of the getter | 2877 * @param getterName the name of the getter |
| 2863 * @param enclosingType the name of the enclosing type where the getter is bei
ng looked for | 2878 * @param enclosingType the name of the enclosing type where the getter is bei
ng looked for |
| 2864 */ | 2879 */ |
| 2865 static final StaticWarningCode UNDEFINED_GETTER = new StaticWarningCode.con1('
UNDEFINED_GETTER', 73, "There is no such getter '%s' in '%s'"); | 2880 static final StaticWarningCode UNDEFINED_GETTER = new StaticWarningCode.con1('
UNDEFINED_GETTER', 70, "There is no such getter '%s' in '%s'"); |
| 2866 | 2881 |
| 2867 /** | 2882 /** |
| 2868 * 12.30 Identifier Reference: It is as static warning if an identifier expres
sion of the form | 2883 * 12.30 Identifier Reference: It is as static warning if an identifier expres
sion of the form |
| 2869 * <i>id</i> occurs inside a top level or static function (be it function, met
hod, getter, or | 2884 * <i>id</i> occurs inside a top level or static function (be it function, met
hod, getter, or |
| 2870 * setter) or variable initializer and there is no declaration <i>d</i> with n
ame <i>id</i> in the | 2885 * setter) or variable initializer and there is no declaration <i>d</i> with n
ame <i>id</i> in the |
| 2871 * lexical scope enclosing the expression. | 2886 * lexical scope enclosing the expression. |
| 2872 * | 2887 * |
| 2873 * @param name the name of the identifier | 2888 * @param name the name of the identifier |
| 2874 */ | 2889 */ |
| 2875 static final StaticWarningCode UNDEFINED_IDENTIFIER = new StaticWarningCode.co
n1('UNDEFINED_IDENTIFIER', 74, "Undefined name '%s'"); | 2890 static final StaticWarningCode UNDEFINED_IDENTIFIER = new StaticWarningCode.co
n1('UNDEFINED_IDENTIFIER', 71, "Undefined name '%s'"); |
| 2876 | 2891 |
| 2877 /** | 2892 /** |
| 2878 * 12.14.2 Binding Actuals to Formals: Furthermore, each <i>q<sub>i</sub></i>,
<i>1<=i<=l</i>, | 2893 * 12.14.2 Binding Actuals to Formals: Furthermore, each <i>q<sub>i</sub></i>,
<i>1<=i<=l</i>, |
| 2879 * must have a corresponding named parameter in the set {<i>p<sub>n+1</sub></i
> ... | 2894 * must have a corresponding named parameter in the set {<i>p<sub>n+1</sub></i
> ... |
| 2880 * <i>p<sub>n+k</sub></i>} or a static warning occurs. | 2895 * <i>p<sub>n+k</sub></i>} or a static warning occurs. |
| 2881 * | 2896 * |
| 2882 * @param name the name of the requested named parameter | 2897 * @param name the name of the requested named parameter |
| 2883 */ | 2898 */ |
| 2884 static final StaticWarningCode UNDEFINED_NAMED_PARAMETER = new StaticWarningCo
de.con1('UNDEFINED_NAMED_PARAMETER', 75, "The named parameter '%s' is not define
d"); | 2899 static final StaticWarningCode UNDEFINED_NAMED_PARAMETER = new StaticWarningCo
de.con1('UNDEFINED_NAMED_PARAMETER', 72, "The named parameter '%s' is not define
d"); |
| 2885 | 2900 |
| 2886 /** | 2901 /** |
| 2887 * 12.18 Assignment: It is as static warning if an assignment of the form <i>v
= e</i> occurs | 2902 * 12.18 Assignment: It is as static warning if an assignment of the form <i>v
= e</i> occurs |
| 2888 * inside a top level or static function (be it function, method, getter, or s
etter) or variable | 2903 * inside a top level or static function (be it function, method, getter, or s
etter) or variable |
| 2889 * initializer and there is no declaration <i>d</i> with name <i>v=</i> in the
lexical scope | 2904 * initializer and there is no declaration <i>d</i> with name <i>v=</i> in the
lexical scope |
| 2890 * enclosing the assignment. | 2905 * enclosing the assignment. |
| 2891 * | 2906 * |
| 2892 * 12.18 Assignment: It is a static warning if there is no class <i>C</i> in t
he enclosing lexical | 2907 * 12.18 Assignment: It is a static warning if there is no class <i>C</i> in t
he enclosing lexical |
| 2893 * scope of the assignment, or if <i>C</i> does not declare, implicitly or exp
licitly, a setter | 2908 * scope of the assignment, or if <i>C</i> does not declare, implicitly or exp
licitly, a setter |
| 2894 * <i>v=</i>. | 2909 * <i>v=</i>. |
| 2895 * | 2910 * |
| 2896 * @param setterName the name of the getter | 2911 * @param setterName the name of the getter |
| 2897 * @param enclosingType the name of the enclosing type where the setter is bei
ng looked for | 2912 * @param enclosingType the name of the enclosing type where the setter is bei
ng looked for |
| 2898 */ | 2913 */ |
| 2899 static final StaticWarningCode UNDEFINED_SETTER = new StaticWarningCode.con1('
UNDEFINED_SETTER', 76, "There is no such setter '%s' in '%s'"); | 2914 static final StaticWarningCode UNDEFINED_SETTER = new StaticWarningCode.con1('
UNDEFINED_SETTER', 73, "There is no such setter '%s' in '%s'"); |
| 2900 | 2915 |
| 2901 /** | 2916 /** |
| 2902 * 12.15.3 Static Invocation: It is a static warning if <i>C</i> does not decl
are a static method | 2917 * 12.15.3 Static Invocation: It is a static warning if <i>C</i> does not decl
are a static method |
| 2903 * or getter <i>m</i>. | 2918 * or getter <i>m</i>. |
| 2904 * | 2919 * |
| 2905 * @param methodName the name of the method | 2920 * @param methodName the name of the method |
| 2906 * @param enclosingType the name of the enclosing type where the method is bei
ng looked for | 2921 * @param enclosingType the name of the enclosing type where the method is bei
ng looked for |
| 2907 */ | 2922 */ |
| 2908 static final StaticWarningCode UNDEFINED_STATIC_METHOD_OR_GETTER = new StaticW
arningCode.con1('UNDEFINED_STATIC_METHOD_OR_GETTER', 77, "There is no such stati
c method '%s' in '%s'"); | 2923 static final StaticWarningCode UNDEFINED_STATIC_METHOD_OR_GETTER = new StaticW
arningCode.con1('UNDEFINED_STATIC_METHOD_OR_GETTER', 74, "There is no such stati
c method '%s' in '%s'"); |
| 2909 static final List<StaticWarningCode> values = [ | 2924 static final List<StaticWarningCode> values = [ |
| 2910 AMBIGUOUS_IMPORT, | 2925 AMBIGUOUS_IMPORT, |
| 2911 ARGUMENT_TYPE_NOT_ASSIGNABLE, | 2926 ARGUMENT_TYPE_NOT_ASSIGNABLE, |
| 2912 ASSIGNMENT_TO_CONST, | 2927 ASSIGNMENT_TO_CONST, |
| 2913 ASSIGNMENT_TO_FINAL, | 2928 ASSIGNMENT_TO_FINAL, |
| 2914 ASSIGNMENT_TO_METHOD, | 2929 ASSIGNMENT_TO_METHOD, |
| 2915 CASE_BLOCK_NOT_TERMINATED, | 2930 CASE_BLOCK_NOT_TERMINATED, |
| 2916 CAST_TO_NON_TYPE, | 2931 CAST_TO_NON_TYPE, |
| 2917 COMMENT_REFERENCE_CONSTRUCTOR_NOT_VISIBLE, | |
| 2918 COMMENT_REFERENCE_IDENTIFIER_NOT_VISIBLE, | |
| 2919 COMMENT_REFERENCE_UNDECLARED_CONSTRUCTOR, | |
| 2920 COMMENT_REFERENCE_UNDECLARED_IDENTIFIER, | |
| 2921 COMMENT_REFERENCE_URI_NOT_LIBRARY, | |
| 2922 CONCRETE_CLASS_WITH_ABSTRACT_MEMBER, | 2932 CONCRETE_CLASS_WITH_ABSTRACT_MEMBER, |
| 2923 CONFLICTING_DART_IMPORT, | 2933 CONFLICTING_DART_IMPORT, |
| 2924 CONFLICTING_INSTANCE_GETTER_AND_SUPERCLASS_MEMBER, | 2934 CONFLICTING_INSTANCE_GETTER_AND_SUPERCLASS_MEMBER, |
| 2925 CONFLICTING_INSTANCE_SETTER_AND_SUPERCLASS_MEMBER, | 2935 CONFLICTING_INSTANCE_SETTER_AND_SUPERCLASS_MEMBER, |
| 2926 CONFLICTING_STATIC_GETTER_AND_INSTANCE_SETTER, | 2936 CONFLICTING_STATIC_GETTER_AND_INSTANCE_SETTER, |
| 2927 CONFLICTING_STATIC_SETTER_AND_INSTANCE_MEMBER, | 2937 CONFLICTING_STATIC_SETTER_AND_INSTANCE_MEMBER, |
| 2928 CONST_WITH_ABSTRACT_CLASS, | 2938 CONST_WITH_ABSTRACT_CLASS, |
| 2929 EQUAL_KEYS_IN_MAP, | 2939 EQUAL_KEYS_IN_MAP, |
| 2930 EXPORT_DUPLICATED_LIBRARY_NAME, | 2940 EXPORT_DUPLICATED_LIBRARY_NAME, |
| 2931 EXTRA_POSITIONAL_ARGUMENTS, | 2941 EXTRA_POSITIONAL_ARGUMENTS, |
| (...skipping 14 matching lines...) Expand all Loading... |
| 2946 INVALID_OVERRIDE_DIFFERENT_DEFAULT_VALUES_NAMED, | 2956 INVALID_OVERRIDE_DIFFERENT_DEFAULT_VALUES_NAMED, |
| 2947 INVALID_OVERRIDE_DIFFERENT_DEFAULT_VALUES_POSITIONAL, | 2957 INVALID_OVERRIDE_DIFFERENT_DEFAULT_VALUES_POSITIONAL, |
| 2948 INVALID_OVERRIDE_NAMED, | 2958 INVALID_OVERRIDE_NAMED, |
| 2949 INVALID_OVERRIDE_POSITIONAL, | 2959 INVALID_OVERRIDE_POSITIONAL, |
| 2950 INVALID_OVERRIDE_REQUIRED, | 2960 INVALID_OVERRIDE_REQUIRED, |
| 2951 INVALID_SETTER_OVERRIDE_NORMAL_PARAM_TYPE, | 2961 INVALID_SETTER_OVERRIDE_NORMAL_PARAM_TYPE, |
| 2952 LIST_ELEMENT_TYPE_NOT_ASSIGNABLE, | 2962 LIST_ELEMENT_TYPE_NOT_ASSIGNABLE, |
| 2953 MAP_KEY_TYPE_NOT_ASSIGNABLE, | 2963 MAP_KEY_TYPE_NOT_ASSIGNABLE, |
| 2954 MAP_VALUE_TYPE_NOT_ASSIGNABLE, | 2964 MAP_VALUE_TYPE_NOT_ASSIGNABLE, |
| 2955 MISMATCHED_GETTER_AND_SETTER_TYPES, | 2965 MISMATCHED_GETTER_AND_SETTER_TYPES, |
| 2966 MISMATCHED_GETTER_AND_SETTER_TYPES_FROM_SUPERTYPE, |
| 2967 MIXED_RETURN_TYPES, |
| 2956 NEW_WITH_ABSTRACT_CLASS, | 2968 NEW_WITH_ABSTRACT_CLASS, |
| 2957 NEW_WITH_INVALID_TYPE_PARAMETERS, | 2969 NEW_WITH_INVALID_TYPE_PARAMETERS, |
| 2958 NEW_WITH_NON_TYPE, | 2970 NEW_WITH_NON_TYPE, |
| 2959 NEW_WITH_UNDEFINED_CONSTRUCTOR, | 2971 NEW_WITH_UNDEFINED_CONSTRUCTOR, |
| 2960 NEW_WITH_UNDEFINED_CONSTRUCTOR_DEFAULT, | 2972 NEW_WITH_UNDEFINED_CONSTRUCTOR_DEFAULT, |
| 2961 NON_ABSTRACT_CLASS_INHERITS_ABSTRACT_MEMBER_FIVE_PLUS, | 2973 NON_ABSTRACT_CLASS_INHERITS_ABSTRACT_MEMBER_FIVE_PLUS, |
| 2962 NON_ABSTRACT_CLASS_INHERITS_ABSTRACT_MEMBER_FOUR, | 2974 NON_ABSTRACT_CLASS_INHERITS_ABSTRACT_MEMBER_FOUR, |
| 2963 NON_ABSTRACT_CLASS_INHERITS_ABSTRACT_MEMBER_ONE, | 2975 NON_ABSTRACT_CLASS_INHERITS_ABSTRACT_MEMBER_ONE, |
| 2964 NON_ABSTRACT_CLASS_INHERITS_ABSTRACT_MEMBER_THREE, | 2976 NON_ABSTRACT_CLASS_INHERITS_ABSTRACT_MEMBER_THREE, |
| 2965 NON_ABSTRACT_CLASS_INHERITS_ABSTRACT_MEMBER_TWO, | 2977 NON_ABSTRACT_CLASS_INHERITS_ABSTRACT_MEMBER_TWO, |
| (...skipping 451 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 3417 */ | 3429 */ |
| 3418 StaticTypeWarningCode.con2(String name, int ordinal, String message, String co
rrection) : super(name, ordinal) { | 3430 StaticTypeWarningCode.con2(String name, int ordinal, String message, String co
rrection) : super(name, ordinal) { |
| 3419 this._message = message; | 3431 this._message = message; |
| 3420 this.correction6 = correction; | 3432 this.correction6 = correction; |
| 3421 } | 3433 } |
| 3422 String get correction => correction6; | 3434 String get correction => correction6; |
| 3423 ErrorSeverity get errorSeverity => ErrorType.STATIC_TYPE_WARNING.severity; | 3435 ErrorSeverity get errorSeverity => ErrorType.STATIC_TYPE_WARNING.severity; |
| 3424 String get message => _message; | 3436 String get message => _message; |
| 3425 ErrorType get type => ErrorType.STATIC_TYPE_WARNING; | 3437 ErrorType get type => ErrorType.STATIC_TYPE_WARNING; |
| 3426 } | 3438 } |
| OLD | NEW |