[glib] Partly revert "glib: Add filename type annotations"



commit c9dd204909aa89648b29c5bd7e159bb32ebc2017
Author: Christoph Reiter <reiter christoph gmail com>
Date:   Tue Jun 7 19:31:51 2016 +0200

    Partly revert "glib: Add filename type annotations"
    
    Revert all annotation changes for environment variables and command line
    arguments.
    
    See commit 41013a01f44e9fc15ffef55eae78af2425bbd5a3.

 glib/genviron.c |   55 +++++++++++++++++++++++++------------------------------
 glib/gshell.c   |   14 +++++++-------
 glib/gspawn.c   |   32 +++++++++++---------------------
 3 files changed, 43 insertions(+), 58 deletions(-)
---
diff --git a/glib/genviron.c b/glib/genviron.c
index d4aa1df..8c64cda 100644
--- a/glib/genviron.c
+++ b/glib/genviron.c
@@ -67,15 +67,15 @@ g_environ_find (gchar       **envp,
 
 /**
  * g_environ_getenv:
- * @envp: (allow-none) (array zero-terminated=1) (transfer none) (element-type filename):
- *     an environment list (eg, as returned from g_get_environ()), or %NULL
+ * @envp: (allow-none) (array zero-terminated=1) (transfer none): an environment
+ *     list (eg, as returned from g_get_environ()), or %NULL
  *     for an empty environment list
- * @variable: (type filename): the environment variable to get
+ * @variable: the environment variable to get
  *
  * Returns the value of the environment variable @variable in the
  * provided list @envp.
  *
- * Returns: (type filename): the value of the environment variable, or %NULL if
+ * Returns: the value of the environment variable, or %NULL if
  *     the environment variable is not set in @envp. The returned
  *     string is owned by @envp, and will be freed if @variable is
  *     set or unset again.
@@ -99,20 +99,19 @@ g_environ_getenv (gchar       **envp,
 
 /**
  * g_environ_setenv:
- * @envp: (allow-none) (array zero-terminated=1) (element-type filename) (transfer full):
- *     an environment list that can be freed using g_strfreev() (e.g., as
+ * @envp: (allow-none) (array zero-terminated=1) (transfer full): an
+ *     environment list that can be freed using g_strfreev() (e.g., as
  *     returned from g_get_environ()), or %NULL for an empty
  *     environment list
- * @variable: (type filename): the environment variable to set, must not
- *     contain '='
- * @value: (type filename): the value for to set the variable to
+ * @variable: the environment variable to set, must not contain '='
+ * @value: the value for to set the variable to
  * @overwrite: whether to change the variable if it already exists
  *
  * Sets the environment variable @variable in the provided list
  * @envp to @value.
  *
- * Returns: (array zero-terminated=1) (element-type filename) (transfer full):
- *     the updated environment list. Free it using g_strfreev().
+ * Returns: (array zero-terminated=1) (transfer full): the
+ *     updated environment list. Free it using g_strfreev().
  *
  * Since: 2.32
  */
@@ -187,17 +186,16 @@ g_environ_unsetenv_internal (gchar        **envp,
 
 /**
  * g_environ_unsetenv:
- * @envp: (allow-none) (array zero-terminated=1) (element-type filename) (transfer full):
- *     an environment list that can be freed using g_strfreev() (e.g., as
- *     returned from g_get_environ()), or %NULL for an empty environment list
- * @variable: (type filename): the environment variable to remove, must not
- *     contain '='
+ * @envp: (allow-none) (array zero-terminated=1) (transfer full): an environment
+ *     list that can be freed using g_strfreev() (e.g., as returned from g_get_environ()), 
+ *     or %NULL for an empty environment list
+ * @variable: the environment variable to remove, must not contain '='
  *
  * Removes the environment variable @variable from the provided
  * environment @envp.
  *
- * Returns: (array zero-terminated=1) (element-type filename) (transfer full):
- *     the updated environment list. Free it using g_strfreev().
+ * Returns: (array zero-terminated=1) (transfer full): the
+ *     updated environment list. Free it using g_strfreev().
  *
  * Since: 2.32
  */
@@ -219,7 +217,7 @@ g_environ_unsetenv (gchar       **envp,
 
 /**
  * g_getenv:
- * @variable: (type filename): the environment variable to get
+ * @variable: the environment variable to get
  *
  * Returns the value of an environment variable.
  *
@@ -229,7 +227,7 @@ g_environ_unsetenv (gchar       **envp,
  * On Windows, in case the environment variable's value contains
  * references to other environment variables, they are expanded.
  *
- * Returns: (type filename): the value of the environment variable, or %NULL if
+ * Returns: the value of the environment variable, or %NULL if
  *     the environment variable is not found. The returned string
  *     may be overwritten by the next call to g_getenv(), g_setenv()
  *     or g_unsetenv().
@@ -244,9 +242,8 @@ g_getenv (const gchar *variable)
 
 /**
  * g_setenv:
- * @variable: (type filename): the environment variable to set, must not
- *     contain '='.
- * @value: (type filename): the value for to set the variable to.
+ * @variable: the environment variable to set, must not contain '='.
+ * @value: the value for to set the variable to.
  * @overwrite: whether to change the variable if it already exists.
  *
  * Sets an environment variable. On UNIX, both the variable's name and
@@ -314,8 +311,7 @@ extern char **environ;
 
 /**
  * g_unsetenv:
- * @variable: (type filename): the environment variable to remove, must
- *     not contain '='
+ * @variable: the environment variable to remove, must not contain '='
  *
  * Removes an environment variable from the environment.
  *
@@ -365,9 +361,8 @@ g_unsetenv (const gchar *variable)
  * use cases for environment variables in GLib-using programs you want
  * the UTF-8 encoding that this function and g_getenv() provide.
  *
- * Returns: (array zero-terminated=1) (element-type filename) (transfer full):
- *     a %NULL-terminated list of strings which must be freed with
- *     g_strfreev().
+ * Returns: (array zero-terminated=1) (transfer full): a %NULL-terminated
+ *     list of strings which must be freed with g_strfreev().
  *
  * Since: 2.8
  */
@@ -407,8 +402,8 @@ g_listenv (void)
  * The return value is freshly allocated and it should be freed with
  * g_strfreev() when it is no longer needed.
  *
- * Returns: (array zero-terminated=1) (element-type filename) (transfer full):
- *     the list of environment variables
+ * Returns: (array zero-terminated=1) (transfer full): the list of
+ *     environment variables
  *
  * Since: 2.28
  */
diff --git a/glib/gshell.c b/glib/gshell.c
index 340a285..2c50af8 100644
--- a/glib/gshell.c
+++ b/glib/gshell.c
@@ -190,7 +190,7 @@ unquote_string_inplace (gchar* str, gchar** end, GError** err)
 
 /**
  * g_shell_quote:
- * @unquoted_string: (type filename): a literal string
+ * @unquoted_string: a literal string
  * 
  * Quotes a string so that the shell (/bin/sh) will interpret the
  * quoted string to mean @unquoted_string. If you pass a filename to
@@ -199,7 +199,7 @@ unquote_string_inplace (gchar* str, gchar** end, GError** err)
  * quoting style used is undefined (single or double quotes may be
  * used).
  * 
- * Returns: (type filename): quoted string
+ * Returns: quoted string
  **/
 gchar*
 g_shell_quote (const gchar *unquoted_string)
@@ -240,7 +240,7 @@ g_shell_quote (const gchar *unquoted_string)
 
 /**
  * g_shell_unquote:
- * @quoted_string: (type filename): shell-quoted string
+ * @quoted_string: shell-quoted string
  * @error: error return location or NULL
  * 
  * Unquotes a string as the shell (/bin/sh) would. Only handles
@@ -265,7 +265,7 @@ g_shell_quote (const gchar *unquoted_string)
  * be escaped with backslash. Otherwise double quotes preserve things
  * literally.
  *
- * Returns: (type filename): an unquoted string
+ * Returns: an unquoted string
  **/
 gchar*
 g_shell_unquote (const gchar *quoted_string,
@@ -618,10 +618,10 @@ tokenize_command_line (const gchar *command_line,
 
 /**
  * g_shell_parse_argv:
- * @command_line: (type filename): command line to parse
+ * @command_line: command line to parse
  * @argcp: (out) (optional): return location for number of args
- * @argvp: (out) (optional) (array length=argcp zero-terminated=1) (element-type filename):
- *   return location for array of args
+ * @argvp: (out) (optional) (array length=argcp zero-terminated=1): return
+ *   location for array of args
  * @error: (optional): return location for error
  * 
  * Parses a command line into an argument vector, in much the same way
diff --git a/glib/gspawn.c b/glib/gspawn.c
index a60ee9b..bf0a268 100644
--- a/glib/gspawn.c
+++ b/glib/gspawn.c
@@ -105,12 +105,9 @@ G_DEFINE_QUARK (g-spawn-exit-error-quark, g_spawn_exit_error)
 
 /**
  * g_spawn_async:
- * @working_directory: (type filename) (allow-none): child's current working
- *     directory, or %NULL to inherit parent's
- * @argv: (array zero-terminated=1) (element-type filename):
- *     child's argument vector
- * @envp: (array zero-terminated=1) (element-type filename) (allow-none):
- *     child's environment, or %NULL to inherit parent's
+ * @working_directory: (type filename) (allow-none): child's current working directory, or %NULL to inherit 
parent's
+ * @argv: (array zero-terminated=1): child's argument vector
+ * @envp: (array zero-terminated=1) (allow-none): child's environment, or %NULL to inherit parent's
  * @flags: flags from #GSpawnFlags
  * @child_setup: (scope async) (allow-none): function to run in the child just before exec()
  * @user_data: (closure): user data for @child_setup
@@ -218,12 +215,9 @@ read_data (GString *str,
 
 /**
  * g_spawn_sync:
- * @working_directory: (type filename) (allow-none): child's current working
- *     directory, or %NULL to inherit parent's
- * @argv: (array zero-terminated=1) (element-type filename):
- *     child's argument vector
- * @envp: (array zero-terminated=1) (element-type filename) (allow-none):
- *     child's environment, or %NULL to inherit parent's
+ * @working_directory: (type filename) (allow-none): child's current working directory, or %NULL to inherit 
parent's
+ * @argv: (array zero-terminated=1): child's argument vector
+ * @envp: (array zero-terminated=1) (allow-none): child's environment, or %NULL to inherit parent's
  * @flags: flags from #GSpawnFlags
  * @child_setup: (scope async) (allow-none): function to run in the child just before exec()
  * @user_data: (closure): user data for @child_setup
@@ -473,13 +467,9 @@ g_spawn_sync (const gchar          *working_directory,
 
 /**
  * g_spawn_async_with_pipes:
- * @working_directory: (type filename) (allow-none): child's current working
- *     directory, or %NULL to inherit parent's, in the GLib file name encoding
- * @argv: (array zero-terminated=1) (element-type filename): child's argument
- *     vector, in the GLib file name encoding
- * @envp: (array zero-terminated=1) (element-type filename) (allow-none):
- *     child's environment, or %NULL to inherit parent's, in the GLib file
- *     name encoding
+ * @working_directory: (type filename) (allow-none): child's current working directory, or %NULL to inherit 
parent's, in the GLib file name encoding
+ * @argv: (array zero-terminated=1): child's argument vector, in the GLib file name encoding
+ * @envp: (array zero-terminated=1) (allow-none): child's environment, or %NULL to inherit parent's, in the 
GLib file name encoding
  * @flags: flags from #GSpawnFlags
  * @child_setup: (scope async) (allow-none): function to run in the child just before exec()
  * @user_data: (closure): user data for @child_setup
@@ -686,7 +676,7 @@ g_spawn_async_with_pipes (const gchar          *working_directory,
 
 /**
  * g_spawn_command_line_sync:
- * @command_line: (type filename): a command line
+ * @command_line: a command line 
  * @standard_output: (out) (array zero-terminated=1) (element-type guint8) (allow-none): return location for 
child output
  * @standard_error: (out) (array zero-terminated=1) (element-type guint8) (allow-none): return location for 
child errors
  * @exit_status: (out) (allow-none): return location for child exit status, as returned by waitpid()
@@ -751,7 +741,7 @@ g_spawn_command_line_sync (const gchar  *command_line,
 
 /**
  * g_spawn_command_line_async:
- * @command_line: (type filename): a command line
+ * @command_line: a command line
  * @error: return location for errors
  * 
  * A simple version of g_spawn_async() that parses a command line with


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]