in reply to Library path question

1) The first one Perl finds, iterating from @INC from start to end, so /common/LIBRARIES/common/MyModule.pm

2) Functionally perfect, so the only possible improvement is style. I'd use

use lib "/common/LIBRARIES/common", "/common/LIBRARIES";

But even the following would be better to me:

BEGIN { unshift @INC, "/common/LIBRARIES/common", "/common/LIBRARIES"; }

Replies are listed 'Best First'.
Re^2: Library path question
by Anonymous Monk on Apr 08, 2012 at 03:51 UTC
    Thank you.