[Haskell-cafe] Hoogle

Neil Mitchell ndmitchell at gmail.com
Wed Apr 16 14:47:46 EDT 2008


>       I tried d to use Hoogle to find openFd's signature and more
> importantly FileMode.

Hoogle does not search the Posix library, because in general people
should steer clear of it - otherwise I won't be able to run your
programs :-) - The next version of Hoogle will permit selecting to
search the Posix library, if you so choose.

> I found FileMode which is  a type synonym with CMode.
> I don't understand what are the "values" for FileMode (so I can call
> openFd). ??

Clearly, the documentation is rather weak. It comes from the Posix
"open" function, which is document all over the place, and you can see
the code here: http://darcs.haskell.org/ghc-6.6/packages/unix/System/Posix/IO.hsc

After figuring out what you want, I recommend submitting a patch for
documentation. Additionally, if what you want can be done in a cross
platform way, but lacks the appropriate abstraction layer, I would add
a request for this to be fixed.



More information about the Haskell-Cafe mailing list