Module ArithConv.
(** This is the ISO C algebra of arithmetic types, without qualifiers. [S] stands for "signed" and [U] for "unsigned".  *)
Inductive int_type : Type :=
| _Bool
| Char | SChar | UChar
| Short | UShort
| Int | UInt
| Long | ULong
| Longlong | ULonglong.
Inductive arith_type : Type :=
| I (it: int_type)
| Float
| Double
| Longdouble.
Definition eq_int_type: forall (x y: int_type), {x=y} + {x<>y}.
(** Relation between [classify_binarith] and arithmetic conversion. *)

Lemma classify_binarith_arithmetic_conversion:
forall t1 t2,
binarith_type (classify_binarith (proj_type t1) (proj_type t2)) =
proj_type (usual_arithmetic_conversion t1 t2).