felipealmeida pushed a commit to branch master. http://git.enlightenment.org/core/efl.git/commit/?id=8240676b01d6c0f2b5cb0471a43eec0d7ef05581
commit 8240676b01d6c0f2b5cb0471a43eec0d7ef05581 Author: Felipe Magno de Almeida <fel...@expertisesolutions.com.br> Date: Thu Oct 23 18:06:13 2014 -0200 [eina-cxx] Fixed EFL_CXX_THROW not defined Fixed errors of EFL_CXX_THROW not defined when #include'ing specific eina C++ headers. --- src/bindings/eina_cxx/Eina.hh | 7 ------- src/bindings/eina_cxx/eina_accessor.hh | 1 + src/bindings/eina_cxx/eina_error.hh | 2 ++ src/bindings/eina_cxx/eina_ptrarray.hh | 1 + src/bindings/eina_cxx/eina_ptrlist.hh | 1 + src/bindings/eina_cxx/eina_stringshare.hh | 1 + src/bindings/eina_cxx/eina_thread.hh | 1 + src/bindings/eina_cxx/eina_throw.hh | 9 +++++++++ src/bindings/eina_cxx/eina_value.hh | 1 + 9 files changed, 17 insertions(+), 7 deletions(-) diff --git a/src/bindings/eina_cxx/Eina.hh b/src/bindings/eina_cxx/Eina.hh index 4e7f7c5..c1d755f 100644 --- a/src/bindings/eina_cxx/Eina.hh +++ b/src/bindings/eina_cxx/Eina.hh @@ -1,12 +1,5 @@ #ifndef EINA_HH_ #define EINA_HH_ - -#if defined ( EFL_CXX_NO_EXCEPTIONS ) -# define EFL_CXX_THROW(x) std::abort() -#else -# define EFL_CXX_THROW(x) throw (x) -#endif - /** * @file * @brief Eina C++ diff --git a/src/bindings/eina_cxx/eina_accessor.hh b/src/bindings/eina_cxx/eina_accessor.hh index 5d9a9c3..98be3af 100644 --- a/src/bindings/eina_cxx/eina_accessor.hh +++ b/src/bindings/eina_cxx/eina_accessor.hh @@ -3,6 +3,7 @@ #include <Eina.h> #include <eina_error.hh> +#include <eina_throw.hh> #include <memory> #include <iterator> diff --git a/src/bindings/eina_cxx/eina_error.hh b/src/bindings/eina_cxx/eina_error.hh index 9acfe26..24e41a8 100644 --- a/src/bindings/eina_cxx/eina_error.hh +++ b/src/bindings/eina_cxx/eina_error.hh @@ -3,6 +3,8 @@ #include <Eina.h> +#include <eina_throw.hh> + #include <system_error> /** diff --git a/src/bindings/eina_cxx/eina_ptrarray.hh b/src/bindings/eina_cxx/eina_ptrarray.hh index ecb4f97..9121de5 100644 --- a/src/bindings/eina_cxx/eina_ptrarray.hh +++ b/src/bindings/eina_cxx/eina_ptrarray.hh @@ -5,6 +5,7 @@ #include <eina_clone_allocators.hh> #include <eina_type_traits.hh> #include <eina_range_types.hh> +#include <eina_throw.hh> #include <memory> #include <iterator> diff --git a/src/bindings/eina_cxx/eina_ptrlist.hh b/src/bindings/eina_cxx/eina_ptrlist.hh index 00a59a5..d6bc9dc 100644 --- a/src/bindings/eina_cxx/eina_ptrlist.hh +++ b/src/bindings/eina_cxx/eina_ptrlist.hh @@ -8,6 +8,7 @@ #include <eina_accessor.hh> #include <eina_eo_base_fwd.hh> #include <eina_iterator.hh> +#include <eina_throw.hh> #include <memory> #include <iterator> diff --git a/src/bindings/eina_cxx/eina_stringshare.hh b/src/bindings/eina_cxx/eina_stringshare.hh index ffdde73..9c93b78 100644 --- a/src/bindings/eina_cxx/eina_stringshare.hh +++ b/src/bindings/eina_cxx/eina_stringshare.hh @@ -3,6 +3,7 @@ #include <Eina.h> #include <eina_type_traits.hh> +#include <eina_throw.hh> #include <cstring> #include <stdexcept> diff --git a/src/bindings/eina_cxx/eina_thread.hh b/src/bindings/eina_cxx/eina_thread.hh index ad851ba..f12c577 100644 --- a/src/bindings/eina_cxx/eina_thread.hh +++ b/src/bindings/eina_cxx/eina_thread.hh @@ -3,6 +3,7 @@ #include <Eina.h> #include <eina_error.hh> +#include <eina_throw.hh> #include <memory> #include <iterator> diff --git a/src/bindings/eina_cxx/eina_throw.hh b/src/bindings/eina_cxx/eina_throw.hh new file mode 100644 index 0000000..3eb382b --- /dev/null +++ b/src/bindings/eina_cxx/eina_throw.hh @@ -0,0 +1,9 @@ +#ifndef EFL_CXX_THROW + +#ifdef EFL_CXX_NO_EXCEPTIONS +# define EFL_CXX_THROW(x) std::abort() +#else +# define EFL_CXX_THROW(x) throw x +#endif + +#endif diff --git a/src/bindings/eina_cxx/eina_value.hh b/src/bindings/eina_cxx/eina_value.hh index f66d5f9..cc57191 100644 --- a/src/bindings/eina_cxx/eina_value.hh +++ b/src/bindings/eina_cxx/eina_value.hh @@ -5,6 +5,7 @@ #include <eina_stringshare.hh> #include <eina_type_traits.hh> +#include <eina_throw.hh> /** * @addtogroup Eina_Cxx_Data_Types_Group --