Re: use lib and locations in a variable

2021-07-13 Thread Joseph Brenner
Elizabeth Mattijsen wrote: >> Joseph Brenner wrote: >> I find that while this works: >> >>use lib $*PROGRAM.parent.add('../lib'); >> >> This doesn't work: >> >>my $lib_loc = $*PROGRAM.parent.add('../lib'); >>use lib "$lib_loc"; >> >> I get a compile time error >> >>Use of unini

Re: use lib and locations in a variable

2021-07-13 Thread Elizabeth Mattijsen
> On 13 Jul 2021, at 19:07, Joseph Brenner wrote: > Bruce Gray points out "constant" works also: > > constant $lib_loc = $*PROGRAM.parent.add('../lib'); Yup. constant $foo = 42; is basically short for: BEGIN my $foo := 42