Dealing With Exceptions

Dwight Hughes dwighth at ipa.net
Tue Aug 17 02:18:45 UTC 1999


A notion I've been occasionally muttering to myself about for the last
year or so is to work through the details of adding success/failure
semantics very similar to that in Icon throughout Squeak. Essentially
creating a generalization of Booleans (you would still have normal
Booleans - they would just be of more specialized use) while directly
taking care of many situations where explicit "exceptions" are now
applied.

-- Dwight

Bijan Parsia wrote:
[....................]
> And I realized that *whenever* I dealt with code that used an exception
> handling mechanism *I WAS CONSTANTLY DISTRACTED BY THE EXCEPTIONS*. This is
> *aside* from the compile and runtime pain of exceptions run amuck (in
> Java). Just *READING* the code was distracting. When I thought "Let's you
> focus on the normal logic" I envisioned myself bounding about, free and
> happy, naively coding in the straightforward manner. Yay! I would only have
> to read methods that, without exceptions, should be burned at the stake for
> the lack of error-checking, etc.
> 
> Of course, this is total fantasy. In really, try/catch, handle/do, signal,
> et al. are just more, and rather confusing, control structures. Boo!
> 
> I would be delighted if the exception stuff were entirely orthoganal to
> regular code, the way that class and variable declarations are. Perhaps
> this can be entirely handled by clever parsing and display. I don't know.
> 
> Maybe TextActions and hyperlinks are the solution. Or footnotes ;)
> 
> (Grumble. I don't like what they do to the call stack, either :))
> 
> Cheers,
> Bijan.





More information about the Squeak-dev mailing list