Debugger: Don't copy unnecessarily

Coverity-Id: 1525663
Change-Id: Ic6abd81fbf3255700aac8e08592a5a59f08ea4ab
Reviewed-by: Alessandro Portale <alessandro.portale@qt.io>
This commit is contained in:
Marcus Tillmanns
2023-11-02 14:51:13 +01:00
parent 4593089bdc
commit 89da353746

View File

@@ -1208,7 +1208,7 @@ void DebuggerToolTipManagerPrivate::slotTooltipOverrideRequested
} else { } else {
context.iname = "tooltip." + toHex(context.expression); context.iname = "tooltip." + toHex(context.expression);
auto reusable = [context](DebuggerToolTipHolder *tooltip) { auto reusable = [&context](DebuggerToolTipHolder *tooltip) {
return tooltip->context.isSame(context); return tooltip->context.isSame(context);
}; };
DebuggerToolTipHolder *tooltip = Utils::findOrDefault(m_tooltips, reusable); DebuggerToolTipHolder *tooltip = Utils::findOrDefault(m_tooltips, reusable);