[Python-checkins] r56844 - sandbox/trunk/2to3/pytree.py
kurt.kaiser
python-checkins at python.org
Thu Aug 9 06:39:36 CEST 2007
Author: kurt.kaiser
Date: Thu Aug 9 06:39:36 2007
New Revision: 56844
Modified:
sandbox/trunk/2to3/pytree.py
Log:
Eliminate DeprecationWarning from 2.6a0
Modified: sandbox/trunk/2to3/pytree.py
==============================================================================
--- sandbox/trunk/2to3/pytree.py (original)
+++ sandbox/trunk/2to3/pytree.py Thu Aug 9 06:39:36 2007
@@ -34,7 +34,7 @@
def __new__(cls, *args, **kwds):
"""Constructor that prevents Base from being instantiated."""
assert cls is not Base, "Cannot instantiate Base"
- return object.__new__(cls, *args, **kwds)
+ return object.__new__(cls)
def __eq__(self, other):
"""Compares two nodes for equality.
@@ -369,7 +369,7 @@
def __new__(cls, *args, **kwds):
"""Constructor that prevents BasePattern from being instantiated."""
assert cls is not BasePattern, "Cannot instantiate BasePattern"
- return object.__new__(cls, *args, **kwds)
+ return object.__new__(cls)
def __repr__(self):
args = [self.type, self.content, self.name]
More information about the Python-checkins
mailing list