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

Unified Diff: dart/sdk/lib/_internal/compiler/implementation/scanner/class_element_parser.dart

Issue 20742002: Clean up error handling. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge
Patch Set: Added documentation guide lines. Created 7 years, 5 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 side-by-side diff with in-line comments
Download patch
Index: dart/sdk/lib/_internal/compiler/implementation/scanner/class_element_parser.dart
diff --git a/dart/sdk/lib/_internal/compiler/implementation/scanner/class_element_parser.dart b/dart/sdk/lib/_internal/compiler/implementation/scanner/class_element_parser.dart
index 81f9fec9f8dd874b964df4abfe3ad7f5c72748af..9cb1736dc0d595fd7c0b61afb8fadab4da7d1645 100644
--- a/dart/sdk/lib/_internal/compiler/implementation/scanner/class_element_parser.dart
+++ b/dart/sdk/lib/_internal/compiler/implementation/scanner/class_element_parser.dart
@@ -104,7 +104,7 @@ class MemberListener extends NodeListener {
return Elements.constructOperatorName(operator.source, isUnary);
} else {
if (receiver == null || receiver.source != enclosingElement.name) {
- listener.reportErrorCode(send.receiver,
+ listener.reportError(send.receiver,
MessageKind.INVALID_CONSTRUCTOR_NAME,
{'name': enclosingElement.name});
}
@@ -142,7 +142,7 @@ class MemberListener extends NodeListener {
Identifier singleIdentifierName = method.name.asIdentifier();
if (singleIdentifierName != null && singleIdentifierName.source == name) {
if (name != enclosingElement.name) {
- listener.reportErrorCode(singleIdentifierName,
+ listener.reportError(singleIdentifierName,
MessageKind.INVALID_UNNAMED_CONSTRUCTOR_NAME,
{'name': enclosingElement.name});
}

Powered by Google App Engine
This is Rietveld 408576698