From e345b3f97f679221d3ec2b8a9f925b98b9a19fd6 Mon Sep 17 00:00:00 2001 From: Christopher Lackner Date: Tue, 5 Sep 2023 12:37:03 +0200 Subject: [PATCH] remove warning abound unused captured this pointer in lambda --- libsrc/core/register_archive.hpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/libsrc/core/register_archive.hpp b/libsrc/core/register_archive.hpp index 80f46fc0..7fbc4c87 100644 --- a/libsrc/core/register_archive.hpp +++ b/libsrc/core/register_archive.hpp @@ -63,11 +63,11 @@ namespace ngcore { return typeid(T) == ti ? nT : Archive::Caster::tryUpcast(ti, nT); }; - info.upcaster = [/*this*/](const std::type_info& ti, void* p) -> void* + info.upcaster = [](const std::type_info& ti, void* p) -> void* { return typeid(T) == ti ? p : Archive::Caster::tryUpcast(ti, static_cast(p)); }; - info.downcaster = [/*this*/](const std::type_info& ti, void* p) -> void* + info.downcaster = [](const std::type_info& ti, void* p) -> void* { return typeid(T) == ti ? p : Archive::Caster::tryDowncast(ti, p); }; - info.cargs_archiver = [this](Archive &ar, void* p) { + info.cargs_archiver = [](Archive &ar, void* p) { if constexpr(detail::has_GetCArgs_v) ar << static_cast(p)->GetCArgs(); };