diff options
author | Saleem Abdulrasool <compnerd@compnerd.org> | 2014-04-04 04:06:10 +0000 |
---|---|---|
committer | Saleem Abdulrasool <compnerd@compnerd.org> | 2014-04-04 04:06:10 +0000 |
commit | 324a1036194f95385b26c941bc82cc6dadf50ac7 (patch) | |
tree | 06bb7d9660aafa1ff4e69cfa813b5c122038e09f /lldb/source/DataFormatters | |
parent | f3aefca7c1bcdd3a6445b7ae04a9f69af567a7e7 (diff) | |
download | bcm5719-llvm-324a1036194f95385b26c941bc82cc6dadf50ac7.tar.gz bcm5719-llvm-324a1036194f95385b26c941bc82cc6dadf50ac7.zip |
sweep up -Wformat warnings from gcc
This is a purely mechanical change explicitly casting any parameters for printf
style conversion. This cleans up the warnings emitted by gcc 4.8 on Linux.
llvm-svn: 205607
Diffstat (limited to 'lldb/source/DataFormatters')
-rw-r--r-- | lldb/source/DataFormatters/FormatManager.cpp | 12 | ||||
-rw-r--r-- | lldb/source/DataFormatters/TypeSummary.cpp | 3 | ||||
-rw-r--r-- | lldb/source/DataFormatters/TypeSynthetic.cpp | 4 |
3 files changed, 13 insertions, 6 deletions
diff --git a/lldb/source/DataFormatters/FormatManager.cpp b/lldb/source/DataFormatters/FormatManager.cpp index e077017f281..2f026b50a28 100644 --- a/lldb/source/DataFormatters/FormatManager.cpp +++ b/lldb/source/DataFormatters/FormatManager.cpp @@ -594,7 +594,9 @@ FormatManager::GetFormat (ValueObject& valobj, if (valobj_type) { if (log) - log->Printf("[FormatManager::GetFormat] Caching %p for type %s",retval.get(),valobj_type.AsCString("<invalid>")); + log->Printf("[FormatManager::GetFormat] Caching %p for type %s", + static_cast<void*>(retval.get()), + valobj_type.AsCString("<invalid>")); m_format_cache.SetFormat(valobj_type,retval); } if (log && log->GetDebug()) @@ -643,7 +645,9 @@ FormatManager::GetSummaryFormat (ValueObject& valobj, if (valobj_type) { if (log) - log->Printf("[FormatManager::GetSummaryFormat] Caching %p for type %s",retval.get(),valobj_type.AsCString("<invalid>")); + log->Printf("[FormatManager::GetSummaryFormat] Caching %p for type %s", + static_cast<void*>(retval.get()), + valobj_type.AsCString("<invalid>")); m_format_cache.SetSummary(valobj_type,retval); } if (log && log->GetDebug()) @@ -693,7 +697,9 @@ FormatManager::GetSyntheticChildren (ValueObject& valobj, if (valobj_type) { if (log) - log->Printf("[FormatManager::GetSyntheticChildren] Caching %p for type %s",retval.get(),valobj_type.AsCString("<invalid>")); + log->Printf("[FormatManager::GetSyntheticChildren] Caching %p for type %s", + static_cast<void*>(retval.get()), + valobj_type.AsCString("<invalid>")); m_format_cache.SetSynthetic(valobj_type,retval); } if (log && log->GetDebug()) diff --git a/lldb/source/DataFormatters/TypeSummary.cpp b/lldb/source/DataFormatters/TypeSummary.cpp index 4c75b4b87d0..628c385b92d 100644 --- a/lldb/source/DataFormatters/TypeSummary.cpp +++ b/lldb/source/DataFormatters/TypeSummary.cpp @@ -129,7 +129,8 @@ std::string CXXFunctionSummaryFormat::GetDescription () { StreamString sstr; - sstr.Printf ("`%s (%p) `%s%s%s%s%s%s%s", m_description.c_str(),m_impl, + sstr.Printf ("`%s (%p) `%s%s%s%s%s%s%s", m_description.c_str(), + static_cast<void*>(&m_impl), Cascades() ? "" : " (not cascading)", !DoesPrintChildren() ? "" : " (show children)", !DoesPrintValue() ? " (hide value)" : "", diff --git a/lldb/source/DataFormatters/TypeSynthetic.cpp b/lldb/source/DataFormatters/TypeSynthetic.cpp index 972be486b78..29f0c627675 100644 --- a/lldb/source/DataFormatters/TypeSynthetic.cpp +++ b/lldb/source/DataFormatters/TypeSynthetic.cpp @@ -57,9 +57,9 @@ CXXSyntheticChildren::GetDescription() Cascades() ? "" : " (not cascading)", SkipsPointers() ? " (skip pointers)" : "", SkipsReferences() ? " (skip references)" : "", - m_create_callback, + reinterpret_cast<void*>(m_create_callback), m_description.c_str()); - + return sstr.GetString(); } |