Yes, I have the same problem with Boost1.30.0/Borland C++ Builder 5.
To be more precise, when I try to compile the following:
//----------------------------------------------
#include
int main(int argc, char* argv[])
{
return 0;
}
//----------------------------------------------
, I get these errors:
[C++ Fehler] tuple_basic.hpp(158): E2434 In Template-Deklaration fehlen
Template-Parameter ('template<...>')
[C++ Fehler] tuple_basic.hpp(158): E2238 Bezeichner 'element' mehrfach
deklariert
[C++ Fehler] tuple_basic.hpp(143): E2344 'element' bereits deklariert
(in english, they should read something like:
E2434 Template declaration missing template parameters ('template<...>')
E2238 Multiple declaration of 'element'
E2344 'element' already declared
)
As a very crude way to fix the problem, I commented out the
const-specializations
of the element template in tuple.hpp:
//template
//struct element
//{
//private:
// typedef typename T::tail_type Next;
// typedef typename element::type unqualified_type;
//public:
// typedef typename boost::add_const::type type;
//};
//template<class T>
//struct element<0,const T>
//{
// typedef typename boost::add_const<typename T::head_type>::type type;
//};
Now I can at least compile code using tuples. (e.g. the knights-tour example
from boost).
Does anyone have a more elegant workaround?
Is this a bug that I should submit or is it already known?
Does anyone know if reverting to an older version of boost will solve the
problem?
Questions, questions... :-)
CU,
Elmar Bihler.