]> granicus.if.org Git - python/commitdiff
The names of lambda functions are now properly displayed in pydoc.
authorGeorg Brandl <georg@python.org>
Fri, 17 Feb 2006 09:45:40 +0000 (09:45 +0000)
committerGeorg Brandl <georg@python.org>
Fri, 17 Feb 2006 09:45:40 +0000 (09:45 +0000)
Lib/pydoc.py
Misc/NEWS

index b82e0e7d7183d0519529590ae2448550752f0726..2bcf4c997b87e9fc2e2717b8c031cbe3736dd7b8 100755 (executable)
@@ -1248,7 +1248,7 @@ class TextDoc(Doc):
             argspec = inspect.formatargspec(
                 args, varargs, varkw, defaults, formatvalue=self.formatvalue)
             if realname == '<lambda>':
-                title = 'lambda'
+                title = self.bold(name) + ' lambda '
                 argspec = argspec[1:-1] # remove parentheses
         else:
             argspec = '(...)'
index cd63e3219c6b92bd20e210fe31d9176d53aeb678..9af61e10540d74bab79f2ff51511e2b65b196ddc 100644 (file)
--- a/Misc/NEWS
+++ b/Misc/NEWS
@@ -363,6 +363,8 @@ Extension Modules
 Library
 -------
 
+- The names of lambda functions are now properly displayed in pydoc.
+
 - Patch #1412872: zipfile now sets the creator system to 3 (Unix)
   unless the system is Win32.