From fd2c9fac101ec6d341db5b30e9d1eba64fa23116 Mon Sep 17 00:00:00 2001 From: Brad King Date: Wed, 2 Oct 2019 13:48:37 -0400 Subject: cmGeneratorTarget: Return non-const sources from GetAllConfigSources We need a non-const pointer to `cmSourceFile` instances in order to call `GetOrDetermineLanguage` on them. --- Source/cmGeneratorTarget.h | 2 +- Source/cmLocalVisualStudio7Generator.cxx | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/Source/cmGeneratorTarget.h b/Source/cmGeneratorTarget.h index 1f824b1..c2811b2 100644 --- a/Source/cmGeneratorTarget.h +++ b/Source/cmGeneratorTarget.h @@ -123,7 +123,7 @@ public: struct AllConfigSource { - cmSourceFile const* Source; + cmSourceFile* Source; cmGeneratorTarget::SourceKind Kind; std::vector Configs; }; diff --git a/Source/cmLocalVisualStudio7Generator.cxx b/Source/cmLocalVisualStudio7Generator.cxx index ff1eaec..fd346df 100644 --- a/Source/cmLocalVisualStudio7Generator.cxx +++ b/Source/cmLocalVisualStudio7Generator.cxx @@ -1329,7 +1329,7 @@ void cmLocalVisualStudio7Generator::WriteVCProjFile(std::ostream& fout, // Add CMakeLists.txt file with rule to re-run CMake for user convenience. if (target->GetType() != cmStateEnums::GLOBAL_TARGET && target->GetName() != CMAKE_CHECK_BUILD_SYSTEM_TARGET) { - if (cmSourceFile const* sf = this->CreateVCProjBuildRule()) { + if (cmSourceFile* sf = this->CreateVCProjBuildRule()) { cmGeneratorTarget::AllConfigSource acs; acs.Source = sf; acs.Kind = cmGeneratorTarget::SourceKindCustomCommand; -- cgit v0.12