| Summary: | [formatter] Bad line breaking in Eclipse javadoc comments | ||
|---|---|---|---|
| Product: | [Eclipse Project] JDT | Reporter: | Ted Hopp <ted.hopp> |
| Component: | Core | Assignee: | Mateusz Matela <mateusz.matela> |
| Status: | VERIFIED FIXED | QA Contact: | Ayushman Jain <amj87.iitr> |
| Severity: | normal | ||
| Priority: | P3 | CC: | amj87.iitr, bepeppered, frederic_fusier, jarthana, manoj.palat, mateusz.matela, tparker, trevor |
| Version: | 3.7 | Flags: | manoj.palat:
review+
|
| Target Milestone: | 4.6 M1 | ||
| Hardware: | PC | ||
| OS: | Windows 7 | ||
| See Also: |
https://git.eclipse.org/r/51624 https://git.eclipse.org/c/jdt/eclipse.jdt.core.git/commit/?id=260ff63e87f242ab982cdcea6ba42f866e16f101 https://bugs.eclipse.org/bugs/show_bug.cgi?id=460318 |
||
| Whiteboard: | |||
Reproduced with 3.7RC4 This still occurs as of Kepler SR1 (20130919-0819). It applies not only to periods, but also commas, semicolons, etc. Still exists in Luna :( Where is the problem to fix this with making an \n to an visible <br/> guys? Manoj, I can provide a patch for this - would you push it into one of the release candidates? Bug 383942 and bug 460318 can be marked as duplicate. (In reply to Mateusz Matela from comment #4) > Manoj, I can provide a patch for this - would you push it into one of the > release candidates? > Bug 383942 and bug 460318 can be marked as duplicate. Is this still a concern and the offer still available? :) Sure :) I've pushed my change to gerrit: https://git.eclipse.org/r/#/c/51624/ I use gerrit for the first time, I don't know why it didn't start a build and add a notification here. In general I have several fixes ready for the formatter, but I was going to wait for one patch to be accepted before pushing another to avoid merge conflicts (which are almost certain in test classes). Currently bug 471090 awaits review. Let me know if conflicts would not be a problem and you'd prefer more patches simultaneously. Gerrit change https://git.eclipse.org/r/51624 was merged to [master]. Commit: http://git.eclipse.org/c/jdt/eclipse.jdt.core.git/commit/?id=260ff63e87f242ab982cdcea6ba42f866e16f101 (In reply to Eclipse Genie from comment #7) > Gerrit change https://git.eclipse.org/r/51624 was merged to [master]. > Commit: > http://git.eclipse.org/c/jdt/eclipse.jdt.core.git/commit/ > ?id=260ff63e87f242ab982cdcea6ba42f866e16f101 It's fixed then. Verified for 4.6 M1 with build I20150804-2000. *** Bug 480359 has been marked as a duplicate of this bug. *** |
Build Identifier: 20110218-0911 If a javadoc line ends with the closing brace of a tag in the last line before the current line wrap setting and is followed immediately by a period, formatting the code will move the period to the start of the next javadoc line. This puts white space between the text and the period in the generated output, so a browser rendering the Javadoc in HTML, for instance, will also think it's okay to break there. This doesn't seem to happen unless the period follows a Javadoc tag. (For instance, if the line ended with a closing parenthesis and a period in column 81, it would correctly break before the last word.) Reproducible: Always Steps to Reproduce: 1. Write some Javadoc like this: /** * - - - stuff - - - {@code mTasksBelow}. */ where the period is at the wrap column + 1. 2. Format the code (using CTRL-SHIFT-F or Source > Format.