aboutsummaryrefslogtreecommitdiffstats
path: root/addr2line.c
diff options
context:
space:
mode:
authornaruse <naruse@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2016-03-29 10:34:54 +0000
committernaruse <naruse@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2016-03-29 10:34:54 +0000
commit3bd0614d79c95833d39a95af277c1a7dd6df0497 (patch)
treeca82ac6fa83ef8711dcd855ebbc03d7c2e4fdbcd /addr2line.c
parent870b6da5c580979a1d22579877231e966c5976c7 (diff)
downloadruby-3bd0614d79c95833d39a95af277c1a7dd6df0497.tar.gz
* addr2line.c: define toupper for its use. fix r54391.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@54392 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'addr2line.c')
-rw-r--r--addr2line.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/addr2line.c b/addr2line.c
index c8faf48d62..b031710d71 100644
--- a/addr2line.c
+++ b/addr2line.c
@@ -812,8 +812,7 @@ next_line:
#include <stdarg.h>
#define MAXNBUF (sizeof(intmax_t) * CHAR_BIT + 1)
-extern int rb_toupper(int c);
-#define toupper(c) rb_toupper(c)
+static inline int toupper(int c) { return ('A' <= c && c <= 'Z') ? (c&0x5f) : c; }
#define hex2ascii(hex) (hex2ascii_data[hex])
char const hex2ascii_data[] = "0123456789abcdefghijklmnopqrstuvwxyz";
static inline int imax(int a, int b) { return (a > b ? a : b); }