From b9e45b17ab89e69e132b6ae8c7f63d9e41a18293 Mon Sep 17 00:00:00 2001 From: David Sobek Date: Mon, 5 May 2025 19:04:36 -0600 Subject: [PATCH] Make BT::Any::copyInto const --- include/behaviortree_cpp/utils/safe_any.hpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/include/behaviortree_cpp/utils/safe_any.hpp b/include/behaviortree_cpp/utils/safe_any.hpp index e056394ac..3a71c1dd6 100644 --- a/include/behaviortree_cpp/utils/safe_any.hpp +++ b/include/behaviortree_cpp/utils/safe_any.hpp @@ -134,7 +134,7 @@ class Any } // copy the value (casting into dst). We preserve the destination type. - void copyInto(Any& dst); + void copyInto(Any& dst) const; // this is different from any_cast, because if allows safe // conversions between arithmetic values and from/to string. @@ -321,7 +321,7 @@ inline bool Any::isIntegral() const return _any.type() == typeid(int64_t) || _any.type() == typeid(uint64_t); } -inline void Any::copyInto(Any& dst) +inline void Any::copyInto(Any& dst) const { if(dst.empty()) {