Pick three bugfixes from next branch to trunk for inclusion in 4.5.0 RC2, as discusse...
[sdcc.git] / sdcc / support / regression / tests / bug-3254.c
blob1b6f2a56d33d8d1a204d48c03a32c5f5568fdaac
1 /*
2 bug-3254.c. A bug in _Generic handling of implicitly assigned intrinsic named address spaces.
3 */
5 #include <testfwk.h>
7 int i;
9 void f(void)
11 i = _Generic(&i, int * : 1, long * : 2); // Failed to compile this line due to &i being __near int *.
15 void testBug(void)
17 f();
18 ASSERT(i == 1);