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

Home » Public Forums » archive » A strange behaviour of parameters passing
Show: Today's Messages :: Show Polls :: Message Navigator
E-mail to friend 
Return to the default flat view Create a new topic Submit Reply
A strange behaviour of parameters passing [message #15630] Thu, 03 June 1999 00:00 Go to previous message
Daniel SAGE is currently offline  Daniel SAGE
Messages: 10
Registered: April 1998
Junior Member
Hi,
Who can explain me the strange behaviour when I passed my parameters ?
I create a small and stupid example to see the disfunctionning of IDL.
Why the first call of the procedure 'one' returns 1 and the second call
return 2 ? According the documentation of IDL, the second calling is
correct but
not the first calling.
Thank you

pro one, b
b[0] = 2
end

pro two
a = intarr(1)
a[*] = 1
one, a[*]
print, a
one, a
print, a
end

% Compiled module: ONE.
% Compiled module: TWO.
IDL> two
1
2

------------------------------------------------------------ ----------------
Daniel Sage
EPFL - Swiss Federal Institute of Technology - http://www.epfl.ch
BIG - Biomedical Imaging Group - http://bigwww.epfl.ch

Address: EPFL, DMT/IOA, BM, CH-1015 Lausanne, Switzerland
Tel: +41 21 693 5189
Fax: +41 21 693 3701
Email: daniel.sage@epfl.ch
------------------------------------------------------------ ----------------
[Message index]
 
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: Re: regular expressions
Next Topic: Re: Making MPEG Movies

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

Current Time: Fri Oct 10 14:10:23 PDT 2025

Total time taken to generate the page: 1.43912 seconds