include-warnings.c 814 B

123456789101112131415161718192021
  1. /*
  2. TEST_BUILD
  3. $C{COMPILE} $DIR/include-warnings.c -o include-warnings.exe -Wsystem-headers -Weverything -Wno-undef -Wno-old-style-cast -Wno-nullability-extension -Wno-c++98-compat 2>&1 | grep -v 'In file' | grep objc || true
  4. END
  5. TEST_RUN_OUTPUT
  6. OK: includes.c
  7. END
  8. */
  9. // Detect warnings inside any header.
  10. // The build command above filters out warnings inside non-objc headers
  11. // (which are noisy with -Weverything).
  12. // -Wno-undef suppresses warnings about `#if __cplusplus` and the like.
  13. // -Wno-old-style-cast is tough to avoid in mixed C/C++ code.
  14. // -Wno-nullability-extension disables a warning about non-portable
  15. // _Nullable etc which we already handle correctly in objc-abi.h.
  16. // -Wno-c++98-compat disables warnings about things that already
  17. // have guards against C++98.
  18. #include "includes.c"