int nextPartitionPos= nextPartitionOrLineEnd(document, line, offset, partitioning); insertPos= offset; if (!isForStatement(text, offset)) {
if (isForStatement(text, offset)) { insertPos= offset; } else { int nextPartitionPos= nextPartitionOrLineEnd(document, line, offset, partitioning);
	protected static int computeCharacterPosition(IDocument document, ITextSelection line, int offset, char character, String partitioning) {		String text= line.getText();		if (text == null)			return 0;		int insertPos;		if (character == BRACECHAR) {			insertPos= computeArrayInitializationPos(document, line, offset, partitioning);			if (insertPos == -1) {				insertPos= computeAfterTryDoElse(document, line, offset);			}			if (insertPos == -1) {				insertPos= computeAfterParenthesis(document, line, offset, partitioning);			}		} else if (character == SEMICHAR) {			int nextPartitionPos= nextPartitionOrLineEnd(document, line, offset, partitioning);			insertPos= offset;			if (!isForStatement(text, offset)) {				insertPos= startOfWhitespaceBeforeOffset(text, nextPartitionPos);			}					} else {			Assert.isTrue(false);			return -1;		}		return insertPos;	}