
Joachim Faulhaber wrote:
2009/9/25 Jeff Flinn <TriumphSprint2000@hotmail.com>:
So the next issue is in map.hpp. I'm getting redefined errors on map::add(const std::parit<const _T0, _T1>&) and map::add(std::map<_T0, _T1, _T3<_T0>, _T6<const std::pair<const _T0, _T1>>>iterator, const std::pair<const _T0, _T1>&)
This is via merely #including <boost/itl/split_interval_map.hpp>. It looks like similar issues with map::subtract as well. Hmm, this sounds similar to other problems defining a template methods out of line?
I don't have a CodeWarrior compiler installed on my machine (yet), so I hope you can figure out the details.
I have committed the code changes according to your former posting to the sandbox. Concerning the redefine errors I suspect that your battlesome compiler is not satisfied with the attempt to declare the member function
map& map::add(const value_type&);
and then an overloaded member function template
private: template<class Combiner> map& map::add(const value_type&);
so I changed the names of those private member function templates adding a leading underscore '_add'. The code looses some simplicity but it compiles and works with msvc and gcc.
I hope this works for the warrior too and he can be appeased soon ;-)
Yep, that worked for both add & subtract private methods. I now get a complete compile, of course that's just with the #include <boost/itl/split_interval_map.hpp>. Now to actually instantiate some code. :-). Jeff