summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorDaniel Kolesa <d.kolesa@osg.samsung.com>2017-01-12 15:08:46 +0100
committerDaniel Kolesa <d.kolesa@osg.samsung.com>2017-01-12 15:13:30 +0100
commitdeb1e58e06120c95373fe54ef84fdfb0e7d1a851 (patch)
treeb592918d3e1decf9aa62ef3dbe13ec72ff6b4648 /src
parent11432d42a717280f2f25cfd52942b0df59b0e35f (diff)
eolian gen: do not use EOLIAN_UNRESOLVED/PROPERTY for lookups
Diffstat (limited to 'src')
-rw-r--r--src/bin/eolian/docs.c4
-rw-r--r--src/bin/eolian/headers.c7
-rw-r--r--src/bin/eolian/sources.c4
3 files changed, 7 insertions, 8 deletions
diff --git a/src/bin/eolian/docs.c b/src/bin/eolian/docs.c
index 41b86f0537..b8bffa9e78 100644
--- a/src/bin/eolian/docs.c
+++ b/src/bin/eolian/docs.c
@@ -69,6 +69,7 @@ _generate_ref(const char *refn, Eina_Strbuf *wbuf, Eina_Bool use_legacy)
69 69
70 const Eolian_Class *cl = eolian_class_get_by_name(bname); 70 const Eolian_Class *cl = eolian_class_get_by_name(bname);
71 const Eolian_Function *fn = NULL; 71 const Eolian_Function *fn = NULL;
72 /* match methods and properties; we're only figuring out existence */
72 Eolian_Function_Type ftype = EOLIAN_UNRESOLVED; 73 Eolian_Function_Type ftype = EOLIAN_UNRESOLVED;
73 if (!cl) 74 if (!cl)
74 { 75 {
@@ -416,9 +417,6 @@ eo_gen_docs_func_gen(const Eolian_Function *fid, Eolian_Function_Type ftype,
416 417
417 const char *group = eolian_class_full_name_get(eolian_function_class_get(fid)); 418 const char *group = eolian_class_full_name_get(eolian_function_class_get(fid));
418 419
419 if (ftype == EOLIAN_UNRESOLVED)
420 ftype = EOLIAN_METHOD;
421
422 if (ftype == EOLIAN_METHOD) 420 if (ftype == EOLIAN_METHOD)
423 { 421 {
424 doc = eolian_function_documentation_get(fid, EOLIAN_METHOD); 422 doc = eolian_function_documentation_get(fid, EOLIAN_METHOD);
diff --git a/src/bin/eolian/headers.c b/src/bin/eolian/headers.c
index 1e4ba4cae4..564eb4f938 100644
--- a/src/bin/eolian/headers.c
+++ b/src/bin/eolian/headers.c
@@ -42,8 +42,9 @@ _gen_func(const Eolian_Function *fid, Eolian_Function_Type ftype,
42 if (!legacy && (fsc == EOLIAN_SCOPE_PROTECTED)) 42 if (!legacy && (fsc == EOLIAN_SCOPE_PROTECTED))
43 eina_strbuf_append_printf(buf, "#ifdef %s_PROTECTED\n", cnameu); 43 eina_strbuf_append_printf(buf, "#ifdef %s_PROTECTED\n", cnameu);
44 44
45 Eina_Bool hasdoc = eolian_function_documentation_get(fid, EOLIAN_UNRESOLVED) || 45 Eina_Bool hasdoc = !!eolian_function_documentation_get(fid, ftype);
46 eolian_function_documentation_get(fid, ftype); 46 if (!hasdoc && ((ftype == EOLIAN_PROP_GET) || (ftype == EOLIAN_PROP_SET)))
47 hasdoc = !!eolian_function_documentation_get(fid, EOLIAN_PROPERTY);
47 if (hasdoc) 48 if (hasdoc)
48 { 49 {
49 Eina_Strbuf *dbuf = eo_gen_docs_func_gen(fid, ftype, 0, legacy); 50 Eina_Strbuf *dbuf = eo_gen_docs_func_gen(fid, ftype, 0, legacy);
@@ -239,7 +240,7 @@ eo_gen_header_gen(const Eolian_Class *cl, Eina_Strbuf *buf, Eina_Bool legacy)
239 _gen_func(fid, EOLIAN_PROP_GET, buf, cname, cnameu, legacy); 240 _gen_func(fid, EOLIAN_PROP_GET, buf, cname, cnameu, legacy);
240 break; 241 break;
241 default: 242 default:
242 _gen_func(fid, EOLIAN_UNRESOLVED, buf, cname, cnameu, legacy); 243 _gen_func(fid, EOLIAN_METHOD, buf, cname, cnameu, legacy);
243 } 244 }
244 } 245 }
245 eina_iterator_free(itr); 246 eina_iterator_free(itr);
diff --git a/src/bin/eolian/sources.c b/src/bin/eolian/sources.c
index 67eb2a9576..82f6412d73 100644
--- a/src/bin/eolian/sources.c
+++ b/src/bin/eolian/sources.c
@@ -673,7 +673,7 @@ eo_gen_source_gen(const Eolian_Class *cl, Eina_Strbuf *buf)
673 _gen_func(cl, fid, EOLIAN_PROP_GET, buf, imp, lbuf); 673 _gen_func(cl, fid, EOLIAN_PROP_GET, buf, imp, lbuf);
674 break; 674 break;
675 default: 675 default:
676 _gen_func(cl, fid, EOLIAN_UNRESOLVED, buf, imp, lbuf); 676 _gen_func(cl, fid, EOLIAN_METHOD, buf, imp, lbuf);
677 } 677 }
678 } 678 }
679 eina_iterator_free(itr); 679 eina_iterator_free(itr);
@@ -991,7 +991,7 @@ eo_gen_impl_gen(const Eolian_Class *cl, Eina_Strbuf *buf)
991 _gen_proto(cl, fid, EOLIAN_PROP_GET, buf, imp, dt, cnamel); 991 _gen_proto(cl, fid, EOLIAN_PROP_GET, buf, imp, dt, cnamel);
992 break; 992 break;
993 default: 993 default:
994 _gen_proto(cl, fid, EOLIAN_UNRESOLVED, buf, imp, dt, cnamel); 994 _gen_proto(cl, fid, EOLIAN_METHOD, buf, imp, dt, cnamel);
995 } 995 }
996 } 996 }
997 eina_iterator_free(itr); 997 eina_iterator_free(itr);