fork download
  1. #include <stdio.h>
  2.  
  3. #ifdef DEBUG
  4. #define CHECK(expr) foo(expr)
  5. #else
  6. #define CHECK(expr) (void)(expr)
  7. #endif /* DEBUG */
  8.  
  9. int bar (int x, int y, int z)
  10. {
  11. //do nothing
  12. return 0;
  13. }
  14.  
  15. int main(void)
  16. {
  17. int a= 0, b = 0, c = 0;
  18. int x = bar(a, b, c); /* bar has to be called for both DEBUG begin defined and undefined */
  19. CHECK(x);
  20. printf("Hello, world!\n");
  21. return 0;
  22. }
  23.  
Success #stdin #stdout 0s 2112KB
stdin
Standard input is empty
stdout
Hello, world!