mikroC

mikroC - C Compiler for Microchip PIC microcontrollers

making it simple...

mikroC SPECIFICS

ANSI Standard Issues

Divergence from the ANSI C Standard

mikroC diverges from the ANSI C standard in few areas. Some of these modifications are improvements intenteded to facilitate PIC programming, while others are result of PICmicro hardware limitations:

Function cross-calling and recursion are unsupported due to the PIC’s limitations of no easily-usable stack and limited memory.

Pointers to variables and pointers to constants are not compatible, i.e. no assigning or comparison is possible between the two.

Function calls from within interrupts are a special case. See Interrupts.

mikroC treats identifiers declared with const qualifier as “true constants” (C++ style). This allows using const objects in places where ANSI C would expect a constant expression. If aiming at portability, use the traditional preprocessor defined constants. See Type Qualifiers and Constants.

Tags scope is specific. Due to separate name space, tags are virtually removed from normal scope rules: they have file scope, but override any block rules.

Ellipsis (...) in formal argument lists is unsupported.

mikroC allows C++ style single–line comments using two adjacent slashes (//).

Features under construction: pointers to functions, and anonymous structures.

Implementation-defined Behavior

Certain sections of the ANSI standard have implementation-defined behavior. This means that the exact behavior of some C code can vary from compiler to compiler. Throughout the help are sections describing how the mikroC compiler behaves in such situations. The most notable specifics include: Floating-point Types, Storage Classes, and Bit Fields.

page

 

32

MikroElektronika: Development tools - Books - Compilers