real x, y char ch data x/0/, y/1.0,2.0/, ch/'a','b',EOS/Any data statements must follow all declarations. Note that variables initialized by data are not guaranteed to have that value except the first time the task is executed from the cl. IRAF tasks executed from the cl may be cached or stored in the process cache. That is, they are not restarted from the main procedure except the first time they are executed and after the process cache is flushed (using the cl task flprcache). Therefore, a variable modified in a task procedure will not have the initialized value the next time the task is executed, but will have the modified value. It is always safer to initialize variables with macro symbolic constant define statements or explicit assignment statements.
The string Statement
Character strings may be declared and initialized with the string statement. This consists of the keyword string followed by the identifier name, followed by the initialization value enclosed in double quotes. Not that there is no explicit string size. A char array is implicitly declared the size of the initialization string.
string errmsg "Could not open input"
Generated with CERN WebMaker