Removed __func__
http://llvm-reviews.chandlerc.com/D1976
CHANGE SINCE LAST DIFF
http://llvm-reviews.chandlerc.com/D1976?vs=5029&id=5030#toc
Files:
source/DataFormatters/FormatManager.cpp
source/Host/common/SocketAddress.cpp
source/Plugins/DynamicLoader/POSIX-DYLD/AuxVector.cpp
source/Plugins/DynamicLoader/POSIX-DYLD/DynamicLoaderPOSIXDYLD.cpp
source/Plugins/Process/gdb-remote/GDBRemoteCommunication.cpp
source/Plugins/Process/gdb-remote/GDBRemoteCommunicationClient.cpp
source/Plugins/Process/gdb-remote/GDBRemoteRegisterContext.cpp
source/Plugins/Process/gdb-remote/ProcessGDBRemote.cpp
source/Target/Process.cpp
tools/driver/ELWrapper.cpp
Index: source/DataFormatters/FormatManager.cpp
===================================================================
--- source/DataFormatters/FormatManager.cpp
+++ source/DataFormatters/FormatManager.cpp
@@ -839,9 +839,11 @@
sys_category_sp->GetSummaryNavigator()->Add(ConstString("char *"), string_format);
sys_category_sp->GetSummaryNavigator()->Add(ConstString("unsigned char *"), string_format);
sys_category_sp->GetRegexSummaryNavigator()->Add(any_size_char_arr, string_array_format);
-
+
+#ifndef LLDB_DISABLE_PYTHON
AddCXXSynthetic(sys_category_sp, FooStructSynth, "Foo synth", ConstString("Foo"), ScriptedSyntheticChildren::Flags(), false);
-
+#endif
+
lldb::TypeSummaryImplSP ostype_summary(new StringSummaryFormat(TypeSummaryImpl::Flags().SetCascades(false)
.SetSkipPointers(true)
.SetSkipReferences(true)
Index: source/Host/common/SocketAddress.cpp
===================================================================
--- source/Host/common/SocketAddress.cpp
+++ source/Host/common/SocketAddress.cpp
@@ -11,7 +11,9 @@
#include <stddef.h>
// C Includes
+#if !defined(_MSC_VER)
#include <arpa/inet.h>
+#endif
#include <assert.h>
#include <string.h>
Index: source/Plugins/DynamicLoader/POSIX-DYLD/AuxVector.cpp
===================================================================
--- source/Plugins/DynamicLoader/POSIX-DYLD/AuxVector.cpp
+++ source/Plugins/DynamicLoader/POSIX-DYLD/AuxVector.cpp
@@ -19,7 +19,7 @@
#include "lldb/Core/Log.h"
#include "lldb/Target/Process.h"
-#if defined(__linux__) or defined(__FreeBSD__)
+#if defined(__linux__) || defined(__FreeBSD__)
#include "Plugins/Process/elf-core/ProcessElfCore.h"
#endif
@@ -57,7 +57,7 @@
DataBufferSP
AuxVector::GetAuxvData()
{
-#if defined(__linux__) or defined(__FreeBSD__)
+#if defined(__linux__) || defined(__FreeBSD__)
if (m_process->GetPluginName() == ProcessElfCore::GetPluginNameStatic())
return static_cast<ProcessElfCore *>(m_process)->GetAuxvData();
#endif
Index: source/Plugins/DynamicLoader/POSIX-DYLD/DynamicLoaderPOSIXDYLD.cpp
===================================================================
--- source/Plugins/DynamicLoader/POSIX-DYLD/DynamicLoaderPOSIXDYLD.cpp
+++ source/Plugins/DynamicLoader/POSIX-DYLD/DynamicLoaderPOSIXDYLD.cpp
@@ -439,7 +439,7 @@
Log *log(GetLogIfAnyCategoriesSet(LIBLLDB_LOG_DYNAMIC_LOADER));
if (log)
log->Printf("DynamicLoaderPOSIXDYLD::%s unable to resolve POSIX DYLD rendezvous address",
- __func__);
+ __FUNCTION__);
return;
}
@@ -463,7 +463,7 @@
Log *log(GetLogIfAnyCategoriesSet(LIBLLDB_LOG_DYNAMIC_LOADER));
if (log)
log->Printf("DynamicLoaderPOSIXDYLD::%s failed loading module %s at 0x%" PRIx64,
- __func__, module_path, I->base_addr);
+ __FUNCTION__, module_path, I->base_addr);
}
}
Index: source/Plugins/Process/gdb-remote/GDBRemoteCommunication.cpp
===================================================================
--- source/Plugins/Process/gdb-remote/GDBRemoteCommunication.cpp
+++ source/Plugins/Process/gdb-remote/GDBRemoteCommunication.cpp
@@ -29,6 +29,12 @@
#define DEBUGSERVER_BASENAME "debugserver"
+#if defined(_MSC_VER)
+#define ZUFix "%d"
+#else
+#define ZUFix "%4zu"
+#endif
+
using namespace lldb;
using namespace lldb_private;
@@ -177,7 +183,7 @@
char ch = '+';
const size_t bytes_written = Write (&ch, 1, status, NULL);
if (log)
- log->Printf ("<%4zu> send packet: %c", bytes_written, ch);
+ log->Printf ("<" ZUFix "> send packet: %c", bytes_written, ch);
m_history.AddPacket (ch, History::ePacketTypeSend, bytes_written);
return bytes_written;
}
@@ -190,7 +196,7 @@
char ch = '-';
const size_t bytes_written = Write (&ch, 1, status, NULL);
if (log)
- log->Printf ("<%4zu> send packet: %c", bytes_written, ch);
+ log->Printf("<" ZUFix "> send packet: %c", bytes_written, ch);
m_history.AddPacket (ch, History::ePacketTypeSend, bytes_written);
return bytes_written;
}
@@ -226,7 +232,7 @@
if (!m_history.DidDumpToLog ())
m_history.Dump (log);
- log->Printf ("<%4zu> send packet: %.*s", bytes_written, (int)packet.GetSize(), packet.GetData());
+ log->Printf ("<" ZUFix "> send packet: %.*s", bytes_written, (int)packet.GetSize(), packet.GetData());
}
m_history.AddPacket (packet.GetString(), packet.GetSize(), History::ePacketTypeSend, bytes_written);
@@ -460,7 +466,7 @@
if (!m_history.DidDumpToLog ())
m_history.Dump (log);
- log->Printf ("<%4zu> read packet: %.*s", total_length, (int)(total_length), m_bytes.c_str());
+ log->Printf ("<" ZUFix "> read packet: %.*s", total_length, (int)(total_length), m_bytes.c_str());
}
m_history.AddPacket (m_bytes.c_str(), total_length, History::ePacketTypeRecv, total_length);
Index: source/Plugins/Process/gdb-remote/GDBRemoteCommunicationClient.cpp
===================================================================
--- source/Plugins/Process/gdb-remote/GDBRemoteCommunicationClient.cpp
+++ source/Plugins/Process/gdb-remote/GDBRemoteCommunicationClient.cpp
@@ -2596,7 +2596,7 @@
{
return ParseHostIOPacketResponse (response, -1, error) == 0;
}
- return UINT64_MAX;
+ return true;
}
// Extension of host I/O packets to get the file size.
Index: source/Plugins/Process/gdb-remote/GDBRemoteRegisterContext.cpp
===================================================================
--- source/Plugins/Process/gdb-remote/GDBRemoteRegisterContext.cpp
+++ source/Plugins/Process/gdb-remote/GDBRemoteRegisterContext.cpp
@@ -17,7 +17,9 @@
#include "lldb/Core/RegisterValue.h"
#include "lldb/Core/Scalar.h"
#include "lldb/Core/StreamString.h"
+#if !defined(LLDB_DISABLE_PYTHON)
#include "lldb/Interpreter/PythonDataObjects.h"
+#endif
#include "lldb/Target/ExecutionContext.h"
#include "lldb/Utility/Utils.h"
// Project includes
Index: source/Plugins/Process/gdb-remote/ProcessGDBRemote.cpp
===================================================================
--- source/Plugins/Process/gdb-remote/ProcessGDBRemote.cpp
+++ source/Plugins/Process/gdb-remote/ProcessGDBRemote.cpp
@@ -49,7 +49,9 @@
#include "lldb/Interpreter/CommandObject.h"
#include "lldb/Interpreter/CommandObjectMultiword.h"
#include "lldb/Interpreter/CommandReturnObject.h"
+#if !defined(LLDB_DISABLE_PYTHON)
#include "lldb/Interpreter/PythonDataObjects.h"
+#endif
#include "lldb/Symbol/ObjectFile.h"
#include "lldb/Target/DynamicLoader.h"
#include "lldb/Target/Target.h"
@@ -320,6 +322,7 @@
bool
ProcessGDBRemote::ParsePythonTargetDefinition(const FileSpec &target_definition_fspec)
{
+#if !defined(LLDB_DISABLE_PYTHON)
ScriptInterpreter *interpreter = GetTarget().GetDebugger().GetCommandInterpreter().GetScriptInterpreter();
Error error;
lldb::ScriptInterpreterObjectSP module_object_sp (interpreter->LoadPluginModule(target_definition_fspec, error));
@@ -353,6 +356,7 @@
}
}
}
+#endif
return false;
}
Index: source/Target/Process.cpp
===================================================================
--- source/Target/Process.cpp
+++ source/Target/Process.cpp
@@ -45,6 +45,12 @@
#include <spawn.h>
#endif
+#if defined(_MSC_VER)
+#define ZUFix "%d"
+#else
+#define ZUFix "%4zu"
+#endif
+
using namespace lldb;
using namespace lldb_private;
@@ -2754,7 +2760,7 @@
addr_t allocated_addr = DoAllocateMemory (size, permissions, error);
Log *log(lldb_private::GetLogIfAllCategoriesSet (LIBLLDB_LOG_PROCESS));
if (log)
- log->Printf("Process::AllocateMemory(size=%4zu, permissions=%s) => 0x%16.16" PRIx64 " (m_stop_id = %u m_memory_id = %u)",
+ log->Printf("Process::AllocateMemory(size=%" ZUFix ", permissions=%s) => 0x%16.16" PRIx64 " (m_stop_id = %u m_memory_id = %u)",
size,
GetPermissionsAsCString (permissions),
(uint64_t)allocated_addr,
Index: tools/driver/ELWrapper.cpp
===================================================================
--- tools/driver/ELWrapper.cpp
+++ tools/driver/ELWrapper.cpp
@@ -199,9 +199,9 @@
if ( _prompt != NULL )
printf( _prompt );
// create a buffer for the user input
- char *buffer = new char[ 64 ];
+ char *buffer = new char[ MAX_PATH ];
// try to get user input string
- if ( el_get_s( buffer, 64 ) )
+ if ( el_get_s( buffer, MAX_PATH ) )
{
// get the string length in 'length'
while ( buffer[ *length ] != '\0' )
_______________________________________________
lldb-commits mailing list
[email protected]
http://lists.cs.uiuc.edu/mailman/listinfo/lldb-commits