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

Unified Diff: compiler/javatests/com/google/dart/compiler/resolver/ResolverTest.java

Issue 9139001: Fix http://code.google.com/p/dart/issues/detail?id=990. (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
« no previous file with comments | « compiler/java/com/google/dart/compiler/resolver/Resolver.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/resolver/ResolverTest.java
diff --git a/compiler/javatests/com/google/dart/compiler/resolver/ResolverTest.java b/compiler/javatests/com/google/dart/compiler/resolver/ResolverTest.java
index 4b17ff094c75ae2c3a4259d40bd00bda1f90ca74..c5de0c573c4f8c477a2d5a305433aa58767a4aed 100644
--- a/compiler/javatests/com/google/dart/compiler/resolver/ResolverTest.java
+++ b/compiler/javatests/com/google/dart/compiler/resolver/ResolverTest.java
@@ -278,6 +278,16 @@ public class ResolverTest extends ResolverTestCase {
ResolverErrorCode.CANNOT_RESOLVE_IMPLICIT_CALL_TO_SUPER_CONSTRUCTOR);
}
+ public void testImplicitSuperCall_NonExistentSuper2() {
+ // Check that we generate an error if the implicit constructor would call a non-existent super.
+ resolveAndTest(Joiner.on("\n").join(
+ "class Object {}",
+ "class B { B.foo() {} }",
+ "class C extends B {}",
+ "class D { main() { new C(); } }"),
+ ResolverErrorCode.CANNOT_RESOLVE_IMPLICIT_CALL_TO_SUPER_CONSTRUCTOR);
+ }
+
public void testCyclicSupertype() {
resolveAndTest(Joiner.on("\n").join(
« no previous file with comments | « compiler/java/com/google/dart/compiler/resolver/Resolver.java ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698