@head
@module std
@title About primitive types
Alore has a fixed set of primitive types: @ref{Int}, @ref{Str},
@ref{Float}, @ref{Boolean}, @ref{Constant}, @ref{Function}, @ref{Type},
@ref{Tuple}, @ref{Pair} and @ref{Range}. Primitive types share these common
properties:
- They are defined in the @ref{std} module.
- Other types cannot inherit from primitive types.
- Their instances are immutable.
- Their instances support comparison for equality and hash value
calculation with @ref{std::Hash}.
- All primitive type constructors that accept arguments accept also
objects of their own type to construct identical copies of them, so that
Int(5) and Str("foo") are valid, for example.
Additionally, most primitive types have special syntax associated with
creating instances of them.