Definition swap (i: int) : int :=
 Int.or (Int.shl (Int.and i (Int.repr 255)) (Int.repr 24))
   (Int.or (Int.shl (Int.and (Shr 8 i) (Int.repr 255)) (Int.repr 16))
      (Int.or (Int.shl (Int.and (Shr 16 i) (Int.repr 255)) (Int.repr 8))
         (Shr 24 i))).

Lemma intlist_to_bytelist_bytes_to_int_cons: forall a b c d l, intlist_to_bytelist (bytes_to_Int a b c d :: l) = a::b::c::d:: intlist_to_bytelist l.