[pypy-commit] pypy newinitwarn: quiet warnings w/ stricter __new__ checks
pjenvey
pypy.commits at gmail.com
Sun Oct 23 13:51:01 EDT 2016
Author: Philip Jenvey <pjenvey at underboss.org>
Branch: newinitwarn
Changeset: r87915:156b4acea3c6
Date: 2016-10-23 10:50 -0700
http://bitbucket.org/pypy/pypy/changeset/156b4acea3c6/
Log: quiet warnings w/ stricter __new__ checks
diff --git a/lib_pypy/_collections.py b/lib_pypy/_collections.py
--- a/lib_pypy/_collections.py
+++ b/lib_pypy/_collections.py
@@ -29,7 +29,7 @@
class deque(object):
def __new__(cls, iterable=(), *args, **kw):
- self = super(deque, cls).__new__(cls, *args, **kw)
+ self = super(deque, cls).__new__(cls)
self.clear()
return self
diff --git a/lib_pypy/_ctypes/structure.py b/lib_pypy/_ctypes/structure.py
--- a/lib_pypy/_ctypes/structure.py
+++ b/lib_pypy/_ctypes/structure.py
@@ -229,7 +229,7 @@
__metaclass__ = StructOrUnionMeta
def __new__(cls, *args, **kwds):
- self = super(_CData, cls).__new__(cls, *args, **kwds)
+ self = super(_CData, cls).__new__(cls)
if '_abstract_' in cls.__dict__:
raise TypeError("abstract class")
if hasattr(cls, '_ffistruct_'):
More information about the pypy-commit
mailing list