summaryrefslogtreecommitdiff
path: root/string.c
diff options
context:
space:
mode:
authormatz <matz@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2007-12-19 17:02:29 +0000
committermatz <matz@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2007-12-19 17:02:29 +0000
commit77629d2cbe4931e3033ae73cef2e9adf6c1c0373 (patch)
tree9b75e0c5b7cffd99cebf28cb557f458b5bbfc974 /string.c
parenta927483326e54e6a4e9387009af0b57f38636497 (diff)
* string.c (rb_str_rindex_m): too much adjustment.
* re.c (reg_match_pos): pos adjustment should be based on characters. * test/ruby/test_m17n.rb (TestM17N::test_str_insert): test updated to check negative offset behavior. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@14340 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'string.c')
-rw-r--r--string.c1
1 files changed, 0 insertions, 1 deletions
diff --git a/string.c b/string.c
index 3f348f2662..2646c8ed30 100644
--- a/string.c
+++ b/string.c
@@ -1650,7 +1650,6 @@ rb_str_rindex_m(int argc, VALUE *argv, VALUE str)
}
/* fall through */
case T_STRING:
- pos = str_sublen(str, pos, enc);
pos = rb_str_rindex(str, sub, pos);
if (pos >= 0) return LONG2NUM(pos);
break;