Author: Manuel Jacob
Branch: refactor-str-types
Changeset: r65796:d42a088324cb
Date: 2013-07-29 17:12 +0200
http://bitbucket.org/pypy/pypy/changeset/d42a088324cb/

Log:    Fix.

diff --git a/pypy/objspace/std/stringmethods.py 
b/pypy/objspace/std/stringmethods.py
--- a/pypy/objspace/std/stringmethods.py
+++ b/pypy/objspace/std/stringmethods.py
@@ -515,6 +515,9 @@
                                  space.wrap("empty separator"))
         pos = value.rfind(sub)
         if pos == -1:
+            from pypy.objspace.std.bytearrayobject import W_BytearrayObject
+            if isinstance(self, W_BytearrayObject):
+                self = self._new(value)
             return space.newtuple([self._empty(), self._empty(), self])
         else:
             from pypy.objspace.std.bytearrayobject import W_BytearrayObject
_______________________________________________
pypy-commit mailing list
pypy-commit@python.org
http://mail.python.org/mailman/listinfo/pypy-commit

Reply via email to