Bug 50212 [formatting] Repeated insertion of new line when formatting javadoc comment
Formatting the following javadoc comment multiple times results in the insertion of a new line before 'test' *each* time: /** * <pre></pre> * test */
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/text/comment/CommentRegion.java
final int spaces= pixels / space;
		if (tabs) {
			final int count= spaces / fTabs;
			final int modulo= spaces % fTabs;
			for (int index= 0; index < count; index++)
				buffer.append('\t');
			for (int index= 0; index < modulo; index++)
				buffer.append(' ');
		} else {
			for (int index= 0; index < spaces; index++)
				buffer.append(' ');
		}
		return buffer.toString();
	}
	/**
	 * Returns the length of the reference string in characters.
	 * 
	 * @param reference
	 *                  The reference string to get the length
	 * @return The length of the string in characters
	 */
	protected final int stringToLength(final String reference) {
		int tabs= 0;
		int count= reference.length();
		for (int index= 0; index < count; index++) {
			if (reference.charAt(index) == '\t')
				tabs++;
		}
		count += tabs * (fTabs - 1);
		return count;