mirror of
https://github.com/capstone-engine/llvm-capstone.git
synced 2025-01-25 10:48:14 +00:00
Allow variable names to be quoted with -var-list-children
Allow both '-var-list-children var0' and '-var-list-children "var0"' to be used with the -var-list-children command. GDB MI allows for this and it is necessary if the variable name contains spaces, such as var5.std::_Vector_base<std::basic_string<char, std::char_traits<char>, std::allocator<char> >, std::allocator<std::basic_string<char, std::char_traits<char>, std::allocator<cahr> > > >. Differential Revision: http://reviews.llvm.org/D15168 llvm-svn: 254941
This commit is contained in:
parent
ecc8038571
commit
1ffd4f5093
@ -49,6 +49,9 @@ class MiVarTestCase(lldbmi_testcase.MiTestCaseBase):
|
||||
self.expect("\^done,status=\"editable\"")
|
||||
self.runCmd("-var-list-children var2")
|
||||
self.expect("\^done,numchild=\"0\",has_more=\"0\"")
|
||||
# Ensure -var-list-children also works with quotes
|
||||
self.runCmd("-var-list-children \"var2\"")
|
||||
self.expect("\^done,numchild=\"0\",has_more=\"0\"")
|
||||
self.runCmd("-data-evaluate-expression \"g_MyVar=30\"")
|
||||
self.expect("\^done,value=\"30\"")
|
||||
self.runCmd("-var-update --all-values var2")
|
||||
|
@ -945,7 +945,7 @@ bool
|
||||
CMICmdCmdVarListChildren::ParseArgs()
|
||||
{
|
||||
m_setCmdArgs.Add(new CMICmdArgValPrintValues(m_constStrArgPrintValues, false, true));
|
||||
m_setCmdArgs.Add(new CMICmdArgValString(m_constStrArgName, true, true));
|
||||
m_setCmdArgs.Add(new CMICmdArgValString(m_constStrArgName, true, true, true));
|
||||
m_setCmdArgs.Add(new CMICmdArgValNumber(m_constStrArgFrom, false, true));
|
||||
m_setCmdArgs.Add(new CMICmdArgValNumber(m_constStrArgTo, false, true));
|
||||
return ParseValidateCmdOptions();
|
||||
|
Loading…
x
Reference in New Issue
Block a user