eo: remove class functions from eo

As in the previous commit explained, we want to get rid of class
functions in eo, and make them just c functions right away.

This commit removes the class parameter from the eo_class_function_set
call, and adjusts the tests to not depend on class functions anymore.
Class functions are now not tested anymore, tests that used them as a
way to test *things* are adjusted to test them now with object
functions, tests that just tested the working of class functions are
dropped.

This fixes T7675.

Reviewed-by: Cedric BAIL <cedric.bail@free.fr>
Differential Revision: https://phab.enlightenment.org/D7902
This commit is contained in:
Marcel Hollerbach 2019-02-10 16:57:00 +01:00
parent 37d2d378ec
commit 46885653bc
44 changed files with 72 additions and 104 deletions

View File

@ -38,7 +38,7 @@ _class_initializer(Efl_Class *klass)
EFL_OBJECT_OP_FUNC(simple_other_call, _other_call),
);
return efl_class_functions_set(klass, &ops, NULL, NULL);
return efl_class_functions_set(klass, &ops, NULL);
}
static const Efl_Class_Description class_desc = {

View File

@ -65,7 +65,7 @@ _class_initializer(Efl_Class *klass)
EFL_OBJECT_OP_FUNC(simple_a_set, _a_set),
);
return efl_class_functions_set(klass, &ops, NULL, NULL);
return efl_class_functions_set(klass, &ops, NULL);
}
static void

View File

@ -907,7 +907,7 @@ _gen_initializer(const Eolian_Class *cl, Eina_Strbuf *buf)
eina_strbuf_append(buf, "#endif\n\n");
}
eina_strbuf_append(buf, " return efl_class_functions_set(klass, opsp, NULL, NULL);\n");
eina_strbuf_append(buf, " return efl_class_functions_set(klass, opsp, NULL);\n");
eina_strbuf_free(ops);

View File

@ -83,11 +83,11 @@ static void _custom_table_calc(Eo *obj, Custom_Table_Data *pd);
static Eina_Bool
_custom_table_initializer(Efl_Class *klass)
{
EFL_OPS_DEFINE(class_ops,
EFL_OPS_DEFINE(ops,
EFL_OBJECT_OP_FUNC(efl_canvas_group_calculate, _custom_table_calc)
);
return efl_class_functions_set(klass, NULL, &class_ops, NULL);
return efl_class_functions_set(klass, &ops, NULL);
};
static const Efl_Class_Description custom_table_class_desc = {

View File

@ -616,7 +616,7 @@ _elm_combobox_class_initializer(Efl_Class *klass)
EFL_CANVAS_GROUP_ADD_DEL_OPS(elm_combobox)
);
return efl_class_functions_set(klass, &ops, NULL, NULL);
return efl_class_functions_set(klass, &ops, NULL);
}
static const Efl_Class_Description _elm_combobox_class_desc = {

View File

@ -897,7 +897,7 @@ EAPI const Efl_Class *efl_class_new(const Efl_Class_Description *desc, const Efl
* efl_property_reflection_set() or efl_property_reflection_get() is called.
* @see #EFL_DEFINE_CLASS
*/
EAPI Eina_Bool efl_class_functions_set(const Efl_Class *klass_id, const Efl_Object_Ops *object_ops, const Efl_Object_Ops *class_ops, const Efl_Object_Property_Reflection_Ops *reflection_table);
EAPI Eina_Bool efl_class_functions_set(const Efl_Class *klass_id, const Efl_Object_Ops *object_ops, const Efl_Object_Property_Reflection_Ops *reflection_table);
/**
* @brief Override Eo functions of this object.

View File

@ -819,7 +819,7 @@ _eo_class_funcs_set(Eo_Vtable *vtable, const Efl_Object_Ops *ops, const _Efl_Cla
}
EAPI Eina_Bool
efl_class_functions_set(const Efl_Class *klass_id, const Efl_Object_Ops *object_ops, const Efl_Object_Ops *class_ops, const Efl_Object_Property_Reflection_Ops *reflection_table)
efl_class_functions_set(const Efl_Class *klass_id, const Efl_Object_Ops *object_ops, const Efl_Object_Property_Reflection_Ops *reflection_table)
{
EO_CLASS_POINTER_GOTO(klass_id, klass, err_klass);
Efl_Object_Ops empty_ops = { 0 };
@ -830,11 +830,9 @@ efl_class_functions_set(const Efl_Class *klass_id, const Efl_Object_Ops *object_
if (!object_ops) object_ops = &empty_ops;
if (!class_ops) class_ops = &empty_ops;
klass->reflection = reflection_table;
klass->ops_count = object_ops->count + class_ops->count;
klass->ops_count = object_ops->count;
klass->base_id = _eo_ops_last_id;
_eo_ops_last_id += klass->ops_count + 1;
@ -851,8 +849,7 @@ efl_class_functions_set(const Efl_Class *klass_id, const Efl_Object_Ops *object_
_vtable_copy_all(&klass->vtable, &(*mro_itr)->vtable);
}
return _eo_class_funcs_set(&klass->vtable, object_ops, klass, klass, 0, EINA_FALSE) &&
_eo_class_funcs_set(&klass->vtable, class_ops, klass, klass, object_ops->count, EINA_FALSE);
return _eo_class_funcs_set(&klass->vtable, object_ops, klass, klass, 0, EINA_FALSE);
err_funcs:
ERR("Class %s already had its functions set..", klass->desc->name);
@ -1693,7 +1690,7 @@ efl_class_new(const Efl_Class_Description *desc, const Efl_Class *parent_id, ...
/* If functions haven't been set, invoke it with an empty ops structure. */
if (!klass->functions_set)
{
efl_class_functions_set(_eo_class_id_get(klass), NULL, NULL, NULL);
efl_class_functions_set(_eo_class_id_get(klass), NULL, NULL);
}
/* Mark which classes we implement */

View File

@ -25,7 +25,7 @@ _class_initializer(Efl_Class *klass)
EFL_OBJECT_OP_FUNC(inherit_prot_print, _prot_print),
);
return efl_class_functions_set(klass, &ops, NULL, NULL);
return efl_class_functions_set(klass, &ops, NULL);
}
static const Efl_Class_Description class_desc = {

View File

@ -39,7 +39,7 @@ _class_initializer(Efl_Class *klass)
EFL_OBJECT_OP_FUNC(simple_a_set, _a_set),
);
return efl_class_functions_set(klass, &ops, NULL, NULL);
return efl_class_functions_set(klass, &ops, NULL);
}
static const Efl_Class_Description class_desc = {

View File

@ -44,7 +44,7 @@ _class_initializer(Efl_Class *klass)
EFL_OBJECT_OP_FUNC(simple_a_get, _a_get),
);
return efl_class_functions_set(klass, &ops, NULL, NULL);
return efl_class_functions_set(klass, &ops, NULL);
}
static const Efl_Class_Description class_desc = {

View File

@ -172,7 +172,7 @@ _class_initializer(Efl_Class *klass)
EFL_OBJECT_OP_FUNC(simple_a_get, _a_get),
);
return efl_class_functions_set(klass, &ops, NULL, NULL);
return efl_class_functions_set(klass, &ops, NULL);
}
static const Efl_Class_Description class_desc = {

View File

@ -46,7 +46,7 @@ _class_initializer(Efl_Class *klass)
EFL_OBJECT_OP_FUNC(efl_destructor, _destructor),
);
return efl_class_functions_set(klass, &ops, NULL, NULL);
return efl_class_functions_set(klass, &ops, NULL);
}
static const Efl_Class_Description class_desc = {

View File

@ -98,7 +98,7 @@ _class_initializer(Efl_Class *klass)
EFL_OBJECT_OP_FUNC(simple_b_get, _b_get),
);
return efl_class_functions_set(klass, &ops, NULL, NULL);
return efl_class_functions_set(klass, &ops, NULL);
}
static const Efl_Class_Description class_desc = {

View File

@ -23,7 +23,7 @@ _class_initializer(Efl_Class *klass)
EFL_OBJECT_OP_FUNC(efl_constructor, _constructor),
);
return efl_class_functions_set(klass, &ops, NULL, NULL);
return efl_class_functions_set(klass, &ops, NULL);
}
static const Efl_Class_Description class_desc = {

View File

@ -21,7 +21,7 @@ _class_initializer(Efl_Class *klass)
EFL_OBJECT_OP_FUNC(efl_constructor, _constructor),
);
return efl_class_functions_set(klass, &ops, NULL, NULL);
return efl_class_functions_set(klass, &ops, NULL);
}
static const Efl_Class_Description class_desc = {

View File

@ -21,7 +21,7 @@ _class_initializer(Efl_Class *klass)
EFL_OBJECT_OP_FUNC(efl_destructor, _destructor),
);
return efl_class_functions_set(klass, &ops, NULL, NULL);
return efl_class_functions_set(klass, &ops, NULL);
}
static const Efl_Class_Description class_desc = {

View File

@ -21,7 +21,7 @@ _class_initializer(Efl_Class *klass)
EFL_OBJECT_OP_FUNC(efl_destructor, _destructor),
);
return efl_class_functions_set(klass, &ops, NULL, NULL);
return efl_class_functions_set(klass, &ops, NULL);
}
static const Efl_Class_Description class_desc = {

View File

@ -25,7 +25,7 @@ _class_initializer(Efl_Class *klass)
EFL_OBJECT_OP_FUNC(efl_constructor, _constructor),
);
return efl_class_functions_set(klass, &ops, NULL, NULL);
return efl_class_functions_set(klass, &ops, NULL);
}
static const Efl_Class_Description class_desc = {

View File

@ -42,20 +42,6 @@ _print2(Eo *obj EINA_UNUSED, void *class_data EINA_UNUSED)
return EINA_TRUE;
}
static Eina_Bool
_class_print(Efl_Class *klass, void *data EINA_UNUSED)
{
Eina_Bool called = EINA_FALSE;
printf("Print %s-%s\n", efl_class_name_get(klass), efl_class_name_get(MY_CLASS));
called = simple_class_print(efl_super(klass, MY_CLASS));
fail_if(!called);
called = simple_class_print2(efl_super(klass, MY_CLASS));
fail_if(!called);
return EINA_TRUE;
}
EAPI EFL_FUNC_BODY(inherit2_print, Eina_Bool, EINA_FALSE);
EAPI EFL_FUNC_BODY(inherit2_print2, Eina_Bool, EINA_FALSE);
@ -67,11 +53,8 @@ _class_initializer(Efl_Class *klass)
EFL_OBJECT_OP_FUNC(inherit2_print2, _print2),
EFL_OBJECT_OP_FUNC(simple_a_set, _a_set),
);
EFL_OPS_DEFINE(cops,
EFL_OBJECT_OP_FUNC(simple_class_print, _class_print),
);
return efl_class_functions_set(klass, &ops, &cops, NULL);
return efl_class_functions_set(klass, &ops, NULL);
}
static const Efl_Class_Description class_desc = {

View File

@ -23,7 +23,7 @@ _class_initializer(Efl_Class *klass)
EFL_OBJECT_OP_FUNC(simple_a_set, _a_set),
);
return efl_class_functions_set(klass, &ops, NULL, NULL);
return efl_class_functions_set(klass, &ops, NULL);
}
static const Efl_Class_Description class_desc = {

View File

@ -66,7 +66,7 @@ _class_initializer(Efl_Class *klass)
EFL_OBJECT_OP_FUNC(simple_class_print2, _class_print2),
);
return efl_class_functions_set(klass, &ops, NULL, NULL);
return efl_class_functions_set(klass, &ops, NULL);
}
static const Efl_Class_Description class_desc = {

View File

@ -17,7 +17,7 @@ _class_initializer(Efl_Class *klass)
EFL_OBJECT_OP_FUNC(interface_ab_sum_get, NULL),
);
return efl_class_functions_set(klass, &ops, NULL, NULL);
return efl_class_functions_set(klass, &ops, NULL);
}
static const Efl_Class_Description class_desc = {

View File

@ -18,7 +18,7 @@ _class_initializer(Efl_Class *klass)
EFL_OBJECT_OP_FUNC(interface2_ab_sum_get2, NULL),
);
return efl_class_functions_set(klass, &ops, NULL, NULL);
return efl_class_functions_set(klass, &ops, NULL);
}
static const Efl_Class_Description class_desc = {

View File

@ -68,7 +68,7 @@ _class_initializer(Efl_Class *klass)
EFL_OBJECT_OP_FUNC(interface2_ab_sum_get2, _ab_sum_get2),
);
return efl_class_functions_set(klass, &ops, NULL, NULL);
return efl_class_functions_set(klass, &ops, NULL);
}
static const Efl_Class_Description class_desc = {

View File

@ -26,7 +26,7 @@ _class_initializer(Efl_Class *klass)
EFL_OBJECT_OP_FUNC(simple_a_get, _a_get),
);
return efl_class_functions_set(klass, &ops, NULL, NULL);
return efl_class_functions_set(klass, &ops, NULL);
}
static const Efl_Class_Description class_desc = {

View File

@ -41,7 +41,7 @@ _class_initializer(Efl_Class *klass)
EFL_OBJECT_OP_FUNC(mixin_ab_sum_get, _ab_sum_get),
);
return efl_class_functions_set(klass, &ops, NULL, NULL);
return efl_class_functions_set(klass, &ops, NULL);
}
static const Efl_Class_Description class_desc = {

View File

@ -55,7 +55,7 @@ _class_initializer(Efl_Class *klass)
EFL_OBJECT_OP_FUNC(mixin_ab_sum_get, _ab_sum_get),
);
return efl_class_functions_set(klass, &ops, NULL, NULL);
return efl_class_functions_set(klass, &ops, NULL);
}
static const Efl_Class_Description class_desc = {

View File

@ -54,7 +54,7 @@ _class_initializer(Efl_Class *klass)
EFL_OBJECT_OP_FUNC(mixin_ab_sum_get, _ab_sum_get),
);
return efl_class_functions_set(klass, &ops, NULL, NULL);
return efl_class_functions_set(klass, &ops, NULL);
}
static const Efl_Class_Description class_desc = {

View File

@ -47,7 +47,7 @@ _class_initializer(Efl_Class *klass)
EFL_OBJECT_OP_FUNC(simple_b_get, _b_get),
);
return efl_class_functions_set(klass, &ops, NULL, NULL);
return efl_class_functions_set(klass, &ops, NULL);
}
static const Efl_Class_Description class_desc = {

View File

@ -79,7 +79,7 @@ _class_initializer(Efl_Class *klass)
EFL_OBJECT_OP_FUNC(simple_a_set, _a_set),
);
return efl_class_functions_set(klass, &ops, NULL, NULL);
return efl_class_functions_set(klass, &ops, NULL);
}
static const Efl_Class_Description class_desc = {

View File

@ -89,7 +89,7 @@ _errorcase_class_initializer(Efl_Class *klass)
EFL_OBJECT_OP_FUNC(simple_error_test, _test),
);
return efl_class_functions_set(klass, &ops, NULL, NULL);
return efl_class_functions_set(klass, &ops, NULL);
}
static const Efl_Class_Description errorcase_class_desc = {

View File

@ -29,7 +29,7 @@ _destructor_unref_class_initializer(Efl_Class *klass2)
EFL_OBJECT_OP_FUNC(efl_destructor, _destructor_unref),
);
return efl_class_functions_set(klass2, &ops, NULL, NULL);
return efl_class_functions_set(klass2, &ops, NULL);
}
EFL_START_TEST(efl_destructor_unref)

View File

@ -203,7 +203,7 @@ _null_class_initializer(Efl_Class *klass)
EFL_OBJECT_OP_FUNC(NULL, _null_fct),
);
return efl_class_functions_set(klass, &ops, NULL, NULL);
return efl_class_functions_set(klass, &ops, NULL);
}
EFL_START_TEST(eo_null_api)
@ -240,7 +240,7 @@ _redefined_class_initializer(Efl_Class *klass)
EFL_OBJECT_OP_FUNC(null_fct, NULL),
);
return efl_class_functions_set(klass, &ops, NULL, NULL);
return efl_class_functions_set(klass, &ops, NULL);
}
EFL_START_TEST(eo_api_redefined)
@ -277,7 +277,7 @@ _dich_func_class_initializer(Efl_Class *klass)
EFL_OBJECT_OP_FUNC(simple_a_set, NULL),
);
return efl_class_functions_set(klass, &ops, NULL, NULL);
return efl_class_functions_set(klass, &ops, NULL);
}
EFL_START_TEST(eo_dich_func_override)

View File

@ -58,14 +58,6 @@ _a_print(Eo *obj EINA_UNUSED, void *class_data)
return EINA_TRUE;
}
static Eina_Bool
_class_hi_print(Efl_Class *klass, void *data EINA_UNUSED)
{
printf("Hi Print %s\n", efl_class_name_get(klass));
return EINA_TRUE;
}
EFL_FUNC_BODYV(simple_part_get, Eo *, NULL, EFL_FUNC_CALL(name), const char *name);
static Eo *
@ -102,7 +94,6 @@ _dbg_info_get(Eo *eo_obj, void *_pd EINA_UNUSED, Efl_Dbg_Info *root)
EFL_VOID_FUNC_BODYV(simple_a_set, EFL_FUNC_CALL(a), int a);
EFL_FUNC_BODY(simple_a_get, int, 0);
EFL_FUNC_BODY(simple_a_print, Eina_Bool, EINA_FALSE);
EFL_FUNC_BODY_CONST(simple_class_hi_print, Eina_Bool, EINA_FALSE);
EFL_VOID_FUNC_BODY(simple_pure_virtual);
EFL_VOID_FUNC_BODY(simple_no_implementation);
@ -118,9 +109,6 @@ _class_initializer(Efl_Class *klass)
EFL_OBJECT_OP_FUNC(simple_pure_virtual, NULL),
EFL_OBJECT_OP_FUNC(efl_dbg_info_get, _dbg_info_get),
);
EFL_OPS_DEFINE(cops,
EFL_OBJECT_OP_FUNC(simple_class_hi_print, _class_hi_print),
);
static const Efl_Object_Property_Reflection reflection_table[] = {
{"simple_a", _a_set_reflect, _a_get_reflect},
};
@ -128,7 +116,7 @@ _class_initializer(Efl_Class *klass)
reflection_table, EINA_C_ARRAY_LENGTH(reflection_table)
};
return efl_class_functions_set(klass, &ops, &cops, &ref_ops);
return efl_class_functions_set(klass, &ops, &ref_ops);
}
static const Efl_Class_Description class_desc = {
@ -142,24 +130,13 @@ static const Efl_Class_Description class_desc = {
};
EFL_DEFINE_CLASS(simple_class_get, &class_desc, EO_CLASS, NULL)
static int
_beef_get(Eo *obj EINA_UNUSED, void *class_data EINA_UNUSED)
{
return 0xBEEF;
}
EFL_FUNC_BODY_CONST(simple2_class_beef_get, int, 0);
static Eina_Bool
_class_initializer2(Efl_Class *klass)
{
EFL_OPS_DEFINE(cops,
EFL_OBJECT_OP_FUNC(simple2_class_beef_get, _beef_get),
);
return efl_class_functions_set(klass, NULL, &cops, NULL);
return efl_class_functions_set(klass, NULL, NULL);
}
static const Efl_Class_Description class_desc2 = {
@ -178,7 +155,7 @@ EFL_DEFINE_CLASS(simple2_class_get, &class_desc2, EO_CLASS, NULL)
static Eina_Bool
_class_initializer3(Efl_Class *klass)
{
return efl_class_functions_set(klass, NULL, NULL, NULL);
return efl_class_functions_set(klass, NULL, NULL);
}
static const Efl_Class_Description class_desc3 = {
@ -209,7 +186,7 @@ _searchable_class_initializer(Efl_Class *klass)
EFL_OBJECT_OP_FUNC(efl_provider_find, _interface_get)
);
return efl_class_functions_set(klass, &ops, NULL, NULL);
return efl_class_functions_set(klass, &ops, NULL);
}
static const Efl_Class_Description class_desc_searchable = {

View File

@ -24,8 +24,6 @@ extern const Efl_Event_Description _EV_A_CHANGED2;
#define SIMPLE_CLASS simple_class_get()
const Efl_Class *simple_class_get(void);
EAPI int simple2_class_beef_get(const Efl_Class *obj);
#define SIMPLE2_CLASS simple2_class_get()
const Efl_Class *simple2_class_get(void);

View File

@ -32,7 +32,7 @@ _class_initializer(Efl_Class *klass)
EFL_OBJECT_OP_FUNC(efl_constructor, _singleton_efl_constructor),
);
return efl_class_functions_set(klass, &ops, NULL, NULL);
return efl_class_functions_set(klass, &ops, NULL);
}
static const Efl_Class_Description class_desc = {

View File

@ -64,7 +64,7 @@ _class_initializer(Efl_Class *klass)
EFL_OBJECT_OP_FUNC(domain_a_get, _a_get),
EFL_OBJECT_OP_FUNC(domain_recursive, _recursive)
);
return efl_class_functions_set(klass, &ops, NULL, NULL);
return efl_class_functions_set(klass, &ops, NULL);
}
static const Efl_Class_Description class_desc = {

View File

@ -66,6 +66,18 @@ _simple_obj_override_a_double_set(Eo *obj, void *class_data EINA_UNUSED, int a)
simple_a_set(efl_super(obj, EFL_OBJECT_OVERRIDE_CLASS), 2 * a);
}
EAPI int test_class_beef_get(const Efl_Object *obj);
EFL_FUNC_BODY_CONST(test_class_beef_get, int, 0)
static int
_simple_obj_override_beef_get(Eo *obj, void *class_data EINA_UNUSED)
{
test_class_beef_get(efl_super(obj, EFL_OBJECT_OVERRIDE_CLASS));
return 1337;
}
EFL_START_TEST(efl_object_override_tests)
{
@ -105,7 +117,7 @@ EFL_START_TEST(efl_object_override_tests)
/* Try introducing a new function */
EFL_OPS_DEFINE(
overrides3,
EFL_OBJECT_OP_FUNC(simple2_class_beef_get, _simple_obj_override_a_double_set));
EFL_OBJECT_OP_FUNC(test_class_beef_get, _simple_obj_override_beef_get));
fail_if(efl_object_override(obj, &overrides3));
fail_if(!efl_object_override(obj, NULL));
fail_if(efl_object_override(obj, &overrides3));
@ -472,7 +484,7 @@ _class_initializer(Efl_Class *klass)
EFL_OBJECT_OP_FUNC(efl_destructor, _man_des),
);
return efl_class_functions_set(klass, &ops, NULL, NULL);
return efl_class_functions_set(klass, &ops, NULL);
}
EFL_START_TEST(eo_man_free)
@ -1049,7 +1061,7 @@ _multi_class_initializer(Efl_Class *klass)
EFL_OBJECT_OP_FUNC(resolve_a_print, _a_print),
);
return efl_class_functions_set(klass, &ops, NULL, NULL);
return efl_class_functions_set(klass, &ops, NULL);
}
EFL_START_TEST(efl_func_resolve)
@ -1215,7 +1227,7 @@ _add_failures_class_initializer(Efl_Class *klass)
EFL_OBJECT_OP_FUNC(efl_finalize, _efl_add_failures_finalize),
);
return efl_class_functions_set(klass, &ops, NULL, NULL);
return efl_class_functions_set(klass, &ops, NULL);
}
EFL_START_TEST(efl_add_failures)
@ -1628,14 +1640,14 @@ static Eina_Bool
_cast_inherit_class_initializer_1(Efl_Class *klass)
{
EFL_OPS_DEFINE(ops, EFL_OBJECT_OP_FUNC(inherit_value, _inherit_value_1), );
return efl_class_functions_set(klass, &ops, NULL, NULL);
return efl_class_functions_set(klass, &ops, NULL);
}
static Eina_Bool
_cast_inherit_class_initializer_2(Efl_Class *klass)
{
EFL_OPS_DEFINE(ops, EFL_OBJECT_OP_FUNC(inherit_value, _inherit_value_2), );
return efl_class_functions_set(klass, &ops, NULL, NULL);
return efl_class_functions_set(klass, &ops, NULL);
}
EFL_START_TEST(efl_cast_test)

View File

@ -23,10 +23,9 @@ EFL_START_TEST(eo_test_init_shutdown)
/* XXX-1: Essential for the next test to assign the wrong op. */
obj = efl_add_ref(SIMPLE_CLASS, NULL);
simple_a_set(obj, 1);
/* XXX-1: Essential for the next test to cache the op. */
ck_assert_int_eq(1, simple_a_get(obj));
/* XXX-1: Essential for the next test to cache the op. */
ck_assert_int_eq(0xBEEF, simple2_class_beef_get(SIMPLE2_CLASS));
efl_unref(obj);
fail_if(efl_object_shutdown());
@ -34,7 +33,9 @@ EFL_START_TEST(eo_test_init_shutdown)
ck_assert_str_eq("Efl.Object", efl_class_name_get(EFL_OBJECT_CLASS));
/* XXX-1: Verify that the op was not cached. */
ck_assert_int_eq(0xBEEF, simple2_class_beef_get(SIMPLE2_CLASS));
obj = efl_add_ref(SIMPLE_CLASS, NULL);
simple_a_set(obj, 1);
ck_assert_int_eq(1, simple_a_get(obj));
}
EFL_END_TEST

View File

@ -69,7 +69,7 @@ _class_initializer(Efl_Class *klass)
EFL_OBJECT_OP_FUNC(thread_test_try_swap_stack, _try_swap_stack),
);
return efl_class_functions_set(klass, &ops, NULL, NULL);
return efl_class_functions_set(klass, &ops, NULL);
}
static const Efl_Class_Description class_desc = {

View File

@ -45,7 +45,7 @@ _class_simple_class_initializer(Efl_Class *klass)
);
opsp = &ops;
return efl_class_functions_set(klass, opsp, NULL, NULL);
return efl_class_functions_set(klass, opsp, NULL);
}
static const Efl_Class_Description _class_simple_class_desc = {

View File

@ -28,7 +28,7 @@ _function_as_argument_class_initializer(Efl_Class *klass)
);
opsp = &ops;
return efl_class_functions_set(klass, opsp, NULL, NULL);
return efl_class_functions_set(klass, opsp, NULL);
}
static const Efl_Class_Description _function_as_argument_class_desc = {

View File

@ -81,7 +81,7 @@ _override_class_initializer(Efl_Class *klass)
);
opsp = &ops;
return efl_class_functions_set(klass, opsp, NULL, NULL);
return efl_class_functions_set(klass, opsp, NULL);
}
static const Efl_Class_Description _override_class_desc = {

View File

@ -56,7 +56,7 @@ _owning_class_initializer(Efl_Class *klass)
);
opsp = &ops;
return efl_class_functions_set(klass, opsp, NULL, NULL);
return efl_class_functions_set(klass, opsp, NULL);
}
static const Efl_Class_Description _owning_class_desc = {