Boost logo

Boost :

From: Howard Hinnant (hinnant_at_[hidden])
Date: 2000-01-18 22:27:12


Dave Abrahams wrote on 1/18/2000 8:36 PM
>> Ladies and Germs,
>> The following doesn't seem to work with the latest
>> MW Codewarrior tools.....
>> Is this a known problem, unknown problem, or, am I smokin' crack?
>>
>> #include <boost/array.hpp>
>>
>> static void test_boost() {
>> static int r[] = { 5, 4, 3, 2, 1, 0 } ;
>> cout << *(boost::begin(r)) << flush;
>> }
>>
>> Error : function call 'begin(int *)' does not match
>> 'boost::begin(T0 &)'
>> 'boost::begin(T0[{targ_expr}] &)' // seems to me it should
>> match this!!!
>> CoreTest.cp line 419 cout << *(boost::begin(r)) << flush;
>>
>> My theory, (ahem), is this.....
>> MW Codewarrior compiler is losing the 'arrayness' of 'r' as SOON as
>> you pass it as a function parameter (without matching the function
>> template parameters first).
>>
>> Thanks ahead of time,
>> Reggie.
>
>I think this is a CodeWarrior bug that they know about, but I'll wait for
>Howard to confirm this one.

Confirmed. Looks like it is already fixed for the next release.

-Howard


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