The primitive names and associated values described below are provided by the Vesta SDL interpreter in C-initial, the initial context. Most of these values are closures with empty contexts; that is, they are primitive functions.
In the descriptions that follow, the notation used for the function signatures follows C++, with the result type preceding the function name and each argument type preceding the corresponding argument name. Defaulting conventions also follow C++; if an argument name is followed by ``= value'', then omitting the corresponding actual argument is equivalent to supplying value.
Some of the function signatures use the C++ operator definition syntax, which should be understood as defining a function whose name is not an Id in the sense of the grammar above. Such operator names cannot be rebound. These operators are typically overloaded, as the descriptions below indicate. Uses of these built-in Vesta primitives within C++ code are denoted by the operator syntax.
The pseudo-code of this section assumes the definition of the Vesta value class given at the start of Section A.3.3. Invocation of a Vesta operator primitive within the pseudo-code is denoted by the operator syntax. All other operators appearing in the pseudo-code denote the C++ operators.
In these descriptions, the argument types represent the natural domain; the result type is the natural range. If a primitive function is passed a value that lies outside its natural domain, evaluation halts with a runtime error. This type-checking occurs when the primitive function is called, not before.