### Eclipse Workspace Patch 1.0 #P org.eclipse.jdt.core.tests.compiler Index: src/org/eclipse/jdt/core/tests/compiler/regression/GenericTypeTest.java =================================================================== RCS file: /cvsroot/eclipse/org.eclipse.jdt.core.tests.compiler/src/org/eclipse/jdt/core/tests/compiler/regression/GenericTypeTest.java,v retrieving revision 1.747 diff -u -r1.747 GenericTypeTest.java --- src/org/eclipse/jdt/core/tests/compiler/regression/GenericTypeTest.java 11 Aug 2008 22:04:54 -0000 1.747 +++ src/org/eclipse/jdt/core/tests/compiler/regression/GenericTypeTest.java 14 Aug 2008 16:07:02 -0000 @@ -31,7 +31,7 @@ // All specified tests which does not belong to the class are skipped... static { // TESTS_NAMES = new String[] { "test0788" }; -// TESTS_NUMBERS = new int[] { 1368 }; +// TESTS_NUMBERS = new int[] { 1369 }; // TESTS_RANGE = new int[] { 1097, -1 }; } public static Test suite() { @@ -45958,4 +45958,30 @@ }, ""); } +//https://bugs.eclipse.org/bugs/show_bug.cgi?id=244164 +public void test1369() { + this.runNegativeTest( + new String[] { + "X.java", //----------------------------------------------------------------------- + "import java.util.HashMap;\n" + + "import java.util.Map;\n" + + "public class X {\n" + + " private static Map map = new HashMap();\n" + + " public static X foo(String s) {\n" + + " return map.get(s);\n" + + " }\n" + + "}",//----------------------------------------------------------------------- + }, + "----------\n" + + "1. ERROR in X.java (at line 4)\n" + + " private static Map map = new HashMap();\n" + + " ^^^^\n" + + "Zork cannot be resolved to a type\n" + + "----------\n" + + "2. ERROR in X.java (at line 6)\n" + + " return map.get(s);\n" + + " ^^^\n" + + "Map cannot be resolved to a type\n" + + "----------\n"); +} } \ No newline at end of file