21
Plugins development / Re: Code completion using LSP and clangd
« Last post by blauzahn on May 13, 2024, 04:12:48 pm »Quote
svn13517: - Clangd_client include "sdk.h" needed for lspdiagresultslog.cpp no matter what clangd says
FYI: The warning can be suppressed by issueing a pragma:
Code
#include <cmath> // IWYU pragma: keep
That reduces clutter in the clangd_client's LSP messages box in Code::Blocks. OTOH, in general, it makes sense to go the extra mile and remove unneded #include pretty much wherever you can.
In cases like these, cmath is needed to provide M_PI which clangd does not see.