summaryrefslogtreecommitdiff
path: root/src/bin/eolian
diff options
context:
space:
mode:
authorDaniel Kolesa <d.kolesa@samsung.com>2019-08-16 16:32:13 +0200
committerDaniel Kolesa <d.kolesa@samsung.com>2019-08-16 16:33:37 +0200
commit2f147f272596306dc230a5085c5a5b21aae6ba3c (patch)
tree5b5c1f516917898bbd9359e1cf23aa6ce26aa587 /src/bin/eolian
parent8a8a833837f7217aea0a33f4f7afbb6edfb103c4 (diff)
eolian: rename is_class api for functions to is_static
Still needs restriction to classes only etc to be done later. Ref https://phab.enlightenment.org/T8118 Ref https://phab.enlightenment.org/T7675
Diffstat (limited to 'src/bin/eolian')
-rw-r--r--src/bin/eolian/docs.c2
-rw-r--r--src/bin/eolian/headers.c4
-rw-r--r--src/bin/eolian/sources.c20
3 files changed, 13 insertions, 13 deletions
diff --git a/src/bin/eolian/docs.c b/src/bin/eolian/docs.c
index e497581..498278f 100644
--- a/src/bin/eolian/docs.c
+++ b/src/bin/eolian/docs.c
@@ -570,7 +570,7 @@ eo_gen_docs_func_gen(const Eolian_State *state, const Eolian_Function *fid,
570 } 570 }
571 } 571 }
572 572
573 if (!eolian_function_is_class(fid)) 573 if (!eolian_function_is_static(fid))
574 { 574 {
575 _indent_line(buf, indent); 575 _indent_line(buf, indent);
576 eina_strbuf_append(buf, " * @param[in] obj The object.\n"); 576 eina_strbuf_append(buf, " * @param[in] obj The object.\n");
diff --git a/src/bin/eolian/headers.c b/src/bin/eolian/headers.c
index a4a20c4..3e433b5 100644
--- a/src/bin/eolian/headers.c
+++ b/src/bin/eolian/headers.c
@@ -129,13 +129,13 @@ _gen_func(const Eolian_State *state, const Eolian_Function *fid,
129 eina_stringshare_del(fcn); 129 eina_stringshare_del(fcn);
130 130
131 Eina_Strbuf *flagbuf = NULL; 131 Eina_Strbuf *flagbuf = NULL;
132 int nidx = !eolian_function_is_class(fid); 132 int nidx = !eolian_function_is_static(fid);
133 133
134 eina_strbuf_append_char(buf, '('); 134 eina_strbuf_append_char(buf, '(');
135 if (nidx) 135 if (nidx)
136 { 136 {
137 if ((ftype == EOLIAN_PROP_GET) || eolian_function_object_is_const(fid) 137 if ((ftype == EOLIAN_PROP_GET) || eolian_function_object_is_const(fid)
138 || eolian_function_is_class(fid)) 138 || eolian_function_is_static(fid))
139 { 139 {
140 eina_strbuf_append(buf, "const "); 140 eina_strbuf_append(buf, "const ");
141 } 141 }
diff --git a/src/bin/eolian/sources.c b/src/bin/eolian/sources.c
index ccf5cc3..93d78eb 100644
--- a/src/bin/eolian/sources.c
+++ b/src/bin/eolian/sources.c
@@ -570,7 +570,7 @@ _gen_func(const Eolian_Class *cl, const Eolian_Function *fid,
570 eina_strbuf_append(params, ", "); 570 eina_strbuf_append(params, ", ");
571 eina_strbuf_append(params, prn); 571 eina_strbuf_append(params, prn);
572 572
573 if (eina_strbuf_length_get(params_full) || !eolian_function_is_class(fid)) 573 if (eina_strbuf_length_get(params_full) || !eolian_function_is_static(fid))
574 { 574 {
575 eina_strbuf_append(params_full, ", "); 575 eina_strbuf_append(params_full, ", ");
576 eina_strbuf_append(params_full_imp, ", "); 576 eina_strbuf_append(params_full_imp, ", ");
@@ -660,7 +660,7 @@ _gen_func(const Eolian_Class *cl, const Eolian_Function *fid,
660 if (eina_strbuf_length_get(params)) 660 if (eina_strbuf_length_get(params))
661 eina_strbuf_append(params, ", "); 661 eina_strbuf_append(params, ", ");
662 662
663 if (eina_strbuf_length_get(params_full_imp) || !eolian_function_is_class(fid)) 663 if (eina_strbuf_length_get(params_full_imp) || !eolian_function_is_static(fid))
664 eina_strbuf_append(params_full_imp, ", "); 664 eina_strbuf_append(params_full_imp, ", ");
665 eina_strbuf_append(params_full_imp, ptn); 665 eina_strbuf_append(params_full_imp, ptn);
666 if (!had_star) 666 if (!had_star)
@@ -671,7 +671,7 @@ _gen_func(const Eolian_Class *cl, const Eolian_Function *fid,
671 eina_strbuf_append(params_full_imp, " EINA_UNUSED"); 671 eina_strbuf_append(params_full_imp, " EINA_UNUSED");
672 eina_strbuf_append(params, prn); 672 eina_strbuf_append(params, prn);
673 673
674 if (eina_strbuf_length_get(params_full) || !eolian_function_is_class(fid)) 674 if (eina_strbuf_length_get(params_full) || !eolian_function_is_static(fid))
675 eina_strbuf_append(params_full, ", "); 675 eina_strbuf_append(params_full, ", ");
676 eina_strbuf_append(params_full, ptn); 676 eina_strbuf_append(params_full, ptn);
677 if (!had_star) 677 if (!had_star)
@@ -729,7 +729,7 @@ _gen_func(const Eolian_Class *cl, const Eolian_Function *fid,
729 { 729 {
730 /* figure out the data type */ 730 /* figure out the data type */
731 Eina_Stringshare *dt = NULL; 731 Eina_Stringshare *dt = NULL;
732 if (eolian_function_is_class(fid)) 732 if (eolian_function_is_static(fid))
733 dt = eina_stringshare_add("void"); 733 dt = eina_stringshare_add("void");
734 else 734 else
735 dt = eolian_class_c_data_type_get(cl); 735 dt = eolian_class_c_data_type_get(cl);
@@ -751,7 +751,7 @@ _gen_func(const Eolian_Class *cl, const Eolian_Function *fid,
751 eina_strbuf_append(buf, func_suffix); 751 eina_strbuf_append(buf, func_suffix);
752 /* ([const ]Eo *obj, Data_Type *pd, impl_full_params); */ 752 /* ([const ]Eo *obj, Data_Type *pd, impl_full_params); */
753 eina_strbuf_append_char(buf, '('); 753 eina_strbuf_append_char(buf, '(');
754 if (!eolian_function_is_class(fid)) 754 if (!eolian_function_is_static(fid))
755 { 755 {
756 if ((ftype == EOLIAN_PROP_GET) || eolian_function_object_is_const(fid)) 756 if ((ftype == EOLIAN_PROP_GET) || eolian_function_object_is_const(fid))
757 eina_strbuf_append(buf, "const "); 757 eina_strbuf_append(buf, "const ");
@@ -760,7 +760,7 @@ _gen_func(const Eolian_Class *cl, const Eolian_Function *fid,
760 eina_strbuf_append(buf, " *pd"); 760 eina_strbuf_append(buf, " *pd");
761 } 761 }
762 eina_strbuf_append(buf, eina_strbuf_string_get(params_full_imp)); 762 eina_strbuf_append(buf, eina_strbuf_string_get(params_full_imp));
763 if (eina_strbuf_length_get(params_full_imp) == 0 && eolian_function_is_class(fid)) 763 if (eina_strbuf_length_get(params_full_imp) == 0 && eolian_function_is_static(fid))
764 eina_strbuf_append(buf, "void"); 764 eina_strbuf_append(buf, "void");
765 eina_strbuf_append(buf, ");\n\n"); 765 eina_strbuf_append(buf, ");\n\n");
766 } 766 }
@@ -832,7 +832,7 @@ _gen_func(const Eolian_Class *cl, const Eolian_Function *fid,
832 eina_stringshare_del(dt); 832 eina_stringshare_del(dt);
833 } 833 }
834 834
835 if (impl_same_class && !eolian_function_is_class(fid)) 835 if (impl_same_class && !eolian_function_is_static(fid))
836 { 836 {
837 /* generate reflection implementation */ 837 /* generate reflection implementation */
838 if (reflect_type) 838 if (reflect_type)
@@ -875,7 +875,7 @@ _gen_func(const Eolian_Class *cl, const Eolian_Function *fid,
875 if (has_params) 875 if (has_params)
876 eina_strbuf_append_char(buf, 'V'); 876 eina_strbuf_append_char(buf, 'V');
877 if ((ftype == EOLIAN_PROP_GET) || eolian_function_object_is_const(fid) 877 if ((ftype == EOLIAN_PROP_GET) || eolian_function_object_is_const(fid)
878 || eolian_function_is_class(fid)) 878 || eolian_function_is_static(fid))
879 { 879 {
880 eina_strbuf_append(buf, "_CONST"); 880 eina_strbuf_append(buf, "_CONST");
881 } 881 }
@@ -909,7 +909,7 @@ _gen_func(const Eolian_Class *cl, const Eolian_Function *fid,
909 909
910 eina_stringshare_del(eofn); 910 eina_stringshare_del(eofn);
911 } 911 }
912 if (impl_same_class && eolian_function_is_class(fid)) 912 if (impl_same_class && eolian_function_is_static(fid))
913 _emit_class_function(buf, fid, rtp, params_full, ocnamel, func_suffix, params, eolian_function_full_c_name_get(fid, ftype)); 913 _emit_class_function(buf, fid, rtp, params_full, ocnamel, func_suffix, params, eolian_function_full_c_name_get(fid, ftype));
914 914
915 free(cname); 915 free(cname);
@@ -1003,7 +1003,7 @@ _gen_initializer(const Eolian_Class *cl, Eina_Strbuf *buf, Eina_Hash *refh)
1003 Eolian_Function_Type ftype; 1003 Eolian_Function_Type ftype;
1004 const Eolian_Function *fid = eolian_implement_function_get(imp, &ftype); 1004 const Eolian_Function *fid = eolian_implement_function_get(imp, &ftype);
1005 1005
1006 if (eolian_function_is_class(fid)) continue; 1006 if (eolian_function_is_static(fid)) continue;
1007 1007
1008 if (!eina_strbuf_length_get(ops)) 1008 if (!eina_strbuf_length_get(ops))
1009 eina_strbuf_append_printf(ops, " EFL_OPS_DEFINE(ops,\n"); 1009 eina_strbuf_append_printf(ops, " EFL_OPS_DEFINE(ops,\n");