[bind] static member function binding

Hi,
does Boost.Bind contain anything to create a function object that is
statically bound to a member function?
IIUC all function objects created by bind contain a function pointer,
so they have overhead compared to a manual function object.
something like:
struct A{ void f(); }
A *a;
bind

Zitat von Stefan Strasser
does Boost.Bind contain anything to create a function object that is statically bound to a member function?
since I haven't found anything, I think this would be a useful
addition to boost.MemFn. (although it might be performance
nitpicking...)
template<class F>
__declspec(noinline) void dispatch(F f){
f();
}
int main(){
A a;
//compiler inlines A::f into dispatch()
dispatch(boost::bind(smem_fun
participants (1)
-
Stefan Strasser