for (group = parser->groups; group < parser->egroup && (!err || err==EBADKEY); group++)
for (group = parser->egroup - 1; group >= parser->groups && (!err || err==EBADKEY); group--)
parser_finalize (struct parser *parser,		 error_t err, int arg_ebadkey, int *end_index){  struct group *group;  UNLOCK_GETOPT;  if (err == EBADKEY && arg_ebadkey)    /* Suppress errors generated by unparsed arguments.  */    err = 0;  if (! err)    {      if (parser->state.next == parser->state.argc)	/* We successfully parsed all arguments!  Call all the parsers again,	   just a few more times... */	{	  for (group = parser->groups;	       group < parser->egroup && (!err || err==EBADKEY);	       group++)	    if (group->args_processed == 0)	      err = group_parse (group, &parser->state, ARGP_KEY_NO_ARGS, 0);	  for (group = parser->groups;	       group < parser->egroup && (!err || err==EBADKEY);	       group++)	    err = group_parse (group, &parser->state, ARGP_KEY_END, 0);	  if (err == EBADKEY)	    err = 0;		/* Some parser didn't understand.  */	  /* Tell the user that all arguments are parsed.  */	  if (end_index)	    *end_index = parser->state.next;	}      else if (end_index)	/* Return any remaining arguments to the user.  */	*end_index = parser->state.next;      else	/* No way to return the remaining arguments, they must be bogus. */	{	  if (!(parser->state.flags & ARGP_NO_ERRS)	      && parser->state.err_stream)	    fprintf (parser->state.err_stream,		     dgettext (parser->argp->argp_domain,			       "%s: Too many arguments\n"),		     parser->state.name);	  err = EBADKEY;	}    }  /* Okay, we're all done, with either an error or success; call the parsers     to indicate which one.  */  if (err)    {      /* Maybe print an error message.  */      if (err == EBADKEY)	/* An appropriate message describing what the error was should have	   been printed earlier.  */	__argp_state_help (&parser->state, parser->state.err_stream,			   ARGP_HELP_STD_ERR);      /* Since we didn't exit, give each parser an error indication.  */      for (group = parser->groups; group < parser->egroup; group++)	group_parse (group, &parser->state, ARGP_KEY_ERROR, 0);    }  else    /* Notify parsers of success, and propagate back values from parsers.  */    {      /* We pass over the groups in reverse order so that child groups are	 given a chance to do there processing before passing back a value to	 the parent.  */      for (group = parser->egroup - 1	   ; group >= parser->groups && (!err || err == EBADKEY)	   ; group--)	err = group_parse (group, &parser->state, ARGP_KEY_SUCCESS, 0);      if (err == EBADKEY)	err = 0;		/* Some parser didn't understand.  */    }  /* Call parsers once more, to do any final cleanup.  Errors are ignored.  */  for (group = parser->egroup - 1; group >= parser->groups; group--)    group_parse (group, &parser->state, ARGP_KEY_FINI, 0);  if (err == EBADKEY)    err = EINVAL;  free (parser->storage);  return err;}