Skip to content

Namespaces and ⎕SE

Vector 11:4, page 119

implementations development practice

Transcribed from the printed issue; not yet reviewed. Read it in the PDF of the issue, page 119

Concerning the Dyalog session-file, I seem to be adopting a minimalist approach! I don’t use any named session.dse; what I need I will load into a namespace under ⎕SE dynamically from a set of little utility workspaces, that are saved and maintained in a quite traditional manner. The functions in them don’t know a thing about been run in a namespace. (Most of them can be used as well under version 6.3.)

My APL loads in at the start a little workspace consisting only of a ⎕lx that moves the most generally used fns & idiomlike stuff (those ROWFINDs) to ⎕SE to be always available. Among those is a two-line function WS2NS by which I’m able to load dynamically whatever tool-ws to a namespace under ⎕SE or #. This gives me the functionality, keeps my application workspace clean and allows me to get rid of the tool whenever space is needed, or if there is no use for it anymore.

There is nothing very brilliant or clever in this, but to me it seems to work perfectly, and brings me the advantages that I consider most relevant in the namespace-concept.