### Eclipse Workspace Patch 1.0 #P org.eclipse.jdt.core.tests.model Index: src/org/eclipse/jdt/core/tests/dom/ASTConverter15Test.java =================================================================== RCS file: /cvsroot/eclipse/org.eclipse.jdt.core.tests.model/src/org/eclipse/jdt/core/tests/dom/ASTConverter15Test.java,v retrieving revision 1.223 diff -u -r1.223 ASTConverter15Test.java --- src/org/eclipse/jdt/core/tests/dom/ASTConverter15Test.java 20 Dec 2006 16:11:56 -0000 1.223 +++ src/org/eclipse/jdt/core/tests/dom/ASTConverter15Test.java 8 Jan 2007 18:44:18 -0000 @@ -47,7 +47,7 @@ } static { -// TESTS_NUMBERS = new int[] { 232, 233 }; +// TESTS_NUMBERS = new int[] { 234 }; // TESTS_NAMES = new String[] {"test0204"}; } public static Test suite() { @@ -7486,4 +7486,35 @@ assertEquals("Wrong key", "message", pairs[0].getName()); assertEquals("Wrong value", "Hello, World!", pairs[0].getValue()); } + + /* + * https://bugs.eclipse.org/bugs/show_bug.cgi?id=169744 + */ + public void test0234() throws JavaModelException { + this.workingCopy = getWorkingCopy("/Converter15/src/X.java", true/*resolve*/); + String contents = + "class B {\n" + + " int m() {\n" + + " return 0;\n" + + " }\n" + + "}\n" + + "public class X extends B {\n" + + " int i = super. m();\n" + + "}"; + ASTNode node = buildAST( + contents, + this.workingCopy, + true); + assertEquals("Not a compilation unit", ASTNode.COMPILATION_UNIT, node.getNodeType()); + CompilationUnit unit = (CompilationUnit) node; + assertProblemsSize(unit, 0); + node = getASTNode(unit, 1, 0); + assertEquals("Not a field declaration", ASTNode.FIELD_DECLARATION, node.getNodeType()); + FieldDeclaration fieldDeclaration = (FieldDeclaration) node; + List fragments = fieldDeclaration.fragments(); + assertEquals("Wrong size", 1, fragments.size()); + VariableDeclarationFragment fragment = (VariableDeclarationFragment) fragments.get(0); + Expression expression = fragment.getInitializer(); + checkSourceRange(expression, "super. m()", contents); + } } \ No newline at end of file