From 179c92eb0be70f3d3babbf511031af0acf6473f6 Mon Sep 17 00:00:00 2001 From: Jovan Gerodetti Date: Sun, 17 Dec 2023 12:42:14 +0100 Subject: [PATCH] Include name field in MethodInfo operator == --- core/object/object.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/core/object/object.h b/core/object/object.h index fdd1c0b2676d..d697f14b7e8c 100644 --- a/core/object/object.h +++ b/core/object/object.h @@ -235,7 +235,7 @@ struct MethodInfo { return arguments_metadata.size() > p_arg ? arguments_metadata[p_arg] : 0; } - inline bool operator==(const MethodInfo &p_method) const { return id == p_method.id; } + inline bool operator==(const MethodInfo &p_method) const { return id == p_method.id && name == p_method.name; } inline bool operator<(const MethodInfo &p_method) const { return id == p_method.id ? (name < p_method.name) : (id < p_method.id); } operator Dictionary() const;