From ba1b279a40c6b491ccd352bf22b888ae7dfbad97 Mon Sep 17 00:00:00 2001 From: Camil Staps Date: Mon, 6 Jan 2020 16:27:27 +0100 Subject: Expose Inotify type itself in callbacks to allow adding/removing watches --- test.icl | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'test.icl') diff --git a/test.icl b/test.icl index 9136510..dedd251 100644 --- a/test.icl +++ b/test.icl @@ -26,12 +26,12 @@ Start w # (inot, w) = inotify_loop_with_timeout (Just 10000) inot w = inotify_close inot where - echo :: String INEvent (Maybe String) () *World -> *((), *World) - echo fname ev f _ w + echo :: String INEvent (Maybe String) *(Inotify ()) *World -> *(*Inotify (), *World) + echo fname ev f st w # (io,w) = stdio w # io = io <<< "EVENT: ["<<< fname <<<"; "<<< ev <<<"; "<<< f <<<"]\n" # (ok,w) = fclose io w - = ((), w) + = (st, w) instance <<< (Maybe a) | <<< a where -- cgit v1.2.3