Buggy code:
case TerminalTokens . TokenNameWHITESPACE : if ( ( this . scanner . currentPosition ) > ( ( this . lineEnd ) + 1 ) ) hasMultiLines = true ; if ( valid ) break ; case TerminalTokens . TokenNameEOF : if ( this . reportProblems ) if ( empty ) this . sourceParser . problemReporter ( ) . javadocMissingParamName ( start , end , this . sourceParser . modifiers ) ; else if ( ( this . jdk15 ) && isTypeParam ) this . sourceParser . problemReporter ( ) . javadocInvalidParamTypeParameter ( start , end ) ; else this . sourceParser . problemReporter ( ) . javadocInvalidParamTagName ( start , end ) ; this . scanner . currentPosition = start ; this . index = start ; this . currentTokenType = - 1 ; this . scanner . tokenizeWhiteSpace = tokenWhiteSpace ; return false ; } } if ( isTypeParam && ( this . jdk15 ) ) { nextToken : while ( true ) { this . currentTokenType = - 1 ; try { token = readToken ( ) ; } catch ( InvalidInputException e ) { valid = false ; } switch ( token ) { case TerminalTokens . TokenNameWHITESPACE : if ( valid && ( ( this . scanner . currentPosition ) <= ( ( this . lineEnd ) + 1 ) ) ) break ; case TerminalTokens . TokenNameEOF : if ( this . reportProblems ) this . sourceParser . problemReporter ( ) . javadocInvalidParamTypeParameter ( start , end ) ; this . scanner . currentPosition = start ; this . index = start ; this . currentTokenType = - 1 ; this . scanner . tokenizeWhiteSpace = tokenWhiteSpace ; return false ; case TerminalTokens . TokenNameIdentifier : end = ( hasMultiLines ) ? this . lineEnd : this . scanner . getCurrentTokenEndPosition ( ) ; if ( valid ) { pushIdentifier ( false ) ; break nextToken ; } break ; default : end = ( hasMultiLines ) ? this . lineEnd : this . scanner . getCurrentTokenEndPosition ( ) ; valid = false ; break ; } } boolean spaces = false ; nextToken : while ( true ) { this . currentTokenType = - 1 ; try { token = readToken ( ) ; } catch ( InvalidInputException e ) { valid = false ; } switch ( token ) { case TerminalTokens . TokenNameWHITESPACE : if ( ( this . scanner . currentPosition ) > ( ( this . lineEnd ) + 1 ) ) { hasMultiLines = true ; valid = false ; } spaces = true ; if ( valid ) break ; case TerminalTokens . TokenNameEOF : if ( this . reportProblems ) this . sourceParser . problemReporter ( ) . javadocInvalidParamTypeParameter ( start , end ) ; this . scanner . currentPosition = start ; this . index = start ; this . currentTokenType = - 1 ; this . scanner . tokenizeWhiteSpace = tokenWhiteSpace ; return false ; case TerminalTokens . TokenNameGREATER : end = ( hasMultiLines ) ? this . lineEnd : this . scanner . getCurrentTokenEndPosition ( ) ; if ( valid ) { pushIdentifier ( false ) ; break nextToken ; } break ; default : if ( ! spaces ) end = ( hasMultiLines ) ? this . lineEnd : this . scanner . getCurrentTokenEndPosition ( ) ; valid = false ; break ; } } } if ( valid ) { this . currentTokenType = - 1 ; int restart = this . scanner . currentPosition ; try { token = readToken ( ) ; } catch ( InvalidInputException e ) { valid = false ; } if ( token == ( TerminalTokens . TokenNameWHITESPACE ) ) { this . scanner . currentPosition = restart ; this . index = restart ; this . scanner . tokenizeWhiteSpace = tokenWhiteSpace ; return pushParamName ( isTypeParam ) ; } } this . currentTokenType = - 1 ; end = ( hasMultiLines ) ? this . lineEnd : this . scanner . getCurrentTokenEndPosition ( ) ; <START_BUG> while ( ( readToken ( ) ) != ( TerminalTokens . TokenNameWHITESPACE ) ) { <END_BUG> this . currentTokenType = - 1 ; end = ( hasMultiLines ) ? this . lineEnd : this . scanner . getCurrentTokenEndPosition ( ) ; } if ( this . reportProblems ) if ( ( this . jdk15 ) && isTypeParam ) this . sourceParser . problemReporter ( ) . javadocInvalidParamTypeParameter ( start , end ) ; else this . sourceParser . problemReporter ( ) . javadocInvalidParamTagName ( start , end ) ; this . scanner . currentPosition = start ; this . index = start ; this . currentTokenType = - 1 ; this . scanner . tokenizeWhiteSpace = tokenWhiteSpace ; return false ; } protected Object parseQualifiedName ( boolean reset ) throws InvalidInputException { } protected boolean parseReference ( ) throws InvalidInputException { } protected abstract boolean parseTag ( int previousPosition ) throws InvalidInputException { } protected boolean parseThrows ( ) { } protected char peekChar ( ) { } protected void pushIdentifier ( boolean newLength ) { } protected void pushOnAstStack ( Object node , boolean newLength ) { } protected abstract boolean pushParamName ( boolean isTypeParam ) { } protected abstract boolean pushSeeRef ( Object statement ) { } protected void pushText ( int start , int end ) { } protected abstract boolean pushThrowName ( Object typeRef ) { } protected char readChar ( ) { } protected int readToken ( ) throws InvalidInputException { } protected int readTokenAndConsume ( ) throws InvalidInputException { } protected int readTokenSafely ( ) { } protected void refreshInlineTagPosition ( int previousPosition ) { } protected void refreshReturnStatement ( ) { } public String toString ( ) { } protected abstract void updateDocComment ( ) { } protected void updateLineEnd ( ) { } private boolean verifyEndLine ( int textPosition ) { } private boolean verifySpaceOrEndComment ( ) { } }

Fix:
while ( ( ( token = readToken ( ) ) != ( TerminalTokens . TokenNameWHITESPACE ) ) && ( token != ( TerminalTokens . TokenNameEOF ) ) ) {