From d00971d2c9b43c0dc060551463353e9f2c849f73 Mon Sep 17 00:00:00 2001 From: Frank Dellaert Date: Wed, 25 Jan 2023 22:59:22 -0800 Subject: [PATCH] Use boost::shared ptr --- gtsam/nonlinear/Values.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gtsam/nonlinear/Values.h b/gtsam/nonlinear/Values.h index 48c9bd1ad9..74f22a27df 100644 --- a/gtsam/nonlinear/Values.h +++ b/gtsam/nonlinear/Values.h @@ -192,8 +192,8 @@ namespace gtsam { const_iterator_type it_; deref_iterator(const_iterator_type it) : it_(it) {} ConstKeyValuePair operator*() const { return {it_->first, *(it_->second)}; } - std::unique_ptr operator->() { - return std::make_unique(it_->first, *(it_->second)); + boost::shared_ptr operator->() { + return boost::make_shared(it_->first, *(it_->second)); } bool operator==(const deref_iterator& other) const { return it_ == other.it_;