[dev] Updated for C++11 functors.