Hello,

if you are using gint32, gint16, and the like, it’s super easy.

gint8: 0x7f guint8: 0xff
gint16: 0x7fff guint16: 0xffff
gint32: 0x7fffffff guint32: 0xffffffff

However, GLib defines such constants:
G_MAXINT and G_MAXUINT for platform-specific types gint and guint.
Personally I don’t like to use them as their size is not always predictable.

G_MAXINT8, G_MAXUINT8
G_MAXINT16, G_MAXUINT16
G_MAXINT32, G_MAXUINT32

Happy coding!

Gergely
On Mon, Aug 21, 2017, 19:43 Igor Korot <ikoro...@gmail.com> wrote:

>  Hi,
> Is there a constant in GTK library that defines the maximum integer value
> one
> can assign to int variable?
>
> Something like "INT_MAX"?
> I just need a very big number for comparison...
>
> Thank you.
> _______________________________________________
> gtk-list mailing list
> gtk-list@gnome.org
> https://mail.gnome.org/mailman/listinfo/gtk-list
>
_______________________________________________
gtk-list mailing list
gtk-list@gnome.org
https://mail.gnome.org/mailman/listinfo/gtk-list

Reply via email to