summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorrune-scape <spartacrafter@gmail.com>2024-07-03 13:32:50 -0700
committerrune-scape <spartacrafter@gmail.com>2024-07-03 13:32:50 -0700
commitc8b697c64c5f366b28d00355acd13c481eb006e7 (patch)
treeb8ae777ee6901d6d651bee0b271ad07f59b72987
parentf0d15bbfdfde1c1076903afb7a7db373580d5534 (diff)
downloadredot-engine-c8b697c64c5f366b28d00355acd13c481eb006e7.tar.gz
Remove unused `initialize_ref`
-rw-r--r--core/variant/variant.cpp7
-rw-r--r--core/variant/variant.h1
-rw-r--r--core/variant/variant_internal.h4
3 files changed, 0 insertions, 12 deletions
diff --git a/core/variant/variant.cpp b/core/variant/variant.cpp
index c1ef31c784..24b30112bd 100644
--- a/core/variant/variant.cpp
+++ b/core/variant/variant.cpp
@@ -1072,13 +1072,6 @@ bool Variant::is_null() const {
}
}
-bool Variant::initialize_ref(Object *p_object) {
- RefCounted *ref_counted = const_cast<RefCounted *>(static_cast<const RefCounted *>(p_object));
- if (!ref_counted->init_ref()) {
- return false;
- }
- return true;
-}
void Variant::reference(const Variant &p_variant) {
switch (type) {
case NIL:
diff --git a/core/variant/variant.h b/core/variant/variant.h
index f352af24da..bd4e74f0fb 100644
--- a/core/variant/variant.h
+++ b/core/variant/variant.h
@@ -254,7 +254,6 @@ private:
} _data alignas(8);
void reference(const Variant &p_variant);
- static bool initialize_ref(Object *p_object);
void _clear_internal();
diff --git a/core/variant/variant_internal.h b/core/variant/variant_internal.h
index c52ab6917b..58a45c0a1f 100644
--- a/core/variant/variant_internal.h
+++ b/core/variant/variant_internal.h
@@ -125,10 +125,6 @@ public:
}
}
- _FORCE_INLINE_ static bool initialize_ref(Object *object) {
- return Variant::initialize_ref(object);
- }
-
// Atomic types.
_FORCE_INLINE_ static bool *get_bool(Variant *v) { return &v->_data._bool; }
_FORCE_INLINE_ static const bool *get_bool(const Variant *v) { return &v->_data._bool; }