On Wed, 30 Dec 2009 07:51:01 +0100 (CET)
Vincent Torri <vto...@univ-evry.fr> wrote:

> 
> 
> On Wed, 30 Dec 2009, Vincent Torri wrote:
> 
> >
> >
> > On Wed, 30 Dec 2009, Gustavo Sverzut Barbieri wrote:
> >
> >> On Wed, Dec 30, 2009 at 12:07 AM, Enlightenment SVN
> >> <no-re...@enlightenment.org> wrote:
> >>> Log:
> >>>  Fix printing of size_t value(s). (removes compiler warning).
> >> 
> >> They invented "z" modifier for that, see "man 3 printf"
> 
> it is also a gnu extension:
> 
> http://swoolley.org/man.cgi/3/printf
> 
> "glibc 2.1 adds length modifiers hh,j,t,z and conversion characters
> a,A."

%z is part of C99.
So for C99 it's %zi of %zd.

C99 also has the PRIx macros for printing all integer types safely.

Unfortunately there is no safe way of printing it in C89 (ie windows).
The best way is:
        printf("... %ld..",(unsigned int)blah);

        Regards,
        nash

------------------------------------------------------------------------------
This SF.Net email is sponsored by the Verizon Developer Community
Take advantage of Verizon's best-in-class app development support
A streamlined, 14 day to market process makes app distribution fast and easy
Join now and get one step closer to millions of Verizon customers
http://p.sf.net/sfu/verizon-dev2dev 
_______________________________________________
enlightenment-devel mailing list
enlightenment-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/enlightenment-devel

Reply via email to