I downloaded boost 1.30.0 but am having trouble with the Tuple
library with Visial Studio.Net. The following code produces the
errors:
#include
boost::tuple f()
{
return boost::tuple(1, 1);
}
c:\cpp\boost_1_30_0
\boost\tuple\detail\tuple_basic_no_partial_spec.hpp(411) : error
C2039: 'map_tuple_to_cons' : is not a member of 'boost::detail'
This code is:
class tuple :
public detail::map_tuple_to_cons::cons1
This appears to be a compiler bug. The code at this line is in the
boost::tuples namespace but the compiler seems to be ignoring
boost::tuples::detail. I replaced detail with tuples::detail in many
places in this code.
Next error:
c:\cpp\boost_1_30_0
\boost\tuple\detail\tuple_basic_no_partial_spec.hpp(456) : error
C2629: unexpected 'boost::tuple ('
This code is:
template
explicit tuple(const cons& other) :
cons1(other.head, other.tail)
{
}
Visual C++ doesn't seem to understand template constructors. I
replaced the template constructor with a copy constructor. VC++
failed to create the default copy constructor :(
c:\cpp\boost_1_30_0
\boost\tuple\detail\tuple_basic_no_partial_spec.hpp(470) : error
C2143: syntax error : missing ',' before '<'
The code is:
template
self_type& operator=(const cons& other)
Lookup failed on cons. I added tuples:: prefix.
Has anyone else run into these or might I have a configuration
problem?
Thanks!
Todd Fleming