Community
Participate
Working Groups
Build ID: I20061214-1445 Steps To Reproduce: Try to format the following snippet: public static interface CustomerData { public /**/OrderData[]/**/ ordersForLastNDays( int _days ); } Eclipse removes the spaces around the /**/ comments. These comments may seem pointless, but they are highlighting markers for JCite (http://arrenbrecht.ch/jcite/). More information: As an alternative, bug 128630 would help me work around this problem.
If I had an option, I would be to remove whitespaces around comments everywhere and not just in the method declaration. Otherwise I will end up with an endless list of new options.
(In reply to comment #1) > If I had an option, I would be to remove whitespaces around comments everywhere > and not just in the method declaration. Otherwise I will end up with an endless > list of new options. I don't think I fully understand what you mean. What option? Can you not just leave the whitespace alone there? Would that have to be an option? And what would be the point of removing all whitespace around comments? Would you then get "i = 3;// three" when you originally wrote "i = 3; // three"?
Created attachment 73389 [details] Proposed patch so people can check the regressions I am trying to fix this. My own test works nicely. But I get regressions where before "abstract /* */ class" would result in "abstract/* */class", but now in "abstract /* */class". Does anyone know if this matters? Or can it be changed? After all, right now "package /*...*/xy" is left as "package /*...*/xy" and not reformatted to "package/*...*/xy". So the current behaviour does not really look consistent to me anyway. I have attached a first version of the proposed patch.
*** Bug 220242 has been marked as a duplicate of this bug. ***
This problem no longer occurs after the formatter redesign. *** This bug has been marked as a duplicate of bug 303519 ***
Verified for 4.12 M3 using build I20190520-1805