Bug 49945 Typing a brace destroys subsequent character
I20040106 + plugin-export 20040108_1804 Typing a brace destroys the subsequent '/' character: public class Example { public Example() { } // <- insert '{' before comment public static void main(String[] args) { } } All Preferences 'Java > Editor > Typing' have the default setting.
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/text/java/JavaAutoIndentStrategy.java
return endOffset;
	}
	private String getIndentOfLine(IDocument d, int line) throws BadLocationException {
		if (line > -1) {
			int start= d.getLineOffset(line);
			int end= start + d.getLineLength(line) - 1;
			int whiteEnd= findEndOfWhiteSpace(d, start, end);
			return d.get(start, whiteEnd - start);
		} else {
			return ""; 
		}
	}
	private int getStringEnd(IDocument d, int offset, int endOffset, char ch) throws BadLocationException {
		while (offset < endOffset) {
			char curr= d.getChar(offset);
			offset++;
			if (curr == '\\') {
				
				offset++;
			} else if (curr == ch) {
				return offset;
			}
		}
		return endOffset;
	}
	private void smartIndentAfterClosingBracket(IDocument d, DocumentCommand c) {
		if (c.offset == -1 || d.getLength() == 0)
			return;
		try {
			int p= (c.offset == d.getLength() ? c.offset - 1 : c.offset);