X-Git-Url: http://matita.cs.unibo.it/gitweb/?p=helm.git;a=blobdiff_plain;f=matita%2Ftests%2Fcoercions_dependent.ma;fp=matita%2Ftests%2Fcoercions_dependent.ma;h=3b6602bbb30c2a5dbaab74d9bdf91e2ae4d8c319;hp=0000000000000000000000000000000000000000;hb=f61af501fb4608cc4fb062a0864c774e677f0d76;hpb=58ae1809c352e71e7b5530dc41e2bfc834e1aef1 diff --git a/matita/tests/coercions_dependent.ma b/matita/tests/coercions_dependent.ma new file mode 100644 index 000000000..3b6602bbb --- /dev/null +++ b/matita/tests/coercions_dependent.ma @@ -0,0 +1,33 @@ +(**************************************************************************) +(* ___ *) +(* ||M|| *) +(* ||A|| A project by Andrea Asperti *) +(* ||T|| *) +(* ||I|| Developers: *) +(* ||T|| The HELM team. *) +(* ||A|| http://helm.cs.unibo.it *) +(* \ / *) +(* \ / This file is distributed under the terms of the *) +(* v GNU General Public License Version 2 *) +(* *) +(**************************************************************************) + + + +include "nat/nat.ma". +include "list/list.ma". +include "decidable_kit/list_aux.ma". +(* tests from "Dependent Coersion" by Luo and Soloviev *) + +inductive vec (A : Type) : nat -> Type := + | vnil : vec A O + | vcons : ∀a:A.∀n:nat.vec A n -> vec A (S n). + +axiom c : ∀A,B.∀l:list A.vec B (length A l). + +axiom veclen : ∀A,n.vec A n -> nat. + +coercion cic:/matita/tests/coercions_dependent/c.con. + +alias num (instance 0) = "natural number". +definition xxx := veclen nat ? [3; 4; 7].