Uploaded image for project: 'NetBeans'
  1. NetBeans
  2. NETBEANS-6194

Renaming folder inside PSR-4 directory don't use refactor feature

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Open
    • Minor
    • Resolution: Unresolved
    • 12.4, 12.5
    • None
    • None

    Description

      <?php
      
      declare(strict_types=1);
      
      namespace Issue\PDO;
      
      class ClassTest
      {
      
          public function __construct(string $a)
          {
              error_log($a);
          }
      
          public function doNothingAction(): Class2
          {
              throw new \Exception('nothing to do');
          }
      
      }
      
      

      The code above is a file inside a PSR-4 project located in directory "src/PDO". If I try to rename the folder "PDO" to "MySQL", a refactor dialog open, "PDO" is changed to new name and nothing else happen ("Rename Without Refactoring" checkbox not checked).

      What I expect is the refactoring feature to

      • change namespaces all over the project from "Issue\PDO" to "Issue\MySQL"
      • adjust "use" statements

      after renaming "PDO" to "MySQL".

      Attachments

        Activity

          People

            Unassigned Unassigned
            frkinta frkinta
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated: