]> granicus.if.org Git - python/commitdiff
Issue #23356: Simplify convert_arg_line_to_args example.
authorBerker Peksag <berker.peksag@gmail.com>
Sun, 26 Apr 2015 09:09:54 +0000 (12:09 +0300)
committerBerker Peksag <berker.peksag@gmail.com>
Sun, 26 Apr 2015 09:09:54 +0000 (12:09 +0300)
Patch by py.user.

Doc/library/argparse.rst

index 73f94808b659b59a2d8de725cdfcc37d482410e6..ebf88fad54bb81f7275b6925c4dfe2fd0253627b 100644 (file)
@@ -1921,10 +1921,7 @@ Customizing file parsing
    as an argument::
 
     def convert_arg_line_to_args(self, arg_line):
-        for arg in arg_line.split():
-            if not arg.strip():
-                continue
-            yield arg
+        return arg_line.split()
 
 
 Exiting methods