| OLD | NEW |
| 1 // Copyright (c) 2011, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2011, the Dart project authors. Please see the AUTHORS file |
| 2 // for details. All rights reserved. Use of this source code is governed by a | 2 // for details. All rights reserved. Use of this source code is governed by a |
| 3 // BSD-style license that can be found in the LICENSE file. | 3 // BSD-style license that can be found in the LICENSE file. |
| 4 | 4 |
| 5 | 5 |
| 6 /** | 6 /** |
| 7 * The messages in this file should meet the following guide lines: | 7 * The messages in this file should meet the following guide lines: |
| 8 * | 8 * |
| 9 * 1. The message should be a complete sentence starting with an uppercase | 9 * 1. The message should be a complete sentence starting with an uppercase |
| 10 * letter, and ending with a period. | 10 * letter, and ending with a period. |
| (...skipping 170 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 181 DUPLICATED_LIBRARY_NAME, | 181 DUPLICATED_LIBRARY_NAME, |
| 182 DUPLICATED_LIBRARY_RESOURCE, | 182 DUPLICATED_LIBRARY_RESOURCE, |
| 183 DUPLICATED_PART_OF, | 183 DUPLICATED_PART_OF, |
| 184 DUPLICATED_RESOURCE, | 184 DUPLICATED_RESOURCE, |
| 185 EMPTY_CATCH_DECLARATION, | 185 EMPTY_CATCH_DECLARATION, |
| 186 EMPTY_ENUM_DECLARATION, | 186 EMPTY_ENUM_DECLARATION, |
| 187 EQUAL_MAP_ENTRY_KEY, | 187 EQUAL_MAP_ENTRY_KEY, |
| 188 EXISTING_DEFINITION, | 188 EXISTING_DEFINITION, |
| 189 EXISTING_LABEL, | 189 EXISTING_LABEL, |
| 190 EXPECTED_IDENTIFIER_NOT_RESERVED_WORD, | 190 EXPECTED_IDENTIFIER_NOT_RESERVED_WORD, |
| 191 EXPERIMENTAL_ASSERT_MESSAGE, |
| 191 EXPONENT_MISSING, | 192 EXPONENT_MISSING, |
| 192 EXPORT_BEFORE_PARTS, | 193 EXPORT_BEFORE_PARTS, |
| 193 EXTERNAL_WITH_BODY, | 194 EXTERNAL_WITH_BODY, |
| 194 EXTRA_CATCH_DECLARATION, | 195 EXTRA_CATCH_DECLARATION, |
| 195 EXTRA_FORMALS, | 196 EXTRA_FORMALS, |
| 196 EXTRANEOUS_MODIFIER, | 197 EXTRANEOUS_MODIFIER, |
| 197 EXTRANEOUS_MODIFIER_REPLACE, | 198 EXTRANEOUS_MODIFIER_REPLACE, |
| 198 FACTORY_REDIRECTION_IN_NON_FACTORY, | 199 FACTORY_REDIRECTION_IN_NON_FACTORY, |
| 199 FINAL_FUNCTION_TYPE_PARAMETER, | 200 FINAL_FUNCTION_TYPE_PARAMETER, |
| 200 FINAL_WITHOUT_INITIALIZER, | 201 FINAL_WITHOUT_INITIALIZER, |
| (...skipping 3061 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 3262 main() => foo(); | 3263 main() => foo(); |
| 3263 """, """ | 3264 """, """ |
| 3264 external foo() {} | 3265 external foo() {} |
| 3265 main() => foo(); | 3266 main() => foo(); |
| 3266 """]), | 3267 """]), |
| 3267 | 3268 |
| 3268 ////////////////////////////////////////////////////////////////////////////// | 3269 ////////////////////////////////////////////////////////////////////////////// |
| 3269 // Patch errors end. | 3270 // Patch errors end. |
| 3270 ////////////////////////////////////////////////////////////////////////////// | 3271 ////////////////////////////////////////////////////////////////////////////// |
| 3271 | 3272 |
| 3273 MessageKind.EXPERIMENTAL_ASSERT_MESSAGE: |
| 3274 const MessageTemplate(MessageKind.EXPERIMENTAL_ASSERT_MESSAGE, |
| 3275 "Experimental language feature 'assertion with message'" |
| 3276 " is not supported.", |
| 3277 howToFix: |
| 3278 "Use option '--assert-message' to use assertions with messages.", |
| 3279 examples: const [r''' |
| 3280 main() { |
| 3281 int n = -7; |
| 3282 assert(n > 0, 'must be positive: $n'); |
| 3283 } |
| 3284 ''']), |
| 3285 |
| 3272 MessageKind.IMPORT_EXPERIMENTAL_MIRRORS: | 3286 MessageKind.IMPORT_EXPERIMENTAL_MIRRORS: |
| 3273 const MessageTemplate(MessageKind.IMPORT_EXPERIMENTAL_MIRRORS, r''' | 3287 const MessageTemplate(MessageKind.IMPORT_EXPERIMENTAL_MIRRORS, r''' |
| 3274 | 3288 |
| 3275 **************************************************************** | 3289 **************************************************************** |
| 3276 * WARNING: dart:mirrors support in dart2js is experimental, | 3290 * WARNING: dart:mirrors support in dart2js is experimental, |
| 3277 * and not recommended. | 3291 * and not recommended. |
| 3278 * This implementation of mirrors is incomplete, | 3292 * This implementation of mirrors is incomplete, |
| 3279 * and often greatly increases the size of the generated | 3293 * and often greatly increases the size of the generated |
| 3280 * JavaScript code. | 3294 * JavaScript code. |
| 3281 * | 3295 * |
| (...skipping 121 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 3403 static String convertToString(value) { | 3417 static String convertToString(value) { |
| 3404 if (value is ErrorToken) { | 3418 if (value is ErrorToken) { |
| 3405 // Shouldn't happen. | 3419 // Shouldn't happen. |
| 3406 return value.assertionMessage; | 3420 return value.assertionMessage; |
| 3407 } else if (value is Token) { | 3421 } else if (value is Token) { |
| 3408 value = value.value; | 3422 value = value.value; |
| 3409 } | 3423 } |
| 3410 return '$value'; | 3424 return '$value'; |
| 3411 } | 3425 } |
| 3412 } | 3426 } |
| OLD | NEW |