https://github.com/math-comp/analysis/blob/9c311a9344f3af02fbb12101b24482846d64e8ea/theories/constructive_ereal.v#L3163