Lines 1153-1156
Link Here
|
1153 |
deleteFile("/P/src/X.java"); |
1153 |
deleteFile("/P/src/X.java"); |
1154 |
} |
1154 |
} |
1155 |
} |
1155 |
} |
|
|
1156 |
public void test120902() throws CoreException { |
1157 |
try { |
1158 |
String source = |
1159 |
"/**\r\n" + |
1160 |
" * Toy\r\n" + |
1161 |
" */\r\n" + |
1162 |
"public class X {\r\n" + |
1163 |
"}"; |
1164 |
createFile("/P/src/X.java", source); |
1165 |
final ICompilationUnit compilationUnit = getCompilationUnit("/P/src/X.java"); |
1166 |
IType type = compilationUnit.getType("X"); |
1167 |
ISourceRange javadocRange = type.getJavadocRange(); |
1168 |
assertNotNull("No source range", javadocRange); |
1169 |
compilationUnit.getBuffer().setContents(""); |
1170 |
try { |
1171 |
javadocRange = type.getJavadocRange(); |
1172 |
assertNull("Got a source range", javadocRange); |
1173 |
} catch (ArrayIndexOutOfBoundsException e) { |
1174 |
assertFalse("Should not happen", true); |
1175 |
} |
1176 |
} finally { |
1177 |
deleteFile("/P/src/X.java"); |
1178 |
} |
1179 |
} |
1156 |
} |
1180 |
} |