gstrfuncs: Add a string formatting note about using G_GUINT64_FORMAT

…and friends. The ‘String precision pitfalls’ section is already linked
to from all the relevant printf()-style functions, so this documentation
should hopefully be easy to find.

https://bugzilla.gnome.org/show_bug.cgi?id=741779
This commit is contained in:
Philip Withnall 2015-03-04 11:37:40 +00:00
parent 8c858a018d
commit 5ee333e4cb

View File

@ -84,6 +84,13 @@
* certain number of columns, then \%Ns is not a correct solution
* anyway, since it fails to take wide characters (see g_unichar_iswide())
* into account.
*
* Note also that there are various printf() parameters which are platform
* dependent. GLib provides platform independent macros for these parameters
* which should be used instead. A common example is %G_GUINT64_FORMAT, which
* should be used instead of `%llu` or similar parameters for formatting
* 64-bit integers. These macros are all named `G_*_FORMAT`; see
* [Basic Types][glib-Basic-Types].
*/
/**