diff --git a/topi/include/topi/reduction.h b/topi/include/topi/reduction.h index d68b9b390419..777c103ec950 100644 --- a/topi/include/topi/reduction.h +++ b/topi/include/topi/reduction.h @@ -262,7 +262,7 @@ using FIdentity = std::function(std::vector types)>; inline FCommReduce MakeCommReducer(FCombine fcombine, FIdentity fidentity, std::string name = "reduce") { - return [fcombine, fidentity, &name] + return [fcombine, fidentity, name] (Array exprs, const Array& axis, Expr* condition) { Array lhs, rhs; std::vector dtypes;