Type-erase setCallback
Summary: `setCallback()` functions just store the argument as a `Function`, so we don't need to specialize the templates all the way down, we can pass directly a `Function`. This reduces code size, and should not have runtime impact: either the move is elided in both cases, or if not there's no particular reason why a `Function` move should be more expensive than an arbitrary functor's (could even be faster). Reviewed By: yfeldblum, luciang Differential Revision: D20561695 fbshipit-source-id: 1973c47a5410a43eb44beea36cb1105663094eb3
Showing
Please register or sign in to comment