diff options
author | Tushar Maheshwari <tushar27192@gmail.com> | 2019-09-08 09:14:55 (GMT) |
---|---|---|
committer | Tushar Maheshwari <tushar27192@gmail.com> | 2019-09-19 13:50:29 (GMT) |
commit | 6511fa6f3309984fc10de8471017c2bb32d8d286 (patch) | |
tree | fb4b068962d37cc9763fd779f45662edc7fd1179 /Source/cmExportSet.h | |
parent | 9b8a1f7c28deac892493b0a5548b08b2003238ea (diff) | |
download | CMake-6511fa6f3309984fc10de8471017c2bb32d8d286.zip CMake-6511fa6f3309984fc10de8471017c2bb32d8d286.tar.gz CMake-6511fa6f3309984fc10de8471017c2bb32d8d286.tar.bz2 |
cmExportSet: default destructor
Diffstat (limited to 'Source/cmExportSet.h')
-rw-r--r-- | Source/cmExportSet.h | 15 |
1 files changed, 6 insertions, 9 deletions
diff --git a/Source/cmExportSet.h b/Source/cmExportSet.h index d654c12..2eee849 100644 --- a/Source/cmExportSet.h +++ b/Source/cmExportSet.h @@ -5,8 +5,8 @@ #include "cmConfigure.h" // IWYU pragma: keep +#include <memory> #include <string> -#include <utility> #include <vector> class cmInstallExportGenerator; @@ -18,10 +18,7 @@ class cmExportSet { public: /// Construct an empty export set named \a name - cmExportSet(std::string name) - : Name(std::move(name)) - { - } + cmExportSet(std::string name); /// Destructor ~cmExportSet(); @@ -30,15 +27,15 @@ public: void Compute(cmLocalGenerator* lg); - void AddTargetExport(cmTargetExport* tgt); + void AddTargetExport(std::unique_ptr<cmTargetExport> tgt); void AddInstallation(cmInstallExportGenerator const* installation); std::string const& GetName() const { return this->Name; } - std::vector<cmTargetExport*> const* GetTargetExports() const + std::vector<std::unique_ptr<cmTargetExport>> const& GetTargetExports() const { - return &this->TargetExports; + return this->TargetExports; } std::vector<cmInstallExportGenerator const*> const* GetInstallations() const @@ -47,7 +44,7 @@ public: } private: - std::vector<cmTargetExport*> TargetExports; + std::vector<std::unique_ptr<cmTargetExport>> TargetExports; std::string Name; std::vector<cmInstallExportGenerator const*> Installations; }; |