44 #define AFF_REPRTEST_CC_VERSION \ 45 "AFF_REPRTEST_CC V1.3" 86 CODE(
const int N=10; )
87 CODE(
const int N2=23; )
93 #warning intentionally compiling senseless code
99 section(
"create a const reference to D");
102 section(
"const int array should share memory with int array");
106 CODE(
for (
int i=0; i<N; i++) { A[i]=(i+1)*10; } )
107 CODE(
for (
int i=0; i<N2; i++) { B[i]=(i+4)*3; } )
108 CODE(
for (
int i=0; i<N2; i++) { D[i]=(i+2.45)*2; } )
110 section(
"dump contents - C is filled through B and E is filled through D");
122 section(
"modify C directly - is illegal");
127 section(
"make B a reference to A");
129 section(
"modification should be visible through B");
132 section(
"but C holds the original values");
int main()
testing SharedHeap
#define DUMP(A)
Dump any object through its dump function.
A template class to share heap memory for different array projections.
#define CODE(C)
Dump code and execute (works like echo)
void section(const char *s)
print headline
shared heap representation (prototypes)
#define AFF_REPRTEST_CC_VERSION
This is the base class for const elements.
debug helpers (prototypes)