Skip to content

Commit 8be3fb1

Browse files
authored
gh-142349: Add help("lazy") support (#149886)
1 parent c575172 commit 8be3fb1

4 files changed

Lines changed: 4 additions & 1 deletion

File tree

Doc/tools/extensions/pydoc_topics.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -68,6 +68,7 @@
6868
"in",
6969
"integers",
7070
"lambda",
71+
"lazy",
7172
"lists",
7273
"naming",
7374
"nonlocal",

Lib/pydoc.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1845,6 +1845,7 @@ class Helper:
18451845
'in': ('in', 'SEQUENCEMETHODS'),
18461846
'is': 'COMPARISON',
18471847
'lambda': ('lambda', 'FUNCTIONS'),
1848+
'lazy': ('lazy', 'MODULES'),
18481849
'nonlocal': ('nonlocal', 'global NAMESPACES'),
18491850
'not': 'BOOLEAN',
18501851
'or': 'BOOLEAN',

Lib/test/test_pydoc/test_pydoc.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2172,7 +2172,7 @@ def mock_getline(prompt):
21722172

21732173
def test_keywords(self):
21742174
self.assertEqual(sorted(pydoc.Helper.keywords),
2175-
sorted(keyword.kwlist))
2175+
sorted(keyword.kwlist + ['lazy']))
21762176

21772177
def test_interact_empty_line_continues(self):
21782178
# gh-138568: test pressing Enter without input should continue in help session
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
Add :keyword:`lazy` to the list of support topic by :func:`help`.

0 commit comments

Comments
 (0)