| 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 part of dart2js; | 5 part of dart2js; |
| 6 | 6 |
| 7 const DONT_KNOW_HOW_TO_FIX = ""; | 7 const DONT_KNOW_HOW_TO_FIX = ""; |
| 8 | 8 |
| 9 /** | 9 /** |
| 10 * The messages in this file should meet the following guide lines: | 10 * The messages in this file should meet the following guide lines: |
| (...skipping 1479 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1490 | 1490 |
| 1491 static const MessageKind ABSTRACT_METHOD = const MessageKind( | 1491 static const MessageKind ABSTRACT_METHOD = const MessageKind( |
| 1492 "The method '#{name}' has no implementation in " | 1492 "The method '#{name}' has no implementation in " |
| 1493 "class '#{class}'.", | 1493 "class '#{class}'.", |
| 1494 howToFix: "Try adding a body to '#{name}' or declaring " | 1494 howToFix: "Try adding a body to '#{name}' or declaring " |
| 1495 "'#{class}' to be 'abstract'.", | 1495 "'#{class}' to be 'abstract'.", |
| 1496 examples: const [""" | 1496 examples: const [""" |
| 1497 class Class { | 1497 class Class { |
| 1498 method(); | 1498 method(); |
| 1499 } | 1499 } |
| 1500 main() => new Class(); | 1500 main() => new Class().method(); |
| 1501 """]); | 1501 """]); |
| 1502 | 1502 |
| 1503 static const MessageKind ABSTRACT_GETTER = const MessageKind( | 1503 static const MessageKind ABSTRACT_GETTER = const MessageKind( |
| 1504 "The getter '#{name}' has no implementation in " | 1504 "The getter '#{name}' has no implementation in " |
| 1505 "class '#{class}'.", | 1505 "class '#{class}'.", |
| 1506 howToFix: "Try adding a body to '#{name}' or declaring " | 1506 howToFix: "Try adding a body to '#{name}' or declaring " |
| 1507 "'#{class}' to be 'abstract'.", | 1507 "'#{class}' to be 'abstract'.", |
| 1508 examples: const [""" | 1508 examples: const [""" |
| 1509 class Class { | 1509 class Class { |
| 1510 get getter; | 1510 get getter; |
| (...skipping 204 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1715 examples: const [""" | 1715 examples: const [""" |
| 1716 main() { | 1716 main() { |
| 1717 var m = const {'foo': 1, 'foo': 2}; | 1717 var m = const {'foo': 1, 'foo': 2}; |
| 1718 }"""]); | 1718 }"""]); |
| 1719 | 1719 |
| 1720 static const MessageKind BAD_INPUT_CHARACTER = const MessageKind( | 1720 static const MessageKind BAD_INPUT_CHARACTER = const MessageKind( |
| 1721 "Character U+#{characterHex} isn't allowed here.", | 1721 "Character U+#{characterHex} isn't allowed here.", |
| 1722 howToFix: DONT_KNOW_HOW_TO_FIX, | 1722 howToFix: DONT_KNOW_HOW_TO_FIX, |
| 1723 examples: const [""" | 1723 examples: const [""" |
| 1724 main() { | 1724 main() { |
| 1725 print(ç); | 1725 String x = ç; |
| 1726 } | 1726 } |
| 1727 """]); | 1727 """]); |
| 1728 | 1728 |
| 1729 static const MessageKind UNTERMINATED_STRING = const MessageKind( | 1729 static const MessageKind UNTERMINATED_STRING = const MessageKind( |
| 1730 "String must end with #{quote}.", | 1730 "String must end with #{quote}.", |
| 1731 howToFix: DONT_KNOW_HOW_TO_FIX, | 1731 howToFix: DONT_KNOW_HOW_TO_FIX, |
| 1732 examples: const [""" | 1732 examples: const [""" |
| 1733 main() { | 1733 main() { |
| 1734 return ' | 1734 return ' |
| 1735 ; | 1735 ; |
| (...skipping 304 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2040 return computeMessage(); | 2040 return computeMessage(); |
| 2041 } | 2041 } |
| 2042 | 2042 |
| 2043 bool operator==(other) { | 2043 bool operator==(other) { |
| 2044 if (other is !Message) return false; | 2044 if (other is !Message) return false; |
| 2045 return (kind == other.kind) && (toString() == other.toString()); | 2045 return (kind == other.kind) && (toString() == other.toString()); |
| 2046 } | 2046 } |
| 2047 | 2047 |
| 2048 int get hashCode => throw new UnsupportedError('Message.hashCode'); | 2048 int get hashCode => throw new UnsupportedError('Message.hashCode'); |
| 2049 } | 2049 } |
| OLD | NEW |