How to restore section name to default? (CC-RL)
Question:
I am using the RL78 CC-RL compiler.
I have changed a section name using #pragma section to allocate a variable in an arbitrary section.
Is there any way to restore the variable section defined after that to a default section name?
[example]
#pragma section bss MyBss
int __near ni_1; //MyBss_n Allocated a variable in a section
int __near ni_2; //Want to restore the variable to the section
Answer:
Section names can be restored to default if a section type and new section name are not specified and #pragma section is specified instead.
[example]
#pragma section bss MyBss
int __near ni_1; //MyBss_n Allocated in a section
#pragma section
int __near ni_2; //.bss Allocated to the section
e² studio |
CS+ (formerly CubeSuite+) |
C Compiler Package for RL78 Family |