[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

forcing variable definition in IDL?



I have seen some threads on Google about the lack of 'implicit none'
Fortran type statement in IDL. However, those threads are, a) short,
b) date from 1995. I have not seen anything later than this.

So, my question: is it possible in IDL 5.4 to force definition of
variables, or at least to automate a variable-check in IDL.

Alternatively, maybe I need to write a function that automatically
checks the first use of a variable in a program. I have used the
routine_info and routine_names functions to obtain information 
about variables in scope at the time.

Does anyone know of either how to get IDL to check variables'
definition,
or how to write a function to do that?

I have also toyed with the idea of using each variable as a single-
element array (eg. b(0) = 1), but that is most inelegant and lengthy.

Best regards,
 Gernot Hassenpflug
PS email address in header includes SPAM TRAP. please note.
-- 
Gernot Hassenpflug, MSc. (Eng.)
+81 (0)75 213-1321 (H) Tel/Fax
+81 (0)774 38-3868 (W) Tel
gernot@kurasc.kyoto-u.ac.jp
Radio Atmospheric Science Centre, Kyoto University
京都