Refactor -> Rename doesn't work completely (2114)
I tried renaming a class that lived in module 1. I have a few more modules
all dependent on module 1. If I rename the class in module 1 then what
happens is that it will replace the name in the other modules except for the
first instance in each file. For example, I have file foo.java in module 2
(dependent on module 1) and in foo.java, I have a Constants class reference
(which lives in module 1). I renamed Constants to CoreConstants and in my
foo.java, what happens is that say for 5 references to that class, the first
is left alone (remains Constants) and the rest of the references are renamed
to the fully qualified path (i.e. com.bc.CoreConstants). So in the end, I
have to go back to every single java file that contained Constants and
replace the first reference to that class manually.
I hope that makes sense.
--Grant
Please sign in to leave a comment.
Grant Gochnauer wrote:
Grant,
please submit an SCR for this one. The SCR will be useless without a test
case (some small project that reproduces this behaviour).
Friendly,
Dmitry
--
Dmitry Lomov
Software Developer
JetBrains Inc.
http://www.jetbrains.com
"Develop with pleasure!"