summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorSebastian Holtermann <sebholt@xwmw.org>2019-05-17 10:30:08 (GMT)
committerSebastian Holtermann <sebholt@xwmw.org>2019-05-17 15:58:55 (GMT)
commitadc3459707c4c942b547eb57d02a82b8d5085962 (patch)
tree64ef61c9a19f3e48b90e18b45ca61d0d0a996eb1
parent0d41b45cc931530d5dbc51674699f4da2290a6d3 (diff)
downloadCMake-adc3459707c4c942b547eb57d02a82b8d5085962.zip
CMake-adc3459707c4c942b547eb57d02a82b8d5085962.tar.gz
CMake-adc3459707c4c942b547eb57d02a82b8d5085962.tar.bz2
Makefiles: Avoid pointer repurposing
-rw-r--r--Source/cmGlobalUnixMakefileGenerator3.cxx8
1 files changed, 4 insertions, 4 deletions
diff --git a/Source/cmGlobalUnixMakefileGenerator3.cxx b/Source/cmGlobalUnixMakefileGenerator3.cxx
index 5486ac0..2f3bc76 100644
--- a/Source/cmGlobalUnixMakefileGenerator3.cxx
+++ b/Source/cmGlobalUnixMakefileGenerator3.cxx
@@ -247,13 +247,13 @@ void cmGlobalUnixMakefileGenerator3::WriteMainMakefile2()
// Write out the "special" stuff
lg->WriteSpecialTargetsTop(makefileStream);
- // write the target convenience rules
+ // Write the target convenience rules
for (cmLocalGenerator* localGen : this->LocalGenerators) {
- lg = static_cast<cmLocalUnixMakefileGenerator3*>(localGen);
- this->WriteConvenienceRules2(makefileStream, lg);
+ this->WriteConvenienceRules2(
+ makefileStream, static_cast<cmLocalUnixMakefileGenerator3*>(localGen));
}
- lg = static_cast<cmLocalUnixMakefileGenerator3*>(this->LocalGenerators[0]);
+ // Write special bottom targets
lg->WriteSpecialTargetsBottom(makefileStream);
}