Documentation of System.Process
jmg at gaillourdet.net
Tue Nov 30 08:00:40 EST 2010
thanks for the clarification.
Simon Marlow <marlowsd at gmail.com> writes:
> On 26/11/2010 10:00, Jean-Marie Gaillourdet wrote:
>> Hi all,
>> I've been searching information regarding file handles to pipes created by System.Process.createProcess. The documentation does not state whether they are in binary mode, i.e. whether they have line ending conversion or an encoding enabled. That kind of information is available for runInteractiveCommand in the same module. runInteractiveCommand opens all pipes in binary mode. I've concluded from the source of that module that the same is probably true for createProcess. I've two questions now:
>> 1. Is it correct that createProcess returns file handles in binary mode when creating pipes?
> No, in fact the Handles use localeEncoding and nativeNewlineMode by
> default. You can use hSetBinaryMode if you want no encoding or
> newline translation.
>> 2. Could you add that information to the haddock docs?
>> Is their some other place where I could have found this?
> The source :-)
More information about the Glasgow-haskell-users