String != [Char]

Johan Tibell johan.tibell at
Mon Mar 26 17:50:51 CEST 2012

On Mon, Mar 26, 2012 at 8:34 AM, Malcolm Wallace <malcolm.wallace at> wrote:
> Yes indeed.  And I think it would be perfectly reasonable for the String (= [Char]) API to have a function "normalise :: String -> String" which would let the user deal with this issue as they see fit.  After all, if you are aware of the difference between combining characters and normalised characters, then you will want to make your own decision about what semantics you want from operations like "take".

Normalization isn't quite enough unfortunately, as it does solve e.g.

    upcase = map toUppper

You need all-at-once functions on strings (which we could add.) I'm
just pointing out that most (all?) list functions do the wrong thing
when used on Strings.

More information about the Haskell-prime mailing list