Skip to content

Instantly share code, notes, and snippets.

@exarkun
Created May 2, 2018 14:08
Show Gist options
  • Save exarkun/417d5b7c5c726d24aec6e06d65bd147a to your computer and use it in GitHub Desktop.
Save exarkun/417d5b7c5c726d24aec6e06d65bd147a to your computer and use it in GitHub Desktop.
Lwt_io.write_line Lwt_io.stdout "Stepping\n" >>= fun () ->
Lwt.choose
[Tezos_p2p.P2p_socket.read socket_t >>=? fun _ -> ();
Lwt_unix.sleep 0.01 >>= fun _ -> return ();
] >>=? fun () ->
Lwt_io.write_line Lwt_io.stdout "Stepped\n" >>= fun () ->
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment