Author: Christian Hudon <chr...@pianocktail.org>
Branch: stdlib-2.7.4
Changeset: r66139:e9f522eea11f
Date: 2013-08-13 17:19 -0400
http://bitbucket.org/pypy/pypy/changeset/e9f522eea11f/

Log:    Remove unnecessary long method on W_root.

diff --git a/pypy/interpreter/baseobjspace.py b/pypy/interpreter/baseobjspace.py
--- a/pypy/interpreter/baseobjspace.py
+++ b/pypy/interpreter/baseobjspace.py
@@ -231,18 +231,6 @@
         msg = "__int__ returned non-int (type '%T')"
         raise operationerrfmt(space.w_TypeError, msg, w_result)
 
-    def long(self, space):
-        w_impl = space.lookup(self, '__long__')
-        if w_impl is None:
-            raise operationerrfmt(space.w_TypeError,
-                  "unsupported operand type for long(): '%T'", self)
-        w_result = space.get_and_call_function(w_impl, self)
-
-        if space.isinstance_w(w_result, space.w_long):
-            return w_result
-        msg = "__long__ returned non-long (type '%T')"
-        raise operationerrfmt(space.w_TypeError, msg, w_result)
-
     def __spacebind__(self, space):
         return self
 
_______________________________________________
pypy-commit mailing list
pypy-commit@python.org
http://mail.python.org/mailman/listinfo/pypy-commit

Reply via email to