src/HOL/Library/IArray.thy
changeset 58266 d4c06c99a4dc
parent 58249 180f1b3508ed
child 58269 ad644790cbbb
equal deleted inserted replaced
58265:cae4f3d14b05 58266:d4c06c99a4dc
    53 | constant IArray \<rightharpoonup> (SML) "Vector.fromList"
    53 | constant IArray \<rightharpoonup> (SML) "Vector.fromList"
    54 | constant IArray.all \<rightharpoonup> (SML) "Vector.all"
    54 | constant IArray.all \<rightharpoonup> (SML) "Vector.all"
    55 | constant IArray.exists \<rightharpoonup> (SML) "Vector.exists"
    55 | constant IArray.exists \<rightharpoonup> (SML) "Vector.exists"
    56 
    56 
    57 lemma [code]:
    57 lemma [code]:
    58 "size (as :: 'a iarray) = 0"
    58 "size (as :: 'a iarray) = Suc (length (IArray.list_of as))"
    59 by (cases as) simp
    59 by (cases as) simp
    60 
    60 
    61 lemma [code]:
    61 lemma [code]:
    62 "size_iarray f as = Suc (size_list f (IArray.list_of as))"
    62 "size_iarray f as = Suc (size_list f (IArray.list_of as))"
    63 by (cases as) simp
    63 by (cases as) simp
   114 
   114 
   115 code_printing
   115 code_printing
   116   constant IArray.length' \<rightharpoonup> (SML) "Vector.length"
   116   constant IArray.length' \<rightharpoonup> (SML) "Vector.length"
   117 
   117 
   118 end
   118 end
   119