summaryrefslogtreecommitdiff
path: root/src/tests/ecore
diff options
context:
space:
mode:
authorMarcel Hollerbach <mail@marcel-hollerbach.de>2019-02-09 18:45:27 +0100
committerMarcel Hollerbach <mail@marcel-hollerbach.de>2019-02-13 16:59:58 +0100
commit37d2d378ec2e2d1f9a3941372ef4d818996291c7 (patch)
treee100879fbdc9ce0d2ce810be81977be97125603b /src/tests/ecore
parent3b2a5a429be16e5b8e5d322b7a077a2c849586b8 (diff)
eolian: drop class function overriding
Until this commit eo did class functions as part of the vtable, which enabled those functions to be overwritten in classes inheriting another class. However in task T7675 we decided that this is not really good for bindings, as most OOP languages do not support this sort of feature. After this commit eolian realizes class function completly outside of the vtable, the c-symbol that is the class funciton is now just directly redirecting to a implementation, without the involvement of the vtable. This also means a change to the syntax created by eo: Calling before: class_function(CLASS_A); Calling after: class_function(); Implementation before: class_function(const Eo *obj, void *pd) { ... } Implementation after: class_function(void) { ... } This fixes T7675. Co-authored-by: lauromauro <lauromoura@expertisesolutions.com.br> Reviewed-by: Daniel Kolesa <daniel@octaforge.org> Differential Revision: https://phab.enlightenment.org/D7901
Diffstat (limited to 'src/tests/ecore')
-rw-r--r--src/tests/ecore/efl_app_suite.c2
-rw-r--r--src/tests/ecore/efl_app_test_env.c4
-rw-r--r--src/tests/ecore/efl_app_test_loop.c14
-rw-r--r--src/tests/ecore/efl_app_test_loop_timer.c2
4 files changed, 11 insertions, 11 deletions
diff --git a/src/tests/ecore/efl_app_suite.c b/src/tests/ecore/efl_app_suite.c
index 2cab632622..957cb3099e 100644
--- a/src/tests/ecore/efl_app_suite.c
+++ b/src/tests/ecore/efl_app_suite.c
@@ -16,7 +16,7 @@ EFL_START_TEST(efl_app_test_efl_build_version)
16 16
17 ecore_init(); 17 ecore_init();
18 18
19 app = efl_app_main_get(EFL_APP_CLASS); 19 app = efl_app_main_get();
20 fail_if(!efl_isa(app, EFL_APP_CLASS)); 20 fail_if(!efl_isa(app, EFL_APP_CLASS));
21 21
22 efl_build_version_set(EFL_VERSION_MAJOR, EFL_VERSION_MINOR, 0, 0, NULL, EFL_BUILD_ID); 22 efl_build_version_set(EFL_VERSION_MAJOR, EFL_VERSION_MINOR, 0, 0, NULL, EFL_BUILD_ID);
diff --git a/src/tests/ecore/efl_app_test_env.c b/src/tests/ecore/efl_app_test_env.c
index 63bad166a2..e7e5a2e034 100644
--- a/src/tests/ecore/efl_app_test_env.c
+++ b/src/tests/ecore/efl_app_test_env.c
@@ -96,7 +96,7 @@ EFL_END_TEST
96 96
97EFL_START_TEST(efl_core_env_test_process) 97EFL_START_TEST(efl_core_env_test_process)
98{ 98{
99 Efl_Core_Env *env_fork, *env = efl_env_self(EFL_CORE_PROC_ENV_CLASS); 99 Efl_Core_Env *env_fork, *env = efl_env_self();
100 100
101 ck_assert(env); 101 ck_assert(env);
102 102
@@ -110,7 +110,7 @@ EFL_END_TEST
110 110
111EFL_START_TEST(efl_core_env_test_undepend_fork) 111EFL_START_TEST(efl_core_env_test_undepend_fork)
112{ 112{
113 Efl_Core_Env *env_fork, *env = efl_env_self(EFL_CORE_PROC_ENV_CLASS); 113 Efl_Core_Env *env_fork, *env = efl_env_self();
114 114
115 ck_assert(env); 115 ck_assert(env);
116 116
diff --git a/src/tests/ecore/efl_app_test_loop.c b/src/tests/ecore/efl_app_test_loop.c
index b37ba414ab..0ab7bb6bdb 100644
--- a/src/tests/ecore/efl_app_test_loop.c
+++ b/src/tests/ecore/efl_app_test_loop.c
@@ -15,24 +15,24 @@ EFL_START_TEST(efl_app_test_efl_loop_register)
15 15
16 ecore_init(); 16 ecore_init();
17 17
18 t = efl_provider_find(efl_app_main_get(EFL_APP_CLASS), EFL_LOOP_CLASS); 18 t = efl_provider_find(efl_app_main_get(), EFL_LOOP_CLASS);
19 fail_if(!efl_isa(t, EFL_LOOP_CLASS)); 19 fail_if(!efl_isa(t, EFL_LOOP_CLASS));
20 fail_if(!efl_isa(t, EFL_APP_CLASS)); 20 fail_if(!efl_isa(t, EFL_APP_CLASS));
21 21
22 t = efl_provider_find(efl_app_main_get(EFL_APP_CLASS), EFL_LOOP_TIMER_CLASS); 22 t = efl_provider_find(efl_app_main_get(), EFL_LOOP_TIMER_CLASS);
23 fail_if(t != NULL); 23 fail_if(t != NULL);
24 24
25 n = efl_add(EFL_LOOP_TIMER_CLASS, efl_app_main_get(EFL_APP_CLASS), 25 n = efl_add(EFL_LOOP_TIMER_CLASS, efl_app_main_get(),
26 efl_loop_timer_interval_set(efl_added, 1.0)); 26 efl_loop_timer_interval_set(efl_added, 1.0));
27 efl_loop_register(efl_app_main_get(EFL_APP_CLASS), EFL_LOOP_TIMER_CLASS, n); 27 efl_loop_register(efl_app_main_get(), EFL_LOOP_TIMER_CLASS, n);
28 28
29 t = efl_provider_find(efl_app_main_get(EFL_APP_CLASS), EFL_LOOP_TIMER_CLASS); 29 t = efl_provider_find(efl_app_main_get(), EFL_LOOP_TIMER_CLASS);
30 fail_if(!efl_isa(t, EFL_LOOP_TIMER_CLASS)); 30 fail_if(!efl_isa(t, EFL_LOOP_TIMER_CLASS));
31 fail_if(t != n); 31 fail_if(t != n);
32 32
33 efl_loop_unregister(efl_app_main_get(EFL_APP_CLASS), EFL_LOOP_TIMER_CLASS, n); 33 efl_loop_unregister(efl_app_main_get(), EFL_LOOP_TIMER_CLASS, n);
34 34
35 t = efl_provider_find(efl_app_main_get(EFL_APP_CLASS), EFL_LOOP_TIMER_CLASS); 35 t = efl_provider_find(efl_app_main_get(), EFL_LOOP_TIMER_CLASS);
36 fail_if(t != NULL); 36 fail_if(t != NULL);
37 37
38 ecore_shutdown(); 38 ecore_shutdown();
diff --git a/src/tests/ecore/efl_app_test_loop_timer.c b/src/tests/ecore/efl_app_test_loop_timer.c
index 999c5f1743..38d16a9728 100644
--- a/src/tests/ecore/efl_app_test_loop_timer.c
+++ b/src/tests/ecore/efl_app_test_loop_timer.c
@@ -66,7 +66,7 @@ EFL_END_TEST
66 66
67EFL_START_TEST(efl_app_test_loop_timer_invalid) 67EFL_START_TEST(efl_app_test_loop_timer_invalid)
68{ 68{
69 Efl_Object *t = efl_add(EFL_LOOP_TIMER_CLASS, efl_app_main_get(EFL_APP_CLASS)); 69 Efl_Object *t = efl_add(EFL_LOOP_TIMER_CLASS, efl_app_main_get());
70 fail_if(t != NULL); 70 fail_if(t != NULL);
71} 71}
72EFL_END_TEST 72EFL_END_TEST