atilaneves/cmake-ide

Error from syntax checker c/c++-clang: Undefined error level: nil

CyberShadow opened this issue · 1 comments

Any idea what could cause this or how to debug it?

Got it. In my CMakeLists.txt, following the advice from https://github.com/ninja-build/ninja/wiki/FAQ , I added:

# Enable color output (for e.g. with the Ninja generator, which redirects stdout/stderr)
add_compile_options(-fcolor-diagnostics)

That broke Flycheck's output parsing, as it prepends -fno-color-diagnostics instead of appending.

This could be fixed in Flycheck, or worked around here by stripping that flag, but really this is mostly me shooting myself in the foot.