File: callingconvention.c

package info (click to toggle)
sdcc 4.2.0%2Bdfsg-1
  • links: PTS, VCS
  • area: main
  • in suites: bookworm
  • size: 105,232 kB
  • sloc: ansic: 956,095; cpp: 110,511; makefile: 59,314; sh: 29,875; asm: 17,178; perl: 12,136; yacc: 7,480; lisp: 1,672; python: 907; lex: 805; awk: 498; sed: 89
file content (66 lines) | stat: -rw-r--r-- 1,257 bytes parent folder | download | duplicates (3)
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
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66

#if defined(__SDCC) && defined(__has_sdcccall)
#define SDCCCALL0  __sdcccall(0)
#define SDCCCALL1  __sdcccall(1)
#else
#define SDCCCALL0
#define SDCCCALL1
#endif

#if defined(__SDCC) && defined(__has_z88dk_fastcall)
#define Z88DK_FASTCALL  __z88dk_fastcall
#else
#define Z88DK_FASTCALL
#endif

#if defined(__SDCC) && defined(__has_raisonance)
#define RAISONANCE  __raisonance
#else
#define RAISONANCE
#endif

#ifdef TEST1
int f(int i) SDCCCALL0;        /* IGNORE */
int f(int i) SDCCCALL1 {       /* ERROR(__has_sdcccall) */
  return i;
}
#endif

#ifdef TEST2
int f(int i) SDCCCALL1;        /* IGNORE */
int f(int i) SDCCCALL0 {       /* ERROR(__has_sdcccall) */

  return i;
}
#endif

#ifdef TEST3
int f(int i) Z88DK_FASTCALL;   /* IGNORE */
int f(int i) {                 /* ERROR(__has_z88dk_fastcall) */
  return i;
}
#endif

#ifdef TEST4
int f(int i);                  /* IGNORE */
int f(int i) Z88DK_FASTCALL {  /* ERROR(__has_z88dk_fastcall) */

  return i;
}
#endif

#ifdef TEST5
int f(int i) RAISONANCE;       /* IGNORE */
int f(int i) {                 /* ERROR(__has_raisonance) */
  return i;
}
#endif

#ifdef TEST6
int f(int i);                  /* IGNORE */
int f(int i) RAISONANCE {      /* ERROR(__has_raisonance) */

  return i;
}
#endif