6 ms·
That's not all. This code: foo = do result <- do_first_thing do_second_thing result Kinda sorta roughly desugars into something like this
by implicit 13y ago
That's not all. This code:
foo = do
result <- do_first_thing
do_second_thing result
Kinda sorta roughly desugars into something like this:
function foo(cb) { do_first_thing(function(result) { do_second_thing(result, cb); }); }
Synchronous and asynchronous Haskell APIs can have the exact same interface.