Everything
A.8 Modification of C Source

By using expanded function object with high efficiency can be created.

Here, two methods are described for shifting to the CCRX from other C compiler and shifting to C compiler from the CCRX.

<From other C compiler to the CCRX>

-

#pragma

C source needs to be modified, when C compiler supports the #pragma. Modification methods are examined according to the C compiler specifications.

-

Expanded Specifications

It should be modified when other C compilers are expanding the specifications such as adding keywords etc. Modified methods are examined according to the C compiler specifications.

Note

#pragma is one of the pre-processing directives supported by ANSI. The character string next to #pragma is made to be recognized as directives to C compiler. If that directive does not supported by the compiler, #pragma directive is ignored and the compiler continues the process and ends normally.

<From the CCRX to other C compiler>

-

The CCRX, either deletes key word or divides # fdef in order shift to other C compiler as key word has been added as expanded function.

Example 1.

Disable the keywords

#ifndef __RX

#define interrupt /*Considered interrupt function as normal function*/

#endif

Example 2.

Change to other type

#ifdef __RX

#define bit char /*Change bit type variable to char type variable*/

#endif