Re: IDL excels in debugging??? Do you know something I dont? [message #4259] |
Thu, 18 May 1995 00:00 |
patterso
Messages: 36 Registered: February 1995
|
Member |
|
|
Mark Rivers (rivers@cars3.uchicago.edu) wrote:
: >The most useful debugging technique (other than the good ole PRINT statement)
: >I know of is the following 2 line routine, offered to me once by
: >rep2857@sbsun0010.sbrc.hac.com (Mike Schienle)
: >
: >; BREAK.PRO: a "debugging" routine. it always causes an error. Period.
: >; A call to 'break' in IDL will break IDL and return to the routine
: >; which called it, allowing you to examine all variables' values at
: >; the point it was called. There is generally no way to continue execution,
: >; you must "RETALL & XMANAGER" (aargh!). R. Welti; from M.Schienle
: >
: >PRO
: >END
: >
: >In fact, I would love to read a discussion of what other people are using
: >for debugging techniques / tools.
: Why not just use the STOP statement in your routine? It stops IDL, leaving you
: at the command line, allowing you to examine all variables' values, etc.
: without generating the error. Once you are done examining variable, etc. you
: can continue on by just typing .CON.
I just use control C and .con (or xmanager in a Windows situation)
to debug my code. But it's not pretty :)
I'd love it if the step command would actaully just oprint the relevant
line of code to the screen so I knew where I was in the code.
|
|
|
Re: IDL excels in debugging??? Do you know something I dont? [message #4261 is a reply to message #4259] |
Thu, 18 May 1995 00:00  |
rivers
Messages: 228 Registered: March 1991
|
Senior Member |
|
|
> The most useful debugging technique (other than the good ole PRINT statement)
> I know of is the following 2 line routine, offered to me once by
> rep2857@sbsun0010.sbrc.hac.com (Mike Schienle)
>
> ; BREAK.PRO: a "debugging" routine. it always causes an error. Period.
> ; A call to 'break' in IDL will break IDL and return to the routine
> ; which called it, allowing you to examine all variables' values at
> ; the point it was called. There is generally no way to continue execution,
> ; you must "RETALL & XMANAGER" (aargh!). R. Welti; from M.Schienle
>
> PRO
> END
>
> In fact, I would love to read a discussion of what other people are using
> for debugging techniques / tools.
Why not just use the STOP statement in your routine? It stops IDL, leaving you
at the command line, allowing you to examine all variables' values, etc.
without generating the error. Once you are done examining variable, etc. you
can continue on by just typing .CON.
____________________________________________________________
Mark Rivers (312) 702-2279 (office)
CARS (312) 702-9951 (secretary)
Univ. of Chicago (312) 702-5454 (FAX)
5640 S. Ellis Ave. (708) 922-0499 (home)
Chicago, IL 60637 rivers@cars3.uchicago.edu (Internet)
|
|
|