1
0
Fork 0
mirror of https://github.com/ruby/ruby.git synced 2022-11-09 12:17:21 -05:00

bignum.c: unnecessary check

* bignum.c (rb_cstr_parse_inum): remove unnecessary check.
  successive sign is rejected by conv_digit.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@57277 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
nobu 2017-01-07 08:31:03 +00:00
parent 60172f015f
commit 4dbbcc48de

View file

@ -4057,9 +4057,6 @@ rb_cstr_parse_inum(const char *str, ssize_t len, char **endp, int base)
sign = 0;
}
ASSERT_LEN();
if (str[0] == '+' || str[0] == '-') {
goto bad;
}
}
if (base <= 0) {
if (str[0] == '0' && len > 1) {