[Python-checkins] cpython (2.7): Issue #25314: Remove confused statement about const argument
martin.panter
python-checkins at python.org
Fri Apr 15 20:21:57 EDT 2016
https://hg.python.org/cpython/rev/c42a9233af04
changeset: 101001:c42a9233af04
branch: 2.7
parent: 100981:0f5eb87afd23
user: Martin Panter <vadmium+py at gmail.com>
date: Sat Apr 09 03:49:48 2016 +0000
summary:
Issue #25314: Remove confused statement about const argument
files:
Doc/library/argparse.rst | 6 +++---
1 files changed, 3 insertions(+), 3 deletions(-)
diff --git a/Doc/library/argparse.rst b/Doc/library/argparse.rst
--- a/Doc/library/argparse.rst
+++ b/Doc/library/argparse.rst
@@ -675,8 +675,7 @@
Namespace(foo='1')
* ``'store_const'`` - This stores the value specified by the const_ keyword
- argument. (Note that the const_ keyword argument defaults to the rather
- unhelpful ``None``.) The ``'store_const'`` action is most commonly used with
+ argument. The ``'store_const'`` action is most commonly used with
optional arguments that specify some sort of flag. For example::
>>> parser = argparse.ArgumentParser()
@@ -878,7 +877,8 @@
command-line argument following it, the value of ``const`` will be assumed instead.
See the nargs_ description for examples.
-The ``const`` keyword argument defaults to ``None``.
+With the ``'store_const'`` and ``'append_const'`` actions, the ``const``
+keyword argument must be given. For other actions, is defaults to ``None``.
default
--
Repository URL: https://hg.python.org/cpython
More information about the Python-checkins
mailing list