[Logging] Replace LogIfAnyCategoriesSet with LLDB_LOG.
This patch removes any remaining instances of LogIfAnyCategoriesSet and
replaces them with the LLDB_LOG macro. This in turn made it possible to
make Log::VAPrintf and Log::VAError private.
llvm-svn: 366768
diff --git a/lldb/source/Target/Target.cpp b/lldb/source/Target/Target.cpp
index 37a661b..71819a9 100644
--- a/lldb/source/Target/Target.cpp
+++ b/lldb/source/Target/Target.cpp
@@ -110,10 +110,10 @@
if (log)
log->Printf("%p Target::Target()", static_cast<void *>(this));
if (target_arch.IsValid()) {
- LogIfAnyCategoriesSet(LIBLLDB_LOG_TARGET,
- "Target::Target created with architecture %s (%s)",
- target_arch.GetArchitectureName(),
- target_arch.GetTriple().getTriple().c_str());
+ LLDB_LOG(lldb_private::GetLogIfAllCategoriesSet(LIBLLDB_LOG_TARGET),
+ "Target::Target created with architecture %s (%s)",
+ target_arch.GetArchitectureName(),
+ target_arch.GetTriple().getTriple().c_str());
}
}
@@ -2319,11 +2319,10 @@
void Target::SetDefaultArchitecture(const ArchSpec &arch) {
TargetPropertiesSP properties_sp(Target::GetGlobalProperties());
if (properties_sp) {
- LogIfAnyCategoriesSet(LIBLLDB_LOG_TARGET,
- "Target::SetDefaultArchitecture setting target's "
- "default architecture to %s (%s)",
- arch.GetArchitectureName(),
- arch.GetTriple().getTriple().c_str());
+ LLDB_LOG(lldb_private::GetLogIfAllCategoriesSet(LIBLLDB_LOG_TARGET),
+ "Target::SetDefaultArchitecture setting target's "
+ "default architecture to %s (%s)",
+ arch.GetArchitectureName(), arch.GetTriple().getTriple().c_str());
return properties_sp->SetDefaultArchitecture(arch);
}
}