diff options
author | emaste <emaste@FreeBSD.org> | 2015-07-03 16:57:06 +0000 |
---|---|---|
committer | emaste <emaste@FreeBSD.org> | 2015-07-03 16:57:06 +0000 |
commit | 8037fa4ee916fa20b3c63cbf531f4ee7e1c76138 (patch) | |
tree | 3c2e41c3be19b7fc7666ed45a5f91ec3b6e35f2a /source/Interpreter/OptionValueArray.cpp | |
parent | d61b076ede88b56f3372a55e7d1eac6a9d717120 (diff) | |
download | FreeBSD-src-8037fa4ee916fa20b3c63cbf531f4ee7e1c76138.zip FreeBSD-src-8037fa4ee916fa20b3c63cbf531f4ee7e1c76138.tar.gz |
Import LLDB as of upstream SVN 241361 (git 612c075f)
Diffstat (limited to 'source/Interpreter/OptionValueArray.cpp')
-rw-r--r-- | source/Interpreter/OptionValueArray.cpp | 12 |
1 files changed, 8 insertions, 4 deletions
diff --git a/source/Interpreter/OptionValueArray.cpp b/source/Interpreter/OptionValueArray.cpp index 86d49c9..aabe457 100644 --- a/source/Interpreter/OptionValueArray.cpp +++ b/source/Interpreter/OptionValueArray.cpp @@ -74,11 +74,13 @@ OptionValueArray::DumpValue (const ExecutionContext *exe_ctx, Stream &strm, uint } Error -OptionValueArray::SetValueFromCString (const char *value, VarSetOperationType op) +OptionValueArray::SetValueFromString (llvm::StringRef value, VarSetOperationType op) { - Args args(value); - NotifyValueChanged(); - return SetArgs (args, op); + Args args(value.str().c_str()); + Error error = SetArgs (args, op); + if (error.Success()) + NotifyValueChanged(); + return error; } @@ -342,6 +344,8 @@ OptionValueArray::DeepCopy () const { OptionValueArray *copied_array = new OptionValueArray (m_type_mask, m_raw_value_dump); lldb::OptionValueSP copied_value_sp(copied_array); + *static_cast<OptionValue *>(copied_array) = *this; + copied_array->m_callback = m_callback; const uint32_t size = m_values.size(); for (uint32_t i = 0; i<size; ++i) { |