-
-
Notifications
You must be signed in to change notification settings - Fork 5.5k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
deprecate string methods of character predicates, e.g. isnumber("")
#20342
Conversation
test/unicode/utf8proc.jl
Outdated
@test isalpha("23435")==false | ||
@test iscntrl( string(Char(0x0080))) == true | ||
@test ispunct( "‡؟჻") ==true | ||
@test all(isspace," \t \n \r ")==true |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
BTW, maybe change ==
into ===
or remove them altogether?
base/strings/basic.jl
Outdated
true | ||
|
||
julia> isxdigit("0x9") | ||
julia> isxdigit('z') |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The 0
and x
cases where interesting to show that the prefix wasn't considered as a valid hexadecimal digit. Say this in the docstring?
base/deprecated.jl
Outdated
@@ -1849,4 +1849,10 @@ end) | |||
|
|||
@deprecate FloatRange{T}(start::T, step, len, den) Base.floatrange(T, start, step, len, den) | |||
|
|||
for name in ("alnum", "alpha", "cntrl", "digit", "number", "graph", | |||
"lower", "print", "punct", "space", "upper", "isxdigit") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think you want just "xdigit"
for the last one.
b49914b
to
541b5f8
Compare
541b5f8
to
38715b8
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
👍
fixes #14156