Re: include (variable with path/file) ?

new topic     » goto parent     » topic index » view thread      » older message » newer message

On Thu, 14 Sep 2000, Dan B Moyer wrote:

> David,
>
> But when I run it I get an error:
>
> C:\Fuphoria\Win32Lib\Versions\v50\DirName.e:1
> C has not been declared
> C:\Fuphoria\Win32Lib\Versions\v50\Win32Lib.ew
>
> yet if I write:
>
> include C:\Fuphoria\Win32Lib\Versions\v50\Win32Lib.ew
>
> it works just fine.  What's happening?
>
> Dan
>
It's just like including a normal file. It won't take the text from the
included file and put it directly into your file. Instead, the include
file is parsed just as any other include file and it must conform to
Euphoria syntax. So given: include dynamic.e

Euphoria reads it like this:
C:\Fuphoria\Win32Lib\Versions\v50\Win32Lib.ew

instead of:
include C:\Fuphoria...

Of course, the interpreter has to use a seperate namespace for the local
identifiers etc., but that's basically how it's seen. Your entire include
statement is replaced, not just the file name.
 --
jeff

new topic     » goto parent     » topic index » view thread      » older message » newer message

Search



Quick Links

User menu

Not signed in.

Misc Menu