[Python-bugs-list] [ python-Bugs-672578 ] pydoc does not cope well with lambda
SourceForge.net
noreply@sourceforge.net
Wed, 22 Jan 2003 09:29:46 -0800
Bugs item #672578, was opened at 2003-01-22 09:29
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=105470&aid=672578&group_id=5470
Category: Demos and Tools
Group: Python 2.2.1
Status: Open
Resolution: None
Priority: 5
Submitted By: Jim Meyer (purp)
Assigned to: Nobody/Anonymous (nobody)
Summary: pydoc does not cope well with lambda
Initial Comment:
pydoc doesn't deal well with lambda expressions. Here's
some sample code:
================================================================
#!/usr/bin/env python2
"""a bogus program
Demonstrate that pydoc doesn't handle lambdas well
"""
#
--------------------------------------------------------------------
# A comment heading
#
--------------------------------------------------------------------
def foo (optional = 1) :
''' A bogus function '''
return optional
bar = lambda opt : foo(opt)
================================================================
...and here's what pydoc says:
================================================================
> pydoc /tmp/foo.py
Python Library Documentation: module foo
NAME
foo - a bogus program
FILE
/tmp/foo.py
DESCRIPTION
Demonstrate that pydoc doesn't handle lambdas well
FUNCTIONS
lambdaopt
#
--------------------------------------------------------------------
# A comment heading
#
--------------------------------------------------------------------
foo(optional=1)
A bogus function
DATA
__file__ = '/tmp/foo.pyc'
__name__ = 'foo'
================================================================
I'm looking for the cause now and hope to contribute a
patch shortly.
--j
----------------------------------------------------------------------
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=105470&aid=672578&group_id=5470