Commit 3441b95e by Yuta Hinokuma Committed by Tianqi Chen

Removed std::unary_function because it is deprecated and removed in newer…

Removed std::unary_function because it is deprecated and removed in newer c++(https://en.cppreference.com/w/cpp/utility/functional/unary_function) (#2962)
parent 17351875
......@@ -44,7 +44,7 @@ class TransformMemorizerNode : public Node {
public:
// map from (Expr, src_layout, dst_layout) to transformed Expr
using TransformKey = std::tuple<const Node*, std::string, std::string>;
struct key_hash : public std::unary_function<TransformKey , std::size_t> {
struct key_hash : public std::function<std::size_t(TransformKey)> {
std::size_t operator()(const TransformKey& k) const {
return dmlc::HashCombine<std::string>(dmlc::HashCombine<std::string>(
std::hash<const Node*>()(std::get<0>(k)), std::get<1>(k)), (std::get<2>(k)));
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment