diff options
author | Pavel Labath <labath@google.com> | 2017-01-13 10:41:59 +0000 |
---|---|---|
committer | Pavel Labath <labath@google.com> | 2017-01-13 10:41:59 +0000 |
commit | 0cfd7dc9eaf5f8c2bf912f759461d5aa068ac04b (patch) | |
tree | bcec895a3f8844ce0ab3df43f1081eda55881efa /lldb/source/Core/Log.cpp | |
parent | a2c59149e14b52b613a5403302cf84d6ab0456d0 (diff) | |
download | bcm5719-llvm-0cfd7dc9eaf5f8c2bf912f759461d5aa068ac04b.tar.gz bcm5719-llvm-0cfd7dc9eaf5f8c2bf912f759461d5aa068ac04b.zip |
Remove a couple of Stream flags
Summary:
I came across this while trying to understand what Log::Debug does. It turns out
it does not do anything, as there is no instance of someone setting a debug flag
on a stream. The same is true for the Verbose and AddPrefix flags. Removing
these will enable some cleanups in the Logging class, and it brings us closer
towards the long term goal of standardizing on llvm stream classes.
I have removed these flags and all code the code which tested for their
presence -- there wasn't much of it, mostly in SymbolFileDWARF, which is
probably going away at some point anyway.
The eBinary flag still has some users, so I am letting it life for the time
being.
Reviewers: clayborg, zturner
Subscribers: aprantl, beanz, lldb-commits
Differential Revision: https://reviews.llvm.org/D28616
llvm-svn: 291895
Diffstat (limited to 'lldb/source/Core/Log.cpp')
-rw-r--r-- | lldb/source/Core/Log.cpp | 19 |
1 files changed, 2 insertions, 17 deletions
diff --git a/lldb/source/Core/Log.cpp b/lldb/source/Core/Log.cpp index b62df3c1fe9..28fb711b0ae 100644 --- a/lldb/source/Core/Log.cpp +++ b/lldb/source/Core/Log.cpp @@ -343,28 +343,13 @@ void Log::ListAllLogChannels(Stream *strm) { } } -bool Log::GetVerbose() const { - // FIXME: This has to be centralized between the stream and the log... - if (m_options.Test(LLDB_LOG_OPTION_VERBOSE)) - return true; - - // Make a copy of our stream shared pointer in case someone disables our - // log while we are logging and releases the stream - StreamSP stream_sp(m_stream_sp); - if (stream_sp) - return stream_sp->GetVerbose(); - return false; -} +bool Log::GetVerbose() const { return m_options.Test(LLDB_LOG_OPTION_VERBOSE); } //------------------------------------------------------------------ // Returns true if the debug flag bit is set in this stream. //------------------------------------------------------------------ bool Log::GetDebug() const { - // Make a copy of our stream shared pointer in case someone disables our - // log while we are logging and releases the stream - StreamSP stream_sp(m_stream_sp); - if (stream_sp) - return stream_sp->GetDebug(); + // TODO: remove and clean up callers return false; } |