Boost logo

Boost :

From: Kresimir Fresl (fresl_at_[hidden])
Date: 2001-08-23 07:59:55


On Thursday 23 August 2001 14:35, I wrote:

> Jaakko Jarvi wrote:

[...]

> > > fresl> PS. There may be some other problems with tuple library:
> >
> > This was due to some missing typenames, and is now fixed.
>
> Thanx. My program can now be compiled with g++ and with Comeau C++.

Sorry, I jumped to the conclusion to early. When called with -pedantic,
g++ complains:

/usr/local/include/boost/tuple/detail/tuple_basic.hpp: In function `typename
   boost::detail::tuples::make_tuple_mapper<T0, T1, boost::null_type,
   boost::null_type, boost::null_type, boost::null_type, boost::null_type,
   boost::null_type, boost::null_type, boost::null_type>::type
   boost::make_tuple(const T0&, const T1&) [with T0 =
   std::__normal_iterator<double*, std::vector<double, std::allocator<double>
> >, T1 = double]':
[...]
/usr/local/include/boost/tuple/detail/tuple_basic.hpp:564: invalid use of
   member
   `boost::detail::tuples::make_tuple_mapper<std::__normal_iterator<double*,
   std::vector<double, std::allocator<double> > >, double, boost::null_type,
   boost::null_type, boost::null_type, boost::null_type, boost::null_type,
   boost::null_type, boost::null_type, boost::null_type>::type'

It seems that pedantic g++ (v 3.0) requires even more ;O) typenames than
Comeau:

template<class T0, class T1>
typename boost::detail::tuples::make_tuple_mapper<T0, T1>::type
inline make_tuple(const T0& t0, const T1& t1) {
  return
     typename boost::detail::tuples::make_tuple_mapper<T0, T1>::type(t0, t1);
// ^^^^^^^^^
}

fres


Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk