24.3 Data Type
Some compilers allow use of the boolean type,
bool
, as
well as associated values true
and false
, as specified by
the C99 ANSI Standard. This type and these values may be used by all MPLAB XC compilers
when in compatibility mode(1), as shown in the table below.As indicated by the ANSI Standard, the <stdbool.h>
header must be included for this feature to work as expected when it is used with MPLAB XC
compilers.
IAR Compatibility Mode | |||
---|---|---|---|
Type | XC8 | XC16 | XC32 |
bool | support | support | support |
Do not confuse the boolean type, bool
, and the integer
type, bit
, implemented by MPLAB XC8.
1
Not all C99 features have been adopted by all Microchip MPLAB XC compilers.