Pragma Sections

Cosmic uses the #pragma section syntax, while this compiler employs either #pragma DATA_SEG or #pragma CONST_SEG or another example (for the data section):

Listing: <codeph>#pragma DATA_SEG</codeph>


#ifdef __MWERKS__

#pragma DATA_SEG APPLDATA_SEG

#else

#pragma section {APPLDATA}

#endif
Listing: <codeph>#pragma CONST_SEG</codeph>


#ifdef __MWERKS__

#pragma CONST_SEG CONSTVECT_SEG

#else

#pragma section const {CONSTVECT}

#endif

Do not forget to use the segments (in the examples above CONSTVECT_SEG and APPLDATA_SEG) in the linker *.prm file in the PLACEMENT block.