diff --git a/src/lib/eo/eo.c b/src/lib/eo/eo.c index 994eb5cda6..9e70aa243f 100644 --- a/src/lib/eo/eo.c +++ b/src/lib/eo/eo.c @@ -1618,6 +1618,27 @@ _eo_dbg_info_copy(const Eina_Value_Type *type EINA_UNUSED, const void *_src, voi return EINA_TRUE; } +static Eina_Bool +_eo_dbg_info_convert_to(const Eina_Value_Type *type EINA_UNUSED, const Eina_Value_Type *convert, const void *type_mem, void *convert_mem) +{ + /* FIXME: For the meanwhile, just use the inner type for the value. */ + const Eo_Dbg_Info **src = (const Eo_Dbg_Info **) type_mem; + if (convert == EINA_VALUE_TYPE_STRINGSHARE || + convert == EINA_VALUE_TYPE_STRING) + { + Eina_Bool ret; + const char *other_mem; + char *inner_val = eina_value_to_string(&(*src)->value); + other_mem = inner_val; + ret = eina_value_type_pset(convert, convert_mem, &other_mem); + free(inner_val); + return ret; + } + + eina_error_set(EINA_ERROR_VALUE_FAILED); + return EINA_FALSE; +} + static Eina_Bool _eo_dbg_info_pset(const Eina_Value_Type *type EINA_UNUSED, void *_mem, const void *_ptr) { @@ -1644,7 +1665,7 @@ static const Eina_Value_Type _EO_DBG_INFO_TYPE = { _eo_dbg_info_flush, _eo_dbg_info_copy, NULL, - NULL, + _eo_dbg_info_convert_to, NULL, NULL, _eo_dbg_info_pset,