diff --git a/lldb/include/lldb/Core/ArchSpec.h b/lldb/include/lldb/Core/ArchSpec.h index 331a5780887b..e4d61748d4d6 100644 --- a/lldb/include/lldb/Core/ArchSpec.h +++ b/lldb/include/lldb/Core/ArchSpec.h @@ -307,7 +307,7 @@ public: /// @return A string representing target CPU for the current /// architecture. //------------------------------------------------------------------ - std::string GetClangTargetCPU(); + std::string GetClangTargetCPU() const; //------------------------------------------------------------------ /// Return a string representing target application ABI. diff --git a/lldb/source/Core/ArchSpec.cpp b/lldb/source/Core/ArchSpec.cpp index 0d10ab7be441..9da2942b67a5 100644 --- a/lldb/source/Core/ArchSpec.cpp +++ b/lldb/source/Core/ArchSpec.cpp @@ -657,7 +657,7 @@ void ArchSpec::SetFlags(std::string elf_abi) { SetFlags(flag); } -std::string ArchSpec::GetClangTargetCPU() { +std::string ArchSpec::GetClangTargetCPU() const { std::string cpu; const llvm::Triple::ArchType machine = GetMachine();