Then it seems strange why "inherit Parent;" doesn't work when Parent.pike is in the same directory where compiled file is... I tried -P. and -M. - it doesn't work, so I use "import .;" instead...
-P. is NOT the same as import ".". -P is relative to cwd, while import "." is relative to the current file.
BTW, do I understand it correctly - i.e., I can specify any directory name for import, so it will be used like -M & -P flags?
Yes.
Regards, /Al
/ Henrik Grubbström (Lysator)
Previous text:
2004-02-02 14:38: Subject: Re: Pike module initialization at compile time
On Mon, Feb 02, 2004 at 01:55:07PM +0100, Henrik Grubbström (Lysator) @ Pike (-) developers forum wrote:
The default implementation of handle_inherit() uses cast_to_program(), which in turn searches the directory the current file is in, and then the program path as specified by ${PIKE_PROGRAM_PATH} and -P.
Then it seems strange why "inherit Parent;" doesn't work when Parent.pike is in the same directory where compiled file is... I tried -P. and -M. - it doesn't work, so I use "import .;" instead...
BTW, do I understand it correctly - i.e., I can specify any directory name for import, so it will be used like -M & -P flags?
Regards, /Al
/ Brevbäraren