Boost logo

Boost :

Subject: [boost] [Polygon] Template error in CodeWarrior when attempting union on polygon_set_data
From: Kef Schecter (furrykef_at_[hidden])
Date: 2010-01-21 11:16:02


I hesitate to mark this as [Polygon] because the error message is in a
different part of Boost. However, I have little idea what the actual
cause of the problem is or what any of the relevant stuff even means, so
I figure [Polygon] is as good as anything at the moment...

As before, this is a custom version of CodeWarrior an embedded ARM
system, so I have no idea how well it corresponds with other versions of
CodeWarrior.

Here is a trivial program that illustrates the problem, using the
BOOST_VERY_LITTLE_SFINAE patch from the last discussion here:

#include <iostream>
#define BOOST_VERY_LITTLE_SFINAE
#include <boost/polygon/polygon.hpp>

using namespace boost::polygon;
using namespace boost::polygon::operators;

int main()
{
     polygon_set_data<int> ps;
     ps += rectangle_data<int>(0, 0, 1, 1);
     return 0;
}

This results in the following error message :

Error : illegal use of template argument dependent type 'T::type'

The error occurs in this part of boost/mpl/aux_/preprocessed/plain/and.hpp:

template< typename T1, typename T2, typename T3, typename T4 >
struct and_impl< true,T1,T2,T3,T4 >
     : and_impl<
           BOOST_MPL_AUX_NESTED_TYPE_WKND(T1)::value
         , T2, T3, T4
         , true_
>
{
};

Any ideas about what's wrong or how to fix it?

- Kef


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