Boost logo

Boost :

From: David Abrahams (dave_at_[hidden])
Date: 2006-12-10 09:07:36


Andreas Pokorny <andreas.pokorny_at_[hidden]> writes:

> Hi,
> GCC-4.1.1 gives me the attached error message while compiling
> dynamic_image.
>
> It boils down to:
>
> dynamic_image.cpp:14: instantiated from here
> boost/mpl/aux_/preprocessed/gcc/template_arity.hpp:85: error: call of overloaded 'arity_helper( aux::type_wrapper< .... >,aux::arity_tag<1>)' is ambiguous
> boost/mpl/aux_/preprocessed/gcc/template_arity.hpp:30: note: candidates are: char (&aux::arity_helper(...))[1]
> boost/mpl/aux_/preprocessed/gcc/template_arity.hpp:37: note: char (&aux::arity_helper(::aux::type_wrapper<F<T1> >,aux::arity_tag<1>))[2]
> boost/mpl/aux_/preprocessed/gcc/template_arity.hpp:37: note: char (&aux::arity_helper(::aux::type_wrapper<F<T1> >,aux::arity_tag<1>))[2]
>
> Is this a known mpl<->gcc-4.1.1 issue?

Looks like a clear GCC-4.1.1 bug to me. The error message says the
overload on line 37 is ambiguous with itself!

That said, if you're trying to use MPL lambda expressions with
templates that have 6 or more arguments, I would expect an error here
(if a more intelligible one).

-- 
Dave Abrahams
Boost Consulting
www.boost-consulting.com

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