Commit fa02d8c0 authored by Peifeng Yu's avatar Peifeng Yu
Browse files

Make MIDebugSession::findVariableByVarobjName const

parent 72388379
......@@ -120,11 +120,11 @@ QMap<QString, MIVariable*> & MIDebugSession::variableMapping()
return m_allVariables;
}
MIVariable* MIDebugSession::findVariableByVarobjName(const QString &varobjName)
MIVariable* MIDebugSession::findVariableByVarobjName(const QString &varobjName) const
{
if (m_allVariables.count(varobjName) == 0)
return nullptr;
return m_allVariables[varobjName];
return m_allVariables.value(varobjName);
}
void MIDebugSession::markAllVariableDead()
......
......@@ -215,7 +215,7 @@ public:
MI::CommandFlags flags = 0);
QMap<QString, MIVariable*> & variableMapping();
MIVariable* findVariableByVarobjName(const QString &varobjName);
MIVariable* findVariableByVarobjName(const QString &varobjName) const;
void markAllVariableDead();
protected Q_SLOTS:
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment