mirror of
https://github.com/mruby/mruby
synced 2026-06-08 16:11:16 +00:00
partial VC support
This commit is contained in:
+2
-1
@@ -3843,6 +3843,7 @@ mrb_cstr_to_inum(mrb_state *mrb, const char *str, int base, int badcheck)
|
||||
// long i;
|
||||
// mrb_value z;
|
||||
// BDIGIT *zds;
|
||||
unsigned long val;
|
||||
|
||||
#undef ISDIGIT
|
||||
#define ISDIGIT(c) ('0' <= (c) && (c) <= '9')
|
||||
@@ -3958,7 +3959,7 @@ mrb_cstr_to_inum(mrb_state *mrb, const char *str, int base, int badcheck)
|
||||
}
|
||||
len *= strlen(str)*sizeof(char);
|
||||
|
||||
unsigned long val = strtoul((char*)str, &end, base);
|
||||
val = strtoul((char*)str, &end, base);
|
||||
|
||||
if (badcheck) {
|
||||
if (end == str) goto bad; /* no number */
|
||||
|
||||
Reference in New Issue
Block a user