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

Unified Diff: editor/tools/plugins/com.google.dart.engine_test/src/com/google/dart/engine/resolver/NonErrorResolverTest.java

Issue 25509003: It is statically OK to call methods on bottom type. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 7 years, 3 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_test/src/com/google/dart/engine/resolver/NonErrorResolverTest.java
diff --git a/editor/tools/plugins/com.google.dart.engine_test/src/com/google/dart/engine/resolver/NonErrorResolverTest.java b/editor/tools/plugins/com.google.dart.engine_test/src/com/google/dart/engine/resolver/NonErrorResolverTest.java
index 97b5d13a34c8e082564fae02abfa09fe286de972..9e70e6598310ba4151bb7b8d53b1601917708a44 100644
--- a/editor/tools/plugins/com.google.dart.engine_test/src/com/google/dart/engine/resolver/NonErrorResolverTest.java
+++ b/editor/tools/plugins/com.google.dart.engine_test/src/com/google/dart/engine/resolver/NonErrorResolverTest.java
@@ -471,7 +471,6 @@ public class NonErrorResolverTest extends ResolverTestCase {
"}"));
resolve(source);
assertNoErrors(source);
- verify(source);
}
public void test_constEvalTypeBoolNumString_notEqual() throws Exception {
@@ -2344,6 +2343,26 @@ public class NonErrorResolverTest extends ResolverTestCase {
verify(source);
}
+ public void test_null_callMethod() throws Exception {
+ Source source = addSource(createSource(//
+ "main() {",
+ " null.m();",
+ "}"));
+ resolve(source);
+ assertNoErrors(source);
+ }
+
+ public void test_null_callOperator() throws Exception {
+ Source source = addSource(createSource(//
+ "main() {",
+ " null + 5;",
+ " null == 5;",
+ " null[0];",
+ "}"));
+ resolve(source);
+ assertNoErrors(source);
+ }
+
public void test_optionalParameterInOperator_required() throws Exception {
Source source = addSource(createSource(//
"class A {",

Powered by Google App Engine
This is Rietveld 408576698