Notation "{ 'perm' T }" := (perm_of (Phant T))
  (at level 0, format "{ 'perm'  T }") : type_scope.Local Notation fun_of_perm_def := (fun T (u : perm_type T) => val u : T -> T).Local Notation perm_def := (fun T f injf => Perm (@perm_proof T f injf)).Definition fun_of_perm := fun_of_perm_def.Definition perm := perm_def.

Lemma fun_of_permE : fun_of_perm = fun_of_perm_def.