mirror of
https://github.com/Kitware/CMake.git
synced 2026-05-03 04:40:18 -05:00
Reduce the scope of temporary cmProp variables and other improvements
This commit is contained in:
@@ -583,14 +583,12 @@ const char* CCONV cmSourceFileGetProperty(void* arg, const char* prop)
|
||||
{
|
||||
cmCPluginAPISourceFile* sf = static_cast<cmCPluginAPISourceFile*>(arg);
|
||||
if (cmSourceFile* rsf = sf->RealSourceFile) {
|
||||
cmProp p = rsf->GetProperty(prop);
|
||||
return cmToCStr(p);
|
||||
return cmToCStr(rsf->GetProperty(prop));
|
||||
}
|
||||
if (!strcmp(prop, "LOCATION")) {
|
||||
return sf->FullPath.c_str();
|
||||
}
|
||||
cmProp retVal = sf->Properties.GetPropertyValue(prop);
|
||||
return cmToCStr(retVal);
|
||||
return cmToCStr(sf->Properties.GetPropertyValue(prop));
|
||||
}
|
||||
|
||||
int CCONV cmSourceFileGetPropertyAsBool(void* arg, const char* prop)
|
||||
|
||||
Reference in New Issue
Block a user