# HG changeset patch # User Martin Panter # Date 1460173788 0 # Sat Apr 09 03:49:48 2016 +0000 # Branch 3.5 # Node ID 0e6515e2b58e8c3463ee686856fce9e94dec0a6b # Parent f51921883f50be87405c81030bf01e6a29211c5e Issue #25314: Remove confused statement about const argument diff -r f51921883f50 Doc/library/argparse.rst --- a/Doc/library/argparse.rst Sun Oct 04 01:19:36 2015 -0400 +++ b/Doc/library/argparse.rst Sat Apr 09 04:15:19 2016 +0000 @@ -720,8 +720,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() @@ -921,7 +920,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