Bug 72100: added macros for the maximum and minimum values of PRInt8,

PRUint8, PRInt16, PRUint16, PRInt32, and PRUint32. r=jkeiser.
This commit is contained in:
wtc%netscape.com 2002-09-18 14:23:46 +00:00
Родитель 8413e578a9
Коммит da4baffe07
1 изменённых файлов: 36 добавлений и 0 удалений

Просмотреть файл

@ -279,6 +279,18 @@ typedef signed char PRInt8;
#error No suitable type for PRInt8/PRUint8
#endif
/************************************************************************
* MACROS: PR_INT8_MAX
* PR_INT8_MIN
* PR_UINT8_MAX
* DESCRIPTION:
* The maximum and minimum values of a PRInt8 or PRUint8.
************************************************************************/
#define PR_INT8_MAX 127
#define PR_INT8_MIN (-128)
#define PR_UINT8_MAX 255U
/************************************************************************
** TYPES: PRUint16
** PRInt16
@ -292,6 +304,18 @@ typedef short PRInt16;
#error No suitable type for PRInt16/PRUint16
#endif
/************************************************************************
* MACROS: PR_INT16_MAX
* PR_INT16_MIN
* PR_UINT16_MAX
* DESCRIPTION:
* The maximum and minimum values of a PRInt16 or PRUint16.
************************************************************************/
#define PR_INT16_MAX 32767
#define PR_INT16_MIN (-32768)
#define PR_UINT16_MAX 65535U
/************************************************************************
** TYPES: PRUint32
** PRInt32
@ -312,6 +336,18 @@ typedef long PRInt32;
#error No suitable type for PRInt32/PRUint32
#endif
/************************************************************************
* MACROS: PR_INT32_MAX
* PR_INT32_MIN
* PR_UINT32_MAX
* DESCRIPTION:
* The maximum and minimum values of a PRInt32 or PRUint32.
************************************************************************/
#define PR_INT32_MAX PR_INT32(2147483647)
#define PR_INT32_MIN (-PR_INT32_MAX - 1)
#define PR_UINT32_MAX PR_UINT32(4294967295)
/************************************************************************
** TYPES: PRUint64
** PRInt64