core :: Char :: is_numeric
assert '0'.is_numeric
assert '9'.is_numeric
assert not 'a'.is_numeric
assert not '?'.is_numeric
FIXME: Works on ASCII-range only
# Returns true if the char is a numerical digit
#
# ~~~
# assert '0'.is_numeric
# assert '9'.is_numeric
# assert not 'a'.is_numeric
# assert not '?'.is_numeric
# ~~~
#
# FIXME: Works on ASCII-range only
fun is_numeric: Bool
do
return self >= '0' and self <= '9'
end
lib/core/text/abstract_text.nit:2267,2--2280,4