mirror of
https://github.com/python/cpython.git
synced 2025-08-03 16:39:00 +00:00
Fix indentation in example.
This commit is contained in:
parent
f6914aa76b
commit
571a953590
1 changed files with 2 additions and 2 deletions
|
@ -698,8 +698,8 @@ An example of a custom action::
|
|||
|
||||
>>> class FooAction(argparse.Action):
|
||||
... def __call__(self, parser, namespace, values, option_string=None):
|
||||
... print('%r %r %r' % (namespace, values, option_string))
|
||||
... setattr(namespace, self.dest, values)
|
||||
... print('%r %r %r' % (namespace, values, option_string))
|
||||
... setattr(namespace, self.dest, values)
|
||||
...
|
||||
>>> parser = argparse.ArgumentParser()
|
||||
>>> parser.add_argument('--foo', action=FooAction)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue