Clarified/added docs for G_STRINGIFY, G_PASTE and G_STATIC_ASSERT, based

2008-10-29 16:04:38  Tim Janik  <timj@gtk.org>

        * glib/tmpl/macros_misc.sgml: Clarified/added docs for
        G_STRINGIFY, G_PASTE and G_STATIC_ASSERT, based on
        patches from Christian Persch and  Christian Dywan.


svn path=/trunk/; revision=7634
This commit is contained in:
16:04:38 Tim Janik 2008-10-29 15:14:29 +00:00 committed by Tim Janik
parent 0ffa76b9e9
commit b54e0af92f
2 changed files with 31 additions and 1 deletions

View File

@ -1,3 +1,9 @@
2008-10-29 16:04:38 Tim Janik <timj@gtk.org>
* glib/tmpl/macros_misc.sgml: Clarified/added docs for
G_STRINGIFY, G_PASTE and G_STATIC_ASSERT, based on
patches from Christian Persch and Christian Dywan.
2008-10-21 Alexander Larsson <alexl@redhat.com>
* gio/gio-sections.txt:

View File

@ -96,12 +96,36 @@ does not include <function>string.h</function> for you.
<!-- ##### MACRO G_STRINGIFY ##### -->
<para>
Accepts a macro or a string and converts it into a string.
Accepts a macro or a string and converts it into a string after
preprocessor argument expansion.
</para>
@macro_or_string: a macro or a string.
<!-- ##### MACRO G_PASTE ##### -->
<para>
Yields a new preprocessor pasted identifier 'identifier1identifier2'
from its expanded arguments 'identifier1' and 'identifier2'.
</para>
@identifier1: an identifier
@identifier2: an identifier
@Since: 2.20
<!-- ##### MACRO G_STATIC_ASSERT ##### -->
<para>
The G_STATIC_ASSERT macro lets the programmer check a condition at compile time,
the condition needs to be compile time computable.
The macro can be used in any place where a <literal>typedef</literal> is valid.
The macro should only be used once per source code line.
</para>
@expr: a constant expression.
@Since: 2.20
<!-- ##### MACRO G_GNUC_EXTENSION ##### -->
<para>
Expands to <literal>__extension__</literal> when <command>gcc</command> is