Hi Lauren,

I am a big fan of Common Lisp conditions and restarts. Just as mentioned I too already mused on the list once that the debugger notifier buttons like Proceed and Abandon could be generalized in this way.

However, they are not Smalltalk "standard" (not even de facto), therefore not portable, and you must expect that they do not get widely adopted even in the Squeak community (how many of us use Traits?!). I could see them being used as a Squeak-internal feature though, like for the debugger buttons... And I would like to use them for some error recovery cases in the Git Browser if they were already there.

About increasing the complexity of the system, I am torn. In Cuis, restarts would probably have no place for that reason, unless the learning/understanding impact is really small. Maybe it would be good to see first how much more complicated things get with a restarts mechanism in place. But that may be well after you or anyone else has already invested most of the work.

So, I would be delighted to see this happen. But I also do not want to incite any illusions. ;-)

Kind regards,
Jakob



Lauren P <drurowin@gmail.com> schrieb am Mo., 28. Nov. 2022, 17:49:
Hi List,

In reference to my question about the debugger in regards to Chronology-Core-dtl.80, I have a proposal.

I am halfway or so to stealing RESTART from Common Lisp for Squeak.  It lets the programmer define alternatives for exception handling.  Restarts would be responsible for making the Proceed, Abandon, etc. buttons in the debugger window, with every #on:offer: defining a button.

It's an extra layer of indirection and complexity in the evaluator, but it is an extremely powerful tool for writing clean code.  If I had to choose one of an interactive debugger or restarts I'd pick restarts.

Implementation is easy but tedious... restarts have lots of optional parameters.  If List thinks RESTART would be a good thing to have I will prioritize it.

PS: Whoever wrote the signalling code, thank you.  It is very clean and easy to read.  I learned everything about dynamic extent in Smalltalk from reading it.

-- 
Obviously, I vote yes, and the effort to not proselytize the Cult Of Restart here is great indeed.