English
Language : 

CC78K0S Datasheet, PDF (372/520 Pages) NEC – C Compiler Ver.1.30 or Later Language
CHAPTER 11 EXTENDED FUNCTIONS
#pragma section…
#pragma section…
Restrictions when this #pragma directive has been specified after the main C code are explained in the following
coding error examples.
CODING ERROR EXAMPLE 1
a1.h
#pragma section @@DATA ??DATA1 // File containing only the #pragma section
a2.h
extern int func1 (void);
#pragma section @@DATA ??DATA2
// File containing the main C code followed by the #pragma
// directive
a3.h
#pragma section @@DATA ??DATA3 // File containing only the #pragma section.
a4.h
#pragma section @@DATA ??DATA3
extern int func2 (void);
// File that includes the main C code.
a.c
#include "a1.h"
#include "a2.h"
#include "a3.h"
#include "a4.h"
// ← Results in an error.
// Because the a2.h file contains the main C code followed by this
// #pragma directive, file a3.h, which includes only this #pragma
// directive, cannot be included.
372
User’s Manual U14872EJ1V0UM