Author: Armin Rigo <[email protected]>
Branch:
Changeset: r3012:10ab414ad7b2
Date: 2017-09-16 15:43 +0200
http://bitbucket.org/cffi/cffi/changeset/10ab414ad7b2/
Log: Python 3
diff --git a/testing/cffi0/test_verify.py b/testing/cffi0/test_verify.py
--- a/testing/cffi0/test_verify.py
+++ b/testing/cffi0/test_verify.py
@@ -2466,8 +2466,8 @@
for i in range(2000):
p = lib.malloc(20*1024*1024) # 20 MB
p1 = ffi.cast("char *", p)
- for j in xrange(0, 20*1024*1024, 4096):
- p1[j] = '!'
+ for j in range(0, 20*1024*1024, 4096):
+ p1[j] = b'!'
p = ffi.gc(p, lib.free, 20*1024*1024)
del p
diff --git a/testing/cffi1/test_verify1.py b/testing/cffi1/test_verify1.py
--- a/testing/cffi1/test_verify1.py
+++ b/testing/cffi1/test_verify1.py
@@ -2303,8 +2303,8 @@
for i in range(2000):
p = lib.malloc(20*1024*1024) # 20 MB
p1 = ffi.cast("char *", p)
- for j in xrange(0, 20*1024*1024, 4096):
- p1[j] = '!'
+ for j in range(0, 20*1024*1024, 4096):
+ p1[j] = b'!'
p = ffi.gc(p, lib.free, 20*1024*1024)
del p
# with PyPy's GC, the above would rapidly consume 40 GB of RAM
_______________________________________________
pypy-commit mailing list
[email protected]
https://mail.python.org/mailman/listinfo/pypy-commit