I guess I should define the terms first:
- small letters denote variable name, capital letters denote terms (exceptions below).
-
denotes a type name. -
denotes the set of all variable names. -
denotes the set of all function names. -
denotes the set of all constants. - term definition:
- if
then is a term. - if
, and and are terms, then so is .
- if
- the functions have type signature
. -
denotes any type i.e., type names as well as function types. -
means that is of type . -
denotes a set of axioms (defined using the axiom
keyword). -
denotes a set of type assignments (defined using the type
keyword). - in
, denotes a pattern/replacement pair, where is a variable, while is a term. - the substitution algorithm
is defined as follows: -
. -
. -
. -
.
-
The heart of nnoq is a single operator, :=
, which is governed by the following axioms:
1.
2.
3.
4.
5.
the following five axioms are for the type analysis (inference and checking):
6.
7. :=
#1)
8. :=
#2)
9.
10.
nnoq builds on top of this foundation by generalizing the functions to arbitrary arity. however, this does not increase its power, as an n-arity function