[Lldb-commits] [lldb] r258548 - Commands: silence dumb -Wextra warning from GCC
Saleem Abdulrasool via lldb-commits
lldb-commits at lists.llvm.org
Fri Jan 22 12:26:34 PST 2016
Author: compnerd
Date: Fri Jan 22 14:26:34 2016
New Revision: 258548
URL: http://llvm.org/viewvc/llvm-project?rev=258548&view=rev
Log:
Commands: silence dumb -Wextra warning from GCC
This is a rather unhelpful warning indicating that the ternary operator return
types are mismatched, returning an integer and an enumeral type. Since the
integeral type is shorter to type, cast the enumeral type to `int`. Silences
the -Wextra warning from GCC.
Modified:
lldb/trunk/source/Commands/CommandObjectTarget.cpp
Modified: lldb/trunk/source/Commands/CommandObjectTarget.cpp
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/source/Commands/CommandObjectTarget.cpp?rev=258548&r1=258547&r2=258548&view=diff
==============================================================================
--- lldb/trunk/source/Commands/CommandObjectTarget.cpp (original)
+++ lldb/trunk/source/Commands/CommandObjectTarget.cpp Fri Jan 22 14:26:34 2016
@@ -4083,11 +4083,11 @@ public:
case eLookupTypeAddress:
if (m_options.m_addr != LLDB_INVALID_ADDRESS)
{
- if (LookupAddressInModule (m_interpreter,
- result.GetOutputStream(),
- module,
- eSymbolContextEverything | (m_options.m_verbose ? eSymbolContextVariable : 0),
- m_options.m_addr,
+ if (LookupAddressInModule (m_interpreter,
+ result.GetOutputStream(),
+ module,
+ eSymbolContextEverything | (m_options.m_verbose ? static_cast<int>(eSymbolContextVariable) : 0),
+ m_options.m_addr,
m_options.m_offset,
m_options.m_verbose))
{
More information about the lldb-commits
mailing list