From a1c77e77f91d13cf54662d0a3387c69e3c7dd86f Mon Sep 17 00:00:00 2001 From: taisa1 Date: Tue, 23 Jul 2024 17:29:24 +0900 Subject: [PATCH] fix: deal with functionStatic warnings Signed-off-by: taisa1 --- .../src/downsample_filter/robin_hood.h | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/sensing/autoware_pointcloud_preprocessor/src/downsample_filter/robin_hood.h b/sensing/autoware_pointcloud_preprocessor/src/downsample_filter/robin_hood.h index f04a84968dbbb..17108dc22ebe8 100644 --- a/sensing/autoware_pointcloud_preprocessor/src/downsample_filter/robin_hood.h +++ b/sensing/autoware_pointcloud_preprocessor/src/downsample_filter/robin_hood.h @@ -567,7 +567,7 @@ template struct NodeAllocator { // we are not using the data, so just free it. - void addOrFree(void * ptr, size_t ROBIN_HOOD_UNUSED(numBytes) /*unused*/) noexcept + static void addOrFree(void * ptr, size_t ROBIN_HOOD_UNUSED(numBytes) /*unused*/) noexcept { ROBIN_HOOD_LOG("std::free") std::free(ptr); @@ -1051,8 +1051,8 @@ class Table } // doesn't do anything - void destroy(M & ROBIN_HOOD_UNUSED(map) /*unused*/) noexcept {} - void destroyDoNotDeallocate() noexcept {} + static void destroy(M & ROBIN_HOOD_UNUSED(map) /*unused*/) noexcept {} + static void destroyDoNotDeallocate() noexcept {} value_type const * operator->() const noexcept { return &mData; } value_type * operator->() noexcept { return &mData; } @@ -1262,15 +1262,15 @@ class Table template struct Destroyer { - void nodes(M & m) const noexcept { m.mNumElements = 0; } + static void nodes(M & m) noexcept { m.mNumElements = 0; } - void nodesDoNotDeallocate(M & m) const noexcept { m.mNumElements = 0; } + static void nodesDoNotDeallocate(M & m) noexcept { m.mNumElements = 0; } }; template struct Destroyer { - void nodes(M & m) const noexcept + static void nodes(M & m) noexcept { m.mNumElements = 0; // clear also resets mInfo to 0, that's sometimes not necessary. @@ -1285,7 +1285,7 @@ class Table } } - void nodesDoNotDeallocate(M & m) const noexcept + static void nodesDoNotDeallocate(M & m) noexcept { m.mNumElements = 0; // clear also resets mInfo to 0, that's sometimes not necessary.