Boost logo

Boost :

From: Chris Trengove (trengove_at_[hidden])
Date: 2002-08-22 17:27:55


I think the problem is that, inside the "is_member_function_pointer_select"
template, the compiler no longer accepts the use of the return value of a
function inside the static initialiser.

              bool, value = (1 ==
sizeof(detail::is_member_function_pointer_helper(make_t()))) );

I have temporarily fixed this by changing the above to

    enum { value = (1 ==
sizeof(detail::is_member_function_pointer_helper(make_t()))) };

which the compiler accepts. After testing, I found that anything like

template <class T>
struct X
    static T& f();
    static const int value = sizeof(f());

will not compile, whether or not instantiated.

I came across this while messing with Boost Python v2, using the recently
patched version of the CBuilder 6 compiler (0x562). So it looks like there
may be some significant changes for 0x562 and 0x570 (hopefully some bug
fixes as well as new bugs).


"John Maddock" <john_maddock_at_[hidden]> wrote in message
> First the good news: Borland have just released a new compiler version
> (0x570) for linux - I've made a few config changes to support this (and
> patched execution_monitor.cpp slightly).
> However is_member_function_pointer is failing badly with this compiler
> version (anything that includes composite_traits.hpp will fail to
> I don't have a patch for this yet, if anyone has any ideas I'm all ears.
> Also the signal test program isn't building with C++ Builder 6 - it looks
> like something is trying to instantiate function_traits<int>, again I'm
> hoping someone will have some ideas about this.
> Regards,
> John Maddock
> _______________________________________________
> Unsubscribe & other changes:

Boost list run by bdawes at, gregod at, cpdaniel at, john at