Boost logo

Boost :

From: David Abrahams (dave_at_[hidden])
Date: 2003-05-22 11:49:30


"Chris Trengove" <trengove_at_[hidden]> writes:

>> I don't know that any BCCs can do it. AFAIK they're all buggy.
>> Someone was working on a port; I think he got pretty far.
>
> I think I am the "someone", and I am fairly sure that no version of BCC will
> compile BP.
>
>> Nope, when I try it, BCC55sp2 chokes on integral constant
>> expressions, as usual. Some fairly mechanical massage might be
>> enough to make it all work, though.
>
> This is probably the most common error with BCC, and it affects some other
> parts of Boost as well. The compiler is happy if these static integral
> constants are explicitly qualified
>
> template <class T>
> struct Y {
> static const bool value = ... // some test here.
> typedef X<Y::value>::type type; // must have Y::value, not just
> value.
> };

Or if you use the MPL protocol of working with types instead of
integral constants directly.

-- 
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