From dd13084557f46343b9fac0c02725a826d0ca397b Mon Sep 17 00:00:00 2001 From: Charles Harris Date: Wed, 27 Feb 2013 18:34:50 -0700 Subject: 2to3: Fix callable. --- doc/sphinxext/docscrape.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'doc/sphinxext/docscrape.py') diff --git a/doc/sphinxext/docscrape.py b/doc/sphinxext/docscrape.py index b08643c8b..2348149ac 100644 --- a/doc/sphinxext/docscrape.py +++ b/doc/sphinxext/docscrape.py @@ -8,6 +8,7 @@ import re import pydoc from StringIO import StringIO from warnings import warn +import collections class Reader(object): """A line-based string reader. @@ -495,7 +496,7 @@ class ClassDoc(NumpyDocString): return [name for name,func in inspect.getmembers(self._cls) if ((not name.startswith('_') or name in self.extra_public_methods) - and callable(func))] + and isinstance(func, collections.Callable))] @property def properties(self): -- cgit v1.2.1