mbien commented on code in PR #8827:
URL: https://github.com/apache/netbeans/pull/8827#discussion_r2370126755
##########
java/java.hints/src/org/netbeans/modules/java/hints/OrganizeImports.java:
##########
@@ -213,21 +243,38 @@ public int compare(ImportTree o1, ImportTree o2) {
return 0;
String s1 = o1.getQualifiedIdentifier().toString();
String s2 = o2.getQualifiedIdentifier().toString();
- int bal = groups.getGroupId(s1, o1.isStatic()) -
groups.getGroupId(s2, o2.isStatic());
+ int bal;
+ if (o1.isModule()) bal = o2.isModule() ? 0 : 1; // Place
element imports last
+ else if (o2.isModule()) bal = -1; // Place
element imports last
+ else bal = groups.getGroupId(s1, o1.isStatic()) -
groups.getGroupId(s2, o2.isStatic());
Review Comment:
nitpick: please use some {} blocks here
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]
For further information about the NetBeans mailing lists, visit:
https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists