`{Funext} (X Y : Type) {Ys : X -> IsHSet Y} : { f : X -> Y & WeaklyConstant f } <~> (merely X -> Y). Proof. pose proof (Ys' := Trunc_rec Ys : merely X -> IsHSet Y). snrapply equiv_adjointify. - intros [f wc]. exact (merely_rec_hset_if_domain f (wc:=wc)). - intro g. exists (g o tr). intros x y; apply (ap g), path_ishprop. - intros g; apply path_arrow; intros mx. pose proof (Ys' mx). strip_truncations; reflexivity. - intros [f wc]. snrapply path_sigma; cbn. + reflexivity. + cbn. funext x y. pose (Ys x); apply path_ishprop. Defined.
Require Import HoTT.Basics HoTT.Types. Require Import Extensions Factorization. Require Import Truncations.Core Modalities.Modality.