https://bugs.kde.org/show_bug.cgi?id=399527

            Bug ID: 399527
           Summary: Rename declaration works only in current class
           Product: kdevelop
           Version: 5.2.4
          Platform: Archlinux Packages
                OS: Linux
            Status: REPORTED
          Severity: normal
          Priority: NOR
         Component: Language Support: CPP (Clang-based)
          Assignee: kdevelop-bugs-n...@kde.org
          Reporter: piotr.mierzwin...@gmail.com
  Target Milestone: ---

SUMMARY
As in subject. I assumed that this function works for all occurrences of
renamed member (in this case name of public function in class) in project. I
was surprised when it didn't happen. I think in previous version of KDevelop
(not sure which version) it was working for whole project not only inside
current class.

Please note that calling "Show uses" for given member shows _all_occurrences_,
appearing in project not only in current class. Maybe this is some regression.

STEPS TO REPRODUCE
1. Remove cache ~/.cache/kdevduchain and run KDevelop with some C++ (Qt5 based)
project (after cache is generated go to step 2)
2. In cpp file call "Rename declaration" for any of public member of class what
is also called from other classes (calling by Ctrl+Shift+R)
3. 

OBSERVED RESULT
In "Rename ..." window, tab "Uses" are visible only uses for current class
Additionally side effect (caused by another bug) is as following.
If renamed function appears in such structure:
if (something)
  renamedFunction();
else
  differentFunction();

then in result I see:
if (something)
      {
  renamedFunction();
else
  differentFunction();


EXPECTED RESULT
In "Rename ..." window, tab "Uses" should be visible uses appearing in whole
project. The same like after usage of "Show uses".

SOFTWARE VERSIONS
(available in About System)
KDE Plasma Version: 5.13.5
KDE Frameworks Version: 5.50.0
Qt Version: 5.11.2

ADDITIONAL INFORMATION

-- 
You are receiving this mail because:
You are watching all bug changes.

Reply via email to