[Python-checkins] cpython (merge 3.6 -> default): Issue #28455: Merge from 3.6

berker.peksag python-checkins at python.org
Sun Oct 16 23:14:49 EDT 2016


https://hg.python.org/cpython/rev/a293e5db9083
changeset:   104520:a293e5db9083
parent:      104517:b37db216c8e0
parent:      104519:0b29adb5c804
user:        Berker Peksag <berker.peksag at gmail.com>
date:        Mon Oct 17 06:15:28 2016 +0300
summary:
  Issue #28455: Merge from 3.6

files:
  Doc/library/argparse.rst |  9 +++++----
  1 files changed, 5 insertions(+), 4 deletions(-)


diff --git a/Doc/library/argparse.rst b/Doc/library/argparse.rst
--- a/Doc/library/argparse.rst
+++ b/Doc/library/argparse.rst
@@ -1958,10 +1958,11 @@
    The method is called once per line read from the argument file, in order.
 
    A useful override of this method is one that treats each space-separated word
-   as an argument::
-
-    def convert_arg_line_to_args(self, arg_line):
-        return arg_line.split()
+   as an argument.  The following example demonstrates how to do this::
+
+    class MyArgumentParser(argparse.ArgumentParser):
+        def convert_arg_line_to_args(self, arg_line):
+            return arg_line.split()
 
 
 Exiting methods

-- 
Repository URL: https://hg.python.org/cpython


More information about the Python-checkins mailing list