Read-only mirrors. Development, issues and pull requests are on GitHub.

summaryrefslogtreecommitdiffhomepage
path: root/src/catch2/catch_registry_hub.cpp
diff options
context:
space:
mode:
authorMartin Hořeňovský2020-01-25 14:07:29 +0100
committerMartin Hořeňovský2020-01-25 14:07:29 +0100
commit7134ad9913a1bc206726b9f1c057e1e625a08c27 (patch)
tree8e94f1ed64d5a75a77505c0dab9da4c9e35923e3 /src/catch2/catch_registry_hub.cpp
parent827733fe81201ec80749e3453167ff775c843d8a (diff)
downloadcatch3-7134ad9913a1bc206726b9f1c057e1e625a08c27.tar.gz
Replace shared_ptr with unique_ptr for reporters
Diffstat (limited to 'src/catch2/catch_registry_hub.cpp')
-rw-r--r--src/catch2/catch_registry_hub.cpp8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/catch2/catch_registry_hub.cpp b/src/catch2/catch_registry_hub.cpp
index f49506a2..8194c417 100644
--- a/src/catch2/catch_registry_hub.cpp
+++ b/src/catch2/catch_registry_hub.cpp
@@ -43,11 +43,11 @@ namespace Catch {
}
public: // IMutableRegistryHub
- void registerReporter( std::string const& name, IReporterFactoryPtr const& factory ) override {
- m_reporterRegistry.registerReporter( name, factory );
+ void registerReporter( std::string const& name, IReporterFactoryPtr factory ) override {
+ m_reporterRegistry.registerReporter( name, std::move(factory) );
}
- void registerListener( IReporterFactoryPtr const& factory ) override {
- m_reporterRegistry.registerListener( factory );
+ void registerListener( IReporterFactoryPtr factory ) override {
+ m_reporterRegistry.registerListener( std::move(factory) );
}
void registerTest( std::unique_ptr<TestCaseInfo>&& testInfo, std::unique_ptr<ITestInvoker>&& invoker ) override {
m_testCaseRegistry.registerTest( std::move(testInfo), std::move(invoker) );