Link Search Menu Expand Document

Primitive values

Conceptually, primitive values are atomic, and not formed from other values: each primitive value corresponds to a constant constructor. For large (or infinite) types of primitive values, however, it is infeasible to declare a separate constant for each value. So in practice, funcons used to construct primitive values usually take other values as arguments. For example, a funcon for constructing a character value takes the integer corresponding to its point in a Unicode plane as argument; and a funcon for constructing an integer value takes its representation in decimal notation as a string argument.

The CBS library includes types of primitive values corresponding to the following concepts:

the usual Boolean truth-values
unbounded integer arithmetic, together with subtypes of bounded integers
IEEE floating point arithmetic
Unicode, its various subtypes, and its encodings as byte sequences
a singleton type

Table of contents