llvm/test/tools/llvm-cov/Inputs/mcdc-macro.c
raw| 1 | #define C c |
| 2 | #define D 1 |
| 3 | #define E (C != a) && (C > a) |
| 4 | #define F E |
| 5 | |
| 6 | void __attribute__((noinline)) func1(void) { return; } |
| 7 | |
| 8 | void __attribute__((noinline)) func(int a, int b, int c) { |
| 9 | if (a && D && E || b) |
| 10 | func1(); |
| 11 | if (b && D) |
| 12 | func1(); |
| 13 | if (a && (b && C) || (D && F)) |
| 14 | func1(); |
| 15 | } |
| 16 | |
| 17 | int main() { |
| 18 | func(2, 3, 3); |
| 19 | return 0; |
| 20 | } |