summaryrefslogtreecommitdiffstats
path: root/Source/cmGlobalNinjaGenerator.h
diff options
context:
space:
mode:
authorMarc Chevrier <marc.chevrier@gmail.com>2020-01-02 16:07:09 (GMT)
committerMarc Chevrier <marc.chevrier@gmail.com>2020-01-07 10:03:11 (GMT)
commita00960288bedb3cd9495222e7917c9a1092ce4c9 (patch)
tree03843ce4517050e051c1a225912841c5dabb8174 /Source/cmGlobalNinjaGenerator.h
parente353d8bd9bfd90396089e514d5b77f027ac27e99 (diff)
downloadCMake-a00960288bedb3cd9495222e7917c9a1092ce4c9.zip
CMake-a00960288bedb3cd9495222e7917c9a1092ce4c9.tar.gz
CMake-a00960288bedb3cd9495222e7917c9a1092ce4c9.tar.bz2
GlobalGenerator family: modernize memory management
Diffstat (limited to 'Source/cmGlobalNinjaGenerator.h')
-rw-r--r--Source/cmGlobalNinjaGenerator.h10
1 files changed, 6 insertions, 4 deletions
diff --git a/Source/cmGlobalNinjaGenerator.h b/Source/cmGlobalNinjaGenerator.h
index 20e2c8e..2115042 100644
--- a/Source/cmGlobalNinjaGenerator.h
+++ b/Source/cmGlobalNinjaGenerator.h
@@ -153,9 +153,10 @@ public:
public:
cmGlobalNinjaGenerator(cmake* cm);
- static cmGlobalGeneratorFactory* NewFactory()
+ static std::unique_ptr<cmGlobalGeneratorFactory> NewFactory()
{
- return new cmGlobalGeneratorSimpleFactory<cmGlobalNinjaGenerator>();
+ return std::unique_ptr<cmGlobalGeneratorFactory>(
+ new cmGlobalGeneratorSimpleFactory<cmGlobalNinjaGenerator>());
}
std::unique_ptr<cmLocalGenerator> CreateLocalGenerator(
@@ -524,9 +525,10 @@ public:
cmGlobalNinjaMultiGenerator(cmake* cm);
bool IsMultiConfig() const override { return true; }
- static cmGlobalGeneratorFactory* NewFactory()
+ static std::unique_ptr<cmGlobalGeneratorFactory> NewFactory()
{
- return new cmGlobalGeneratorSimpleFactory<cmGlobalNinjaMultiGenerator>();
+ return std::unique_ptr<cmGlobalGeneratorFactory>(
+ new cmGlobalGeneratorSimpleFactory<cmGlobalNinjaMultiGenerator>());
}
static void GetDocumentation(cmDocumentationEntry& entry);