It took a while to figure out that some haddock
curiosa were no my fault but widespread.
The result is that we are at `pipes-text-0.0.0.5`
but have more or less proper haddocking":
http://hackage.haskell.org/package/pipes-text
On a couple of Gabriel's remarks:
> Also, I would either avoid the
> `stdinLn` and `stdoutLn`
> functions or place a warning in
> the documentation that they are
> not idiomatic because of
> potentially unbounded memory use
> and should be avoided for
> production code with a brief
> reference to `Pipes.Text.lines`
> and `Pipes.Group.Tutorial`.
Yes, I wrote a warning in the
haddocks about how horrible it
would be to pipe an unlined monster
text through an executable defined
with `stdinLn`, saying it's for use
in ghci etc., but hadn't yet drawn
the obvious conclusion and deleted
it, which I have now done. Because
we have a real `Text` chunk and not
a lazy `String`, there is not
really the close similarity to
`Pipes.Prelude` I was going for,
reasonably or unreasonably.
You are lucky I didn't define
something like
interact :: Pipe Text Text IO r -> IO r
named for my favorite Prelude
function -- since it is too
pleasant for the user to do by
hand. (I just need to figure out
the right type of `interactLn` ...)
> One thing I might recommend is to
> take out all the `pipes-safe`
> stuff. My plan is to reserve
> functions similar to `readFile`
> for a `pipes-filesystem` package
> (along with all the original
> `dirstream` stuff I worked on)
> and make that package the primary
> consumer of `pipes-safe`.
Yes I had already formed the plan
of omitting all the `Safe`
material, thinking it should be
outsourced to the general
framework, and that any IO
explicitly defined here is on the
quick script level.
(The docs for the functions in
`Data.Text.IO` basically say the
same -- that one should use
bytestring IO + decoding/encoding
functions instead -- but no one
pays much attention, I think.
`fmap decodeUtf8 . B.readFile` is
*much* faster than `T.readFile`
And anyway, he does provide them.)
The only `safe`-involving terms
that remain are `readFile` and
`writeFile` . Is there some way of
writing these (perhaps as
`naiveReadFile` or whatever) that
will not be terribly objectionable
and suitable for writing simple
scripts? I actually use them so it
would pain me a little, but I
suppose it is just a bad
`System.IO` habit.I still think there
is a place for some rough
`Prelude`-like IO, but maybe in
another module in the style of
`Data.Text.IO`
Anyway thanks, I will work on
improving the documentation and on
testing some of the material I
haven't thought about much.
yours Michael
--
You received this message because you are subscribed to the Google Groups
"Haskell Pipes" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To post to this group, send email to [email protected].