2014-09-12 20:17:20 +00:00
|
|
|
inductive obj (A : Type) :=
|
|
|
|
mk : A → obj A
|
|
|
|
|
|
|
|
inductive fn (A B : Type) :=
|
|
|
|
mk : (obj A → obj B) → fn A B
|
|
|
|
|
|
|
|
definition to_fun [coercion] {A B : Type} (f : fn A B) : obj A → obj B :=
|
|
|
|
fn.rec (λf, f) f
|
|
|
|
|
2014-10-02 23:20:52 +00:00
|
|
|
constant n : Type.{1}
|
|
|
|
constant f : fn n n
|
|
|
|
constant a : obj n
|
2014-09-12 20:17:20 +00:00
|
|
|
check (f a)
|