Index: test/tools/lldb-mi/data/TestMiData.py =================================================================== --- test/tools/lldb-mi/data/TestMiData.py +++ test/tools/lldb-mi/data/TestMiData.py @@ -122,7 +122,7 @@ self.expect(r'\*stopped,reason="breakpoint-hit"') # Get address of local char[] - self.runCmd('-data-evaluate-expression &array') + self.runCmd('-data-evaluate-expression "(void *)&array"') self.expect(r'\^done,value="0x[0-9a-f]+"') addr = int(self.child.after.split('"')[1], 16) size = 4 Index: test/tools/lldb-mi/variable/TestMiVar.py =================================================================== --- test/tools/lldb-mi/variable/TestMiVar.py +++ test/tools/lldb-mi/variable/TestMiVar.py @@ -111,7 +111,7 @@ # Print argument "argv[0]" self.runCmd("-data-evaluate-expression \"argv[0]\"") - self.expect("\^done,value=\"0x[0-9a-f]+\"") + self.expect("\^done,value=\"0x[0-9a-f]+ \\\\\\\".*?%s\\\\\\\"\"" % self.myexe) self.runCmd("-var-create var6 * \"argv[0]\"") self.expect("\^done,name=\"var6\",numchild=\"1\",value=\"0x[0-9a-f]+ \\\\\\\".*?%s\\\\\\\"\",type=\"const char \*\",thread-id=\"1\",has_more=\"0\"" % self.myexe) self.runCmd("-var-evaluate-expression var6") Index: tools/lldb-mi/MICmdCmdData.cpp =================================================================== --- tools/lldb-mi/MICmdCmdData.cpp +++ tools/lldb-mi/MICmdCmdData.cpp @@ -125,7 +125,7 @@ lldb::SBValue value = frame.EvaluateExpression(rExpression.c_str()); if (!value.IsValid() || value.GetError().Fail()) value = frame.FindVariable(rExpression.c_str()); - const CMICmnLLDBUtilSBValue utilValue(value); + const CMICmnLLDBUtilSBValue utilValue(value, true); if (!utilValue.IsValid() || utilValue.IsValueUnknown()) { m_bEvaluatedExpression = false; @@ -153,12 +153,7 @@ { const lldb::ValueType eValueType = value.GetValueType(); MIunused(eValueType); - m_strValue = utilValue.GetValue(); - CMIUtilString strCString; - if (CMICmnLLDBProxySBValue::GetCString(value, strCString)) - { - m_strValue += CMIUtilString::Format(" '%s'", strCString.c_str()); - } + m_strValue = utilValue.GetValue().Escape().AddSlashes(); return MIstatus::success; }