English
Language : 

CC78K0S Datasheet, PDF (383/520 Pages) NEC – C Compiler Ver.1.30 or Later Language
CHAPTER 11 EXTENDED FUNCTIONS
Rotate Function
#pragma rot
• Declare the use of the function for rotate by the #pragma rot directive of the module.
However, the following items can be described before #pragma rot.
• Comments
• Other #pragma directives
• Preprocessing directives that neither define nor reference variables or functions
• Keywords following #pragma can be described in either uppercase or lowercase letters.
EXAMPLE
(C source)
#pragma rot
unsigned char a = 0x11 ;
unsigned char b = 2 ;
unsigned char c ;
void main ( ) {
c = rorb(a, b) ;
}
(Output assembler source)
mov
mov
mov
ror
dbnz
mov
a,!_b
c,a
a,!_a
a, 1
c,$$-1
!_c,a
RESTRICTIONS
• The function names for rotate cannot be used as function names.
• The function names for rotate must be described in lowercase letters. If the functions for rotate are described
in uppercase letters, they are handled as ordinary functions.
User’s Manual U14872EJ1V0UM
383