1(** Internal utilities for crypto-pk. *)23valuntil:('a->bool)->(unit->'a)->'a4(** [until p f] repeatedly calls [f ()] until [p] holds on the result. *)56valguard:bool->'a->(unit,'a)result7(** [guard p err] is [Ok ()] if [p] is true, [Error err] otherwise. *)