[LispM-Hackers] error handling by abusing macro system
John Morrison
jm@mak.com
Mon, 9 Apr 2001 23:23:11 -0400
Hi;
(0) Oh, for a *real* macro system!
(1) Define a macro that causes the program to complain to stderr,
shoot itself in the head, and leave its corpse in a core file (hmm. A
CORpsE file?)
#define E3ThrowError(args) { cerr << "E3 THROW:" << args ; abort(); }
(2) Call the macro like so:
E3ThrowError("CALL_1_DEST_INDS::execute -- bad DTP target of call = "
<< (int)operand.getDataType()
<< endl);
(3) Replace later with something less, well, embarrassing.
-jm