Unity build breaks C without extensions
With CMake 3.27, a fix for #24857 (closed) has been introduced: During Unity builds, CMake now inserts the following line into CMake-generated C files:
// NOLINTNEXTLINE(bugprone-suspicious-include)
Unfortunately, this breaks the compilation if C extensions are off in gcc using set(CMAKE_C_EXTENSIONS OFF)
:
unity_0_c.c:3:1: error: C++ style comments are not allowed in ISO C90
3 | // NOLINTNEXTLINE(bugprone-suspicious-include)
| ^
Thanks