summaryrefslogtreecommitdiffstats
path: root/Lib/pydoc.py
diff options
context:
space:
mode:
authorGuido van Rossum <guido@python.org>2003-02-27 20:14:51 (GMT)
committerGuido van Rossum <guido@python.org>2003-02-27 20:14:51 (GMT)
commit68468eba635570400f607e140425a222018e56f9 (patch)
tree2176c8822392383a88caa0a2209a1d2f3446d45c /Lib/pydoc.py
parentf389c7727362321a91dbaff13b7e1cef6cbaa3d8 (diff)
downloadcpython-68468eba635570400f607e140425a222018e56f9.zip
cpython-68468eba635570400f607e140425a222018e56f9.tar.gz
cpython-68468eba635570400f607e140425a222018e56f9.tar.bz2
Get rid of many apply() calls.
Diffstat (limited to 'Lib/pydoc.py')
-rwxr-xr-xLib/pydoc.py10
1 files changed, 5 insertions, 5 deletions
diff --git a/Lib/pydoc.py b/Lib/pydoc.py
index 4513733..90df45b 100755
--- a/Lib/pydoc.py
+++ b/Lib/pydoc.py
@@ -266,10 +266,10 @@ class Doc:
def document(self, object, name=None, *args):
"""Generate documentation for an object."""
args = (object, name) + args
- if inspect.ismodule(object): return apply(self.docmodule, args)
- if inspect.isclass(object): return apply(self.docclass, args)
- if inspect.isroutine(object): return apply(self.docroutine, args)
- return apply(self.docother, args)
+ if inspect.ismodule(object): return self.docmodule(*args)
+ if inspect.isclass(object): return self.docclass(*args)
+ if inspect.isroutine(object): returnself.docroutine(*args)
+ return self.docother(*args)
def fail(self, object, name=None, *args):
"""Raise an exception for unimplemented types."""
@@ -379,7 +379,7 @@ TT { font-family: lucidatypewriter, lucida console, courier }
def bigsection(self, title, *args):
"""Format a section with a big heading."""
title = '<big><strong>%s</strong></big>' % title
- return apply(self.section, (title,) + args)
+ return self.section(title, *args)
def preformat(self, text):
"""Format literal preformatted text."""