useOne statement loads a library into the current interpreter; dotted paths resolve under the SPL library roots (see interpreter).
.spl)
Parsed and executed in the same
global scope as the host program (unless you structure code into
functions). Chains with other statements. For a given
use a.b.spl;, the interpreter looks for
a.b.spl in the same
directory as the SPL file that contains the use
first, then under someProgrammingLanguage/lib/.
Inside classDefine,
inherit path.spl; uses the same path
rules to load a parent class from another
.spl file — see
Classes & OOP.
.py)
Loaded via importlib. The
module should expose spl_register(interpreter)
to add callables into interpreter.library
namespaces.
Compiled to a shared object; must export
spl_register per the bundled
native header. Used for performance or OS glue.
.java libraries integrate via
the host bridge (see lib/SPLHost.java).
Libraries can opt in (e.g. Python
reqFileExtension = False) so
use foo resolves a single file.
If ambiguous, the interpreter asks for an explicit extension.