X-Git-Url: https://erislabs.net/gitweb/?a=blobdiff_plain;f=lib%2Fargmatch.h;h=7e88696a4a39461a6318dfef4b24d422ba76bfbd;hb=4f044de87e05bee61005c48bb93f3bb9a4b76461;hp=4972abe956c22101b1803b9eea851b4fb4047a9c;hpb=441aa3044f43e5572f58c354f01e6bc070acd5c7;p=gnulib.git diff --git a/lib/argmatch.h b/lib/argmatch.h index 4972abe95..7e88696a4 100644 --- a/lib/argmatch.h +++ b/lib/argmatch.h @@ -1,6 +1,6 @@ /* argmatch.h -- definitions and prototypes for argmatch.c - Copyright (C) 1990, 1998, 1999, 2001, 2002, 2004, 2005 Free Software + Copyright (C) 1990, 1998-1999, 2001-2002, 2004-2005, 2009-2012 Free Software Foundation, Inc. This program is free software: you can redistribute it and/or modify @@ -40,14 +40,14 @@ to the same values in VALLIST). */ ptrdiff_t argmatch (char const *arg, char const *const *arglist, - char const *vallist, size_t valsize); + char const *vallist, size_t valsize) _GL_ATTRIBUTE_PURE; # define ARGMATCH(Arg, Arglist, Vallist) \ argmatch (Arg, Arglist, (char const *) (Vallist), sizeof *(Vallist)) /* xargmatch calls this function when it fails. This function should not return. By default, this is a function that calls ARGMATCH_DIE which - in turn defaults to `exit (exit_failure)'. */ + in turn defaults to 'exit (exit_failure)'. */ typedef void (*argmatch_exit_fn) (void); extern argmatch_exit_fn argmatch_die; @@ -73,8 +73,8 @@ void argmatch_valid (char const *const *arglist, -/* Same as argmatch, but upon failure, reports a explanation on the - failure, and exits using the function EXIT_FN. */ +/* Same as argmatch, but upon failure, report an explanation of the + failure, and exit using the function EXIT_FN. */ ptrdiff_t __xargmatch_internal (char const *context, char const *arg, char const *const *arglist, @@ -93,7 +93,8 @@ ptrdiff_t __xargmatch_internal (char const *context, char const *argmatch_to_argument (char const *value, char const *const *arglist, - char const *vallist, size_t valsize); + char const *vallist, size_t valsize) + _GL_ATTRIBUTE_PURE; # define ARGMATCH_TO_ARGUMENT(Value, Arglist, Vallist) \ argmatch_to_argument (Value, Arglist, \