comp.lang.idl-pvwave archive
Messages from Usenet group comp.lang.idl-pvwave, compiled by Paulo Penteado

Home » Public Forums » archive » Varaibles higher on the stack
Show: Today's Messages :: Show Polls :: Message Navigator
E-mail to friend 
Switch to threaded view of this topic Create a new topic Submit Reply
Varaibles higher on the stack [message #15100] Wed, 21 April 1999 00:00 Go to next message
Carsten Dominik is currently offline  Carsten Dominik
Messages: 45
Registered: February 1998
Member
Hi everyone.

I am wondering: can I print the value of variables higher up on the
calling stack? In IDLDE version 5.2 this is possible with the

"Move up the call stack" and "Move down the call stack" icons.

Can I do something similar from the command line or does this use an
internal feature of IDL which is not accessible to the ordinary user?

- Carsten

--
Carsten Dominik <dominik@strw.LeidenUniv.nl> \ _ /
Sterrewacht, P.O. Box 9513 |X| _
NL-2300 RA Leiden (The Netherlands) /| |\ _ _ _/ \
phone +31 (71) 527-5812; FAX +31 (71) 527-5819 ___|o|____/ ~~ \___/ ~~~~~
Re: Varaibles higher on the stack [message #15166 is a reply to message #15100] Fri, 23 April 1999 00:00 Go to previous message
Carsten Dominik is currently offline  Carsten Dominik
Messages: 45
Registered: February 1998
Member
"R.Bauer" <R.Bauer@fz-juelich.de> writes:

> Carsten Dominik wrote:
>
>> Hi everyone.
>>
>> I am wondering: can I print the value of variables higher up on the
>> calling stack? In IDLDE version 5.2 this is possible with the
>>
>> "Move up the call stack" and "Move down the call stack" icons.
>>
>> Can I do something similar from the command line or does this use an
>> internal feature of IDL which is not accessible to the ordinary user?
>>
>> - Carsten
>>
>> --
>
> Result = RECALL_COMMANDS()
>

Thanks, but that is not what I mean. I mean this:

pro test
x=1
test1
end

pro test1
x=2
stop
end


When I run "TEST", the program execution stops at the STOP statement
in the test1 procedure. When I then ask for the value of X with

print,x

I get 2, the value of x in the procedure TEST1.

For debugging purposes it can be useful to ask what x was (1) in the
calling procedure TEST. The answer should be one (1).

In IDL5.2, in the develloment environment you can ask such a question.
When you press the "up stack" button, the variable list shows the
value of x in TEST. When you press the "Down stack" button, you get
back to the value in TEST1.

However, PRINT always says x is 2, even when the variable display is
showing values higher on the stack (which I would consider a bug).

I would like to know if there is a magic command to read the values of
variables higher on the calling stack, or if this is only possible in
idlde because it uses some internal stuff not available at the command
prompt.

I am asking because I would like to support stack motions also with
the Emacs IDL modes.

- Carsten

--
Carsten Dominik <dominik@strw.LeidenUniv.nl> \ _ /
Sterrewacht, P.O. Box 9513 |X| _
NL-2300 RA Leiden (The Netherlands) /| |\ _ _ _/ \
phone +31 (71) 527-5812; FAX +31 (71) 527-5819 ___|o|____/ ~~ \___/ ~~~~~
  Switch to threaded view of this topic Create a new topic Submit Reply
Previous Topic: Structure in argument #2 -> With IDL ActiveX control
Next Topic: Re: PB: Color tables on Macintosh

-=] Back to Top [=-
[ Syndicate this forum (XML) ] [ RSS ] [ PDF ]

Current Time: Wed Oct 08 18:40:36 PDT 2025

Total time taken to generate the page: 0.00521 seconds