let reprintf fmt = Printf.ksprintf (fun str -> try return & (output_string stderr str; flush stderr) with | e -> `Error e) fmt