]> matita.cs.unibo.it Git - helm.git/blobdiff - helm/software/matita/library/list/list.ma
Initial implementation of statuses using objects in place of nested records.
[helm.git] / helm / software / matita / library / list / list.ma
index e4787fe8422fcf55a0888cc9da3b4d237239ff0c..19866cc2992499df10a53a9c0fba8766458c601f 100644 (file)
@@ -34,9 +34,8 @@ notation "hvbox(l1 break @ l2)"
   right associative with precedence 47
   for @{'append $l1 $l2 }.
 
-interpretation "nil" 'nil = (cic:/matita/list/list/list.ind#xpointer(1/1/1) _).
-interpretation "cons" 'cons hd tl =
-  (cic:/matita/list/list/list.ind#xpointer(1/1/2) _ hd tl).
+interpretation "nil" 'nil = (nil ?).
+interpretation "cons" 'cons hd tl = (cons ? hd tl).
 
 (* theorem test_notation: [O; S O; S (S O)] = O :: S O :: S (S O) :: []. *)
 
@@ -63,7 +62,7 @@ definition tail := \lambda A:Type. \lambda l: list A.
   [ nil => []
   | (cons hd tl) => tl].
 
-interpretation "append" 'append l1 l2 = (cic:/matita/list/list/append.con _ l1 l2).
+interpretation "append" 'append l1 l2 = (append ? l1 l2).
 
 theorem append_nil: \forall A:Type.\forall l:list A.l @ [] = l.
   intros;
@@ -110,8 +109,8 @@ with permut1 : list A -> list A -> Prop \def
   | step : \forall l1,l2:list A. \forall x,y:A. 
       permut1 ? (l1 @ (x :: y :: l2)) (l1 @ (y :: x :: l2)).
 
-include "nat/nat.ma".  
-   
+(*
+
 definition x1 \def S O.
 definition x2 \def S x1.
 definition x3 \def S x2.
@@ -122,15 +121,9 @@ theorem tmp : permutation nat (x1 :: x2 :: x3 :: []) (x1 :: x3 :: x2 :: []).
   apply (step ? (x1::[]) [] x2 x3).
   qed. 
 
-
-(*
 theorem nil_append_nil_both:
   \forall A:Type.\forall l1,l2:list A.
     l1 @ l2 = [] \to l1 = [] \land l2 = [].
-*)
-
-(*
-include "nat/nat.ma".
 
 theorem test_notation: [O; S O; S (S O)] = O :: S O :: S (S O) :: []. 
 reflexivity.
@@ -140,6 +133,7 @@ theorem test_append: [O;O;O;O;O;O] = [O;O;O] @ [O;O] @ [O].
 simplify.
 reflexivity.
 qed.
+
 *)
 
 definition nth ≝