+wxObject *wxObject::Clone() const
+{
+    wxObject *object = GetClassInfo()->CreateObject();
+    CopyObject(*object);
+    return object;
+}
+
+void wxObject::CopyObject(wxObject& object_dest) const
+{
+    wxASSERT(object_dest.GetClassInfo()->IsKindOf(GetClassInfo()));
+}
+
+#if wxUSE_STD_IOSTREAM && (defined(__WXDEBUG__) || wxUSE_DEBUG_CONTEXT)