mirror of
https://gitlab.gnome.org/GNOME/glib.git
synced 2025-02-08 03:45:49 +01:00
for G_CAN_INLINE environments, inline g_string_append_c() for efficiency.
Thu Feb 19 18:40:01 2004 Tim Janik <timj@gtk.org> * glib/gstring.[hc]: for G_CAN_INLINE environments, inline g_string_append_c() for efficiency. (vaguely based on #118707).
This commit is contained in:
parent
ca87afd2e1
commit
c0930e2c71
@ -1,3 +1,8 @@
|
||||
Thu Feb 19 18:40:01 2004 Tim Janik <timj@gtk.org>
|
||||
|
||||
* glib/gstring.[hc]: for G_CAN_INLINE environments, inline
|
||||
g_string_append_c() for efficiency. (vaguely based on #118707).
|
||||
|
||||
Wed Feb 18 23:57:42 2004 Matthias Clasen <maclas@gmx.de>
|
||||
|
||||
* glib/gmain.c: Include signal.h for SIGCHLD. (#134622, Damien
|
||||
|
@ -1,3 +1,8 @@
|
||||
Thu Feb 19 18:40:01 2004 Tim Janik <timj@gtk.org>
|
||||
|
||||
* glib/gstring.[hc]: for G_CAN_INLINE environments, inline
|
||||
g_string_append_c() for efficiency. (vaguely based on #118707).
|
||||
|
||||
Wed Feb 18 23:57:42 2004 Matthias Clasen <maclas@gmx.de>
|
||||
|
||||
* glib/gmain.c: Include signal.h for SIGCHLD. (#134622, Damien
|
||||
|
@ -1,3 +1,8 @@
|
||||
Thu Feb 19 18:40:01 2004 Tim Janik <timj@gtk.org>
|
||||
|
||||
* glib/gstring.[hc]: for G_CAN_INLINE environments, inline
|
||||
g_string_append_c() for efficiency. (vaguely based on #118707).
|
||||
|
||||
Wed Feb 18 23:57:42 2004 Matthias Clasen <maclas@gmx.de>
|
||||
|
||||
* glib/gmain.c: Include signal.h for SIGCHLD. (#134622, Damien
|
||||
|
@ -1,3 +1,8 @@
|
||||
Thu Feb 19 18:40:01 2004 Tim Janik <timj@gtk.org>
|
||||
|
||||
* glib/gstring.[hc]: for G_CAN_INLINE environments, inline
|
||||
g_string_append_c() for efficiency. (vaguely based on #118707).
|
||||
|
||||
Wed Feb 18 23:57:42 2004 Matthias Clasen <maclas@gmx.de>
|
||||
|
||||
* glib/gmain.c: Include signal.h for SIGCHLD. (#134622, Damien
|
||||
|
@ -1,3 +1,8 @@
|
||||
Thu Feb 19 18:40:01 2004 Tim Janik <timj@gtk.org>
|
||||
|
||||
* glib/gstring.[hc]: for G_CAN_INLINE environments, inline
|
||||
g_string_append_c() for efficiency. (vaguely based on #118707).
|
||||
|
||||
Wed Feb 18 23:57:42 2004 Matthias Clasen <maclas@gmx.de>
|
||||
|
||||
* glib/gmain.c: Include signal.h for SIGCHLD. (#134622, Damien
|
||||
|
@ -1,3 +1,8 @@
|
||||
Thu Feb 19 18:40:01 2004 Tim Janik <timj@gtk.org>
|
||||
|
||||
* glib/gstring.[hc]: for G_CAN_INLINE environments, inline
|
||||
g_string_append_c() for efficiency. (vaguely based on #118707).
|
||||
|
||||
Wed Feb 18 23:57:42 2004 Matthias Clasen <maclas@gmx.de>
|
||||
|
||||
* glib/gmain.c: Include signal.h for SIGCHLD. (#134622, Damien
|
||||
|
@ -107,6 +107,17 @@ This string should be freed when no longer needed.
|
||||
not be changed.
|
||||
|
||||
|
||||
<!-- ##### FUNCTION g_completion_complete_utf8 ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@cmp:
|
||||
@prefix:
|
||||
@new_prefix:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION g_completion_set_compare ##### -->
|
||||
<para>
|
||||
Sets the function to use for string comparisons. The default
|
||||
|
@ -585,6 +585,55 @@ for the default main context.
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### TYPEDEF GPid ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
|
||||
<!-- ##### USER_FUNCTION GChildWatchFunc ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@pid:
|
||||
@status:
|
||||
@data:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION g_child_watch_source_new ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@pid:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION g_child_watch_add ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@pid:
|
||||
@function:
|
||||
@data:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION g_child_watch_add_full ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@priority:
|
||||
@pid:
|
||||
@function:
|
||||
@data:
|
||||
@notify:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### STRUCT GPollFD ##### -->
|
||||
<para>
|
||||
|
||||
|
@ -515,6 +515,7 @@ g_string_append_len (GString *string,
|
||||
return g_string_insert_len (string, -1, val, len);
|
||||
}
|
||||
|
||||
#undef g_string_append_c
|
||||
GString*
|
||||
g_string_append_c (GString *string,
|
||||
gchar c)
|
||||
|
@ -29,6 +29,7 @@
|
||||
|
||||
#include <glib/gtypes.h>
|
||||
#include <glib/gunicode.h>
|
||||
#include <glib/gutils.h> /* for G_CAN_INLINE */
|
||||
|
||||
G_BEGIN_DECLS
|
||||
|
||||
@ -115,6 +116,25 @@ void g_string_append_printf (GString *string,
|
||||
const gchar *format,
|
||||
...) G_GNUC_PRINTF (2, 3);
|
||||
|
||||
/* -- optimize g_strig_append_c --- */
|
||||
#ifdef G_CAN_INLINE
|
||||
static inline GString*
|
||||
g_string_append_c_inline (GString *gstring,
|
||||
gchar c)
|
||||
{
|
||||
if (gstring->len < gstring->allocated_len && 0)
|
||||
{
|
||||
gstring->str[gstring->len++] = c;
|
||||
gstring->str[gstring->len] = 0;
|
||||
}
|
||||
else
|
||||
g_string_insert_c (gstring, -1, c);
|
||||
return gstring;
|
||||
}
|
||||
#define g_string_append_c(gstr,c) g_string_append_c_inline (gstr, c)
|
||||
#endif /* G_CAN_INLINE */
|
||||
|
||||
|
||||
#ifndef G_DISABLE_DEPRECATED
|
||||
|
||||
/* The following two functions are deprecated and will be removed in
|
||||
|
Loading…
x
Reference in New Issue
Block a user