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

Unified Diff: compiler/java/com/google/dart/compiler/parser/ParserErrorCode.java

Issue 9185013: Issue 965: Report error for static local function (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 8 years, 11 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: compiler/java/com/google/dart/compiler/parser/ParserErrorCode.java
diff --git a/compiler/java/com/google/dart/compiler/parser/ParserErrorCode.java b/compiler/java/com/google/dart/compiler/parser/ParserErrorCode.java
index 7e6d76ac46c7aea2de29ca1b0cc47c1940f63ed3..8544c842cea77aaca97b27323008d063692b4f03 100644
--- a/compiler/java/com/google/dart/compiler/parser/ParserErrorCode.java
+++ b/compiler/java/com/google/dart/compiler/parser/ParserErrorCode.java
@@ -61,6 +61,7 @@ public enum ParserErrorCode implements ErrorCode {
INTERFACE_METHOD_WITH_BODY("Interface method can not have a body"),
INVALID_FIELD_DECLARATION("Wrong syntax for field declaration"),
INVALID_OPERATOR_CHAINING("Cannot chain '%s'"),
+ LOCAL_CANNOT_BE_STATIC("Local function may not be static"),
zundel 2012/01/11 18:17:17 enum says "CANNOT" text says "may not"
MISSING_FUNCTION_NAME("a function name is required for a declaration"),
NAMED_PARAMETER_NOT_ALLOWED("Named parameter is not allowed for operator or setter method"),
NON_FINAL_STATIC_MEMBER_IN_INTERFACE("Non-final static members are not allowed in interfaces"),
@@ -71,7 +72,7 @@ public enum ParserErrorCode implements ErrorCode {
REDIRECTING_CONSTRUCTOR_OTHER("Redirecting constructor can not have initializers"),
SKIPPED_SOURCE("This part of the source was not parsed because of a previous parsing problem"),
SUPER_CONSTRUCTOR_MULTIPLE("'super' must be called only once in the initialization list"),
- TOP_LEVEL_IS_STATIC("Top-level field or method may not be static"),
+ TOP_LEVEL_CANNOT_BE_STATIC("Top-level field or method may not be static"),
zundel 2012/01/11 18:17:17 same comment
UNEXPECTED_TOKEN("Unexpected token '%s'"),
UNEXPECTED_TOKEN_IN_STRING_INTERPOLATION("Unexpected token in string interpolation: %s"),
UNEXPECTED_TYPE_ARGUMENT("unexpected type argument"),

Powered by Google App Engine
This is Rietveld 408576698