let rec tic () =
let () = print_endline "tic" in
let* () = Lwt_unix.sleep 1.0 in
tic ()
let _ = Lwt_main.run tic
I get the following error:
let _ = Lwt_main.run tic
^^^
Error: This expression has type unit -> 'a Lwt.t
but an expression was expected of type 'b Lwt.t
Hint: Did you forget to provide `()' as argument?