There are two questions, but only response accepted.
I just want a pull up with nothing extra done.
If I click yes, I get the extra methods.
If I click no, nothing at all happens.
Please advise,
Thanks,
Aik-Siong Koh
Yes, I've run into this before. I think the reasoning is that, if you do
not copy down the superclass implementation, this is not truly a
refactoring—it will change the behavior of a selector that was already
understood by the siblings. But I agree that in many cases, this change of
behavior is the desired outcome and having the option would be good. The
simplest change would be to add a "Cancel" button, and make the "No" option
do what you want—perform the refactoring without adding the extra methods.
Perhaps adding a warning to the text of the dialog like "Choosing 'No' may
modify behavior." (ideally more detailed but I'm having trouble phrasing it
concisely).
On Sat, Jun 28, 2025 at 10:54 AM Aik-Siong Koh askoh@askoh.com wrote:
There are two questions, but only response accepted.
I just want a pull up with nothing extra done.
If I click yes, I get the extra methods.
If I click no, nothing at all happens.
Please advise,
Thanks,
Aik-Siong Koh
HI daniel
You are right. Now a bit more context of our current work.
We are working on this.
The point is that the old refactoring code hardcoded in precondition the possible actions in an non user friendly way.
Now in Pharo 13 and 14 we have introduced Drivers.
A drivers is
- using finer decomposition of preconditions to able to propose for example multiple actions
such as executing another refactorings to a mere transformation
Have a look at Remove Classes on a non empty or classes with subclasses
to see what I mean.
Now we are adding and reviewing slowly a driver to each refactorings.
For the PullUp method the refact
On 29 Jun 2025, at 01:37, Daniel Slomovits daniels220@gmail.com wrote:
Yes, I've run into this before. I think the reasoning is that, if you do not copy down the superclass implementation, this is not truly a refactoring—it will change the behavior of a selector that was already understood by the siblings.
Indeed this is what the refactoring should do in batch mode.
Now in interactive mode then a driver should propose multiple alternatives.
But I agree that in many cases, this change of behavior is the desired outcome and having the option would be good. The simplest change would be to add a "Cancel" button, and make the "No" option do what you want—perform the refactoring without adding the extra methods. Perhaps adding a warning to the text of the dialog like "Choosing 'No' may modify behavior." (ideally more detailed but I'm having trouble phrasing it concisely).
Now to be able to do it we have to rewrite all the conditions to not raise pop up but give enough information to the driver so that it can propose nice choices.
S
On Sat, Jun 28, 2025 at 10:54 AM Aik-Siong Koh <askoh@askoh.com mailto:askoh@askoh.com> wrote:
<felikbkighlfeoli.png>
There are two questions, but only response accepted.
I just want a pull up with nothing extra done.
If I click yes, I get the extra methods.
If I click no, nothing at all happens.
Please advise,
Thanks,
Aik-Siong Koh
Stéphane Ducasse
http://stephane.ducasse.free.fr
06 30 93 66 73
"If you knew today was your last day on earth, what would you do differently? ....ESPECIALLY if, by doing something different, today might not be your last day on earth.” Calvin & Hobbes