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

Unified Diff: editor/tools/plugins/com.google.dart.engine/src/com/google/dart/engine/error/StaticTypeWarningCode.java

Issue 27179004: Issue 12103. It is warning to provide wrong number of type arguments for list/map literals. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Non-error tests. Created 7 years, 2 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
« no previous file with comments | « no previous file | editor/tools/plugins/com.google.dart.engine/src/com/google/dart/engine/internal/verifier/ErrorVerifier.java » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: editor/tools/plugins/com.google.dart.engine/src/com/google/dart/engine/error/StaticTypeWarningCode.java
diff --git a/editor/tools/plugins/com.google.dart.engine/src/com/google/dart/engine/error/StaticTypeWarningCode.java b/editor/tools/plugins/com.google.dart.engine/src/com/google/dart/engine/error/StaticTypeWarningCode.java
index 374dd7507295357e6344ddd175b33d5ec1467e62..e8ff1de60f426c8bec1b26bebc3bc0c4732b7cdf 100644
--- a/editor/tools/plugins/com.google.dart.engine/src/com/google/dart/engine/error/StaticTypeWarningCode.java
+++ b/editor/tools/plugins/com.google.dart.engine/src/com/google/dart/engine/error/StaticTypeWarningCode.java
@@ -23,6 +23,24 @@ package com.google.dart.engine.error;
*/
public enum StaticTypeWarningCode implements ErrorCode {
/**
+ * 12.7 Lists: A fresh instance (7.6.1) <i>a</i>, of size <i>n</i>, whose class implements the
+ * built-in class <i>List&lt;E></i> is allocated.
+ *
+ * @param numTypeArgument the number of provided type arguments
+ */
+ EXPECTED_ONE_LIST_TYPE_ARGUMENTS(
+ "List literal requires exactly one type arguments or none, but %d found"),
+
+ /**
+ * 12.8 Maps: A fresh instance (7.6.1) <i>m</i>, of size <i>n</i>, whose class implements the
+ * built-in class <i>Map&lt;K, V></i> is allocated.
+ *
+ * @param numTypeArgument the number of provided type arguments
+ */
+ EXPECTED_TWO_MAP_TYPE_ARGUMENTS(
+ "Map literal requires exactly two type arguments or none, but %d found"),
+
+ /**
* 12.18 Assignment: Let <i>T</i> be the static type of <i>e<sub>1</sub></i>. It is a static type
* warning if <i>T</i> does not have an accessible instance setter named <i>v=</i>.
*
« no previous file with comments | « no previous file | editor/tools/plugins/com.google.dart.engine/src/com/google/dart/engine/internal/verifier/ErrorVerifier.java » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698