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

Side by Side Diff: pkg/dart_messages/lib/shared_messages.dart

Issue 1716463002: More shared messages. (Closed) Base URL: git@github.com:dart-lang/sdk.git@master
Patch Set: Address comments. Created 4 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « pkg/dart_messages/lib/generated/shared_messages.json ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2015, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2015, 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 // An update to this file must be followed by regenerating the corresponding 5 // An update to this file must be followed by regenerating the corresponding
6 // json, dart2js and analyzer file. Use `publish.dart` in the bin directory. 6 // json, dart2js and analyzer file. Use `publish.dart` in the bin directory.
7 // 7 //
8 // Every message in this file must have an id. Use `message_id.dart` in the 8 // Every message in this file must have an id. Use `message_id.dart` in the
9 // bin directory to generate a fresh one. 9 // bin directory to generate a fresh one.
10 10
(...skipping 386 matching lines...) Expand 10 before | Expand all | Expand 10 after
397 examples: const ["class A { class B {} } main() { new A(); }",]), 397 examples: const ["class A { class B {} } main() { new A(); }",]),
398 398
399 'CONSTRUCTOR_WITH_RETURN_TYPE': new Message( 399 'CONSTRUCTOR_WITH_RETURN_TYPE': new Message(
400 id: 'VOJBWY', 400 id: 'VOJBWY',
401 category: Category.parserError, 401 category: Category.parserError,
402 template: "Constructors can't have a return type", 402 template: "Constructors can't have a return type",
403 howToFix: "Try removing the return type.", 403 howToFix: "Try removing the return type.",
404 usedBy: [analyzer, dart2js], 404 usedBy: [analyzer, dart2js],
405 examples: const ["class A { int A() {} } main() { new A(); }",]), 405 examples: const ["class A { int A() {} } main() { new A(); }",]),
406 406
407 'MISSING_EXPRESSION_IN_THROW': new Message(
408 id: 'FTGGMJ',
409 subId: 0,
410 category: Category.parserError,
411 template: "Missing expression after 'throw'.",
412 howToFix: "Did you mean 'rethrow'?",
413 usedBy: [
414 analyzer,
415 dart2js
416 ],
417 examples: const [
418 'main() { throw; }',
419 'main() { try { throw 0; } catch(e) { throw; } }'
420 ]),
421
422 /**
423 * 12.8.1 Rethrow: It is a compile-time error if an expression of the form
424 * <i>rethrow;</i> is not enclosed within a on-catch clause.
425 */
426 'RETHROW_OUTSIDE_CATCH': new Message(
427 id: 'MWETLC',
428 category: Category.compileTimeError,
429 template: 'Rethrow must be inside of catch clause',
430 howToFix: "Try moving the expression into a catch clause, or "
431 "using a 'throw' expression.",
432 usedBy: [analyzer, dart2js],
433 examples: const ["main() { rethrow; }"]),
434
407 /** 435 /**
408 * 13.12 Return: It is a compile-time error if a return statement of the form 436 * 13.12 Return: It is a compile-time error if a return statement of the form
409 * <i>return e;</i> appears in a generative constructor. 437 * <i>return e;</i> appears in a generative constructor.
410 */ 438 */
411 'RETURN_IN_GENERATIVE_CONSTRUCTOR': new Message( 439 'RETURN_IN_GENERATIVE_CONSTRUCTOR': new Message(
412 id: 'UOTDQH', 440 id: 'UOTDQH',
413 category: Category.compileTimeError, 441 category: Category.compileTimeError,
414 template: "Constructors can't return values.", 442 template: "Constructors can't return values.",
415 howToFix: 443 howToFix:
416 "Try removing the return statement or using a factory constructor.", 444 "Try removing the return statement or using a factory constructor.",
(...skipping 32 matching lines...) Expand 10 before | Expand all | Expand 10 after
449 """ 477 """
450 foo() async* { return 0; } 478 foo() async* { return 0; }
451 main() => foo(); 479 main() => foo();
452 """, 480 """,
453 """ 481 """
454 foo() sync* { return 0; } 482 foo() sync* { return 0; }
455 main() => foo(); 483 main() => foo();
456 """ 484 """
457 ]), 485 ]),
458 }; 486 };
OLDNEW
« no previous file with comments | « pkg/dart_messages/lib/generated/shared_messages.json ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698