[Haskell-cafe] Replacing stdin from within Haskell
hesselink at gmail.com
Thu Jun 9 15:11:13 CEST 2011
On Thu, Jun 9, 2011 at 13:40, Neil Davies <semanticphilosopher at gmail.com> wrote:
> Anyone out there got an elegant solution to being able to fork a haskell thread and replace its 'stdin' ?
If you don't mind being tied to GHC you can use hDuplicateTo from
GHC.IO.Handle . You can also use dupTo from the unix package ,
but that ties you to unix-like platforms instead.
More information about the Haskell-Cafe