struct / union in initializer, RFE #901.
[sdcc.git] / sdcc / support / regression / tests / bug-2629.c
blob3122b73caaa15b6092054037a28c24b5790bd633
1 /*
2 bug-3240.c. A problem in the interaction between pointers to __code (implicit in this case) and plain pointers resulted in a false error.
3 */
5 #include <testfwk.h>
7 #pragma disable_warning 283
9 const char *const data[] = {"a", "b", "c"};
11 char ptrs(const char *const * ptr);
13 void ptrs1()
15 ptrs(data); // False error on about incompatible types this line
18 void testBug(void)
20 ptrs1();
21 ASSERT (ptrs(data) == 'b');
24 char ptrs(const char *const * ptr)
26 return ptr[1][0];