Skip to content
GitLab
Menu
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
CMake
CMake
Commits
cfb66613
Commit
cfb66613
authored
Sep 15, 2012
by
Stephen Kelly
Browse files
Don't call SetProperty from GetProperty.
Memoize with the internal container directly instead.
parent
8a6e8272
Changes
1
Show whitespace changes
Inline
Side-by-side
Source/cmTarget.cxx
View file @
cfb66613
...
...
@@ -2907,7 +2907,8 @@ const char *cmTarget::GetProperty(const char* prop,
// cannot take into account the per-configuration name of the
// target because the configuration type may not be known at
// CMake time.
this
->
SetProperty
(
"LOCATION"
,
this
->
GetLocation
(
0
));
this
->
Properties
.
SetProperty
(
"LOCATION"
,
this
->
GetLocation
(
0
),
cmProperty
::
TARGET
);
}
// Support "LOCATION_<CONFIG>".
...
...
@@ -2918,7 +2919,9 @@ const char *cmTarget::GetProperty(const char* prop,
return
0
;
}
std
::
string
configName
=
prop
+
9
;
this
->
SetProperty
(
prop
,
this
->
GetLocation
(
configName
.
c_str
()));
this
->
Properties
.
SetProperty
(
prop
,
this
->
GetLocation
(
configName
.
c_str
()),
cmProperty
::
TARGET
);
}
else
{
...
...
@@ -2933,7 +2936,9 @@ const char *cmTarget::GetProperty(const char* prop,
{
return
0
;
}
this
->
SetProperty
(
prop
,
this
->
GetLocation
(
configName
.
c_str
()));
this
->
Properties
.
SetProperty
(
prop
,
this
->
GetLocation
(
configName
.
c_str
()),
cmProperty
::
TARGET
);
}
}
}
...
...
@@ -3038,7 +3043,8 @@ const char *cmTarget::GetProperty(const char* prop,
// Append this list entry.
ss
<<
sname
;
}
this
->
SetProperty
(
"SOURCES"
,
ss
.
str
().
c_str
());
this
->
Properties
.
SetProperty
(
"SOURCES"
,
ss
.
str
().
c_str
(),
cmProperty
::
TARGET
);
}
// the type property returns what type the target is
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment