Bug 40205 automatically insert closing brace: does not handle '//' in strings
200307150800 1. Try this snippet { String s= "//"; void m() <CURSOR> } 2. Insert an opening brace 3. Press <ENTER> The expected closing brace does not get inserted
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/text/java/JavaAutoIndentStrategy.java
return true;
		return false;
	}
	/**
	 * Checks whether <code>position</code> resides in a default (Java) partition of <code>document</code>.
	 * 
	 * @param document the document being modified
	 * @param position the position to be checked
	 * @return <code>true</code> if <code>position</code> is in the default partition of <code>document</code>, <code>false</code> otherwise
	 */
	private static boolean isDefaultPartition(IDocument document, int position) {
		Assert.isTrue(position >= 0);
		Assert.isTrue(position <= document.getLength());
		
		try {
			ITypedRegion region= document.getPartition(position);
			return region != null && region.getType().equals(IDocument.DEFAULT_CONTENT_TYPE);
			
		} catch (BadLocationException e) {
		}
		
		return false;
	}
	/**
	 * Finds the position of the parenthesis matching the closing parenthesis at <code>position</code>.
	 * 
	 * @param document the document being modified
	 * @param position the position in <code>document</code> of a closing parenthesis
	 * @return the position in <code>document</code> of the matching parenthesis, or -1 if none can be found
	 */