diff options
author | Ezio Melotti <ezio.melotti@gmail.com> | 2011-04-28 04:51:14 (GMT) |
---|---|---|
committer | Ezio Melotti <ezio.melotti@gmail.com> | 2011-04-28 04:51:14 (GMT) |
commit | 44aad855ddb0fed3a76c839598a9c3be31d0b7cb (patch) | |
tree | 4579df393960fd3da0945661aefc2e2138cbb8bf /Lib/pydoc.py | |
parent | 4f7412356d669fcd035f0ee220242a35310ba51b (diff) | |
parent | b185a04aa10209df7c5fa329696e3c33c38eba7a (diff) | |
download | cpython-44aad855ddb0fed3a76c839598a9c3be31d0b7cb.zip cpython-44aad855ddb0fed3a76c839598a9c3be31d0b7cb.tar.gz cpython-44aad855ddb0fed3a76c839598a9c3be31d0b7cb.tar.bz2 |
#11926: merge with 3.1.
Diffstat (limited to 'Lib/pydoc.py')
-rwxr-xr-x | Lib/pydoc.py | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/Lib/pydoc.py b/Lib/pydoc.py index dc398e3..2391013e 100755 --- a/Lib/pydoc.py +++ b/Lib/pydoc.py @@ -1576,6 +1576,9 @@ class Helper: # in Doc/ and copying the output file into the Lib/ directory. keywords = { + 'False': '', + 'None': '', + 'True': '', 'and': 'BOOLEAN', 'as': 'with', 'assert': ('assert', ''), @@ -1791,6 +1794,9 @@ has the same effect as typing a particular string at the help> prompt. elif request[:8] == 'modules ': self.listmodules(request.split()[1]) elif request in self.symbols: self.showsymbol(request) + elif request in ['True', 'False', 'None']: + # special case these keywords since they are objects too + doc(eval(request), 'Help on %s:') elif request in self.keywords: self.showtopic(request) elif request in self.topics: self.showtopic(request) elif request: doc(request, 'Help on %s:', output=self._output) |