[pypy-commit] pypy default: Change the repr of 'lib.func' to include the full signature
arigo
pypy.commits at gmail.com
Sat Apr 23 03:19:31 EDT 2016
Author: Armin Rigo <arigo at tunes.org>
Branch:
Changeset: r83832:7e2e9ca21aac
Date: 2016-04-23 09:19 +0200
http://bitbucket.org/pypy/pypy/changeset/7e2e9ca21aac/
Log: Change the repr of 'lib.func' to include the full signature
diff --git a/pypy/module/_cffi_backend/wrapper.py b/pypy/module/_cffi_backend/wrapper.py
--- a/pypy/module/_cffi_backend/wrapper.py
+++ b/pypy/module/_cffi_backend/wrapper.py
@@ -92,7 +92,8 @@
return ctype._call(self.fnptr, args_w)
def descr_repr(self, space):
- return space.wrap("<FFIFunctionWrapper for %s()>" % (self.fnname,))
+ doc = self.rawfunctype.repr_fn_type(self.ffi, self.fnname)
+ return space.wrap("<FFIFunctionWrapper '%s'>" % (doc,))
def descr_get_doc(self, space):
doc = self.rawfunctype.repr_fn_type(self.ffi, self.fnname)
More information about the pypy-commit
mailing list