String != [Char]

Ian Lynagh igloo at earth.li
Sat Mar 24 23:15:21 CET 2012


On Sat, Mar 24, 2012 at 08:38:23PM +0000, Thomas Schilling wrote:
> On 24 March 2012 20:16, Ian Lynagh <igloo at earth.li> wrote:
> >
> >> Correctness
> >> ==========
> >>
> >> Using list-based operations on Strings are almost always wrong
> >
> > Data.Text seems to think that many of them are worth reimplementing for
> > Text. It looks like someone's systematically gone through Data.List.
> 
> That's exactly what happened as part of the platform inclusion
> process.  In fact, there was quite a bit of bike shedding whether the
> Text API should be compatible with the list API or not.  In the end
> the decision was made to add all the list functions even if that
> encouraged running into unicode issues.  I'm pretty sure you
> participated in that discussion.

As far as I remember, a few functions were added to text and bytestring
during that, but mostly the discussion was about naming.

Even in the first 0.1 release of bytestring:
  http://hackage.haskell.org/packages/archive/text/0.1/doc/html/Data-Text.html
there is a large amount of Data.List covered, e.g. map, transpose,
foldl1', minimum, mapAccumR, groupBy.


Thanks
Ian




More information about the Haskell-prime mailing list