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

Side by Side Diff: pkg/compiler/lib/src/messages.dart

Issue 1284593003: Remove dart2jslib.dart (Closed) Base URL: https://github.com/dart-lang/sdk.git@master
Patch Set: Created 5 years, 4 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
OLDNEW
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 45 matching lines...) Expand 10 before | Expand all | Expand 10 after
56 * or ERROR about the duplicated element, and then report an INFO about the 56 * or ERROR about the duplicated element, and then report an INFO about the
57 * location of the existing element. 57 * location of the existing element.
58 * 58 *
59 * Generally, we want to provide messages that consists of three sentences: 59 * Generally, we want to provide messages that consists of three sentences:
60 * 1. what is wrong, 2. why is it wrong, 3. how do I fix it. However, we 60 * 1. what is wrong, 2. why is it wrong, 3. how do I fix it. However, we
61 * combine the first two in [template] and the last in [howToFix]. 61 * combine the first two in [template] and the last in [howToFix].
62 */ 62 */
63 63
64 library dart2js.messages; 64 library dart2js.messages;
65 65
66 import 'dart2jslib.dart'; 66 import 'diagnostics/invariant.dart' show
67 invariant;
68 import 'diagnostics/spannable.dart' show
69 CURRENT_ELEMENT_SPANNABLE;
67 import 'scanner/scannerlib.dart'; 70 import 'scanner/scannerlib.dart';
68 import 'util/util.dart' show CURRENT_ELEMENT_SPANNABLE;
69 71
70 const DONT_KNOW_HOW_TO_FIX = "Computer says no!"; 72 const DONT_KNOW_HOW_TO_FIX = "Computer says no!";
71 73
72 /// Keys for the [MessageTemplate]s. 74 /// Keys for the [MessageTemplate]s.
73 enum MessageKind { 75 enum MessageKind {
74 ABSTRACT_CLASS_INSTANTIATION, 76 ABSTRACT_CLASS_INSTANTIATION,
75 ABSTRACT_GETTER, 77 ABSTRACT_GETTER,
76 ABSTRACT_METHOD, 78 ABSTRACT_METHOD,
77 ABSTRACT_SETTER, 79 ABSTRACT_SETTER,
78 ACCESSED_IN_CLOSURE, 80 ACCESSED_IN_CLOSURE,
(...skipping 3265 matching lines...) Expand 10 before | Expand all | Expand 10 after
3344 static String convertToString(value) { 3346 static String convertToString(value) {
3345 if (value is ErrorToken) { 3347 if (value is ErrorToken) {
3346 // Shouldn't happen. 3348 // Shouldn't happen.
3347 return value.assertionMessage; 3349 return value.assertionMessage;
3348 } else if (value is Token) { 3350 } else if (value is Token) {
3349 value = value.value; 3351 value = value.value;
3350 } 3352 }
3351 return '$value'; 3353 return '$value';
3352 } 3354 }
3353 } 3355 }
OLDNEW
« no previous file with comments | « pkg/compiler/lib/src/library_loader.dart ('k') | pkg/compiler/lib/src/mirror_renamer/mirror_renamer.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698