runProcess/ createPipe

George Russell
Fri, 02 Mar 2001 22:29:01 +0100

If Posix.runProcess really is supposed "our candidate for the high-level OS-independent
primitive" (see documentation), it would help if there was a documented way of using it
with pipes.  The problem is that runProcess takes handles as arguments, while the obvious
function, createPipe, returns two Fds.  There seems to be no _documented_ way of
converting an Fd to a Handle.  I suggest therefore that either there be a
   createPipeHandle :: IO (Handle,Handle)
(which would be nice, because it might avoid bothering the operating system completely, and
would makes sense on non-Posix systems).  Or else, the existing Posix.fdToHandle
   fdToHandle :: Fd -> IO Handle
should be documented.