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

Unified Diff: compiler/javatests/com/google/dart/compiler/type/TypeAnalyzerTest.java

Issue 12566012: Change analyzer to not complain about string+string. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Make test that should fail also do so. Created 7 years, 9 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 | « compiler/java/com/google/dart/compiler/type/TypeAnalyzer.java ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: compiler/javatests/com/google/dart/compiler/type/TypeAnalyzerTest.java
diff --git a/compiler/javatests/com/google/dart/compiler/type/TypeAnalyzerTest.java b/compiler/javatests/com/google/dart/compiler/type/TypeAnalyzerTest.java
index 8f67edc7d97201ed7a588f26a477e8bc37fb2b37..a6c646489275bc17e584f50d9e5e42d6d4dc8508 100644
--- a/compiler/javatests/com/google/dart/compiler/type/TypeAnalyzerTest.java
+++ b/compiler/javatests/com/google/dart/compiler/type/TypeAnalyzerTest.java
@@ -1211,11 +1211,9 @@ public class TypeAnalyzerTest extends TypeAnalyzerTestCase {
"String s = 'foo';");
analyzeClasses(source);
analyze("{ var c = a + b; }");
- analyzeFail("{ var c = s + b; }",
- TypeErrorCode.PLUS_CANNOT_BE_USED_FOR_STRING_CONCAT);
+ analyze("{ var c = s + b; }");
analyzeFail("var c = 'foo' + 1;",
- TypeErrorCode.PLUS_CANNOT_BE_USED_FOR_STRING_CONCAT);
- analyzeFail("var c = 'foo' + 'bar';",
- TypeErrorCode.PLUS_CANNOT_BE_USED_FOR_STRING_CONCAT);
+ TypeErrorCode.TYPE_NOT_ASSIGNMENT_COMPATIBLE);
+ analyze("var c = 'foo' + 'bar';");
}
}
« no previous file with comments | « compiler/java/com/google/dart/compiler/type/TypeAnalyzer.java ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698