diff --git a/test/jdk/valhalla/valuetypes/Nest.java b/test/jdk/valhalla/valuetypes/Nest.java index 6b785c5fe8b..5a79ea647df 100644 --- a/test/jdk/valhalla/valuetypes/Nest.java +++ b/test/jdk/valhalla/valuetypes/Nest.java @@ -33,25 +33,6 @@ import org.junit.jupiter.api.Test; import static org.junit.jupiter.api.Assertions.*; public class Nest { - static interface I { - String toString(); - } - - static I of(int value, Object next) { - // anonymous class capturing outer locals - return new value I() { - public String toString() { - return value + " -> " + next; - } - }; - } - - @Test - public void test1() { - assertEquals(Nest.of(1, null), Nest.of(1, null)); - assertNotEquals(Nest.of(1, null), Nest.of(2, null)); - } - @Test public void test2() { Outer n = new Outer(1);