[clang-tidy] Add option to disable bugprone-multi-level-pointer-conversion in C code (#141209)

Sometimes a project may want to enable this check only in C++, and
disable it in C, since the patterns the check warns about are quite
common and idiomatic in C, and there are no better alternatives.
    
Fixes #140659

Co-authored-by: Carlos Gálvez <carlos.galvez@zenseact.com>
This commit is contained in:
Carlos Galvez
2025-06-07 21:52:23 +02:00
committed by GitHub
parent 97a32f2ad9
commit 30d8aebbe2
5 changed files with 42 additions and 2 deletions

View File

@@ -159,6 +159,10 @@ Changes in existing checks
false positives on deleted constructors that cannot be used to construct
objects, even if they have public or protected access.
- Added an option to :doc:`bugprone-multi-level-implicit-pointer-conversion
<clang-tidy/checks/bugprone/multi-level-implicit-pointer-conversion>` to
choose whether to enable the check in C code or not.
- Improved :doc:`bugprone-optional-value-conversion
<clang-tidy/checks/bugprone/optional-value-conversion>` check to detect
conversion in argument of ``std::make_optional``.