aboutsummaryrefslogtreecommitdiffstats
path: root/src/bin/eolian
diff options
context:
space:
mode:
authorDaniel Kolesa <d.kolesa@osg.samsung.com>2018-01-16 16:10:43 +0100
committerDaniel Kolesa <d.kolesa@osg.samsung.com>2018-01-16 16:37:52 +0100
commitdd2e579fecbe6ec4d1e0e7d46c82daff39be03c5 (patch)
tree3de0f6b1e40b3d5477f87792f46e186312972d88 /src/bin/eolian
parenteolian: cache enum expr in the database (diff)
downloadefl-dd2e579fecbe6ec4d1e0e7d46c82daff39be03c5.tar.gz
eolian: do not require unit for expr eval APIs
The necessary information is now stored directly in the expr during database validation. Also enable expr validation for params.
Diffstat (limited to 'src/bin/eolian')
-rw-r--r--src/bin/eolian/sources.c4
-rw-r--r--src/bin/eolian/types.c6
2 files changed, 5 insertions, 5 deletions
diff --git a/src/bin/eolian/sources.c b/src/bin/eolian/sources.c
index e6dff01eb7..c430eb70df 100644
--- a/src/bin/eolian/sources.c
+++ b/src/bin/eolian/sources.c
@@ -108,7 +108,7 @@ _append_defval(const Eolian_Unit *src, Eina_Strbuf *buf,
{
if (exp)
{
- Eolian_Value val = eolian_expression_eval_type(src, exp, tp);
+ Eolian_Value val = eolian_expression_eval_type(exp, tp);
Eina_Stringshare *lit = eolian_expression_value_to_literal(&val);
if (lit)
{
@@ -474,7 +474,7 @@ _gen_func(const Eolian_Unit *src, const Eolian_Class *cl,
}
else if ((ftype != EOLIAN_PROP_SET) && dfv)
{
- Eolian_Value val = eolian_expression_eval(src, dfv, EOLIAN_MASK_ALL);
+ Eolian_Value val = eolian_expression_eval(dfv, EOLIAN_MASK_ALL);
if (val.type)
{
Eina_Stringshare *vals = eolian_expression_value_to_literal(&val);
diff --git a/src/bin/eolian/types.c b/src/bin/eolian/types.c
index d8285fbeb4..fc57ba0d37 100644
--- a/src/bin/eolian/types.c
+++ b/src/bin/eolian/types.c
@@ -87,7 +87,7 @@ _type_generate(const Eolian_Unit *src, const Eolian_Typedecl *tp,
else
{
Eolian_Value val =
- eolian_expression_eval(src, vale, EOLIAN_MASK_INT);
+ eolian_expression_eval(vale, EOLIAN_MASK_INT);
const char *lit = eolian_expression_value_to_literal(&val);
eina_strbuf_append_printf(buf, " %s = %s", membn, lit);
const char *exp = eolian_expression_serialize(vale);
@@ -183,7 +183,7 @@ _var_generate(const Eolian_Unit *src, const Eolian_Variable *vr, Eina_Bool legac
eina_strbuf_prepend_printf(buf, "#ifndef %s\n", fn);
eina_strbuf_append_printf(buf, "#define %s ", fn);
const Eolian_Expression *vv = eolian_variable_value_get(vr);
- Eolian_Value val = eolian_expression_eval_type(src, vv, vt);
+ Eolian_Value val = eolian_expression_eval_type(vv, vt);
Eina_Stringshare *lit = eolian_expression_value_to_literal(&val);
eina_strbuf_append(buf, lit);
Eina_Stringshare *exp = eolian_expression_serialize(vv);
@@ -290,7 +290,7 @@ void eo_gen_types_source_gen(const Eolian_Unit *src,
eina_stringshare_del(ct);
free(fn);
- Eolian_Value val = eolian_expression_eval_type(src, vv, vt);
+ Eolian_Value val = eolian_expression_eval_type(vv, vt);
Eina_Stringshare *lit = eolian_expression_value_to_literal(&val);
eina_strbuf_append(buf, lit);
eina_strbuf_append_char(buf, ';');