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/summarize.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'doc/summarize.py') diff --git a/doc/summarize.py b/doc/summarize.py index cfaec6f7a..bd7567d1b 100755 --- a/doc/summarize.py +++ b/doc/summarize.py @@ -7,6 +7,7 @@ Show a summary about which Numpy functions are documented and which are not. """ import os, glob, re, sys, inspect, optparse +import collections sys.path.append(os.path.join(os.path.dirname(__file__), 'sphinxext')) from sphinxext.phantom_import import import_phantom_module @@ -134,7 +135,7 @@ def get_undocumented(documented, module, module_name=None, skip=[]): if full_name in skip: continue if full_name.startswith('numpy.') and full_name[6:] in skip: continue - if not (inspect.ismodule(obj) or callable(obj) or inspect.isclass(obj)): + if not (inspect.ismodule(obj) or isinstance(obj, collections.Callable) or inspect.isclass(obj)): continue if full_name not in documented: -- cgit v1.2.1