pypy / pypy / rpython / rbool.py

Diff from to

pypy/rpython/rbool.py

 from pypy.rpython.lltypesystem.lltype import Signed, Unsigned, Bool, Float
 from pypy.rpython.error import TyperError
 from pypy.rpython.rmodel import IntegerRepr, BoolRepr
-from pypy.rpython.robject import PyObjRepr, pyobj_repr
 from pypy.rpython.rmodel import log
 
 
             log.debug('explicit cast_int_to_bool')
             return llops.genop('int_is_true', [v], resulttype=Bool)
         return NotImplemented
-
-class __extend__(pairtype(PyObjRepr, BoolRepr)):
-    def convert_from_to((r_from, r_to), v, llops):
-        if r_to.lowleveltype == Bool:
-            # xxx put in table
-            return llops.gencapicall('PyObject_IsTrue', [v], resulttype=Bool,
-                                     _callable=lambda pyo: bool(pyo._obj.value))
-        return NotImplemented
-
-class __extend__(pairtype(BoolRepr, PyObjRepr)):
-    def convert_from_to((r_from, r_to), v, llops):
-        if r_from.lowleveltype == Bool:
-            return llops.gencapicall('PyBool_FromLong', [v],
-                                     resulttype = pyobj_repr)
-        return NotImplemented
Tip: Filter by directory path e.g. /media app.js to search for public/media/app.js.
Tip: Use camelCasing e.g. ProjME to search for ProjectModifiedEvent.java.
Tip: Filter by extension type e.g. /repo .js to search for all .js files in the /repo directory.
Tip: Separate your search with spaces e.g. /ssh pom.xml to search for src/ssh/pom.xml.
Tip: Use ↑ and ↓ arrow keys to navigate and return to view the file.
Tip: You can also navigate files with Ctrl+j (next) and Ctrl+k (previous) and view the file with Ctrl+o.
Tip: You can also navigate files with Alt+j (next) and Alt+k (previous) and view the file with Alt+o.