diff --git a/src/bin/eolian/eo_generator.c b/src/bin/eolian/eo_generator.c index 2df68df705..9231d08d87 100644 --- a/src/bin/eolian/eo_generator.c +++ b/src/bin/eolian/eo_generator.c @@ -187,7 +187,7 @@ eo_fundef_generate(const Eolian_Class class, Eolian_Function func, Eolian_Functi pdir = EOLIAN_OUT_PARAM; } if (ftype == EOLIAN_PROP_SET) pdir = EOLIAN_IN_PARAM; - if (ftype == EOLIAN_UNRESOLVED || ftype == EOLIAN_METHOD) add_star = (pdir == EOLIAN_OUT_PARAM); + if (ftype == EOLIAN_UNRESOLVED || ftype == EOLIAN_METHOD) add_star = (pdir == EOLIAN_OUT_PARAM || pdir == EOLIAN_INOUT_PARAM); Eina_Bool had_star = !!strchr(ptype, '*'); const char *dir_str = str_dir[(int)pdir]; @@ -402,7 +402,7 @@ eo_bind_func_generate(const Eolian_Class class, Eolian_Function funcid, Eolian_F Eina_Bool is_const = eolian_parameter_const_attribute_get(data, ftype == EOLIAN_PROP_GET); Eina_Bool had_star = !!strchr(ptype, '*'); - if (ftype == EOLIAN_UNRESOLVED || ftype == EOLIAN_METHOD) add_star = (pdir == EOLIAN_OUT_PARAM); + if (ftype == EOLIAN_UNRESOLVED || ftype == EOLIAN_METHOD) add_star = (pdir == EOLIAN_OUT_PARAM || pdir == EOLIAN_INOUT_PARAM); if (eina_strbuf_length_get(params)) eina_strbuf_append(params, ", "); eina_strbuf_append_printf(params, "%s", pname); eina_strbuf_append_printf(full_params, ", %s%s%s%s%s", diff --git a/src/bin/eolian/impl_generator.c b/src/bin/eolian/impl_generator.c index 423b6b1ea9..e583356134 100644 --- a/src/bin/eolian/impl_generator.c +++ b/src/bin/eolian/impl_generator.c @@ -48,7 +48,7 @@ _params_generate(Eolian_Function foo, Eolian_Function_Type ftype, Eina_Bool var_ ptype = eolian_type_c_type_get(ptypet); Eina_Bool is_const = eolian_parameter_const_attribute_get(param, ftype == EOLIAN_PROP_GET); Eina_Bool had_star = !!strchr(ptype, '*'); - if (ftype == EOLIAN_UNRESOLVED || ftype == EOLIAN_METHOD) add_star = (pdir == EOLIAN_OUT_PARAM); + if (ftype == EOLIAN_UNRESOLVED || ftype == EOLIAN_METHOD) add_star = (pdir == EOLIAN_OUT_PARAM || pdir == EOLIAN_INOUT_PARAM); if (eina_strbuf_length_get(params)) { eina_strbuf_append(params, ", "); diff --git a/src/bin/eolian/legacy_generator.c b/src/bin/eolian/legacy_generator.c index cb93ec8346..a6c2b647d9 100644 --- a/src/bin/eolian/legacy_generator.c +++ b/src/bin/eolian/legacy_generator.c @@ -142,7 +142,7 @@ _eapi_decl_func_generate(Eolian_Class class, Eolian_Function funcid, Eolian_Func eolian_parameter_information_get((Eolian_Function_Parameter)data, &pdir, &ptypet, &pname, &pdesc); ptype = eolian_type_c_type_get(ptypet); Eina_Bool had_star = !!strchr(ptype, '*'); - if (ftype == EOLIAN_UNRESOLVED || ftype == EOLIAN_METHOD) add_star = (pdir == EOLIAN_OUT_PARAM); + if (ftype == EOLIAN_UNRESOLVED || ftype == EOLIAN_METHOD) add_star = (pdir == EOLIAN_OUT_PARAM || pdir == EOLIAN_INOUT_PARAM); if (ftype == EOLIAN_PROP_GET) pdir = EOLIAN_OUT_PARAM; if (ftype == EOLIAN_PROP_SET) pdir = EOLIAN_IN_PARAM; leg_param_idx++; @@ -277,7 +277,7 @@ _eapi_func_generate(const Eolian_Class class, Eolian_Function funcid, Eolian_Fun eolian_parameter_information_get((Eolian_Function_Parameter)data, &pdir, &ptypet, &pname, NULL); ptype = eolian_type_c_type_get(ptypet); Eina_Bool had_star = !!strchr(ptype, '*'); - if (ftype == EOLIAN_UNRESOLVED || ftype == EOLIAN_METHOD) add_star = (pdir == EOLIAN_OUT_PARAM); + if (ftype == EOLIAN_UNRESOLVED || ftype == EOLIAN_METHOD) add_star = (pdir == EOLIAN_OUT_PARAM || pdir == EOLIAN_INOUT_PARAM); eina_strbuf_append_printf(fparam, ", %s%s%s%s%s", eolian_parameter_const_attribute_get(data, ftype == EOLIAN_PROP_GET)?"const ":"", ptype, had_star?"":" ", add_star?"*":"", pname); diff --git a/src/lib/eo/eo_base.eo b/src/lib/eo/eo_base.eo index bbeaa05812..e913a06adc 100644 --- a/src/lib/eo/eo_base.eo +++ b/src/lib/eo/eo_base.eo @@ -71,7 +71,7 @@ Prevents event callbacks from being called for the object. */ wref_del { /*@ Delete the weak reference passed. */ params { - @inout Eo** wref; + @inout Eo* wref; } } destructor { @@ -128,7 +128,7 @@ callbacks of the same priority are called in reverse order of creation. */ /*@ Add a new weak reference to obj. This function registers the object handle pointed by wref to obj so when obj is deleted it'll be updated to NULL. This functions should be used when you want to keep track of an object in a safe way, but you don't want to prevent it from being freed. */ params { - @inout Eo** wref; + @inout Eo* wref; } } dbg_info_get { diff --git a/src/tests/eolian/data/class_simple.eo b/src/tests/eolian/data/class_simple.eo index 843e7454e3..3485177251 100644 --- a/src/tests/eolian/data/class_simple.eo +++ b/src/tests/eolian/data/class_simple.eo @@ -22,7 +22,7 @@ class Simple { /*@ comment foo */ params { @in int a; /*@ a */ - @inout char *b; + @inout char b; @out double c; } return char *(NULL); /*@ comment for method return */ diff --git a/src/tests/eolian/data/consts.eo b/src/tests/eolian/data/consts.eo index 04e174a361..690e811519 100644 --- a/src/tests/eolian/data/consts.eo +++ b/src/tests/eolian/data/consts.eo @@ -18,7 +18,7 @@ class Const { /*@ comment foo */ params { @in int a; /*@ a */ - @inout char *b; + @inout char b; @out double c; } const; diff --git a/src/tests/eolian/data/object_impl.eo b/src/tests/eolian/data/object_impl.eo index 8ce38de0de..10c4e36415 100644 --- a/src/tests/eolian/data/object_impl.eo +++ b/src/tests/eolian/data/object_impl.eo @@ -40,7 +40,7 @@ class Object (Base) { /*@ comment foo */ params { @in int a; /*@ a */ - @inout char *b; + @inout char b; @out double c; } return char *(NULL); /*@ comment for method return */ diff --git a/src/tests/eolian/eolian_parsing.c b/src/tests/eolian/eolian_parsing.c index db177890c5..24348d227e 100644 --- a/src/tests/eolian/eolian_parsing.c +++ b/src/tests/eolian/eolian_parsing.c @@ -463,8 +463,8 @@ START_TEST(eolian_simple_parsing) fail_if(!(param = eina_list_nth(list, 1))); eolian_parameter_information_get(param, &dir, &ptypep, &pname, &string); fail_if(dir != EOLIAN_INOUT_PARAM); - ptype = eolian_type_c_type_get(ptypep); - fail_if(strcmp(ptype, "char *")); + ptype = eolian_type_name_get(ptypep); + fail_if(strcmp(ptype, "char")); eina_stringshare_del(ptype); fail_if(strcmp(pname, "b")); fail_if(string);