mirror of
https://gitlab.gnome.org/GNOME/glib.git
synced 2025-08-23 01:18:53 +02:00
Add tests for the handling of non-option arguments, "--" and
2004-10-29 Matthias Clasen <mclasen@redhat.com> * tests/option-test.c: Add tests for the handling of non-option arguments, "--" and G_OPTION_REMAINING. * glib/goption.[hc]: #define G_OPTION_REMAINING, which is a special long option name, which can be used for an option in the main group which collects the non-option arguments. It must be of type G_OPTION_ARG_STRING_ARRAY or G_OPTION_ARG_FILENAME_ARRAY. If the main group doesn't contain an option whose name is G_OPTION_REMAINING, the non-option arguments are left behind in argv as before.
This commit is contained in:
committed by
Matthias Clasen
parent
a0e217e94a
commit
a9fa61a13e
@@ -87,6 +87,8 @@ struct _GOptionEntry
|
||||
const gchar *arg_description;
|
||||
};
|
||||
|
||||
#define G_OPTION_REMAINING ""
|
||||
|
||||
GOptionContext *g_option_context_new (const gchar *parameter_string);
|
||||
void g_option_context_free (GOptionContext *context);
|
||||
void g_option_context_set_help_enabled (GOptionContext *context,
|
||||
@@ -132,9 +134,6 @@ void g_option_group_set_translation_domain (GOptionGroup *group,
|
||||
const gchar *domain);
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
G_END_DECLS
|
||||
|
||||
#endif /* __G_OPTION_H__ */
|
||||
|
Reference in New Issue
Block a user