[Lldb-commits] [lldb] r251722 - Make the error return more explicit when an SBValue has no value.
Jim Ingham via lldb-commits
lldb-commits at lists.llvm.org
Fri Oct 30 14:43:15 PDT 2015
Author: jingham
Date: Fri Oct 30 16:43:15 2015
New Revision: 251722
URL: http://llvm.org/viewvc/llvm-project?rev=251722&view=rev
Log:
Make the error return more explicit when an SBValue has no value.
Modified:
lldb/trunk/source/API/SBValue.cpp
Modified: lldb/trunk/source/API/SBValue.cpp
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/source/API/SBValue.cpp?rev=251722&r1=251721&r2=251722&view=diff
==============================================================================
--- lldb/trunk/source/API/SBValue.cpp (original)
+++ lldb/trunk/source/API/SBValue.cpp Fri Oct 30 16:43:15 2015
@@ -1425,7 +1425,10 @@ lldb::ValueObjectSP
SBValue::GetSP (ValueLocker &locker) const
{
if (!m_opaque_sp || !m_opaque_sp->IsValid())
+ {
+ locker.GetError().SetErrorString("No value");
return ValueObjectSP();
+ }
return locker.GetLockedSP(*m_opaque_sp.get());
}
More information about the lldb-commits
mailing list