(** Absolute value *)

Definition abs (n : int) : int := if (0 <=? n)%sint63 then n else - n.

(* Specifications: *)
Lemma abs_spec (x : int) : to_Z (abs x)%sint63 = cmod (Z.abs (to_Z x)) wB.
Lemma to_Z_abs (x : int) : x <> min_int -> to_Z (abs x) = Z.abs (to_Z x).