You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@netbeans.apache.org by "junichi11 (via GitHub)" <gi...@apache.org> on 2023/07/11 15:35:08 UTC

[GitHub] [netbeans] junichi11 opened a new pull request, #6179: Don't remove existing uses if they are the same as the created string for use statements

junichi11 opened a new pull request, #6179:
URL: https://github.com/apache/netbeans/pull/6179

   - https://github.com/apache/netbeans/pull/5681
   - Avoid changing the file state if the created string is the same as the existing use statements
   


-- 
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: notifications-unsubscribe@netbeans.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org
For additional commands, e-mail: notifications-help@netbeans.apache.org

For further information about the NetBeans mailing lists, visit:
https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists


[GitHub] [netbeans] tmysik commented on pull request #6179: Don't remove existing uses if they are the same as the created string for use statements

Posted by "tmysik (via GitHub)" <gi...@apache.org>.
tmysik commented on PR #6179:
URL: https://github.com/apache/netbeans/pull/6179#issuecomment-1631934407

   @junichi11 I agree, it makes sense to me. We can always wait for a new report.
   


-- 
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: notifications-unsubscribe@netbeans.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org
For additional commands, e-mail: notifications-help@netbeans.apache.org

For further information about the NetBeans mailing lists, visit:
https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists


[GitHub] [netbeans] junichi11 merged pull request #6179: Don't remove existing uses if they are the same as the created string for use statements

Posted by "junichi11 (via GitHub)" <gi...@apache.org>.
junichi11 merged PR #6179:
URL: https://github.com/apache/netbeans/pull/6179


-- 
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: notifications-unsubscribe@netbeans.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org
For additional commands, e-mail: notifications-help@netbeans.apache.org

For further information about the NetBeans mailing lists, visit:
https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists


[GitHub] [netbeans] junichi11 commented on a diff in pull request #6179: Don't remove existing uses if they are the same as the created string for use statements

Posted by "junichi11 (via GitHub)" <gi...@apache.org>.
junichi11 commented on code in PR #6179:
URL: https://github.com/apache/netbeans/pull/6179#discussion_r1260955269


##########
php/php.editor/src/org/netbeans/modules/php/editor/actions/FixUsesPerformer.java:
##########
@@ -493,13 +505,22 @@ private String createStringForCommonUse(List<UsePart> useParts) {
         return result.toString();
     }
 
-    private void processExistingUses() {
-        ExistingUseStatementVisitor visitor = new ExistingUseStatementVisitor();
-        Program program = parserResult.getProgram();
-        if (program != null) {
-            program.accept(visitor);
+    private String getExistingUses(List<OffsetRange> usedRanges) {
+        String existingUses = ""; // NOI18N

Review Comment:
   Fixed.



-- 
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: notifications-unsubscribe@netbeans.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org
For additional commands, e-mail: notifications-help@netbeans.apache.org

For further information about the NetBeans mailing lists, visit:
https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists


[GitHub] [netbeans] junichi11 commented on a diff in pull request #6179: Don't remove existing uses if they are the same as the created string for use statements

Posted by "junichi11 (via GitHub)" <gi...@apache.org>.
junichi11 commented on code in PR #6179:
URL: https://github.com/apache/netbeans/pull/6179#discussion_r1260950236


##########
php/php.editor/src/org/netbeans/modules/php/editor/actions/FixUsesPerformer.java:
##########
@@ -493,13 +505,22 @@ private String createStringForCommonUse(List<UsePart> useParts) {
         return result.toString();
     }
 
-    private void processExistingUses() {
-        ExistingUseStatementVisitor visitor = new ExistingUseStatementVisitor();
-        Program program = parserResult.getProgram();
-        if (program != null) {
-            program.accept(visitor);
+    private String getExistingUses(List<OffsetRange> usedRanges) {
+        String existingUses = ""; // NOI18N

Review Comment:
   Oops, thank you for catching it :)



-- 
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: notifications-unsubscribe@netbeans.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org
For additional commands, e-mail: notifications-help@netbeans.apache.org

For further information about the NetBeans mailing lists, visit:
https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists


[GitHub] [netbeans] junichi11 commented on pull request #6179: Don't remove existing uses if they are the same as the created string for use statements

Posted by "junichi11 (via GitHub)" <gi...@apache.org>.
junichi11 commented on PR #6179:
URL: https://github.com/apache/netbeans/pull/6179#issuecomment-1631060827

   I didn't fix the "multiple default namespaces" issue because I didn't think it's important.
   I hope that the regressions are resolved in NB19.


-- 
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: notifications-unsubscribe@netbeans.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org
For additional commands, e-mail: notifications-help@netbeans.apache.org

For further information about the NetBeans mailing lists, visit:
https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists


[GitHub] [netbeans] tmysik commented on a diff in pull request #6179: Don't remove existing uses if they are the same as the created string for use statements

Posted by "tmysik (via GitHub)" <gi...@apache.org>.
tmysik commented on code in PR #6179:
URL: https://github.com/apache/netbeans/pull/6179#discussion_r1260673403


##########
php/php.editor/src/org/netbeans/modules/php/editor/actions/FixUsesPerformer.java:
##########
@@ -493,13 +505,22 @@ private String createStringForCommonUse(List<UsePart> useParts) {
         return result.toString();
     }
 
-    private void processExistingUses() {
-        ExistingUseStatementVisitor visitor = new ExistingUseStatementVisitor();
-        Program program = parserResult.getProgram();
-        if (program != null) {
-            program.accept(visitor);
+    private String getExistingUses(List<OffsetRange> usedRanges) {
+        String existingUses = ""; // NOI18N

Review Comment:
   Nitpick:
   
   ```suggestion
           String existingUses = EMPTY_STRING;
   ```



-- 
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: notifications-unsubscribe@netbeans.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org
For additional commands, e-mail: notifications-help@netbeans.apache.org

For further information about the NetBeans mailing lists, visit:
https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists