[range + string algos] bug with Intel C++ 7.0 on Windows

This 2-liner: --------------------------- #include <boost/algorithm/string.hpp> #include <boost/range/iterator_range.hpp> --------------------------- produces error with Intel C++ 7.0 for Windows (plugged in VC6 IDE, old Dinkumware): P:\N\src\boost_1_32_0\boost/range/iterator_range.hpp(78): error: class template "boost::algorithm::iterator_range" may not be redeclared in the current scope class iterator_range ^ P:\N\src\boost_1_32_0\boost/range/iterator_range.hpp(78): error: class template "boost::algorithm::iterator_range" has already been defined class iterator_range ------ Comment on this from Eric Niebler: it's a compiler bug, algorithm/string.hpp causes iterator_range to be declared in boost::algorithm namespace, and range/iterator_range.hpp causes a different iterator_range to be defined in the boost namespace. That's fine, but your compiler doesn't seem to like it. The fix is probably to make the string algorithms use boost::iterator_range instead of defining its own version. ------ /Pavel

On Sun, Dec 12, 2004 at 02:13:18AM +0100, Pavel Vozenilek wrote:
This 2-liner: --------------------------- #include <boost/algorithm/string.hpp> #include <boost/range/iterator_range.hpp> ---------------------------
produces error with Intel C++ 7.0 for Windows (plugged in VC6 IDE, old Dinkumware):
P:\N\src\boost_1_32_0\boost/range/iterator_range.hpp(78): error: class template "boost::algorithm::iterator_range" may not be redeclared in the current scope class iterator_range ^ P:\N\src\boost_1_32_0\boost/range/iterator_range.hpp(78): error: class template "boost::algorithm::iterator_range" has already been defined class iterator_range
------ Comment on this from Eric Niebler:
it's a compiler bug, algorithm/string.hpp causes iterator_range to be declared in boost::algorithm namespace, and range/iterator_range.hpp causes a different iterator_range to be defined in the boost namespace. That's fine, but your compiler doesn't seem to like it. The fix is probably to make the string algorithms use boost::iterator_range instead of defining its own version.
------
This is a known problem with this release. It is a plan to fix string_algo to use Boost.Range instead of its internal version Before the release, the Boost.Range was not stable enough. It has changed later on, but then I didn't want the make big changes just before the release. If I would know that it would take so long to get the release the change would have be there long time ago. Regards, Pavol

"Pavol Droba" wrote:
This 2-liner: --------------------------- #include <boost/algorithm/string.hpp> #include <boost/range/iterator_range.hpp> ---------------------------
produces error ...
This is a known problem with this release. It is a plan to fix string_algo to use Boost.Range instead of its internal version Before the release, the Boost.Range was not stable enough. It has changed later on, but then I didn't want the make big changes just before the release. If I would know that it would take so long to get the release the change would have be there long time ago.
Would you send me mail when CVS/whatever gets updated? The problem had shown itself also with BOOST_FOREACH I would like to use. /Pavel

On Sun, Dec 12, 2004 at 05:58:08PM +0100, Pavel Vozenilek wrote:
"Pavol Droba" wrote:
This 2-liner: --------------------------- #include <boost/algorithm/string.hpp> #include <boost/range/iterator_range.hpp> ---------------------------
produces error ...
This is a known problem with this release. It is a plan to fix string_algo to use Boost.Range instead of its internal version Before the release, the Boost.Range was not stable enough. It has changed later on, but then I didn't want the make big changes just before the release. If I would know that it would take so long to get the release the change would have be there long time ago.
Would you send me mail when CVS/whatever gets updated?
The problem had shown itself also with BOOST_FOREACH I would like to use.
Sure, but I don't think that I will be able to do it before christmas. Pavol
participants (2)
-
Pavel Vozenilek
-
Pavol Droba