From 1743d74e87745a26043642a06dc8a57b1af29740 Mon Sep 17 00:00:00 2001 From: Noel Grandin Date: Tue, 17 May 2022 10:50:59 +0200 Subject: clang-tidy modernize-pass-by-value in various Change-Id: Ie091b22bd77d4e1fbff46545bc86c12f1dbafcfe Reviewed-on: https://gerrit.libreoffice.org/c/core/+/138171 Tested-by: Jenkins Reviewed-by: Noel Grandin --- store/source/storbase.hxx | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) (limited to 'store') diff --git a/store/source/storbase.hxx b/store/source/storbase.hxx index 4963ee2ddcfb..feac0db96227 100644 --- a/store/source/storbase.hxx +++ b/store/source/storbase.hxx @@ -319,8 +319,8 @@ struct PageData class Deallocate { public: - explicit Deallocate(rtl::Reference const & allocator): - allocator_(allocator) {}; + explicit Deallocate(rtl::Reference allocator): + allocator_(std::move(allocator)) {}; void operator ()(void * page) const { allocator_->deallocate(page); } @@ -425,8 +425,8 @@ public: return bool(m_xPage); } - explicit PageHolderObject (std::shared_ptr const & rxPage = std::shared_ptr()) - : m_xPage (rxPage) + explicit PageHolderObject (std::shared_ptr xPage = std::shared_ptr()) + : m_xPage (std::move(xPage)) {} void swap (PageHolderObject & rhs) @@ -547,8 +547,8 @@ protected: /** Construction. */ - explicit OStorePageObject (std::shared_ptr const & rxPage) - : m_xPage (rxPage), m_bDirty (false) + explicit OStorePageObject (std::shared_ptr rxPage) + : m_xPage (std::move(rxPage)), m_bDirty (false) {} /** Destruction. -- cgit