|• Entry format:|
|• Names and namespaces:|
In this manual, each entry is represented like this:
[spec] Description of foo …
Category denotes the category of the entry foo. The following categories will appear in this manual:
|Function||A Scheme function.|
|Special Form||A special form (in the R7RS term, “syntax”).|
|Generic Function||A generic function|
|Reader Syntax||A lexical syntax that is interpreted by the reader.|
|Parameter||A parameter, which is a procedure that follows a certain protocol and used to manipulate the dynamic environment. See Parameters, for the details.|
|Generic application||In Gauche, you can “apply” a non-procedure object to arguments as if it is a procedure (see Applicable objects, for the details). This entry explains the behavior of an object applied to arguments.|
For functions, special forms and macros, the entry may be followed by one or more arguments. In the argument list, the following notations may appear:
Indicates zero or more arguments.
:optional x y z
:optional (x x-default) (y y-default) z
Indicates it may take up to three optional arguments. The second form specifies default values to x and y. This is Gauche’s enhancement to Scheme; see Making Procedures for the definition of complete argument list syntax.
:key x y z
:key (x x-default) (y y-default) z
Indicates it may take keyword arguments x, y and z. The second form shows the default values for x and y. This is also Gauche’s enhancement to Scheme; see Making Procedures for the definition of complete argument list syntax.
Indicates it may take rest arguments. This is also Gauche’s enhancement to Scheme; see Making Procedures for the definition of complete argument list syntax.
The description of the entry follows the entry line. If the specification of the entry comes from some standard, its origin is noted in the bracket at the beginning of the description. The following origins are noted:
The entry works as specified in R7RS, R6RS or R5RS, respectively. If a plus sign is appended such as "[R7RS+]", the entry has extended functionality.
Since R7RS is mostly upward-compatible to R5RS, and has a lot in common with R6RS, we mark an entry as R5RS or R6RS only if it is not a part of R7RS.
The entry works as specified in SRFI-n. If it is marked as "[SRFI-n+]", the entry has additional functionality.
The API of the entry reflects the API specified in POSIX.
Since R6RS, you can split toplevel definitions of Scheme programs into multiple namespaces. In the standards such namespaces are called libraries. Gauche predates R6RS and has been calling them modules, and we use the latter throughout this manual.
(Note: RnRS libraries are more abstract concept than Gauche’s modules; RnRS defines libraries in a way that they can be implemented in various ways, and it just happens that Gauche realises the library semantics using modules. When you write a portable R7RS library, be aware not to rely on Gauche-specific module semantics. Especially, RnRS libraries are more static than Gauche modules; you cannot add definitions to exiting libraries within RnRS, for example.)
Sometimes the same name is used for multiple definitions in
different modules. If we need to distinguish those names,
we prefix the name with the module name and a hash sign.
gauche module. This does not mean
you can write
gauche#lambda in the source code,
though: This notation is just for explanation.