24 Jan
2014
24 Jan
'14
10:17 p.m.
On 2014-01-24 16:56, Antoine Pitrou wrote:
On Fri, 24 Jan 2014 08:47:14 -0800 (PST) Ram Rachum
wrote: I propose implementing str.rreplace. (It'll be to str.replace what str.rsplit is to str.split.)
I suppose it only differs when the count parameter is supplied?
Not necessarily:
'aaa'.replace('aa', 'x') 'xa' 'aaa'.rreplace('aa', 'x') 'ax'
I don't think it can hurt, except for the funny looks of its name. In any case, if str.rreplace is added then so should bytes.rreplace and bytearray.rreplace.