Opened 11 years ago

Last modified 9 years ago

#525 new enhancement

Feature request: "Rename subroutine"

Reported by: rhebus Owned by:
Priority: major Milestone:
Component: Refactoring Perl 5 Version: 0.45
Keywords: refactor Cc:


Subroutine renaming is an important refactoring technique. Often you find that the name you originally used for a subroutine wasn't ideal, but by the time you have thought of a better, clearer name it is already referenced 20 times in 10 files.

A "rename subroutine" function would rename the subroutine *and* all references to it throughout the project. Clearly this requires syntactic parsing of all files in the project; a global search-and-replace is flaky and dangerous since it will change subroutines with the same name in different packages.

More info on subroutine renaming: -- example of rename field and method in eclipse for Java

Change History (4)

comment:1 Changed 11 years ago by szabgab

  • Component changed from editor to advanced perl tools

comment:2 Changed 11 years ago by rhebus

Devel::Refactor provides the functionality needed if someone can help me plumb it in.

comment:3 Changed 10 years ago by zenogantner

  • Keywords refactor added

comment:4 Changed 9 years ago by szabgab

  • Component changed from advanced perl tools to Refactoring Perl 5
Note: See TracTickets for help on using tickets.