2014-05-20 18:53:58 +00:00
|
|
|
local env = environment()
|
|
|
|
local f = Local("f", mk_arrow(Bool, Bool, Bool))
|
|
|
|
local a = Local("a", Bool)
|
|
|
|
local b = Local("b", Bool)
|
|
|
|
local x = Local("x", Bool)
|
2014-06-30 16:14:55 +00:00
|
|
|
local t = Fun(f, a, b, f(Fun(x, x)(b), a))
|
2014-05-20 18:53:58 +00:00
|
|
|
print(env:normalize(t))
|
2014-06-30 16:14:55 +00:00
|
|
|
assert(env:normalize(t) == Fun(f, a, b, f(b, a)))
|