Weird Language Features

Neelakantan Krishnaswami neelk at alum.mit.edu
Sun Feb 18 16:15:37 EST 2001


[Crossposting trimmed]

On 18 Feb 2001 12:16:31 -0800, Johann Hibschman <johann at physics.berkeley.edu>
wrote:
>Dave Cross writes:
>
>> 1/ The programmer calls a function that doesn't actually exist within
>> the application (or libraries).
>
> It's easy to trap this error in Common Lisp, but it's hard to set up a
> "general replacement" routine.  You can, generally, trap the error for
> a given block of code, then attempt to guess a replacement function,
> but I don't think you can then resume the calculation.

I'm not a serious CL user, but aren't its exceptions restartable? That
would permit you to do this. It would be really nice if Python's
exception system supported this. Then I wouldn't have to choose
between raising an exception and having my constructor functions
behave algebraically.

> Have fun.  I do suspect that Common Lisp whups Perl in this respect,
> though.  :-)

Yeah. :)


Neel



More information about the Python-list mailing list