Open macta opened 4 months ago
I do not know how to reproduce this. Would it be possible to give us step by step instructions?
This has happened to me several times now - although I just noticed that If I save the outer method - it does recompute and clean up (before I had closed that class).
This is GT 853 (not sure if there is a way in the environment to see this version number easily - I found the zip file I last used)
I will see if I can do it with a simpler example - in the case above it was my ParseNode visitor and I simply was added a new case to handle HasOne tokens - so literally had just typed the line where the red smudge is, and clicked on the spanner next to the self hasOneReferences code - and then I got the above.
Hmm in a small example it seems to work as expected - I suspect it has something to do with having more than 1 page of methods, and rather than editing the new method inline, I scrolled up to the top - fixed my method and added a new slot and save the method and then when I scrolled back down to the original code it then exhibited this problem (I'ts happened 2x to me now). A simple subclass with a few methods seems to work fine... so not quite sure where it gets mixed up and will have to keep an eye open.
I can't repro it in the original class now either - if it doesn't happen again in the next few days, just close it ... its some strange ordering of operations. I did notice that when I did it in my original class, the window scrolled funny so I didn't notice the inline option to edit my method inplace and so scrolled up in my browser window to edit it alphabetically. I wonder if its something to do with that (but still couldn't repro it)
If I have a method in a class inspector, and I add a reference to an undefined method in an existing method that I am editing - GT offers a spanner correction to define the method (even before I have saved). If I click on the spanner it creates me a new empty method (in this case a getter method #hasOneReferences) which I have gone up to complete this code (add a slot and lazy initialization code - aside: would be awesome to have a spanner action to just do this for me vs create an empty method) - however when I have gone back to my original method (and not sure if the adding my getter has something to do with this) but I discover that the code section for my existing method is now corrupted - it has inline expanded the definition of the newly added method buy I can't collapse it - in fact expanding it gives me 2 inline expansions. (attached pictures show both states - see the inline expansion below the red shaded method)