HighCommander4 wrote: > `FlagConfigProvider` is pushed in the vector after `.clangd` config in > [CLangdMain.cpp](https://github.com/llvm/llvm-project/blob/a4586bd2d4fa7d6c0100893496a9383fd581e2e9/clang-tools-extra/clangd/tool/ClangdMain.cpp#L926) > Then > [ConfigProvider.cpp](https://github.com/llvm/llvm-project/blob/5ac97d397c2088c3ac0a113506e57ab9b1e69ac8/clang-tools-extra/clangd/ConfigProvider.cpp#L154) > just iterates over it, which means that `FlagConfigProvider` is evaluated > **after** `.clangd` and will override it!
Thanks for catching that; I was under the mistaken impression that it was the other way around! I think it would be a nicer user experience if the config file took precedence over compile flags... but since that's not the case today for existing flags (like `--background-index`), I think it's appropriate for this patch to remain consistent with the existing behaviour. In other words, I think what the current version of the patch is doing is fine. https://github.com/llvm/llvm-project/pull/108005 _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits