[C++-sig] Re: add_property and boost::bind?

Max Khesin MKhesin at liquidnet.com
Thu Aug 5 07:46:07 CEST 2004


> You can use make_function with a Signature parameter and pass that to
> add_property.  But your bind expression above won't work.
> 
> Maybe something like:
> 
>  	.add_property("aaa", 
>         make_function(
>             boost::bind(&Foo::lookup, _1, "aaa")
>           , default_call_policies()
>           , mpl::vector1<int>()
>         )
>      )
> 

This is what I was looking for. I knew my example was not complete - it was
just wishful thinking code. But this fails to compile on vc6 & vc8, both
pretty much indicate the same error:
c:\home\mkhesin\libs\boost_1_31_0\boost\bind.hpp(246) : error C2784:
'result_traits<R,F>::type boost::_bi::list0::operator [](const
boost::_bi::bind_t<R,F,L> &) const' : could not deduce template argument for
'const boost::_bi::bind_t<R,F,L> &' from 'boost::arg<I>'
        with
        [
            I=1
        ]

any idea?
This email and any files transmitted with it are confidential and intended solely for the use of the individual or entity to whom they are addressed. If you have received this email in error please notify the system manager. This message contains confidential information and is intended only for the individual named. If you are not the named addressee you should not disseminate, distribute or copy this e-mail.



More information about the Cplusplus-sig mailing list