Removed dependency on <functional>