Issue #9116 has been updated by alexeymuranov (Alexey Muranov).


=begin
--- phluid61 (Matthew Kerwin) wrote:

--- > I understand that the difference only applies when a ((|limit|)) parameter is given

It is not only when (({limit})) parameter is given:

  "aaa".split("aa")  # =>["", "a"]
  "aaa".rsplit("aa") # => ["a", ""]

Maybe with a regex there can be a more meaningful example.
=end
----------------------------------------
Feature #9116: String#rsplit missing
https://bugs.ruby-lang.org/issues/9116#change-43018

Author: artagnon (Ramkumar Ramachandra)
Status: Open
Priority: Normal
Assignee: 
Category: lib
Target version: 


There's nothing corresponding to Python's rsplit(). A quick glance at rb_str_split_m() tells me that it should be pretty trivial to implement. Is there any specific reason it hasn't already been done?


-- 
http://bugs.ruby-lang.org/