summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorakr <akr@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2008-01-02 17:48:20 +0000
committerakr <akr@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2008-01-02 17:48:20 +0000
commit9d52fda376509f22bee858b0190eb0b289734b90 (patch)
treefb3a936a66b46cfd683f499aedb6dc96eae16e3c
parent1db957718408370ce6b23435ef642e6fad130ef0 (diff)
* bignum.c (conv_digit): use ISDIGIT, ISLOWER and ISUPPER.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@14855 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
-rw-r--r--ChangeLog4
-rw-r--r--bignum.c6
2 files changed, 7 insertions, 3 deletions
diff --git a/ChangeLog b/ChangeLog
index 8aa245f..497131a 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,7 @@
+Thu Jan 3 02:44:34 2008 Tanaka Akira <akr@fsij.org>
+
+ * bignum.c (conv_digit): use ISDIGIT, ISLOWER and ISUPPER.
+
Wed Jan 2 23:50:15 2008 Tanaka Akira <akr@fsij.org>
* util.c (ruby_strtoul): "0x", "+" and "-" is not a valid integer.
diff --git a/bignum.c b/bignum.c
index 283a4f4..227e7a0 100644
--- a/bignum.c
+++ b/bignum.c
@@ -380,9 +380,9 @@ rb_cstr_to_inum(const char *str, int base, int badcheck)
#define conv_digit(c) \
(!ISASCII(c) ? -1 : \
- isdigit(c) ? ((c) - '0') : \
- islower(c) ? ((c) - 'a' + 10) : \
- isupper(c) ? ((c) - 'A' + 10) : \
+ ISDIGIT(c) ? ((c) - '0') : \
+ ISLOWER(c) ? ((c) - 'a' + 10) : \
+ ISUPPER(c) ? ((c) - 'A' + 10) : \
-1)
if (!str) {