Bug 61759 [typing] Smart semicolon does not work at end of string literal
I20040506 0. smart semicolon is on, smart typing mode 1. have this code: String s= "asdfasdf<caret>" 2. press SEMICOLON -> expected: semicolon gets inserted after the closing quotation mark -> real: the semicolon is inserted at the caret position -> note that it works if the caret position is not before the closing quotation mark.
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/text/java/SmartSemicolonAutoEditStrategy.java
while (true) {
			int startScan= closingParen + 1;
			closingParen= scanForward(document, startScan, partitioning, scanTo, ')');
			if (closingParen == -1)
				break;
			int openingParen= findOpeningParenMatch(document, closingParen, partitioning);
			
			if (openingParen < 1)
				break;
			
			if (openingParen > pos)
				continue;
			if (looksLikeAnonymousClassDef(document, openingParen - 1, partitioning))
				return closingParen + 1 - line.getOffset();
			if (looksLikeIfWhileForCatch(document, openingParen - 1, partitioning))
				return closingParen + 1 - line.getOffset();
			if (looksLikeMethodDecl(document, openingParen - 1, partitioning))
				return closingParen + 1 - line.getOffset();
		}
		return -1;
	}
	/**
	 * Finds a closing parenthesis to the left of <code>position</code> in document, where that parenthesis is only
	 * separated by whitespace from <code>position</code>. If no such parenthesis can be found, <code>position</code> is returned.
	 * 
	 * @param document the document being modified
	 * @param position the first character position in <code>document</code> to be considered
	 * @param partitioning the document partitioning
	 * @return the position of a closing parenthesis left to <code>position</code> separated only by whitespace, or <code>position</code> if no parenthesis can be found
	 */