summaryrefslogtreecommitdiff
path: root/src/lib
diff options
context:
space:
mode:
authorDaniel Kolesa <d.kolesa@osg.samsung.com>2016-03-01 13:44:43 +0000
committerDaniel Kolesa <d.kolesa@osg.samsung.com>2016-03-03 18:58:11 +0000
commit5401c775ec3ca95ad3c7d303238d9d53134414f4 (patch)
tree88dfb5d3002e8c34d89fd5636fb43398efe47627 /src/lib
parent4c4fbfae0bfb739fd0d87d452022d7026d0645f9 (diff)
downloadefl-5401c775ec3ca95ad3c7d303238d9d53134414f4.tar.gz
eolian: remove database_type_print (unused)
Diffstat (limited to 'src/lib')
-rw-r--r--src/lib/eolian/database_type.c80
-rw-r--r--src/lib/eolian/eolian_database.h1
2 files changed, 0 insertions, 81 deletions
diff --git a/src/lib/eolian/database_type.c b/src/lib/eolian/database_type.c
index fc24d9beb9..2d5b11a092 100644
--- a/src/lib/eolian/database_type.c
+++ b/src/lib/eolian/database_type.c
@@ -291,83 +291,3 @@ database_type_to_str(const Eolian_Type *tp, Eina_Strbuf *buf, const char *name)
eina_strbuf_append(buf, name);
}
}
-
-static void
-_typedef_print(Eolian_Type *tp)
-{
- printf("type %s: ", tp->full_name);
- database_type_print(tp->base_type);
-}
-
-void
-database_expr_print(Eolian_Expression *exp)
-{
- Eolian_Value val = eolian_expression_eval(exp, EOLIAN_MASK_ALL);
- const char *ret = eolian_expression_value_to_literal(&val);
- printf("%s", ret);
- eina_stringshare_del(ret);
-}
-
-void
-database_type_print(Eolian_Type *tp)
-{
- if (tp->type == EOLIAN_TYPE_ALIAS)
- {
- _typedef_print(tp);
- return;
- }
- if (tp->is_own)
- printf("own(");
- if (tp->is_const)
- printf("const(");
- if (tp->type == EOLIAN_TYPE_REGULAR || tp->type == EOLIAN_TYPE_COMPLEX
- || tp->type == EOLIAN_TYPE_CLASS)
- printf("%s", tp->full_name);
- else if (tp->type == EOLIAN_TYPE_VOID)
- printf("void");
- else if (tp->type == EOLIAN_TYPE_STRUCT_OPAQUE)
- printf("struct %s", tp->full_name);
- else if (tp->type == EOLIAN_TYPE_POINTER)
- {
- database_type_print(tp->base_type);
- putchar('*');
- }
- else if (tp->type == EOLIAN_TYPE_STRUCT)
- {
- Eolian_Struct_Type_Field *sf;
- Eina_List *m;
- printf("struct ");
- if (tp->full_name) printf("%s ", tp->full_name);
- printf("{ ");
- EINA_LIST_FOREACH(tp->field_list, m, sf)
- {
- printf("%s: ", sf->name);
- database_type_print(sf->type);
- printf("; ");
- }
- printf("}");
- }
- else if (tp->type == EOLIAN_TYPE_ENUM)
- {
- Eolian_Enum_Type_Field *ef;
- Eina_List *m;
- printf("enum %s ", tp->full_name);
- printf("{ ");
- EINA_LIST_FOREACH(tp->field_list, m, ef)
- {
- printf("%s", ef->name);
- if (ef->value)
- {
- printf(" = ");
- database_expr_print(ef->value);
- }
- if (m != eina_list_last(tp->field_list))
- printf(", ");
- }
- printf(" }");
- }
- if (tp->is_own)
- putchar(')');
- if (tp->is_const)
- putchar(')');
-}
diff --git a/src/lib/eolian/eolian_database.h b/src/lib/eolian/eolian_database.h
index bf9c107a5c..4919c55bf5 100644
--- a/src/lib/eolian/eolian_database.h
+++ b/src/lib/eolian/eolian_database.h
@@ -310,7 +310,6 @@ void database_typedef_del(Eolian_Type *tp);
void database_typedecl_del(Eolian_Typedecl *tp);
-void database_type_print(Eolian_Type *type);
void database_type_to_str(const Eolian_Type *tp, Eina_Strbuf *buf, const char *name);
/* expressions */