src/HOL/Lazy_Sequence.thy
changeset 58152 6fe60a9a5bad
parent 56846 9df717fef2bb
child 58310 91ea607a34d8
     1.1 --- a/src/HOL/Lazy_Sequence.thy	Wed Sep 03 00:06:23 2014 +0200
     1.2 +++ b/src/HOL/Lazy_Sequence.thy	Wed Sep 03 00:06:24 2014 +0200
     1.3 @@ -9,7 +9,7 @@
     1.4  
     1.5  subsection {* Type of lazy sequences *}
     1.6  
     1.7 -datatype 'a lazy_sequence = lazy_sequence_of_list "'a list"
     1.8 +datatype_new (dead 'a) lazy_sequence = lazy_sequence_of_list "'a list"
     1.9  
    1.10  primrec list_of_lazy_sequence :: "'a lazy_sequence \<Rightarrow> 'a list"
    1.11  where
    1.12 @@ -29,7 +29,7 @@
    1.13  
    1.14  lemma size_lazy_sequence_eq [code]:
    1.15    "size_lazy_sequence f xq = Suc (size_list f (list_of_lazy_sequence xq))"
    1.16 -  "size (xq :: 'a lazy_sequence) = 0"
    1.17 +  "size xq = Suc (length (list_of_lazy_sequence xq))"
    1.18    by (cases xq, simp)+
    1.19  
    1.20  lemma case_lazy_sequence [simp]: