[Haskell-beginners] Data.Char: isAlpha vs. isLetter
allbery.b at gmail.com
Tue Sep 11 17:10:52 CEST 2012
On Tue, Sep 11, 2012 at 1:49 AM, Joey Hess <joey at kitenet.net> wrote:
> Brandon Allbery wrote:
> > Probably an alias for backward compatibility; isAlpha is C-style
> > stuff, which was ASCII only, whereas isLetter is Unicode style.
> Prelude Data.Char> all (\c -> isLetter c == isAlpha c) [minBound..maxBound]
> Whew! You had me worried my code had unicode bugs.
I phrased it as "*alias* for backward compatibility" for a reason. It
should be the same thing, but I expect older versions of Haskell used the
older name because it was well established in the pre-Unicode era. (I
couldn't say whether it was ever *native*; Haskell did not evolve in a
vacuum, there are other languages in its background.)
brandon s allbery allbery.b at gmail.com
wandering unix systems administrator (available) (412) 475-9364 vm/sms
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the Beginners