summaryrefslogtreecommitdiff
path: root/support/regression/tests/bug-1805702.c
blob: fe64361861640be32daf61d71cc5bda748ca068c (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
/* bug-1805702.c
 */

#include <testfwk.h>

int foo;
extern int foo;

void
test(void)
{
#if !defined(__SDCC_pdk14) // Not enough RAM
  foo = 10;

  ASSERT(foo == 10);
#endif
}

#if !defined(__SDCC_pdk14) // Not enough RAM
/* compile time check for compiler defined functions (cdef) */

#ifndef __SDCC_mcs51
#define __nonbanked
#endif

float __fsdiv (float, float) __nonbanked;

float __fsdiv (float a1, float a2) __nonbanked {
  /* just for testing... */
  return (a1 + a2);
}
#endif