Author: Matti Picus <[email protected]>
Branch: issue2444
Changeset: r89239:680bcb971f9b
Date: 2016-12-26 21:22 +0200
http://bitbucket.org/pypy/pypy/changeset/680bcb971f9b/
Log: use _attrs_ instead of __slots__
diff --git a/rpython/rlib/buffer.py b/rpython/rlib/buffer.py
--- a/rpython/rlib/buffer.py
+++ b/rpython/rlib/buffer.py
@@ -6,6 +6,7 @@
class Buffer(object):
"""Abstract base class for buffers."""
+ _attrs_ = ['readonly']
_immutable_ = True
def getlength(self):
@@ -78,7 +79,7 @@
pass
class StringBuffer(Buffer):
- __slots__ = ['readonly', 'value']
+ _attrs_ = ['readonly', 'value']
_immutable_ = True
def __init__(self, value):
@@ -109,7 +110,7 @@
class SubBuffer(Buffer):
- __slots__ = ['buffer', 'offset', 'size', 'readonly']
+ _attrs_ = ['buffer', 'offset', 'size', 'readonly']
_immutable_ = True
def __init__(self, buffer, offset, size):
_______________________________________________
pypy-commit mailing list
[email protected]
https://mail.python.org/mailman/listinfo/pypy-commit