Re: recursive functions? [message #21624 is a reply to message #21526] |
Thu, 31 August 2000 09:08  |
Nando Iavarone
Messages: 48 Registered: December 1998
|
Member |
|
|
<!doctype html public "-//w3c//dtd html 4.0 transitional//en">
<html>
Nando Iavarone wrote:
<blockquote TYPE=CITE>ENVI> .compile recFun
<br>% Compiled module: RECFUN.
<br>% Compiled module: RECFUNTEST.
<br>ENVI> err=recFunTest(12,15)
<br> 12.Prrrr
15.Prrrr
<br>% Variable is undefined: RECFUN.
<br>% Execution halted at: RECFUN & ;nbsp; & ;nbsp;
5
<br> /home/nando/InPhase/procedureDiProva/recFun.pro
<br> %   ;   ;   ;
RECFUNTEST 19
<br> /home/nando/InPhase/procedureDiProva/recFun.pro
<br> %   ;   ;   ;
$MAIN$
<br>ENVI>
<br>
<br>
<br> </blockquote>
it seems that the first time IDL 'compile' recFun function,
<br>it consider recFun (in the code it is a function) a variable and on
run it does not find it.
<br>if I recompile the source, recFun is now in the table of the functions
and it works.
<br>as a workaround I compile the source twice and it works, but I don't
like this.
<br>I am sure there is something I have not considered.
<p>I don't remember well, but 5.3 would have a mechanism in compiling to
avoid this.
<br>Is it true?
<br>Oh oh........ but I am working with 5.2 (to use ENVI 3.2).
<p>Bye.
<br>
<pre>--
Nando Iavarone
Advanced Computer System - SPACE DIVISION
via Lazzaro Belli, 23
00040 Frascati - RM
Tel: +39-6-944091 (switchboard)
9440968 (direct)
E-mail:
f.iavarone@acsys.it
FrdndVrn@altavista.net</pre>
</html>
|
|
|