| 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 791 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 802 // This is used as an exception. | 802 // This is used as an exception. |
| 803 static const MessageKind INVALID_SOURCE_FILE_LOCATION = const MessageKind(''' | 803 static const MessageKind INVALID_SOURCE_FILE_LOCATION = const MessageKind(''' |
| 804 Invalid offset (#{offset}) in source map. | 804 Invalid offset (#{offset}) in source map. |
| 805 File: #{fileName} | 805 File: #{fileName} |
| 806 Length: #{length}'''); | 806 Length: #{length}'''); |
| 807 | 807 |
| 808 static const MessageKind TOP_LEVEL_VARIABLE_DECLARED_STATIC = | 808 static const MessageKind TOP_LEVEL_VARIABLE_DECLARED_STATIC = |
| 809 const MessageKind( | 809 const MessageKind( |
| 810 "Error: Top-level variable cannot be declared static."); | 810 "Error: Top-level variable cannot be declared static."); |
| 811 | 811 |
| 812 static const MessageKind REFERENCE_IN_INITIALIZATION = const MessageKind( | 812 static const MessageKind ACCESS_BEFORE_INITIALIZATION = const MessageKind( |
| 813 "Error: Variable '#{variableName}' is referenced during its " | 813 "Error: Variable '#{variableName}' is referenced before its " |
| 814 "initialization.", | 814 "initialization.", |
| 815 howToFix: "If you are trying to reference a shadowed variable, rename" | 815 howToFix: "If you are trying to reference a shadowed variable, rename" |
| 816 " one of the variables.", | 816 " one of the variables.", |
| 817 examples: const [""" | 817 examples: const [""" |
| 818 foo(t) { | 818 foo(t) { |
| 819 var t = t; | 819 var t = t; |
| 820 return t; | 820 return t; |
| 821 } | 821 } |
| 822 | 822 |
| 823 main() => foo(1); | 823 main() => foo(1); |
| 824 """]); | 824 """]); |
| 825 | 825 |
| 826 static const MessageKind CONST_WITHOUT_INITIALIZER = const MessageKind( | 826 static const MessageKind CONST_WITHOUT_INITIALIZER = const MessageKind( |
| 827 "Error: A constant variable must be initialized.", | 827 "Error: A constant variable must be initialized.", |
| (...skipping 485 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1313 | 1313 |
| 1314 class CompileTimeConstantError extends Diagnostic { | 1314 class CompileTimeConstantError extends Diagnostic { |
| 1315 CompileTimeConstantError(MessageKind kind, Map arguments, bool terse) | 1315 CompileTimeConstantError(MessageKind kind, Map arguments, bool terse) |
| 1316 : super(kind, arguments, terse); | 1316 : super(kind, arguments, terse); |
| 1317 } | 1317 } |
| 1318 | 1318 |
| 1319 class CompilationError extends Diagnostic { | 1319 class CompilationError extends Diagnostic { |
| 1320 CompilationError(MessageKind kind, Map arguments, bool terse) | 1320 CompilationError(MessageKind kind, Map arguments, bool terse) |
| 1321 : super(kind, arguments, terse); | 1321 : super(kind, arguments, terse); |
| 1322 } | 1322 } |
| OLD | NEW |