Pick three bugfixes from next branch to trunk for inclusion in 4.5.0 RC2, as discusse...
[sdcc.git] / sdcc / support / regression / tests / bug1253.c
blob84d9c51da17a2e155bbdf83a35abfec0c8962c80
1 /* Bug 1253, was bug 1609244
2 */
4 #include <testfwk.h>
6 typedef char * PCHAR;
8 char KAR;
10 // bug.c:7: warning 60: function return value mismatch from type 'char near* '
11 // to type 'char generic* unknown type'
12 // bug.c:5: warning 59: function 'foo' must return value
14 PCHAR foo(void) __reentrant //this fails
16 return &KAR;
19 PCHAR bar(void) // this is ok
21 return &KAR;
24 void
25 testBug(void)
27 ASSERT(foo() == bar());