Re: HELP! scope or interpreter problem (I think) with include files
- Posted by jimcbrown (admin) Dec 27, 2010
- 1215 views
I develop on a Linux system using svn3379. Works perfectly. Port to windows vista with a newly loaded version 4.0 I begin to have numerous problems with include files like map.e, prime.e, etc. The error message says that a value internal to the include file has not been initialized. I look at the include code and the variable has clearly been set. Any thoughts as to what I am doing incorredtly> ex.err output.....
C:\euphoria\include\std\primes.e:187 in function next_prime() variable list_of_primes has not been assigned a value n = 30 fail_signal_p = -1 time_out_p = 1 i = <no value> ... called from c:\euphoria\include\std\map.e:385 in function new() initial_size_p = 690 buckets_ = 30 new_map_ = <no value> temp_map_ = <no value>the code from the primes.e file-
namespace primes include std/search.e sequence list_of_primes = {2,3} -- Initial seedings. --****
Any and all help appreciated.
Regards, jd
Only think I can think of is that somehow the order of includes and forward referencing are interacting such that a function in std/primes.e that uses list_of_primes is getting called before the main program code - or the top level code of the include file - is run.
The only dependency that I can see is std/map.e depends on std/primes.e depends on std/search.e
It's not obvious to me what you could be doing to cause that error. In that light, it does seem like a bug in 4.0.0
If you can post a simple test case (one that causes the error, and one that'll work after copy&pasting), that would help greatly to finding the cause.