From ccb5ba1b923afe412f026fb97c9aea5fa8cc4f57 Mon Sep 17 00:00:00 2001 From: Richard Smith Date: Thu, 17 Sep 2026 01:23:25 +0000 Subject: [PATCH] Turn off `-Wunneeded-internal-declaration` in clangd. (#7793) Like the other unused warnings, it misfires when the only uses are in template instantiations. This is misfiring in #7771's CI checks. --- .clangd | 12 +++++------- 1 file changed, 5 insertions(+), 7 deletions(-) diff --git a/.clangd b/.clangd index 971c6f182ddf..b6112b197c55 100644 --- a/.clangd +++ b/.clangd @@ -6,13 +6,11 @@ CompileFlags: # Workaround for https://github.com/clangd/clangd/issues/1582 Remove: [-march=*] Diagnostics: - # `unused-function`: has false positives due to not performing template - # instantiation. We get a more reliable version of this warning from the - # compiler. - # `unused-includes`: has false positives, reporting includes unused when - # they are used. Probably the same root cause as unused-function. - # `unused-template`: has false positives, which we see in eval.cpp. - Suppress: [unused-function, unused-includes, unused-template] + # `unneeded-internal-declaration`, `unused-function`, `unused-includes`, + # `unused-template`: These all have false positives due to not performing + # template instantiation. We get a more reliable version of these warnings + # from the compiler. + Suppress: [unneeded-internal-declaration, unused-function, unused-includes, unused-template] ---