Author: zturner Date: Wed Nov 16 23:14:32 2016 New Revision: 287208 URL: http://llvm.org/viewvc/llvm-project?rev=287208&view=rev Log: Fix warnings and errors introduced with UUID changes.
Modified: lldb/trunk/source/Interpreter/OptionValueUUID.cpp lldb/trunk/source/Target/StackFrame.cpp Modified: lldb/trunk/source/Interpreter/OptionValueUUID.cpp URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/source/Interpreter/OptionValueUUID.cpp?rev=287208&r1=287207&r2=287208&view=diff ============================================================================== --- lldb/trunk/source/Interpreter/OptionValueUUID.cpp (original) +++ lldb/trunk/source/Interpreter/OptionValueUUID.cpp Wed Nov 16 23:14:32 2016 @@ -79,9 +79,8 @@ size_t OptionValueUUID::AutoComplete(Com const size_t num_modules = target->GetImages().GetSize(); if (num_modules > 0) { UUID::ValueType uuid_bytes; - size_t num_bytes_decoded = 0; - llvm::StringRef rest = - UUID::DecodeUUIDBytesFromString(s, uuid_bytes, num_bytes_decoded); + uint32_t num_bytes_decoded = 0; + UUID::DecodeUUIDBytesFromString(s, uuid_bytes, num_bytes_decoded); for (size_t i = 0; i < num_modules; ++i) { ModuleSP module_sp(target->GetImages().GetModuleAtIndex(i)); if (module_sp) { Modified: lldb/trunk/source/Target/StackFrame.cpp URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/source/Target/StackFrame.cpp?rev=287208&r1=287207&r2=287208&view=diff ============================================================================== --- lldb/trunk/source/Target/StackFrame.cpp (original) +++ lldb/trunk/source/Target/StackFrame.cpp Wed Nov 16 23:14:32 2016 @@ -484,14 +484,16 @@ StackFrame::GetInScopeVariableList(bool } ValueObjectSP StackFrame::GetValueForVariableExpressionPath( - llvm::StringRef var_expr_cstr, DynamicValueType use_dynamic, - uint32_t options, VariableSP &var_sp, Error &error) { + llvm::StringRef var_expr, DynamicValueType use_dynamic, uint32_t options, + VariableSP &var_sp, Error &error) { + llvm::StringRef original_var_expr = var_expr; // We can't fetch variable information for a history stack frame. if (m_is_history_frame) return ValueObjectSP(); - if (var_expr_cstr.empty()) { - error.SetErrorStringWithFormat("invalid variable path '%s'", var_expr_cstr); + if (var_expr.empty()) { + error.SetErrorStringWithFormat("invalid variable path '%s'", + var_expr.str().c_str()); return ValueObjectSP(); } @@ -517,7 +519,6 @@ ValueObjectSP StackFrame::GetValueForVar return ValueObjectSP(); // If first character is a '*', then show pointer contents - llvm::StringRef var_expr = var_expr_cstr; std::string var_expr_storage; if (var_expr[0] == '*') { deref = true; @@ -688,7 +689,8 @@ ValueObjectSP StackFrame::GetValueForVar } else { error.SetErrorStringWithFormat( "incomplete expression path after \"%s\" in \"%s\"", - var_expr_path_strm.GetData(), var_expr_cstr); + var_expr_path_strm.GetData(), + original_var_expr.str().c_str()); } } return ValueObjectSP(); _______________________________________________ lldb-commits mailing list lldb-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits