.. method:: ArgumentParser.exit(status=0, message=None)
This method terminates the program, exiting with the specified *status*
- and, if given, it prints a *message* before that. The user can override
- this method to handle these steps differently::
+ and, if given, it prints a *message* to :data:`sys.stderr` before that.
+ The user can override this method to handle these steps differently::
class ErrorCatchingArgumentParser(argparse.ArgumentParser):
def exit(self, status=0, message=None):
.. method:: ArgumentParser.error(message)
- This method prints a usage message including the *message* to the
- standard error and terminates the program with a status code of 2.
+ This method prints a usage message, including the *message*, to
+ :data:`sys.stderr` and terminates the program with a status code of 2.
Intermixed parsing