Boost logo

Proto :

Subject: Re: [proto] [Spirit-devel] [Spirit Development] Bug in today's boost_trunk -- ambiguous operator >
From: Hartmut Kaiser (hartmut.kaiser_at_[hidden])
Date: 2010-12-25 16:59:12


> On 12/24/2010 1:57 PM, Hartmut Kaiser wrote:
> >> Just because a type is a Fusion sequence, that doesn't mean it has
> >> boost::fusion as an associated namespace. I'm asking why
> >> boost::fusion::operator< is in the overload set.
> >
> > Ohh, sorry, I misunderstood. That's a good question indeed. However, I
> > have no answer, yet.
>
> I know why:
>
> template <
> typename Iterator
> , typename T1 = unused_type
> , typename T2 = unused_type
> , typename T3 = unused_type
> , typename T4 = unused_type
> >
> struct rule
>
> And in support/unused.hpp:
>
> using boost::fusion::unused_type;

Doh! I'm blind!

> Your use of fusion::unused_type is making boost::fusion an associated
> namespace of qi::rule. I suggest eliminating this needless reuse, or else
> use an ADL barrier namespace around Fusion's unused_type definition.

That's done in SVN and the problem is gone. Thanks!

Anyways, I'd suggest to do the outlined changes to Fusion and Proto in any
case, as in other contexts the very same problem might pop up again.

Regards Hartmut
---------------
http://boost-spirit.com


Proto list run by eric at boostpro.com