Where are the limits for Qt types?

前端 未结 2 1170
借酒劲吻你
借酒劲吻你 2021-01-17 11:07

Regularly, I could reference limits.h to see what the max is for a certain type, like an int or long.

In Qt, there are types like qlonglong. Is there a header file

2条回答
  •  不知归路
    2021-01-17 11:32

    Take a look at the QtGlobal documentation.

    For some of the non-obvious ones:
    qlonglong - 64-bit
    qptrdiff - 32-bit or 64-bit depending on platform
    qreal - double (float on ARM architectures)
    quintptr - unsigned 32-bit or 64-bit depending on platform
    qulonglong - unsigned 64-bit
    uchar, uint, ulong, ushort - convenience shorthand for unsigned types

提交回复
热议问题