2005-05-02 Thierry GERAUD <theo(a)tegucigalpa.lrde.epita.fr>
* oln/core/ch_value_type.hh: Fix bug.
* oln/core/gen/image_with_nbh.hh (ch_value_type): Add.
Index: oln/core/ch_value_type.hh
===================================================================
--- oln/core/ch_value_type.hh (revision 180)
+++ oln/core/ch_value_type.hh (working copy)
@@ -37,12 +37,12 @@
// FIXME: bad name...
# define oln_ch_concrete_type(I, T) \
- typename ch_value_type< oln_type_of(I, concrete), T >::ret
+ typename oln::ch_value_type< oln_type_of(I, concrete), T >::ret
namespace oln {
- template<class I, class T = oln_type_of(I, value)>
+ template<class I, class T>// FIXME: remove cause pb with compiler =
oln_type_of(I, value)>
struct ch_value_type
{
// FIXME: Use/extend oln/core/properties.hh mechanisms, instead of
Index: oln/core/gen/image_with_nbh.hh
===================================================================
--- oln/core/gen/image_with_nbh.hh (revision 180)
+++ oln/core/gen/image_with_nbh.hh (working copy)
@@ -30,6 +30,7 @@
# include <oln/core/abstract/image_with_extension.hh>
# include <oln/core/abstract/neighborhood.hh>
+# include <oln/core/ch_value_type.hh>
# include <oln/utils/record.hh>
@@ -51,6 +52,13 @@
typedef is_a<abstract::image_with_nbh> image_neighbness_type;
typedef N neighb_type;
typedef image_with_nbh< oln_type_of(I, concrete), N> concrete_type;
+
+ template <typename U>
+ struct ch_value_type
+ {
+ typedef typename oln::ch_value_type<I, U>::ret IU;
+ typedef oln::image_with_nbh< IU, N > ret;
+ };
};