Jelajahi Sumber

Suppress unused-includes in clangd for false positives (#4573)

clangd-17 reports includes as being unused when they are used, such as
in common/ostream.h. There it says the `<concepts>` include is unused
but `std::derived_from` is present in the same file (and clangd points
out that it is coming from `<concepts>` on hover).
Dana Jansens 1 tahun lalu
induk
melakukan
77689c4a72
1 mengubah file dengan 4 tambahan dan 0 penghapusan
  1. 4 0
      .clangd

+ 4 - 0
.clangd

@@ -5,3 +5,7 @@
 CompileFlags:
 CompileFlags:
   # Workaround for https://github.com/clangd/clangd/issues/1582
   # Workaround for https://github.com/clangd/clangd/issues/1582
   Remove: [-march=*]
   Remove: [-march=*]
+Diagnostics:
+  # `unused-includes`: has false positives, reporting includes unused when
+  #   they are used.
+  Suppress: [unused-includes]