From 014132d4c03290448d214d22a07e1f84fdd931c6 Mon Sep 17 00:00:00 2001 From: A Thousand Ships <96648715+AThousandShips@users.noreply.github.com> Date: Wed, 6 Sep 2023 19:32:55 +0200 Subject: [PATCH] Ensure `const` correctness for wrappers (cherry picked from commit f651df5e7a74f4ee357b4db41880b31535e660a8) --- include/godot_cpp/classes/wrapped.hpp | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) diff --git a/include/godot_cpp/classes/wrapped.hpp b/include/godot_cpp/classes/wrapped.hpp index 9a01672f..63126f27 100644 --- a/include/godot_cpp/classes/wrapped.hpp +++ b/include/godot_cpp/classes/wrapped.hpp @@ -132,16 +132,16 @@ protected: return (void(::godot::Wrapped::*)(::godot::List<::godot::PropertyInfo> * p_list) const) & m_class::_get_property_list; \ } \ \ - static bool (::godot::Wrapped::*_get_property_can_revert())(const ::godot::StringName &p_name) { \ - return (bool(::godot::Wrapped::*)(const ::godot::StringName &p_name)) & m_class::_property_can_revert; \ + static bool (::godot::Wrapped::*_get_property_can_revert())(const ::godot::StringName &p_name) const { \ + return (bool(::godot::Wrapped::*)(const ::godot::StringName &p_name) const) & m_class::_property_can_revert; \ } \ \ - static bool (::godot::Wrapped::*_get_property_get_revert())(const ::godot::StringName &p_name, ::godot::Variant &) { \ - return (bool(::godot::Wrapped::*)(const ::godot::StringName &p_name, ::godot::Variant &)) & m_class::_property_get_revert; \ + static bool (::godot::Wrapped::*_get_property_get_revert())(const ::godot::StringName &p_name, ::godot::Variant &) const { \ + return (bool(::godot::Wrapped::*)(const ::godot::StringName &p_name, ::godot::Variant &) const) & m_class::_property_get_revert; \ } \ \ - static ::godot::String (::godot::Wrapped::*_get_to_string())() { \ - return (::godot::String(::godot::Wrapped::*)()) & m_class::_to_string; \ + static ::godot::String (::godot::Wrapped::*_get_to_string())() const { \ + return (::godot::String(::godot::Wrapped::*)() const) & m_class::_to_string; \ } \ \ template \ @@ -338,15 +338,15 @@ protected: return nullptr; \ } \ \ - static bool (Wrapped::*_get_property_can_revert())(const ::godot::StringName &p_name) { \ + static bool (Wrapped::*_get_property_can_revert())(const ::godot::StringName &p_name) const { \ return nullptr; \ } \ \ - static bool (Wrapped::*_get_property_get_revert())(const ::godot::StringName &p_name, Variant &) { \ + static bool (Wrapped::*_get_property_get_revert())(const ::godot::StringName &p_name, Variant &) const { \ return nullptr; \ } \ \ - static String (Wrapped::*_get_to_string())() { \ + static String (Wrapped::*_get_to_string())() const { \ return nullptr; \ } \ \