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

Unified Diff: editor/tools/plugins/com.google.dart.engine/src/com/google/dart/engine/parser/ParserErrorCode.java

Issue 10700082: Comment clean-up (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: Created 8 years, 6 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: editor/tools/plugins/com.google.dart.engine/src/com/google/dart/engine/parser/ParserErrorCode.java
===================================================================
--- editor/tools/plugins/com.google.dart.engine/src/com/google/dart/engine/parser/ParserErrorCode.java (revision 9355)
+++ editor/tools/plugins/com.google.dart.engine/src/com/google/dart/engine/parser/ParserErrorCode.java (working copy)
@@ -28,7 +28,7 @@
// ABSTRACT_MEMBER_IN_INTERFACE("Abstract members are not allowed in interfaces"),
// ABSTRACT_METHOD_WITH_BODY("Abstract method can not have a body"),
// ABSTRACT_TOP_LEVEL_ELEMENT("Only class can be abstract top-level element"),
-// CATCH_OR_FINALLY_EXPECTED("catch or finally clause expected."),
+ CATCH_OR_FINALLY_EXPECTED("catch or finally clause expected."),
// DEFAULT_VALUE_CAN_NOT_BE_SPECIFIED_IN_ABSTRACT(
// "Default values can not be specified in abstract method"),
// DEFAULT_VALUE_CAN_NOT_BE_SPECIFIED_IN_CLOSURE(
@@ -43,20 +43,20 @@
DIRECTIVE_OUT_OF_ORDER("Directive out of order"),
// DISALLOWED_ABSTRACT_KEYWORD("Abstract keyword not allowed here"),
// DISALLOWED_FACTORY_KEYWORD("Factory keyword not allowed here"),
-// EXPECTED_CASE_OR_DEFAULT("Expected 'case' or 'default'"),
+ EXPECTED_CASE_OR_DEFAULT("Expected 'case' or 'default'"),
// EXPECTED_CLASS_DECLARATION_LBRACE("Expected '{' in class or interface declaration"),
// EXPECTED_COMMA_OR_RIGHT_BRACE("Expected ',' or '}'"),
// EXPECTED_COMMA_OR_RIGHT_PAREN("Expected ',' or ')', but got '%s'"),
// EXPECTED_EOS("Unexpected token '%s' (expected end of file)"),
// EXPECTED_EXTENDS("Expected 'extends'"),
-// EXPECTED_IDENTIFIER("Expected identifier"),
+ EXPECTED_IDENTIFIER("Expected identifier"),
// EXPECTED_LEFT_PAREN("'(' expected"),
- EXPECTED_LIST_OR_MAP_LITERAL("Expected list or map literal");
+ EXPECTED_LIST_OR_MAP_LITERAL("Expected list or map literal"),
// EXPECTED_PERIOD_OR_LEFT_BRACKET("Expected '.' or '['"),
// EXPECTED_PREFIX_KEYWORD("Expected 'prefix' after comma"),
// EXPECTED_PREFIX_IDENTIFIER("Prefix string can only contain valid identifier characters"),
// EXPECTED_SEMICOLON("Expected ';'"),
-// EXPECTED_STRING_LITERAL("Expected string literal"),
+ EXPECTED_STRING_LITERAL("Expected string literal"),
// EXPECTED_STRING_LITERAL_MAP_ENTRY_KEY("Expected string literal for map entry key"),
// EXPECTED_TOKEN("Unexpected token '%s' (expected '%s')"),
// EXPECTED_VAR_FINAL_OR_TYPE("Expected 'var', 'final' or type"),
@@ -86,10 +86,10 @@
// NAMED_PARAMETER_NOT_ALLOWED("Named parameter is not allowed for operator or setter method"),
// NO_UNARY_PLUS_OPERATOR("No unary plus operator in Dart"),
// NON_FINAL_STATIC_MEMBER_IN_INTERFACE("Non-final static members are not allowed in interfaces"),
-// ONLY_ONE_LIBRARY_DIRECTIVE("Only one library directive may be declared in a file"),
+ ONLY_ONE_LIBRARY_DIRECTIVE("Only one library directive may be declared in a file"),
// OPERATOR_CANNOT_BE_STATIC("Operators cannot be static"),
// OPERATOR_IS_NOT_USER_DEFINABLE("Operator is not user definable"),
-// POSITIONAL_AFTER_NAMED_ARGUMENT("Positional argument after named argument"),
+ POSITIONAL_AFTER_NAMED_ARGUMENT("Positional argument after named argument"),
// REDIRECTING_CONSTRUCTOR_PARAM("Redirecting constructor can not have initializers"),
// REDIRECTING_CONSTRUCTOR_ITSELF("Redirecting constructor can not have initializers"),
// REDIRECTING_CONSTRUCTOR_MULTIPLE("Multiple redirecting constructor invocations"),
@@ -101,18 +101,28 @@
// SUPER_IS_NOT_VALID_ALONE_OR_AS_A_BOOLEAN_OPERAND(
// "'super' is not valid alone or as a boolean operand"),
// TOP_LEVEL_CANNOT_BE_STATIC("Top-level field or method can not be static"),
-// UNEXPECTED_TOKEN("Unexpected token '%s'"),
+ UNEXPECTED_TOKEN("Unexpected token '%s'");
// UNEXPECTED_TOKEN_IN_STRING_INTERPOLATION("Unexpected token in string interpolation: %s"),
// UNEXPECTED_TYPE_ARGUMENT("unexpected type argument"),
// VAR_IS_NOT_ALLOWED_ON_A_METHOD_DEFINITION("'var' is not allowed on a method definition"),
// VOID_FIELD("Field cannot be of type void"),
// VOID_PARAMETER("Parameter cannot be of type void");
+ /**
+ * The severity of this error.
+ */
private final ErrorSeverity severity;
+
+ /**
+ * The message template used to create the message to be displayed for this error.
+ */
private final String message;
/**
* Initialize a newly created error code to have the given severity and message.
+ *
+ * @param severity the severity of the error
+ * @param message the message template used to create the message to be displayed for the error
*/
private ParserErrorCode(ErrorSeverity severity, String message) {
this.severity = severity;
@@ -120,7 +130,9 @@
}
/**
- * Initialize a newly created error code to have the given message and ERROR severity.
+ * Initialize a newly created error code to have the given message and a severity of ERROR.
+ *
+ * @param message the message template used to create the message to be displayed for the error
*/
private ParserErrorCode(String message) {
this(ErrorSeverity.ERROR, message);

Powered by Google App Engine
This is Rietveld 408576698