forked from qt-creator/qt-creator
Don't allocate unneeded temporary containers
Fix clazy warnings: allocating an unneeded temporary container [clazy-container-anti-pattern] Change-Id: I4b4c2c634eea650bbdf3c12d982a17f899fc94ec Reviewed-by: Alessandro Portale <alessandro.portale@qt.io> Reviewed-by: David Schulz <david.schulz@qt.io> Reviewed-by: hjk <hjk@qt.io>
This commit is contained in:
@@ -500,8 +500,10 @@ void DebuggerMainWindow::savePersistentSettings() const
|
||||
|
||||
QVariantHash states;
|
||||
qCDebug(perspectivesLog) << "PERSPECTIVE TYPES: " << d->m_lastTypePerspectiveStates.keys();
|
||||
for (const QString &type : d->m_lastTypePerspectiveStates.keys()) {
|
||||
const PerspectiveState state = d->m_lastTypePerspectiveStates.value(type);
|
||||
for (auto it = d->m_lastTypePerspectiveStates.cbegin();
|
||||
it != d->m_lastTypePerspectiveStates.cend(); ++it) {
|
||||
const QString &type = it.key();
|
||||
const PerspectiveState &state = it.value();
|
||||
qCDebug(perspectivesLog) << "PERSPECTIVE TYPE " << type
|
||||
<< " HAS STATE: " << !state.mainWindowState.isEmpty();
|
||||
QTC_ASSERT(!state.mainWindowState.isEmpty(), continue);
|
||||
|
||||
Reference in New Issue
Block a user