1. Enhancement to debugging facilities?

I was working on a fairly complex program over the past couple
  of days (bad idea when you're down with the flu, but I needed
  something to do) and kept on hitting an error that was hell to
  track down.  It turned out to be fairly trivial, and I easily
  fixed it - but it was in a procedure that was called from
  several locations, and it was a logic error that caused flow
  to be directed into what amounts to my "errorexit" procedure.
  When I tried deskchecking the code, I couldn't reproduce the
  error.  When I finally solved it, I realized that an ex.err
  dump would have been helpful.

  Would it be possible or reasonable to have a procedure
  equivalent to abort() that would, if provided with a non-zero
  parameter, create an ex.err file?  Or, alternatively, modify
  abort() to do so, possibly via a second parameter or setting a
  pragma?

 =========================================================================
Jeff Zeitlin                                      jeff.zeitlin at execnet.com
---
 ~ OLXWin 1.00b ~ The "chain" of command is often a noose.

new topic     » topic index » view message » categorize

2. Enhancement to debugging facilities?

Jeff Zeitlin writes:
> Would it be possible or reasonable to have a procedure
> equivalent to abort() that would, if provided with a non-zero
> parameter, create an ex.err file?  Or, alternatively, modify
> abort() to do so, possibly via a second parameter or setting a
> pragma?

What I usually do is something like:

   if something_is_wrong then
      ? 1/0
   end if

This will generate a divide by zero error and
you'll get a full ex.err dump with traceback.
You could put this into your own routine like
the modified "abort" routine in demo\sanity.ex
that overrides the usual abort().

Regards,
  Rob Craig
  Rapid Deployment Software

new topic     » goto parent     » topic index » view message » categorize

Search



Quick Links

User menu

Not signed in.

Misc Menu