patch applied (packages/HaXml): Use ByteString for output (contributed by Jason Dagit, with modifications)

Malcolm Wallace Malcolm.Wallace at cs.york.ac.uk
Tue Nov 14 12:49:31 EST 2006


[moved from cvs-libraries to reach a wider audience]
Ian Lynagh <igloo at earth.li> wrote:

> On Mon, Nov 13, 2006 at 10:46:14AM -0800, Malcolm Wallace wrote:
> >   * Use ByteString for output (contributed by Jason Dagit, with
> >   modifications) There are some new signatures in
> >   Text.XML.HaXml.XmlContent:
> >       fpsShowXml
> >       fpsWriteXml
> >       fpsHPutXml
> 
> I think bs* would make more sense than fps*,

OK, I can see your reasoning.  Are there any other good suggestions out
there?

Normally, Data.ByteString users tend to put their operations in a
separate module altogether, with the same function names as the normal
String-based ops.  Then it is easy to distinguish them by simple module
import/qualification.  In fact, that is how Jason originally implemented
it - but I was unhappy about the huge amount of code duplication
involved, which is why I choose a different route.  I am open to further
ideas about how to best achieve a similar effect (i.e. ByteString ops
available, but minimal code duplication).

Regards,
    Malcolm


More information about the Libraries mailing list