mirror of
https://github.com/HigherOrderCO/Kind.git
synced 2024-09-11 16:25:54 +03:00
Now, there are two local binders: let x = ... use x = ... The 'let' binder will create a local definition, type-check it, and assign a name to it. When compiled, it will create 'dup' nodes. The 'use' binder is just an alias. It will not bind a new variable, and, when compiled, will create inline copies. Also, for type-checking, it allows creating aliases that are definitionaly equal for the checker.
39 lines
612 B
Plaintext
39 lines
612 B
Plaintext
Kind.skip
|
|
: ∀(x: Kind.Term) Kind.Term
|
|
= λx
|
|
use P = λx Kind.Term
|
|
use all = Kind.all
|
|
use lam = Kind.lam
|
|
use app = Kind.app
|
|
use ann = λval λtyp (Kind.skip val)
|
|
use slf = Kind.slf
|
|
use ins = λval (Kind.skip val)
|
|
use ref = Kind.ref
|
|
use def = λnam λval λbod (Kind.skip (bod val))
|
|
use set = Kind.set
|
|
use u60 = Kind.u60
|
|
use num = Kind.num
|
|
use op2 = Kind.op2
|
|
use mat = Kind.mat
|
|
use txt = Kind.txt
|
|
use hol = Kind.hol
|
|
use var = Kind.var
|
|
(~x
|
|
P
|
|
all
|
|
lam
|
|
app
|
|
ann
|
|
slf
|
|
ins
|
|
ref
|
|
def
|
|
set
|
|
u60
|
|
num
|
|
op2
|
|
mat
|
|
txt
|
|
hol
|
|
var
|
|
) |