| Summary: | [formatting] Java condition (ternary) operator formatting error | ||||||||
|---|---|---|---|---|---|---|---|---|---|
| Product: | [Eclipse Project] JDT | Reporter: | Attila Molnar <amolnar> | ||||||
| Component: | Core | Assignee: | Mateusz Matela <mateusz.matela> | ||||||
| Status: | VERIFIED DUPLICATE | QA Contact: | |||||||
| Severity: | normal | ||||||||
| Priority: | P3 | CC: | bsd, daniel_megert, dusisarath, manoj.palat, mateusz.matela | ||||||
| Version: | 4.5.2 | ||||||||
| Target Milestone: | 4.6 M7 | ||||||||
| Hardware: | PC | ||||||||
| OS: | Linux | ||||||||
| Whiteboard: | |||||||||
| Attachments: |
|
||||||||
|
Description
Attila Molnar
Sorry, but I can't reproduce on 4.5.2 with a simple Java project. Please check your formatter settings. Or attach a small test project with embedded formatter settings to reproduce.
public class FormatterTest {
public static void main(String[] args) {
String report = args.length > 0 ? args[0] : "";
}
}
Created attachment 260345 [details]
format.xml
Created attachment 260346 [details]
screenshot
Attached the xml and the screenshot. Note, that even the preview is wrong not just the actual formatting. Repoened (added format.xml and screenshot) The problem is "Force wrap" option - even though it looks disabled, it still affects the formatting. So you can change the wrapping policy to something else, uncheck "Force split" and change policy back to "Do not wrap". *** This bug has been marked as a duplicate of bug 488898 *** Verified using Eclipse Version: Neon (4.6) Build id: I20160425-1300 |