[Lldb-commits] [lldb] r192920 - Fix building with ENABLE_DEBUG_PRINTF
Ed Maste
emaste at freebsd.org
Thu Oct 17 13:42:56 PDT 2013
Author: emaste
Date: Thu Oct 17 15:42:56 2013
New Revision: 192920
URL: http://llvm.org/viewvc/llvm-project?rev=192920&view=rev
Log:
Fix building with ENABLE_DEBUG_PRINTF
Clang tells me that "token pasting of ',' and __VA_ARGS__ is a GNU
extension". Also catch up with changes in function args.
Modified:
lldb/trunk/source/Plugins/SymbolFile/DWARF/SymbolFileDWARF.cpp
Modified: lldb/trunk/source/Plugins/SymbolFile/DWARF/SymbolFileDWARF.cpp
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/source/Plugins/SymbolFile/DWARF/SymbolFileDWARF.cpp?rev=192920&r1=192919&r2=192920&view=diff
==============================================================================
--- lldb/trunk/source/Plugins/SymbolFile/DWARF/SymbolFileDWARF.cpp (original)
+++ lldb/trunk/source/Plugins/SymbolFile/DWARF/SymbolFileDWARF.cpp Thu Oct 17 15:42:56 2013
@@ -70,7 +70,7 @@
#ifdef ENABLE_DEBUG_PRINTF
#include <stdio.h>
-#define DEBUG_PRINTF(fmt, ...) printf(fmt, ## __VA_ARGS__)
+#define DEBUG_PRINTF(fmt, ...) printf(fmt, __VA_ARGS__)
#else
#define DEBUG_PRINTF(fmt, ...)
#endif
@@ -4852,9 +4852,8 @@ SymbolFileDWARF::FindCompleteObjCDefinit
Type *resolved_type = ResolveType (type_cu, type_die, false);
if (resolved_type && resolved_type != DIE_IS_BEING_PARSED)
{
- DEBUG_PRINTF ("resolved 0x%8.8" PRIx64 " (cu 0x%8.8" PRIx64 ") from %s to 0x%8.8" PRIx64 " (cu 0x%8.8" PRIx64 ")\n",
+ DEBUG_PRINTF ("resolved 0x%8.8" PRIx64 " from %s to 0x%8.8" PRIx64 " (cu 0x%8.8" PRIx64 ")\n",
MakeUserID(die->GetOffset()),
- MakeUserID(dwarf_cu->GetOffset()),
m_obj_file->GetFileSpec().GetFilename().AsCString(),
MakeUserID(type_die->GetOffset()),
MakeUserID(type_cu->GetOffset()));
@@ -5130,7 +5129,7 @@ SymbolFileDWARF::FindDefinitionTypeForDI
{
DEBUG_PRINTF ("resolved 0x%8.8" PRIx64 " (cu 0x%8.8" PRIx64 ") from %s to 0x%8.8" PRIx64 " (cu 0x%8.8" PRIx64 ")\n",
MakeUserID(die->GetOffset()),
- MakeUserID(dwarf_cu->GetOffset()),
+ MakeUserID(cu->GetOffset()),
m_obj_file->GetFileSpec().GetFilename().AsCString(),
MakeUserID(type_die->GetOffset()),
MakeUserID(type_cu->GetOffset()));
@@ -5745,7 +5744,7 @@ SymbolFileDWARF::ParseType (const Symbol
}
}
- DEBUG_PRINTF ("0x%8.8" PRIx64 ": %s (\"%s\") type => 0x%8.8x\n", MakeUserID(die->GetOffset()), DW_TAG_value_to_name(tag), type_name_cstr, encoding_uid);
+ DEBUG_PRINTF ("0x%8.8" PRIx64 ": %s (\"%s\") type => 0x%8.8lx\n", MakeUserID(die->GetOffset()), DW_TAG_value_to_name(tag), type_name_cstr, encoding_uid);
switch (tag)
{
More information about the lldb-commits
mailing list