Should I Use std.ascii.isWhite or std.uni.isWhite?

Dmitry Olshansky dmitry.olsh at gmail.com
Fri Jul 26 10:58:19 PDT 2013


26-Jul-2013 09:54, Meta пишет:
> On Friday, 26 July 2013 at 05:06:45 UTC, Jonathan M Davis wrote:
[snip]
>
> That makes sense. I know that the first 127 unicode characters are
> equivalent to the 7-bit ASCII charset, but it confused me that the
> module is named std.ascii when it actually operates on unicode
> characters, I guess.
>
> Another question, I'm not all that familiar with unicode, so what is the
> difference between std.uni.isNumber and std.ascii.isNumber? Am I right
> in thinking that std.uni.isNumber will match things outside of the basic
> 0..9?

You are spot on. In case you want to further dig into Unicode characters 
and properties, there is this nice tool:
http://unicode.org/cldr/utility/list-unicodeset.jsp?a=%5B%3AN%3A%5D&g=
(e.g. this link shows all of 'N' = Number characters)

-- 
Dmitry Olshansky


More information about the Digitalmars-d-learn mailing list