1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-07-25 15:27:35 +00:00

AK+Kernel: Suppress clang-tidy warnings from the cert-* category

cert-dcl50-cpp: No variadic functions, suppressed in RefCounted and
ThreadSafeRefCounted for implementing the magic one_ref_left and
will_be_destroyed functions.

cert-dcl58-cpp: No opening ::std, suppressed in the places we put names
in ::std to aid tools (move, forward, nullptr_t, align_val_t, etc).
This commit is contained in:
Andrew Kaster 2021-11-06 11:55:32 -06:00 committed by Andreas Kling
parent 2b16ee742e
commit 7014d37dd6
5 changed files with 7 additions and 3 deletions

View file

@ -22,6 +22,7 @@ constexpr auto call_will_be_destroyed_if_present(const T* object) -> decltype(co
return {};
}
// NOLINTNEXTLINE(cert-dcl50-cpp) variadic argument used to implement "is detected" pattern
constexpr auto call_will_be_destroyed_if_present(...) -> FalseType
{
return {};
@ -34,6 +35,7 @@ constexpr auto call_one_ref_left_if_present(const T* object) -> decltype(const_c
return {};
}
// NOLINTNEXTLINE(cert-dcl50-cpp) variadic argument used to implement "is detected" pattern
constexpr auto call_one_ref_left_if_present(...) -> FalseType
{
return {};