Make lines stricter to fix a space leak

Christian Maeder Christian.Maeder at
Mon Sep 27 04:54:56 EDT 2010

Am 24.09.2010 21:21, schrieb Daniel Fischer:
> Proposal: A stricter implementation of lines.
> Reason: The current implementation causes a space leak (cf. 
>, at least in GHC.
> The proposed implementation fixes the leak at the small cost of being 
> stricter if the first _|_ in the String is the first character of a line.
> Discussion period: Three weeks, until 15th October (because of ICFP).
> Ticket:

You make interesting proposals. Changing a let to a case!

I wonder if a generic version costs performance?

 lines = breaksBy (== "\n")
  (or "linesBy" or "splitBy")

Cheers Christian

> Cheers,
> Daniel

More information about the Libraries mailing list