Bug 229682

Summary: [formatter] New comment put text over the max line length in some cases
Product: [Eclipse Project] JDT Reporter: Frederic Fusier <frederic_fusier>
Component: CoreAssignee: Frederic Fusier <frederic_fusier>
Status: VERIFIED FIXED QA Contact:
Severity: normal    
Priority: P3 CC: daniel_megert, eric_jodet, jerome_lanneluc
Version: 3.4Flags: jerome_lanneluc: review+
Target Milestone: 3.4 RC1   
Hardware: PC   
OS: Windows XP   
Whiteboard:
Attachments:
Description Flags
Test case to illustrate the problem none

Description Frederic Fusier CLA 2008-04-30 13:35:24 EDT
Created attachment 98228 [details]
Test case to illustrate the problem

Using build I20080427-2000.

The new formatter fails to format correctly the attached test case.
The closing parenthesis should not be put on the same line than the reference as it makes the line over the max line length (80)
Comment 1 Frederic Fusier CLA 2008-05-06 05:49:52 EDT
The patch fixing this issue has been attached to bug 230230.
Jerome can you please review?
Comment 2 Frederic Fusier CLA 2008-05-06 07:08:25 EDT
Released for 3.4RC1 in HEAD stream.
Comment 3 Eric Jodet CLA 2008-05-13 06:14:27 EDT
using build I20080510-2000 and formatting attached file.

Formatted javadoc is still:

/**
 * Shutdown the HCR mgr and the Java debug targets.
 * 
 * @see
 * org.osgi.framework.BundleActivator#stop(org.osgi.framework.BundleContext
 * ) text
 */


Expected formatted javadoc comment:

/**
 * Shutdown the HCR mgr and the Java debug targets.
 * 
 * @see org.osgi.framework.BundleActivator#stop(org.osgi.framework.BundleContext)
 *      text
 */
Comment 4 Eric Jodet CLA 2008-05-13 06:15:37 EDT
(In reply to comment #3)
> Expected formatted javadoc comment:
> 
expect the @see and its reference to be on the same line
Comment 5 Frederic Fusier CLA 2008-05-13 11:43:03 EDT
This problem has been definitely fixed with bug 231263 patch...
Comment 6 Frederic Fusier CLA 2008-05-13 11:49:03 EDT
I should not have set this bug as fixed before the patch was released!
Comment 7 Frederic Fusier CLA 2008-05-13 11:49:16 EDT
Jerome, could you please review?
Comment 8 Jerome Lanneluc CLA 2008-05-13 11:55:59 EDT
Reviewed patch with Frederic: +1
Comment 9 Frederic Fusier CLA 2008-05-13 13:21:44 EDT
Released for 3.4RC1 in HEAD stream.
Comment 10 Eric Jodet CLA 2008-05-14 02:10:12 EDT
Verified for 3.4RC1 using build I20080513-2000
(this now works perfectly)