summaryrefslogtreecommitdiffstats
path: root/lldb/source/Commands
diff options
context:
space:
mode:
authorSaleem Abdulrasool <compnerd@compnerd.org>2014-03-18 04:43:47 +0000
committerSaleem Abdulrasool <compnerd@compnerd.org>2014-03-18 04:43:47 +0000
commit44edda0af7b7aa18da51eea47f978bb1db88e462 (patch)
treed73b52b2619372980170b33411861260216971a0 /lldb/source/Commands
parentcb97c48243d600e29889be85bdd61ce24999f041 (diff)
downloadbcm5719-llvm-44edda0af7b7aa18da51eea47f978bb1db88e462.tar.gz
bcm5719-llvm-44edda0af7b7aa18da51eea47f978bb1db88e462.zip
create constants for multichar constants
Multichar constants are not portable as the byte order is undefined. Use a constant value instead. This avoids a warning when compiling with gcc 4.8+ (-Wmultichar) and makes the code more portable. llvm-svn: 204110
Diffstat (limited to 'lldb/source/Commands')
-rw-r--r--lldb/source/Commands/CommandObjectTarget.cpp11
1 files changed, 9 insertions, 2 deletions
diff --git a/lldb/source/Commands/CommandObjectTarget.cpp b/lldb/source/Commands/CommandObjectTarget.cpp
index 16ce7ee32d8..ec303e4be71 100644
--- a/lldb/source/Commands/CommandObjectTarget.cpp
+++ b/lldb/source/Commands/CommandObjectTarget.cpp
@@ -678,6 +678,9 @@ protected:
class CommandObjectTargetVariable : public CommandObjectParsed
{
+ static const uint32_t SHORT_OPTION_FILE = 0x66696c65; // 'file'
+ static const uint32_t SHORT_OPTION_SHLB = 0x73686c62; // 'shlb'
+
public:
CommandObjectTargetVariable (CommandInterpreter &interpreter) :
CommandObjectParsed (interpreter,
@@ -688,8 +691,12 @@ public:
m_option_group (interpreter),
m_option_variable (false), // Don't include frame options
m_option_format (eFormatDefault),
- m_option_compile_units (LLDB_OPT_SET_1, false, "file", 'file', 0, eArgTypeFilename, "A basename or fullpath to a file that contains global variables. This option can be specified multiple times."),
- m_option_shared_libraries (LLDB_OPT_SET_1, false, "shlib",'shlb', 0, eArgTypeFilename, "A basename or fullpath to a shared library to use in the search for global variables. This option can be specified multiple times."),
+ m_option_compile_units (LLDB_OPT_SET_1, false, "file",
+ SHORT_OPTION_FILE, 0, eArgTypeFilename,
+ "A basename or fullpath to a file that contains global variables. This option can be specified multiple times."),
+ m_option_shared_libraries (LLDB_OPT_SET_1, false, "shlib",
+ SHORT_OPTION_SHLB, 0, eArgTypeFilename,
+ "A basename or fullpath to a shared library to use in the search for global variables. This option can be specified multiple times."),
m_varobj_options()
{
CommandArgumentEntry arg;
OpenPOWER on IntegriCloud