From: Thorsten Ottosen (nesotto_at_[hidden])
Date: 2004-04-12 05:28:43
"Vladimir Prus" <ghost_at_[hidden]> wrote in message
> What I was saying is that bind uses non-const reference for operator(), so
> if you use:
> bind(foo, _1)(i);
> bind( foo, _1 )(ci);
> then it will work ok. In fact, first one compiles and the second one does
> And, BTW, "foo(i)" compiles just fine too, so your 'proper_forward(i)'
> should compile too, but it does not.
yes, but there is a huge difference between compiling wrong code silentltly
ok code. The use of ref() nicely documents that an address is taken.
> bind(foo, i)();
> bind(foo, ci)();
> I don't have any opinion yet.
I guess I didn't know that I was "misusing" bind(). Anyway, I find it wrong
bind(foo,_1)(i) and bind(foo,i)() differs.
Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk