1
0
Fork 0

Merging upstream version 1.1~rc2.

Signed-off-by: Daniel Baumann <daniel@debian.org>
This commit is contained in:
Daniel Baumann 2025-02-17 19:14:54 +01:00
parent a8d17e4a46
commit 950a431716
Signed by: daniel
GPG key ID: FBB4F0E80A80222F
22 changed files with 1309 additions and 1071 deletions

View file

@ -57,8 +57,8 @@ enum ap_Has_arg { ap_no, ap_yes, ap_maybe };
struct ap_Option
{
int code; // Short option letter or code ( code != 0 )
const char * name; // Long option name (maybe null)
int code; /* Short option letter or code ( code != 0 ) */
const char * name; /* Long option name (maybe null) */
enum ap_Has_arg has_arg;
};
@ -87,11 +87,11 @@ void ap_free( struct Arg_parser * const ap );
const char * ap_error( const struct Arg_parser * const ap );
// The number of arguments parsed (may be different from argc)
/* The number of arguments parsed (may be different from argc) */
int ap_arguments( const struct Arg_parser * const ap );
// If ap_code( i ) is 0, ap_argument( i ) is a non-option.
// Else ap_argument( i ) is the option's argument (or empty).
/* If ap_code( i ) is 0, ap_argument( i ) is a non-option.
Else ap_argument( i ) is the option's argument (or empty). */
int ap_code( const struct Arg_parser * const ap, const int i );
const char * ap_argument( const struct Arg_parser * const ap, const int i );