mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2024-08-16 17:00:35 +03:00
AK: Suppress false positive readability-non-const-parameter in Function
In AK::Function::CallableWrapper::init_and_swap(), clang-tidy wants us to mark the destination argument as pointer to const, which doesn't work because we use placement new to construct a move'd *this into.
This commit is contained in:
parent
7014d37dd6
commit
f32e185269
Notes:
sideshowbarker
2024-07-18 01:07:33 +09:00
Author: https://github.com/ADKaster Commit: https://github.com/SerenityOS/serenity/commit/f32e1852694 Pull-request: https://github.com/SerenityOS/serenity/pull/10737 Reviewed-by: https://github.com/BenWiederhake Reviewed-by: https://github.com/PeterBindels-TomTom Reviewed-by: https://github.com/awesomekling Reviewed-by: https://github.com/dascandy Reviewed-by: https://github.com/trflynn89
@ -156,6 +156,7 @@ private:
|
||||
delete this;
|
||||
}
|
||||
|
||||
// NOLINTNEXTLINE(readability-non-const-parameter) False positive; destination is used in a placement new expression
|
||||
void init_and_swap(u8* destination, size_t size) final override
|
||||
{
|
||||
VERIFY(size >= sizeof(CallableWrapper));
|
||||
|
Loading…
Reference in New Issue
Block a user