From: Neal Becker (ndbecker2_at_[hidden])
Date: 2006-05-02 13:01:12
David Abrahams wrote:
> "Arkadiy Vertleyb" <vertleyb_at_[hidden]> writes:
>> "Neal Becker" <ndbecker2_at_[hidden]> wrote
>>> I'd like to use boost::function to wrap (pointer to) function to pass to
>>> template functions that expect function objects. I'm just wondering,
>>> though, if using boost::function wrapper will introduce additional
>>> into the function call?
>> boost::function will introduce an extra virtual function call (which is
>> not a big deal in most cases).
> Actually it's not a virtual call, it's a call through a function
> pointer. That's one less indirection.
Do you think a smart compiler might optimize this to a direct call?
Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk