H98: unicode

Marcin 'Qrczak' Kowalczyk qrczak@knm.org.pl
31 Aug 2001 20:49:20 GMT


Fri, 31 Aug 2001 11:54:29 +0100, Ross Paterson <ross@soi.city.ac.uk> pisze:

>    uniDigit   -> any Unicode decimal digit
> 
> One could mix digits from different languages, but the meaning would
> be clear (the Unicode tables include the digit value).  An alternative
> would be to drop uniDigit; octal or hexadecimal numerals are already
> limited to ASCII.

Some people on linux-utf8 list were *strongly* in favor of not limiting
digits to ASCII (in the context of Char.isDigit and Char.digitToInt).
Especially as it seems that all characters marked as decimal digits are
used in the same way and order as European digits for forming numbers.

Unfortunately a predicate for ASCII digits is needed when the syntax
we are going to recognize is specified as using only ASCII digits.
One can always write c >= '0' && c <= '9', but named predicates like
isDigit are handy as arguments to span, dropWhile etc. Perhaps Haskell
2002 should have both; it's not clear how they should be named.

The above paragraph this is irrelevant for Haskell 98 clarification
of course.

-- 
 __("<  Marcin Kowalczyk * qrczak@knm.org.pl http://qrczak.ids.net.pl/
 \__/
  ^^                      SYGNATURA ZASTĘPCZA
QRCZAK