User manual
140
mikoC PRO for dsPIC
MikroElektronika
ANSI Standard Issues
Divergence from the ANSI C Standard
The mikroC PRO for dsPIC30/33 and PIC24 diverges from the ANSI C standard in a few areas. Some of these
modications are improvements intended to facilitate dsPIC programming, while others are the result of dsPIC30/33
and PIC24 hardware limitations.
- Case Sensitivity. Check identiers
- The mikroC PRO for dsPIC30/33 and PIC24 treats identiers declared with the const qualier as “true
constants” (C++ style). This allows using const objects in places where ANSI C expects a constant
expression. If aiming at portability, use the traditional preprocessor dened constants. See Type Qualiers
and Constants.
- The mikroC PRO for dsPIC30/33 and PIC24 allows C++ style single–line comments using two adjacent
slashes (//). The comment can start at any position and extends until the next new line. See Comments.
- A number of standard C libraries (ctype, math, stdlib, string) have been implemented; check the individual
functions for divergence.
- The mikroC PRO for dsPIC30/33 and PIC24 does not provide automatic initialization for objects.
Uninitialized globals and objects with static duration will take random values from memory.
- Anonymous unions and structures are now supported.
C Language Extensions
mikroC PRO for dsPIC30/33 and PIC24 has additional set of keywords that do not belong to the ANSI standard C
language keywords:
- code
- data
- rx
- sfr
- xdata
- ydata
- dma
- near
- far
- at
- sbit
- bit
- iv
Implementation-dened Behavior
Certain sections of the ANSI standard have implementation-dened behavior. This means that the exact behavior of
some C code can vary from compiler to compiler. This Help contains the sections describing how the mikroC PRO for
dsPIC30/33 and PIC24 compiler behaves in such situations.
The most notable specics include:
- Storage Classes
- Bit Fields
Related topics: Keywords, dsPIC30/33 and PIC24 Specics