1 /* Demo of argument passing by Key words, in this way
2 arbitrary arguments and default options may
3 be specified. The names of arguments and the default values
4 are available for inspection by the user as the TRANSLATE_KEYARG
5 property of the function.
8 if get('sharem,'version)=false then loadfile(autolo,fasl,dsk,sharem)$
10 def_keyarg(bar(foop,maxi=33,time=4.4),
11 ['foop=foop,'maxi=maxi,'time=time])$
13 /* In the argument specification VARIABLE = DEFAULT_VALUE
14 indicates a variable which can be specified in a call to the
15 function by VARIABLE = USERS_VALUE.
16 An atom is the same thing as VARIABLE = FALSE.
18 When the call to the function is parsed an atom indicator is the
19 same thing as VARIABLE=TRUE.
23 bar(maxi=100000,foop);
27 /* misspell an argument on purpose: */
29 errcatch(bar(maxi=10,timem=33));