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

Home » Public Forums » archive » Re: Compile Problem with IDL5.2
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
Re: Compile Problem with IDL5.2 [message #16328] Wed, 21 July 1999 00:00
davidf is currently offline  davidf
Messages: 2866
Registered: September 1996
Senior Member
Joerg Mosthaf (joerg.mosthaf@urz.uni-heidelberg.de) writes:

> I got a little problem with compiling programms in IDL5.2. Usually everything
> works just fine, but sometimes (about 1 in 5) some procedure or function just
> doesn't compile and I get an "undefined variablename"-error with the name of
> the procedure as undefined variablename. If I compile the programm again after
> the error, it usually runs fine.
> All my procedures are in one file and the main procedure is the last one.

This is a classic symptom of a function being called
before it is compiled, so I am dubious about your statement
that all the procedures and functions are in a single file,
with the main procedure as the last one.

I presume you know that any procedure or function in front
of the last module should be utility routines for the last
module? That is to say, one way this could be happening
(the "1 in 5" strongly suggests it) is that you have
a function in the "main" file that you are calling from
within some other program. If that function gets called
before the main program is called, then you will get
this error.

If this is the case, then you want to take that
function module out and put it in its own file. That
way both programs will be able to use it without
running into this problem.

Cheers,

David
--
David Fanning, Ph.D.
Fanning Software Consulting
Phone: 970-221-0438 E-Mail: davidf@dfanning.com
Coyote's Guide to IDL Programming: http://www.dfanning.com/
Toll-Free IDL Book Orders: 1-888-461-0155
  Switch to threaded view of this topic Create a new topic Submit Reply
Previous Topic: Histogram Hot-shots Required
Next Topic: Re: Missing red color

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

Current Time: Wed Oct 08 15:47:57 PDT 2025

Total time taken to generate the page: 0.00326 seconds