Modified July 2017
Deprecated. See Comments below.
xcall MIAMEX, MX_XCBINFOX, xcbadr, xcbcnt, xcbstructx
coMX_XCBINFO (MIAMEX 80) is needed at the start of an subroutine to retrieve information about the parameters which were passed to the subroutine. Because every subroutine needs this information, the xcall.bsi file which is included by every subroutine includes a call to this function.
Parameters
xcbadr ()
must be set to the address of the parameter structure. This value is passed on the command line to the routine.
xcbcnt ()
returns the number of parameters passed.
xcbstructx
is a structure containing information about the parameters, mapped as follows:
MAP1 XCBSTRUCTX
MAP2 XCBSTRUCT(20) ! up to 20 parameters
MAP3 XCB'PTYPE,b,2 ! 0=X, 2=S, 4=F, 6=B, +8=I, +16=array
MAP3 XCB'PSIZE,b,2 ! size of parameter
Comments
This function is still supported but has been deprecated since the introduction of the .ARGCNT dot variables and the .ARGTYP and .ARGSIZ dot functions which are more elegant and preferred. See History.
Refer to Writing SBX Subroutines for more information on this and related MIAMEX functions.
History
2017 July, A-Shell 6.4.1553: XCB'PTYPE() is now stripped to just the low 5 bits (4 bit type code and 1 bit array flag) to avoid confusion with values that were not defined when this function was implemented. See .ARGTYP and .ARGSIZ for the latest complete set of argument type flags.
2014 January, A-Shell 6.1.1373.0: .ARGTYP and .ARGSIZ dot functions; MX_XCBINFO now deprecated.
|