User manual

UM0036 Project creation and build
Doc ID 7705 Rev 11 103/385
Figure 67. Cosmic C language view
In this tab view, you can choose from the C language options described in Tabl e 35.
Table 35. Cosmic C compiler language options
Option
(1)
Description
Don’t make public symbols with
absolute addresses (-gna)
Do not produce an xdef directive for the equate names
created for each C object declared with an absolute address.
Enforce Type Checking
(+strict)
Instructs the compiler to enforce stronger type checking.
Enforce Prototyping for
Functions (-pp)
Enforces prototype declaration for functions. An error message
is issued if a function is used and no prototype declaration is
found for it.
Don’t replace a const object by
its value (-pnc)
Instructs the compiler to store const objects as variables.
Allow Pointer Narrowing (-pnp)
Allow pointer narrowing. By default, the compiler refuses to cast
the pointer into any smaller object.
Fill bitfields from MSB to LSB
(-prb)
Reverse the bitfield fill order. By default, bitfields are filled from
least significant bit (LSB) to most significant bit (MSB). If this
option is specified, bitfields are filled from the MSB to the LSB.
Don’t reorder local variables
(-ps)
Do not reorder local variables. By default, the compiler sorts the
local variables of a function and stores the most used variables
as close as possible to the frame pointer in order to shorten
addressing modes for those variables.
Enforce Strict ANSI Checking
(-psa)
Enforce a strict ANSI checking by rejecting any syntax or
semantic extension. This disables the enum size optimization
(-pne).