Community
Participate
Working Groups
);
}
// duplicate bug https://bugs.eclipse.org/bugs/show_bug.cgi?id=201022
// TODO (frederic) Enable when bug https://bugs.eclipse.org/bugs/show_bug.cgi?id=287462 will be fixed
public void testBug201022() throws JavaModelException {
public void _testBug201022() throws JavaModelException {
this.formatterPrefs.join_wrapped_lines = false;
String source =
"public class Test {\n" +
"\n" +
" void foo() {\n" +
" String sQuery =\n" +
" \"select * \" +\n" +
" \"from person p, address a \" +\n" +
" \"where p.person_id = a.person_id \" +\n" +
" \"and p.person_id = ?\";\n" +
" }\n" +
"}\n"
int getCurrentIndentation(int start) {
int linePtr = -Arrays.binarySearch(this.lineEnds, start);
int linePtr = Arrays.binarySearch(this.lineEnds, start);
if (linePtr < 0) {
linePtr = -linePtr - 1;
int offset = 0;
int beginningOfLine = getLineEnd(linePtr - 1);
int beginningOfLine = getLineEnd(linePtr);
if (beginningOfLine == -1) {
beginningOfLine = 0;