summaryrefslogtreecommitdiffstats
path: root/Source/cmStateDirectory.h
diff options
context:
space:
mode:
authorMarc Chevrier <marc.chevrier@gmail.com>2023-05-26 09:09:07 (GMT)
committerMarc Chevrier <marc.chevrier@gmail.com>2023-05-26 12:48:22 (GMT)
commitaa5fed5052f903614a06c55786a1f682fee787a5 (patch)
treeadcf76aa35a0f8aab8b0a15db3be43cfd773855c /Source/cmStateDirectory.h
parenta645a80040d35162ba34ddec39b1b90b2466b72f (diff)
downloadCMake-aa5fed5052f903614a06c55786a1f682fee787a5.zip
CMake-aa5fed5052f903614a06c55786a1f682fee787a5.tar.gz
CMake-aa5fed5052f903614a06c55786a1f682fee787a5.tar.bz2
SetProperty: suppress raw pointer usage
Diffstat (limited to 'Source/cmStateDirectory.h')
-rw-r--r--Source/cmStateDirectory.h8
1 files changed, 6 insertions, 2 deletions
diff --git a/Source/cmStateDirectory.h b/Source/cmStateDirectory.h
index 8c6b09d..55cc716 100644
--- a/Source/cmStateDirectory.h
+++ b/Source/cmStateDirectory.h
@@ -5,6 +5,7 @@
#include "cmConfigure.h" // IWYU pragma: keep
+#include <cstddef>
#include <string>
#include <vector>
@@ -57,10 +58,13 @@ public:
void SetLinkDirectories(BT<std::string> const& vecs);
void ClearLinkDirectories();
- void SetProperty(const std::string& prop, const char* value,
- cmListFileBacktrace const& lfbt);
void SetProperty(const std::string& prop, cmValue value,
cmListFileBacktrace const& lfbt);
+ void SetProperty(const std::string& prop, std::nullptr_t,
+ cmListFileBacktrace const& lfbt)
+ {
+ this->SetProperty(prop, cmValue{ nullptr }, lfbt);
+ }
void AppendProperty(const std::string& prop, const std::string& value,
bool asString, cmListFileBacktrace const& lfbt);
cmValue GetProperty(const std::string& prop) const;