aboutsummaryrefslogtreecommitdiffstats
path: root/src/tests
diff options
context:
space:
mode:
authorDaniel Kolesa <d.kolesa@osg.samsung.com>2017-09-22 18:01:15 +0200
committerDaniel Kolesa <d.kolesa@osg.samsung.com>2017-09-22 18:01:15 +0200
commit1577c576e6141eeb80f9e6c7018310690bb1d8bc (patch)
tree787ebb7cad35729ca10d844587d268d574c20972 /src/tests
parenteolian: merge REGULAR and COMPLEX types (diff)
downloadefl-1577c576e6141eeb80f9e6c7018310690bb1d8bc.tar.gz
eolian: remove static_array and terminated_array
These types are of questionable value and the API was not entirely thought out - remove for now, and if a legitimate use is found later, they may be readded (with a better API), but typically it seems best to redesign the bad APIs around safe containers...
Diffstat (limited to 'src/tests')
-rw-r--r--src/tests/eolian/data/struct.eo2
-rw-r--r--src/tests/eolian/data/struct_ref.c2
-rw-r--r--src/tests/eolian/eolian_parsing.c15
3 files changed, 0 insertions, 19 deletions
diff --git a/src/tests/eolian/data/struct.eo b/src/tests/eolian/data/struct.eo
index cb664f366c..55e6c50f4c 100644
--- a/src/tests/eolian/data/struct.eo
+++ b/src/tests/eolian/data/struct.eo
@@ -1,8 +1,6 @@
struct Named {
field: ptr(int);
something: string;
- arr: static_array<int, 16>;
- tarr: terminated_array<string>;
}
struct Another {
diff --git a/src/tests/eolian/data/struct_ref.c b/src/tests/eolian/data/struct_ref.c
index cb64af6cb3..42f34a9be2 100644
--- a/src/tests/eolian/data/struct_ref.c
+++ b/src/tests/eolian/data/struct_ref.c
@@ -15,8 +15,6 @@ typedef struct _Named
{
int *field;
const char *something;
- int arr[16];
- const char **tarr;
} Named;
typedef struct _Another
diff --git a/src/tests/eolian/eolian_parsing.c b/src/tests/eolian/eolian_parsing.c
index 79fdb64bb4..9e2c0d9bfc 100644
--- a/src/tests/eolian/eolian_parsing.c
+++ b/src/tests/eolian/eolian_parsing.c
@@ -677,21 +677,6 @@ START_TEST(eolian_struct)
fail_if(!(type_name = eolian_type_c_type_get(ftype, EOLIAN_C_TYPE_DEFAULT)));
fail_if(strcmp(type_name, "const char *"));
eina_stringshare_del(type_name);
- fail_if(!(field = eolian_typedecl_struct_field_get(tdl, "arr")));
- fail_if(!(ftype = eolian_typedecl_struct_field_type_get(field)));
- fail_if(eolian_type_is_ptr(ftype));
- fail_if(eolian_type_array_size_get(ftype) != 16);
- fail_if(eolian_type_type_get(ftype) != EOLIAN_TYPE_STATIC_ARRAY);
- fail_if(!(type_name = eolian_type_c_type_get(ftype, EOLIAN_C_TYPE_DEFAULT)));
- fail_if(strcmp(type_name, "int *"));
- eina_stringshare_del(type_name);
- fail_if(!(field = eolian_typedecl_struct_field_get(tdl, "tarr")));
- fail_if(!(ftype = eolian_typedecl_struct_field_type_get(field)));
- fail_if(eolian_type_is_ptr(ftype));
- fail_if(!(type_name = eolian_type_c_type_get(ftype, EOLIAN_C_TYPE_DEFAULT)));
- fail_if(eolian_type_type_get(ftype) != EOLIAN_TYPE_TERMINATED_ARRAY);
- fail_if(strcmp(type_name, "const char **"));
- eina_stringshare_del(type_name);
/* referencing */
fail_if(!(tdl = eolian_typedecl_struct_get_by_name(unit, "Another")));