numericValue for (unicode) characters

monarch_dodra monarchdodra at gmail.com
Fri Jan 4 09:53:33 PST 2013


On Friday, 4 January 2013 at 17:48:28 UTC, monarch_dodra wrote:
> //----
> Maybe we should just return -1 on invalid unicode? Or maybe 
> it's just my input file:
> http://www.unicode.org/Public/UNIDATA/UnicodeData.txt
> It doesn't have a separate field for isNumber/numericValue, so 
> it is forced to write a wild number. Maybe these four chars 
> should return nan?

Wait: I figured it out: They are just non-numbers that happen to 
be inside Nl (Number Letter): 
http://unicode.org/cldr/utility/character.jsp?a=12433

Documentation on this is not very clear, nor consistent, so sorry 
for any confusion.

Well, I guess there is a bug in std.isNumber then...


More information about the Digitalmars-d mailing list