[pypy-commit] pypy default: Kill this method. This adds yet another special case which

arigo noreply at buildbot.pypy.org
Tue Jun 5 09:57:53 CEST 2012


Author: Armin Rigo <arigo at tunes.org>
Branch: 
Changeset: r55297:d4ed2c8ac9b1
Date: 2012-06-03 19:52 +0200
http://bitbucket.org/pypy/pypy/changeset/d4ed2c8ac9b1/

Log:	Kill this method. This adds yet another special case which can
	potentially break code.

diff --git a/lib_pypy/_ctypes/basics.py b/lib_pypy/_ctypes/basics.py
--- a/lib_pypy/_ctypes/basics.py
+++ b/lib_pypy/_ctypes/basics.py
@@ -47,10 +47,6 @@
         else:
             return self.from_param(as_parameter)
 
-    def get_ffi_param(self, value):
-        cdata = self.from_param(value)
-        return cdata, cdata._to_ffi_param()
-
     def get_ffi_argtype(self):
         if self._ffiargtype:
             return self._ffiargtype
diff --git a/lib_pypy/_ctypes/function.py b/lib_pypy/_ctypes/function.py
--- a/lib_pypy/_ctypes/function.py
+++ b/lib_pypy/_ctypes/function.py
@@ -444,10 +444,6 @@
 
     @classmethod
     def _conv_param(cls, argtype, arg):
-        if isinstance(argtype, _CDataMeta):
-            cobj, ffiparam = argtype.get_ffi_param(arg)
-            return cobj, ffiparam, argtype
-        
         if argtype is not None:
             arg = argtype.from_param(arg)
         if hasattr(arg, '_as_parameter_'):


More information about the pypy-commit mailing list