diff options
author | Vitaly Stakhovsky <vvs31415@gitlab.org> | 2020-04-29 15:00:00 (GMT) |
---|---|---|
committer | Vitaly Stakhovsky <vvs31415@gitlab.org> | 2020-04-29 14:59:39 (GMT) |
commit | 36aba01223cfb28ee574386cd91dbfccc4dc9359 (patch) | |
tree | 7acf2fc54b9ddf7a5372cb088eb80cde6764408d /Source/cmNinjaNormalTargetGenerator.cxx | |
parent | d63c442a6bcec287afb32a88c80b68cb141f49f4 (diff) | |
download | CMake-36aba01223cfb28ee574386cd91dbfccc4dc9359.zip CMake-36aba01223cfb28ee574386cd91dbfccc4dc9359.tar.gz CMake-36aba01223cfb28ee574386cd91dbfccc4dc9359.tar.bz2 |
cmGeneratorTarget::GetProperty: return cmProp
Diffstat (limited to 'Source/cmNinjaNormalTargetGenerator.cxx')
-rw-r--r-- | Source/cmNinjaNormalTargetGenerator.cxx | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/Source/cmNinjaNormalTargetGenerator.cxx b/Source/cmNinjaNormalTargetGenerator.cxx index 49e8af9..db069ed 100644 --- a/Source/cmNinjaNormalTargetGenerator.cxx +++ b/Source/cmNinjaNormalTargetGenerator.cxx @@ -847,8 +847,8 @@ void cmNinjaNormalTargetGenerator::WriteLinkStatement( }(); vars["SWIFT_MODULE_NAME"] = [gt]() -> std::string { - if (const char* name = gt->GetProperty("Swift_MODULE_NAME")) { - return name; + if (cmProp name = gt->GetProperty("Swift_MODULE_NAME")) { + return *name; } return gt->GetName(); }(); @@ -856,15 +856,15 @@ void cmNinjaNormalTargetGenerator::WriteLinkStatement( vars["SWIFT_MODULE"] = [this](const std::string& module) -> std::string { std::string directory = this->GetLocalGenerator()->GetCurrentBinaryDirectory(); - if (const char* prop = this->GetGeneratorTarget()->GetProperty( + if (cmProp prop = this->GetGeneratorTarget()->GetProperty( "Swift_MODULE_DIRECTORY")) { - directory = prop; + directory = *prop; } std::string name = module + ".swiftmodule"; - if (const char* prop = + if (cmProp prop = this->GetGeneratorTarget()->GetProperty("Swift_MODULE")) { - name = prop; + name = *prop; } return this->GetLocalGenerator()->ConvertToOutputFormat( |