From: Michael W. Hudson Date: Mon, 20 May 2002 17:29:46 +0000 (+0000) Subject: Use types.StringTypes instead of explicit (str, unicode) list X-Git-Tag: v2.3c1~5638 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=755f75eef813963009a82e066e952f24077d1017;p=python Use types.StringTypes instead of explicit (str, unicode) list --- diff --git a/Lib/inspect.py b/Lib/inspect.py index 38b93bf80c..2f9511a0ee 100644 --- a/Lib/inspect.py +++ b/Lib/inspect.py @@ -267,7 +267,7 @@ def getdoc(object): doc = object.__doc__ except AttributeError: return None - if not isinstance(doc, (str, unicode)): + if not isinstance(doc, types.StringTypes): return None try: lines = string.split(string.expandtabs(doc), '\n')