-
-
Notifications
You must be signed in to change notification settings - Fork 32.7k
Open
Labels
docsDocumentation in the Doc dirDocumentation in the Doc dir
Description
Documentation
I've highlighted the error in bold in the following passage from the doc.
When add_argument() is called with option strings (like -f or --foo) and nargs='?'. This creates an optional argument that can be followed by zero or one command-line arguments. When parsing the command line, if the option string is encountered with no command-line argument following it, the value of const will be assumed to be None instead.
The bold text should be replaced with "used".
Justification: the previous passage is contradicted by the following passage from the same page.
for optional arguments, there is an additional case - the option string is present but not followed by a command-line argument. In this case the value from const will be produced.
Metadata
Metadata
Assignees
Labels
docsDocumentation in the Doc dirDocumentation in the Doc dir
Projects
Status
No status
Status
Todo