From fc99572540f6012d0f5147dddcb4a7fdefb7af0e Mon Sep 17 00:00:00 2001 From: Steve Pucci Date: Fri, 17 Jan 2014 18:18:31 +0000 Subject: [PATCH] Rename Platform::GetFile (3-arg version) to GetFileWithUUID This rename was suggested by gclayton as a way to silence gcc warnings; the warning is emitted when there is an overloaded function in a base class (Platform) for which a derived class redefines one of the overloads but not the other (because doing so hides the other overload from users of the derived class). By giving the two methods different names, the situation is avoided. llvm-svn: 199504 --- lldb/include/lldb/Target/Platform.h | 6 +++--- lldb/source/Plugins/Platform/FreeBSD/PlatformFreeBSD.cpp | 8 ++++---- lldb/source/Plugins/Platform/FreeBSD/PlatformFreeBSD.h | 4 ++-- lldb/source/Plugins/Platform/Linux/PlatformLinux.cpp | 6 +++--- lldb/source/Plugins/Platform/Linux/PlatformLinux.h | 4 ++-- lldb/source/Plugins/Platform/MacOSX/PlatformMacOSX.cpp | 8 ++++---- lldb/source/Plugins/Platform/MacOSX/PlatformMacOSX.h | 6 +++--- lldb/source/Plugins/Platform/Windows/PlatformWindows.cpp | 8 ++++---- lldb/source/Plugins/Platform/Windows/PlatformWindows.h | 4 ++-- .../Platform/gdb-server/PlatformRemoteGDBServer.cpp | 6 +++--- .../Plugins/Platform/gdb-server/PlatformRemoteGDBServer.h | 6 +++--- lldb/source/Target/Platform.cpp | 6 +++--- lldb/source/Target/Target.cpp | 2 +- 13 files changed, 37 insertions(+), 37 deletions(-) diff --git a/lldb/include/lldb/Target/Platform.h b/lldb/include/lldb/Target/Platform.h index 355c0528bed8..be54df9fcb30 100644 --- a/lldb/include/lldb/Target/Platform.h +++ b/lldb/include/lldb/Target/Platform.h @@ -314,9 +314,9 @@ namespace lldb_private { /// An error object. //------------------------------------------------------------------ virtual Error - GetFile (const FileSpec &platform_file, - const UUID *uuid_ptr, - FileSpec &local_file); + GetFileWithUUID (const FileSpec &platform_file, + const UUID *uuid_ptr, + FileSpec &local_file); //---------------------------------------------------------------------- // Locate the scripting resource given a module specification. diff --git a/lldb/source/Plugins/Platform/FreeBSD/PlatformFreeBSD.cpp b/lldb/source/Plugins/Platform/FreeBSD/PlatformFreeBSD.cpp index da29c16ac3ab..10449ff9aa6d 100644 --- a/lldb/source/Plugins/Platform/FreeBSD/PlatformFreeBSD.cpp +++ b/lldb/source/Plugins/Platform/FreeBSD/PlatformFreeBSD.cpp @@ -571,14 +571,14 @@ PlatformFreeBSD::GetGroupName (uint32_t gid) // From PlatformMacOSX only Error -PlatformFreeBSD::GetFile (const FileSpec &platform_file, - const UUID *uuid_ptr, - FileSpec &local_file) +PlatformFreeBSD::GetFileWithUUID (const FileSpec &platform_file, + const UUID *uuid_ptr, + FileSpec &local_file) { if (IsRemote()) { if (m_remote_platform_sp) - return m_remote_platform_sp->GetFile (platform_file, uuid_ptr, local_file); + return m_remote_platform_sp->GetFileWithUUID (platform_file, uuid_ptr, local_file); } // Default to the local case diff --git a/lldb/source/Plugins/Platform/FreeBSD/PlatformFreeBSD.h b/lldb/source/Plugins/Platform/FreeBSD/PlatformFreeBSD.h index 11d1cd609779..d09557d45c45 100644 --- a/lldb/source/Plugins/Platform/FreeBSD/PlatformFreeBSD.h +++ b/lldb/source/Plugins/Platform/FreeBSD/PlatformFreeBSD.h @@ -144,8 +144,8 @@ public: // Only on PlatformMacOSX: virtual lldb_private::Error - GetFile (const lldb_private::FileSpec &platform_file, - const lldb_private::UUID* uuid, lldb_private::FileSpec &local_file); + GetFileWithUUID (const lldb_private::FileSpec &platform_file, + const lldb_private::UUID* uuid, lldb_private::FileSpec &local_file); lldb_private::Error GetSharedModule (const lldb_private::ModuleSpec &module_spec, diff --git a/lldb/source/Plugins/Platform/Linux/PlatformLinux.cpp b/lldb/source/Plugins/Platform/Linux/PlatformLinux.cpp index 7ffb30ead62d..be3b0a981f0b 100644 --- a/lldb/source/Plugins/Platform/Linux/PlatformLinux.cpp +++ b/lldb/source/Plugins/Platform/Linux/PlatformLinux.cpp @@ -285,13 +285,13 @@ PlatformLinux::ResolveExecutable (const FileSpec &exe_file, } Error -PlatformLinux::GetFile (const FileSpec &platform_file, - const UUID *uuid_ptr, FileSpec &local_file) +PlatformLinux::GetFileWithUUID (const FileSpec &platform_file, + const UUID *uuid_ptr, FileSpec &local_file) { if (IsRemote()) { if (m_remote_platform_sp) - return m_remote_platform_sp->GetFile (platform_file, uuid_ptr, local_file); + return m_remote_platform_sp->GetFileWithUUID (platform_file, uuid_ptr, local_file); } // Default to the local case diff --git a/lldb/source/Plugins/Platform/Linux/PlatformLinux.h b/lldb/source/Plugins/Platform/Linux/PlatformLinux.h index a77780d59a2c..91010b987fb4 100644 --- a/lldb/source/Plugins/Platform/Linux/PlatformLinux.h +++ b/lldb/source/Plugins/Platform/Linux/PlatformLinux.h @@ -73,8 +73,8 @@ namespace lldb_private { GetStatus (Stream &strm); virtual Error - GetFile (const FileSpec &platform_file, - const UUID* uuid, FileSpec &local_file); + GetFileWithUUID (const FileSpec &platform_file, + const UUID* uuid, FileSpec &local_file); virtual bool GetProcessInfo (lldb::pid_t pid, ProcessInstanceInfo &proc_info); diff --git a/lldb/source/Plugins/Platform/MacOSX/PlatformMacOSX.cpp b/lldb/source/Plugins/Platform/MacOSX/PlatformMacOSX.cpp index 9ffd68d5514c..74b4f354ecc7 100644 --- a/lldb/source/Plugins/Platform/MacOSX/PlatformMacOSX.cpp +++ b/lldb/source/Plugins/Platform/MacOSX/PlatformMacOSX.cpp @@ -249,7 +249,7 @@ PlatformMacOSX::GetSymbolFile (const FileSpec &platform_file, if (IsRemote()) { if (m_remote_platform_sp) - return m_remote_platform_sp->GetFile (platform_file, uuid_ptr, local_file); + return m_remote_platform_sp->GetFileWithUUID (platform_file, uuid_ptr, local_file); } // Default to the local case @@ -258,9 +258,9 @@ PlatformMacOSX::GetSymbolFile (const FileSpec &platform_file, } lldb_private::Error -PlatformMacOSX::GetFile (const lldb_private::FileSpec &platform_file, - const lldb_private::UUID *uuid_ptr, - lldb_private::FileSpec &local_file) +PlatformMacOSX::GetFileWithUUID (const lldb_private::FileSpec &platform_file, + const lldb_private::UUID *uuid_ptr, + lldb_private::FileSpec &local_file) { if (IsRemote() && m_remote_platform_sp) { diff --git a/lldb/source/Plugins/Platform/MacOSX/PlatformMacOSX.h b/lldb/source/Plugins/Platform/MacOSX/PlatformMacOSX.h index 2354e6fb8404..57e57e7b38e7 100644 --- a/lldb/source/Plugins/Platform/MacOSX/PlatformMacOSX.h +++ b/lldb/source/Plugins/Platform/MacOSX/PlatformMacOSX.h @@ -87,9 +87,9 @@ public: } virtual lldb_private::Error - GetFile (const lldb_private::FileSpec &platform_file, - const lldb_private::UUID *uuid_ptr, - lldb_private::FileSpec &local_file); + GetFileWithUUID (const lldb_private::FileSpec &platform_file, + const lldb_private::UUID *uuid_ptr, + lldb_private::FileSpec &local_file); virtual bool GetSupportedArchitectureAtIndex (uint32_t idx, diff --git a/lldb/source/Plugins/Platform/Windows/PlatformWindows.cpp b/lldb/source/Plugins/Platform/Windows/PlatformWindows.cpp index 361e91049d44..a362ffa3c4c5 100644 --- a/lldb/source/Plugins/Platform/Windows/PlatformWindows.cpp +++ b/lldb/source/Plugins/Platform/Windows/PlatformWindows.cpp @@ -542,14 +542,14 @@ PlatformWindows::GetGroupName (uint32_t gid) } Error -PlatformWindows::GetFile (const FileSpec &platform_file, - const UUID *uuid_ptr, - FileSpec &local_file) +PlatformWindows::GetFileWithUUID (const FileSpec &platform_file, + const UUID *uuid_ptr, + FileSpec &local_file) { if (IsRemote()) { if (m_remote_platform_sp) - return m_remote_platform_sp->GetFile (platform_file, uuid_ptr, local_file); + return m_remote_platform_sp->GetFileWithUUID (platform_file, uuid_ptr, local_file); } // Default to the local case diff --git a/lldb/source/Plugins/Platform/Windows/PlatformWindows.h b/lldb/source/Plugins/Platform/Windows/PlatformWindows.h index 67d3e88feddb..7d3a1677010c 100644 --- a/lldb/source/Plugins/Platform/Windows/PlatformWindows.h +++ b/lldb/source/Plugins/Platform/Windows/PlatformWindows.h @@ -125,8 +125,8 @@ public: lldb_private::Error &error); virtual lldb_private::Error - GetFile(const lldb_private::FileSpec &platform_file, - const lldb_private::UUID* uuid, lldb_private::FileSpec &local_file); + GetFileWithUUID(const lldb_private::FileSpec &platform_file, + const lldb_private::UUID* uuid, lldb_private::FileSpec &local_file); lldb_private::Error GetSharedModule(const lldb_private::ModuleSpec &module_spec, diff --git a/lldb/source/Plugins/Platform/gdb-server/PlatformRemoteGDBServer.cpp b/lldb/source/Plugins/Platform/gdb-server/PlatformRemoteGDBServer.cpp index cd2433df0107..80421ad8b247 100644 --- a/lldb/source/Plugins/Platform/gdb-server/PlatformRemoteGDBServer.cpp +++ b/lldb/source/Plugins/Platform/gdb-server/PlatformRemoteGDBServer.cpp @@ -119,9 +119,9 @@ PlatformRemoteGDBServer::ResolveExecutable (const FileSpec &exe_file, } Error -PlatformRemoteGDBServer::GetFile (const FileSpec &platform_file, - const UUID *uuid_ptr, - FileSpec &local_file) +PlatformRemoteGDBServer::GetFileWithUUID (const FileSpec &platform_file, + const UUID *uuid_ptr, + FileSpec &local_file) { // Default to the local case local_file = platform_file; diff --git a/lldb/source/Plugins/Platform/gdb-server/PlatformRemoteGDBServer.h b/lldb/source/Plugins/Platform/gdb-server/PlatformRemoteGDBServer.h index 808fb5ed61cc..91e1e7c7e274 100644 --- a/lldb/source/Plugins/Platform/gdb-server/PlatformRemoteGDBServer.h +++ b/lldb/source/Plugins/Platform/gdb-server/PlatformRemoteGDBServer.h @@ -73,9 +73,9 @@ public: GetDescription (); virtual lldb_private::Error - GetFile (const lldb_private::FileSpec &platform_file, - const lldb_private::UUID *uuid_ptr, - lldb_private::FileSpec &local_file); + GetFileWithUUID (const lldb_private::FileSpec &platform_file, + const lldb_private::UUID *uuid_ptr, + lldb_private::FileSpec &local_file); virtual bool GetProcessInfo (lldb::pid_t pid, diff --git a/lldb/source/Target/Platform.cpp b/lldb/source/Target/Platform.cpp index 66f9c0e552a8..dc80b4a54fc6 100644 --- a/lldb/source/Target/Platform.cpp +++ b/lldb/source/Target/Platform.cpp @@ -81,9 +81,9 @@ Platform::SetDefaultPlatform (const lldb::PlatformSP &platform_sp) } Error -Platform::GetFile (const FileSpec &platform_file, - const UUID *uuid_ptr, - FileSpec &local_file) +Platform::GetFileWithUUID (const FileSpec &platform_file, + const UUID *uuid_ptr, + FileSpec &local_file) { // Default to the local case local_file = platform_file; diff --git a/lldb/source/Target/Target.cpp b/lldb/source/Target/Target.cpp index a34d53e88f8d..c53c1e3c1c2f 100644 --- a/lldb/source/Target/Target.cpp +++ b/lldb/source/Target/Target.cpp @@ -1067,7 +1067,7 @@ Target::SetExecutableModule (ModuleSP& executable_sp, bool get_dependent_files) FileSpec dependent_file_spec (dependent_files.GetFileSpecPointerAtIndex(i)); FileSpec platform_dependent_file_spec; if (m_platform_sp) - m_platform_sp->GetFile (dependent_file_spec, NULL, platform_dependent_file_spec); + m_platform_sp->GetFileWithUUID (dependent_file_spec, NULL, platform_dependent_file_spec); else platform_dependent_file_spec = dependent_file_spec;