octave-maintainers
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [pkg.m] Load order of dependencies


From: PhilipNienhuis
Subject: Re: [pkg.m] Load order of dependencies
Date: Thu, 12 Dec 2019 15:17:55 -0600 (CST)

JuanPi wrote
> Hi all,
> 
> Is there any reason to make pkg.m load first the package and then the
> dependencies?
> 
> Taking the development version of geometry as an example:
> 
>> pkg load geometry
> GEOMETRY
> matgeom loaded 0
> MATGEOM
> geometry loaded 1
> 
> For me it would make only sense that at the time the package folder is
> added to the path the dependencies are already loaded.

I looked a little more into it and found something I didn't know or realize:

>> addpath ("a", "b")
>> path
Octave's search path contains the following directories:

.
"a"
"b"
:
<rest of path>

so addpath() loads packages in its argument list from right to left; IMO
contrary to at least my expectations. Anyway this isn't documented in "help
addpath".

Maybe this behavior was different in the past when pkg.m was written?

Philip




--
Sent from: https://octave.1599824.n4.nabble.com/Octave-Maintainers-f1638794.html



reply via email to

[Prev in Thread] Current Thread [Next in Thread]