On 13-08-19 10:33 AM, Dimitar Zhekov wrote:
On Sun, 18 Aug 2013 03:56:01 -0700
Matthew Brush <mbr...@codebrainz.ca> wrote:

My concern here with stdint.h was that if CHAR_BIT > 8 then C99 forbids
an implementation from defining int8_t and if int8_t isn't defined then
uint8_t can't be defined.  And if this is true [citation needed], and
you couldn't rely on (u)int8_t, then might as well just stick to
portable GLib typedefs.

In POSIX and Windows, CHAR_BIT is always 8, and we don't really support
anything else.

CHAR_BIT may be > 8 if the system can not address 8-bit values, but in
that case, no 8-bit integer type will exist, and GLib will be unable to
define a gint8 either. Which is not a problem, since GLib (as of 2.37)
supports only G_OS_BEOS, G_OS_UNIX and G_OS_WIN32...


Thanks for the info, good to know!

I'm still +1 for using the standard types over the weird G* types, but I'll stop annoying everyone about it if others like them (for reasons I didn't understand). Maybe I'll ask again about it maybe once we're ready to switch to C11 in a decade or so :)

Cheers,
Matthew Brush

_______________________________________________
Devel mailing list
Devel@lists.geany.org
https://lists.geany.org/cgi-bin/mailman/listinfo/devel

Reply via email to