For better or worse, A-Shell uses fixed search paths to locate files to be opened or executed. The ability to define and map logical devices and PPNs on to host operating system directories eliminates most of the benefit of user-customizable search paths, and the fixed paths provide a reasonable compromise between simplicity and flexibility. The specific search path logic depends on the context and type of file (command, program, subroutine, data), as detailed in the sections below.
Command Search Path
The search path for the subroutine referenced by <XCALL name> or <VXCALL expr> is as follows:
| • | dev:name.sbx[p,0] (replace dev: and [p,pn] with current .RUN file location if SBX_RUNDIR set) |
Note that an ALTSBXEXT system parameter directive may be specified to add an additional extension that will act as an alternative to SBX. If defined, the alternate extension will be searched for prior to SBX for each of the separate directories in the search path above. Note also that although it is not possible to specify an extension in the XCALL statement, it is possible with VXCALL, in which case the search would only look for that extension.
See Also
|
The default path for a RUN file, in the context of a RUN command or CHAIN statement, is listed below. It is modified or shortened as appropriate if the filespec contains an explicit device, PPN, and/or extension.
| • | prog.run in user memory (see LOAD) |
| • | current dev:prog.run[p,pn] |
| • | current dev:prog.run[p,0] |
The file extension (ext) is RUN. In addition, an ALTRUNEXT system parameter directive may be specified to add an additional extension that will act as an alternative to RUN. If defined, the alternate extension will be searched for prior to RUN for each of the separate directories in the search path above. However, if the filespec in the RUN or CHAIN statement contains an explicit extension, then the search will be limited to just that extension (and any extension would be allowed).
See Also
|
When opening a data file (see File I/O), A-Shell will search for the file in the following locations:
| • | If the AUTO_MEMOPEN option has been defined, file.ext in user memory. This overrides an explicit dev: and/or PPN in the OPEN statement. |
| • | current dev:file.ext[p,pn] |
| • | current dev:file.ext[p,0] |
The default file extension is DAT, except in the case of ISAM or ISAMA files, where the default extension is IDX and the corresponding data file is opened implicitly from the same directory location.
See Also
|