diff --git a/tests/cpp/tree/test_quantile_hist.cc b/tests/cpp/tree/test_quantile_hist.cc index 4959ce453775..6be71687191c 100644 --- a/tests/cpp/tree/test_quantile_hist.cc +++ b/tests/cpp/tree/test_quantile_hist.cc @@ -26,9 +26,8 @@ class QuantileHistMock : public QuantileHistMaker { struct BuilderMock : public QuantileHistMaker::Builder { using RealImpl = QuantileHistMaker::Builder; - BuilderMock(const TrainParam ¶m, std::unique_ptr pruner, - DMatrix const *fmat, GenericParameter const* ctx) - : RealImpl(1, param, std::move(pruner), fmat, ObjInfo{ObjInfo::kRegression}, ctx) {} + BuilderMock(const TrainParam& param, DMatrix const* fmat, GenericParameter const* ctx) + : RealImpl(1, param, fmat, ObjInfo{ObjInfo::kRegression}, ctx) {} public: void TestInitData(const GHistIndexMatrix& gmat, @@ -113,10 +112,10 @@ class QuantileHistMock : public QuantileHistMaker { dmat_ = RandomDataGenerator(kNRows, kNCols, 0.8).Seed(3).GenerateDMatrix(); ctx_.UpdateAllowUnknown(Args{}); if (single_precision_histogram) { - float_builder_.reset(new BuilderMock(param_, std::move(pruner_), dmat_.get(), &ctx_)); + float_builder_.reset(new BuilderMock(param_, dmat_.get(), &ctx_)); } else { double_builder_.reset( - new BuilderMock(param_, std::move(pruner_), dmat_.get(), &ctx_)); + new BuilderMock(param_, dmat_.get(), &ctx_)); } } ~QuantileHistMock() override = default;