diff --git a/src/variant/variant.cpp b/src/variant/variant.cpp index 4026637c..1627367d 100644 --- a/src/variant/variant.cpp +++ b/src/variant/variant.cpp @@ -719,14 +719,12 @@ String Variant::get_type_name(Variant::Type type) { } bool Variant::can_convert(Variant::Type from, Variant::Type to) { - GDExtensionBool can; - internal::gde_interface->variant_can_convert(static_cast(from), static_cast(to)); + GDExtensionBool can = internal::gde_interface->variant_can_convert(static_cast(from), static_cast(to)); return PtrToArg::convert(&can); } bool Variant::can_convert_strict(Variant::Type from, Variant::Type to) { - GDExtensionBool can; - internal::gde_interface->variant_can_convert_strict(static_cast(from), static_cast(to)); + GDExtensionBool can = internal::gde_interface->variant_can_convert_strict(static_cast(from), static_cast(to)); return PtrToArg::convert(&can); }