mirror of
https://github.com/ruby/ruby.git
synced 2022-11-09 12:17:21 -05:00
* string.c (rb_str_succ): alphabets or numerics mutually enclosing
non-alphanumeric characters can carry up. e.g., "1.999".succ should be "2.000". git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@17963 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
parent
1d1a3fb75a
commit
6e0b5f40cc
3 changed files with 24 additions and 8 deletions
|
@ -1221,6 +1221,7 @@ class TestString < Test::Unit::TestCase
|
|||
|
||||
assert_equal(S("124"), S("123").succ)
|
||||
assert_equal(S("1000"), S("999").succ)
|
||||
assert_equal(S("2.000"), S("1.999").succ)
|
||||
|
||||
assert_equal(S("No.10"), S("No.9").succ)
|
||||
assert_equal(S("2000aaa"), S("1999zzz").succ)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue