Skip to content

Commit 1c59362

Browse files
authored
[clangd] Make it possible to enable misc-const-correctness clang-tidy check (#94920)
Before this PR, clangd forcefully disabled misc-const-correctness in disableUnusableChecks(). Now we have a FastCheckFilter configuration whose default value (Strict) also disables it. This patch removes misc-const-correctness from disableUnusableChecks() so it's possible to enable by setting FastCheckFilter to None. Fixes #89758
1 parent 27f3ac5 commit 1c59362

File tree

1 file changed

+1
-7
lines changed

1 file changed

+1
-7
lines changed

clang-tools-extra/clangd/TidyProvider.cpp

Lines changed: 1 addition & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -221,13 +221,7 @@ TidyProvider disableUnusableChecks(llvm::ArrayRef<std::string> ExtraBadChecks) {
221221
"-hicpp-invalid-access-moved",
222222
// Check uses dataflow analysis, which might hang/crash unexpectedly on
223223
// incomplete code.
224-
"-bugprone-unchecked-optional-access",
225-
226-
// ----- Performance problems -----
227-
228-
// This check runs expensive analysis for each variable.
229-
// It has been observed to increase reparse time by 10x.
230-
"-misc-const-correctness");
224+
"-bugprone-unchecked-optional-access");
231225

232226
size_t Size = BadChecks.size();
233227
for (const std::string &Str : ExtraBadChecks) {

0 commit comments

Comments
 (0)