[MLton-commit] r5279
Vesa Karvonen
vesak at mlton.org
Tue Feb 20 11:06:13 PST 2007
More implementation.
----------------------------------------------------------------------
U mltonlib/trunk/com/ssh/windows/unstable/detail/windows.sml
----------------------------------------------------------------------
Modified: mltonlib/trunk/com/ssh/windows/unstable/detail/windows.sml
===================================================================
--- mltonlib/trunk/com/ssh/windows/unstable/detail/windows.sml 2007-02-20 18:37:04 UTC (rev 5278)
+++ mltonlib/trunk/com/ssh/windows/unstable/detail/windows.sml 2007-02-20 19:06:12 UTC (rev 5279)
@@ -28,6 +28,7 @@
val int = int
val dbl = real
val sw = word64
+ val bool = bool
end
val op >>& = With.>>&
@@ -450,8 +451,17 @@
end
type t = C.voidptr
- val first = undefined
- val next = undefined
+ fun first (n, b, f) =
+ (withZs n)
+ (fn n' =>
+ raiseLastErrorOnNull
+ (fn () => F"FileChange.first"[A str n, A bool b, A sw f])
+ F_win_FindFirstChangeNotification.f'
+ (n', if b then 1 else 0, SysWord.toWord f))
+ fun next h =
+ raiseLastErrorOnFalse
+ (fn () => F"FileChange.next"[A ptr h])
+ F_win_FindNextChangeNotification.f' h
val close = ignore o F_win_FindCloseChangeNotification.f'
val toWait = id
end
More information about the MLton-commit
mailing list