Atmel CAVR-4 ユーザーズマニュアル
CAVR-4
232
Predefined symbols
AVR® IAR C/C++ Compiler
Reference Guide
_ _IAR_SYSTEMS_ICC_ _
This predefined symbol expands to a number that identifies the IAR compiler platform.
The current identifier is 6. Note that the number could be higher in a future version of
the product.
The current identifier is 6. Note that the number could be higher in a future version of
the product.
This symbol can be tested with
#ifdef
to detect whether the code was compiled by a
compiler from IAR Systems.
_ _ICCAVR_ _
This predefined symbol expands to the number 1 when the code is compiled with the
AVR IAR C/C++ Compiler.
AVR IAR C/C++ Compiler.
_ _LINE_ _
This predefined symbol expands to the current line number of the file currently being
compiled.
compiled.
_ _MEMORY_MODEL_ _
Use this symbol to identify the used memory model.
This symbol expands to a value reflecting the selected memory model according to the
following table:
following table:
NDEBUG
This preprocessor symbol determines whether any assert code you have written in your
application shall be included or not in the built application.
application shall be included or not in the built application.
If the symbol is:
●
defined, the assert code will not be included
●
not defined, the assert code will be included
This means that if you have written any assert code and build your application, you
should define this symbol to exclude the assert code from the application.
should define this symbol to exclude the assert code from the application.
Note that the assert macro is defined in the
assert.h
standard include file.
In IAR Embedded Workbench, the
NDEBUG
symbol is automatically defined if you build
your application in the Release build configuration.
Value
Memory model
1
Tiny
2
Small
3
Large
Table 71: Predefined memory model symbol values