-
Notifications
You must be signed in to change notification settings - Fork 2
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Class rename also updates method sends (3.0.76) #513
Comments
Note - updated issue report for easier to read formatting |
Removed dialog & and make sure methods are still shown after rename
Removed the dialog in 3.0.77 but the primary complaint is a Rowan issue as the recompiled method behavior is handled there. Closing. @LisaAlmarode - Can you create a Rowan issue for the primary complaint? |
I'm afraid we can't just close issues that show up in Oscar if we are waiting on a fix in Rowan. They are still bugs. |
Opened rowan bug for Eric: |
I refer you this comment ... the mistaken edit is occurring right here in RowanClassService code. |
@dalehenrich is correct. Services is making the changes to methods and is responsible for updating renamed classes in method source properly. (Oversight / Faulty memory on my part) I believe a fix is to look for references to the old class rather than the old class name in However, If there isn't a way to find the references to the class object with source offsets, maybe we can just live with a substring search / replace. After all, we do display the changed methods so the user can review and fix any mistakes. Thoughts @LisaAlmarode? |
@ericwinger I don't know of anyplace other than |
I've improved the reference search to only search for references to the class, not the class name. GemTalk/Rowan@b207488 @LisaAlmarode Dale's suggestion to write up an object reference search with offsets is a good one. However, after reviewing the |
The basic issue is fixed, so I am fine to remove the November 19 label. I'm not entirely sure I follow the details of the discussion. Are there some behaviors that are incorrect, or do you want to improve the underlying code? (Boy, do I dislike autocomplete! It slowed things down like crazy (perhaps since I'm remote), and I accidentally entered wrong code. I suggest the default be off). |
As of v3.2.12, my method doesn't get renamed; this issue is fixed. Opened issue #974 for the converse, methods on that class that refer to that class fail to recompile, which I think is the point of the later discussion under this issue. |
If you have a method send within a method that is the same as the class name, the method name gets updated.
The class is named
RenameTest
.instance methods:
When I renamed
RenameTest
toNewName
,the
RenameTest
method was unchanged.the test method was updated:
which will fail since there's no method
NewName
.It would be more serious if it was likely that this occurred under normal conditions - I just stuck a 'self' in front of the class name so I would be able to test the rename.
This is a good time to also request that I not be informed if no methods were updated. That extra dialog I don't need.
The text was updated successfully, but these errors were encountered: