[Ecls-list] Comment of ongoing changes

Juan Jose Garcia-Ripoll jjgarcia at users.sourceforge.net
Mon Oct 30 13:12:06 UTC 2006


Hi,

as you have read from previous emails, I am slightly changing the way
ECL reports error messages. Currently there are a lot of functions
FEwrong_type_argument, FEerror,... which do little else than signaling
an error and jumping into the debugger.

My hope is to reduce the number of error reporting functions. They
will be replaced by a small number of functions ecl_check_type*, which
check take as input a lisp object and return an object whose type has
been verified. If the type check fails, an error is signaled, but a
number of hopefully useful restarts are set up. Right now we have
ecl_check_cl_type() and ecl_check_type_string(), which provide
USE-VALUE restarts (i.e. the user supplies a new value), but I am also
thinking about other ones such as looking for similar files or
mistyped symbols, etc.

The code is unfortunately slightly enlarged, because the checking
functions have to be supplied with useful debugging information
(function name, some string identifying the value, etc). However the
changes so far have not been very dramatic, and seems to be
compensated by other code simplifications and clarity of error
messages.

A side effect is that I am writing down all places where error may
happen and expect to produce a useful table for the documentation,
with the type of conditions to be expected, when, etc.

Finally, my own wish would be if someone could come up with a
semiportable way to produce backtraces that include not only
interpreted but also compiled functions. By "semiportable" I mean that
a little assembler will not hurt, as far as it is confined by a useful
API, like in our FFI.

Regards,

Juanjo




More information about the ecl-devel mailing list