A Gcc configuration of Emacs emits -fstrict-flex-arrays but
clangd doesn't understand that. This causes spurious errors of
"unknown flag" that prevent analysis. So tweak .clangd to the
nearest clang equivalent (which is very similar).
* .clangd (CompileFlags): Remove -fstrict-flex-arrays, add
-fstrict-flex-arrays=3.
(cherry picked from commit
9df2074a06fefa0b5bfe9714b45c383fa45d6650)
If:
PathMatch: "src/*.c"
CompileFlags:
- Add: [-Wno-unused-macros, -include=config.h]
+ Add: [-Wno-unused-macros, -include=config.h, -fstrict-flex-arrays=3]
+ Remove: [-fstrict-flex-arrays]