diff options
author | Kyle Edwards <kyle.edwards@kitware.com> | 2021-04-20 20:16:57 (GMT) |
---|---|---|
committer | Kyle Edwards <kyle.edwards@kitware.com> | 2021-06-03 12:37:25 (GMT) |
commit | b613e09778260c26c6323026dc2ccb980c102f3e (patch) | |
tree | b1d3b836f03bb7af750aef4a6680ad104d786053 /Source | |
parent | 9c33ff4dda643f8a93d55f9895e31dce9056134f (diff) | |
download | CMake-b613e09778260c26c6323026dc2ccb980c102f3e.zip CMake-b613e09778260c26c6323026dc2ccb980c102f3e.tar.gz CMake-b613e09778260c26c6323026dc2ccb980c102f3e.tar.bz2 |
cmRuntimeDependencyArchive: Fix const-ness of method signatures
Diffstat (limited to 'Source')
-rw-r--r-- | Source/cmRuntimeDependencyArchive.cxx | 18 | ||||
-rw-r--r-- | Source/cmRuntimeDependencyArchive.h | 20 |
2 files changed, 20 insertions, 18 deletions
diff --git a/Source/cmRuntimeDependencyArchive.cxx b/Source/cmRuntimeDependencyArchive.cxx index a6ed523..57b4bd6 100644 --- a/Source/cmRuntimeDependencyArchive.cxx +++ b/Source/cmRuntimeDependencyArchive.cxx @@ -198,25 +198,26 @@ void cmRuntimeDependencyArchive::SetError(const std::string& e) this->Status.SetError(e); } -std::string cmRuntimeDependencyArchive::GetBundleExecutable() +const std::string& cmRuntimeDependencyArchive::GetBundleExecutable() const { return this->BundleExecutable; } const std::vector<std::string>& -cmRuntimeDependencyArchive::GetSearchDirectories() +cmRuntimeDependencyArchive::GetSearchDirectories() const { return this->SearchDirectories; } -std::string cmRuntimeDependencyArchive::GetGetRuntimeDependenciesTool() +const std::string& cmRuntimeDependencyArchive::GetGetRuntimeDependenciesTool() + const { return this->GetMakefile()->GetSafeDefinition( "CMAKE_GET_RUNTIME_DEPENDENCIES_TOOL"); } bool cmRuntimeDependencyArchive::GetGetRuntimeDependenciesCommand( - const std::string& search, std::vector<std::string>& command) + const std::string& search, std::vector<std::string>& command) const { // First see if it was supplied by the user std::string toolCommand = this->GetMakefile()->GetSafeDefinition( @@ -309,7 +310,7 @@ bool cmRuntimeDependencyArchive::GetGetRuntimeDependenciesCommand( return false; } -bool cmRuntimeDependencyArchive::IsPreExcluded(const std::string& name) +bool cmRuntimeDependencyArchive::IsPreExcluded(const std::string& name) const { cmsys::RegularExpressionMatch match; auto const regexMatch = @@ -326,7 +327,7 @@ bool cmRuntimeDependencyArchive::IsPreExcluded(const std::string& name) regexSearch(this->PreExcludeRegexes); } -bool cmRuntimeDependencyArchive::IsPostExcluded(const std::string& name) +bool cmRuntimeDependencyArchive::IsPostExcluded(const std::string& name) const { cmsys::RegularExpressionMatch match; auto const regexMatch = @@ -373,18 +374,19 @@ void cmRuntimeDependencyArchive::AddUnresolvedPath(const std::string& name) this->UnresolvedPaths.insert(name); } -cmMakefile* cmRuntimeDependencyArchive::GetMakefile() +cmMakefile* cmRuntimeDependencyArchive::GetMakefile() const { return &this->Status.GetMakefile(); } const std::map<std::string, std::set<std::string>>& -cmRuntimeDependencyArchive::GetResolvedPaths() +cmRuntimeDependencyArchive::GetResolvedPaths() const { return this->ResolvedPaths; } const std::set<std::string>& cmRuntimeDependencyArchive::GetUnresolvedPaths() + const { return this->UnresolvedPaths; } diff --git a/Source/cmRuntimeDependencyArchive.h b/Source/cmRuntimeDependencyArchive.h index 1dc3261..3f368c5 100644 --- a/Source/cmRuntimeDependencyArchive.h +++ b/Source/cmRuntimeDependencyArchive.h @@ -36,21 +36,21 @@ public: void SetError(const std::string& e); - std::string GetBundleExecutable(); - const std::vector<std::string>& GetSearchDirectories(); - std::string GetGetRuntimeDependenciesTool(); - bool GetGetRuntimeDependenciesCommand(const std::string& search, - std::vector<std::string>& command); - bool IsPreExcluded(const std::string& name); - bool IsPostExcluded(const std::string& name); + const std::string& GetBundleExecutable() const; + const std::vector<std::string>& GetSearchDirectories() const; + const std::string& GetGetRuntimeDependenciesTool() const; + bool GetGetRuntimeDependenciesCommand( + const std::string& search, std::vector<std::string>& command) const; + bool IsPreExcluded(const std::string& name) const; + bool IsPostExcluded(const std::string& name) const; void AddResolvedPath(const std::string& name, const std::string& path, bool& unique); void AddUnresolvedPath(const std::string& name); - cmMakefile* GetMakefile(); - const std::map<std::string, std::set<std::string>>& GetResolvedPaths(); - const std::set<std::string>& GetUnresolvedPaths(); + cmMakefile* GetMakefile() const; + const std::map<std::string, std::set<std::string>>& GetResolvedPaths() const; + const std::set<std::string>& GetUnresolvedPaths() const; private: cmExecutionStatus& Status; |