Include <functional>
Fix warning on mac.
Compile on mac.