nodes: 0, module; 1, function_definition; 2, function_name:add_parser; 3, parameters; 4, block; 5, identifier:self; 6, list_splat_pattern; 7, dictionary_splat_pattern; 8, expression_statement; 9, expression_statement; 10, expression_statement; 11, expression_statement; 12, expression_statement; 13, expression_statement; 14, expression_statement; 15, expression_statement; 16, return_statement; 17, identifier:args; 18, identifier:kwargs; 19, comment:"""each time a subparser action is used to create a new parser object
          we must save the original args & kwargs.  In a later phase of
          configman, we'll need to reproduce the subparsers exactly without
          resorting to copying.  We save the args & kwargs in the 'foreign_data'
          section of the configman option that corresponds with the subparser
          action."""; 20, assignment; 21, assignment; 22, assignment; 23, assignment; 24, assignment; 25, assignment; 26, assignment; 27, identifier:a_subparser; 28, identifier:command_name; 29, subscript; 30, identifier:new_kwargs; 31, call; 32, subscript; 33, attribute; 34, subscript; 35, identifier:command_name; 36, identifier:subparsers; 37, attribute; 38, identifier:a_subparser; 39, call; 40, subscript; 41, call; 42, identifier:args; 43, integer:0; 44, attribute; 45, argument_list; 46, identifier:new_kwargs; 47, string; 48, identifier:self; 49, identifier:_configman_option; 50, identifier:new_kwargs; 51, string; 52, attribute; 53, identifier:subparsers; 54, attribute; 55, argument_list; 56, identifier:subparsers; 57, identifier:command_name; 58, identifier:DotDict; 59, argument_list; 60, identifier:kwargs; 61, identifier:copy; 62, string_content:configman_subparsers_option; 63, string_content:subparser_name; 64, attribute; 65, identifier:argparse; 66, call; 67, identifier:add_parser; 68, list_splat; 69, dictionary_splat; 70, dictionary; 71, attribute; 72, identifier:foreign_data; 73, identifier:super; 74, argument_list; 75, identifier:args; 76, identifier:new_kwargs; 77, pair; 78, pair; 79, pair; 80, identifier:self; 81, identifier:_configman_option; 82, identifier:ConfigmanSubParsersAction; 83, identifier:self; 84, string:"args"; 85, identifier:args; 86, string:"kwargs"; 87, identifier:new_kwargs; 88, string:"subparser"; 89, identifier:a_subparser
code: def add_parser(self, *args, **kwargs):
          """each time a subparser action is used to create a new parser object
          we must save the original args & kwargs.  In a later phase of
          configman, we'll need to reproduce the subparsers exactly without
          resorting to copying.  We save the args & kwargs in the 'foreign_data'
          section of the configman option that corresponds with the subparser
          action."""
          command_name = args[0]
          new_kwargs = kwargs.copy()
          new_kwargs['configman_subparsers_option'] = self._configman_option
          new_kwargs['subparser_name'] = command_name
          subparsers = self._configman_option.foreign_data.argparse.subparsers
          a_subparser = super(ConfigmanSubParsersAction, self).add_parser(
              *args,
              **new_kwargs
          )
          subparsers[command_name] = DotDict({
              "args": args,
              "kwargs": new_kwargs,
              "subparser": a_subparser
          })
          return a_subparser