Record class_of (T : Type) := Class {
   base : Equality.class_of T; 
   mixin : mixin_of (EqType T base)}.Record class_of (T : Type) := Class {
   base : Equality.class_of T; 
   mixin : mixin_of (EqType T base)}.Record class_of (T : Type) := Class {
   base : Equality.class_of T; 
   mixin : mixin_of (EqType T base)}.Record class_of (T : Type) := Class {
   base : Equality.class_of T; 
   mixin : mixin_of (EqType T base)}.Structure type : Type := Pack {sort : Type; _ : class_of sort}.Structure type : Type := Pack {sort : Type; _ : class_of sort}.Structure type : Type := Pack {sort : Type; _ : class_of sort}.Definition class := let: Pack _ c as cT' := cT return class_of cT' in c.Definition clone c of phant_id class c := @Pack T c.(* produce an ordered type out of the inherited mixins *)
(* equalize m0 and m by means of a phantom; will be exploited *)
(* further down in the definition of OrdType *)
Definition pack b (m0 : mixin_of (EqType T b)) := 
  fun m & phant_id m0 m => Pack (@Class T b m).Definition eqType := Eval hnf in EqType cT class.Notation ordType := Ordered.type.Notation OrdMixin := Mixin.Notation OrdType T m := (@pack T _ m _ id).Definition ord T : rel (sort T) := (ordering (mixin (class T))).Notation "[ 'ordType' 'of' T 'for' cT ]" := (@clone T cT _ id)
  (at level 0, format "[ 'ordType'  'of'  T  'for'  cT ]") : form_scope.Notation "[ 'ordType' 'of' T ]" := (@clone T _ _ id)
  (at level 0, format "[ 'ordType'  'of'  T ]") : form_scope.Implicit Types x y : T.

Lemma otrans : transitive (@oleq T).