[pypy-commit] pypy py3k: reapply py3k's wrapbytes
pjenvey
noreply at buildbot.pypy.org
Thu May 23 00:29:32 CEST 2013
Author: Philip Jenvey <pjenvey at underboss.org>
Branch: py3k
Changeset: r64489:1ea11f8296ab
Date: 2013-05-22 15:16 -0700
http://bitbucket.org/pypy/pypy/changeset/1ea11f8296ab/
Log: reapply py3k's wrapbytes
diff --git a/pypy/objspace/std/bytearrayobject.py b/pypy/objspace/std/bytearrayobject.py
--- a/pypy/objspace/std/bytearrayobject.py
+++ b/pypy/objspace/std/bytearrayobject.py
@@ -264,7 +264,7 @@
def str_startswith__Bytearray_ANY_ANY_ANY(space, w_bytearray, w_prefix, w_start, w_stop):
if space.isinstance_w(w_prefix, space.w_tuple):
w_str = _to_bytes(space, w_bytearray)
- w_prefix = space.newtuple([space.wrap(space.bufferstr_new_w(w_entry)) for w_entry in
+ w_prefix = space.newtuple([space.wrapbytes(space.bufferstr_new_w(w_entry)) for w_entry in
space.fixedview(w_prefix)])
return stringobject.str_startswith__String_ANY_ANY_ANY(space, w_str, w_prefix,
w_start, w_stop)
@@ -277,7 +277,7 @@
def str_endswith__Bytearray_ANY_ANY_ANY(space, w_bytearray, w_suffix, w_start, w_stop):
if space.isinstance_w(w_suffix, space.w_tuple):
w_str = _to_bytes(space, w_bytearray)
- w_suffix = space.newtuple([space.wrap(space.bufferstr_new_w(w_entry)) for w_entry in
+ w_suffix = space.newtuple([space.wrapbytes(space.bufferstr_new_w(w_entry)) for w_entry in
space.fixedview(w_suffix)])
return stringobject.str_endswith__String_ANY_ANY_ANY(space, w_str, w_suffix,
w_start, w_stop)
More information about the pypy-commit
mailing list