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()); } _______________________________________________ lldb-commits mailing list lldb-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits