From f7895e272b4555ce1963790b9db1eea91bf359fb Mon Sep 17 00:00:00 2001 From: Ulf Hermann Date: Fri, 11 May 2018 14:09:41 +0200 Subject: [PATCH] QML Debugger: Don't hang if there are no scopes to be retrieved Qt 5.11.0 contains an optimization that does away with call contexts for simple inline bindings. Also, it doesn't report QML contexts as scopes in the "frame" and "backtrace" commands. Therefore, in those cases "this" is the only thing to be retrieved. Check if we are done when "this" has been retrieved and no scopes have been found. Change-Id: I9e0f545777bc38333938b65a934d42701ec4f807 Task-number: QTBUG-68218 Reviewed-by: Eike Ziller Reviewed-by: hjk --- src/plugins/debugger/qml/qmlengine.cpp | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/plugins/debugger/qml/qmlengine.cpp b/src/plugins/debugger/qml/qmlengine.cpp index 96007d1bcb6..214313773f8 100644 --- a/src/plugins/debugger/qml/qmlengine.cpp +++ b/src/plugins/debugger/qml/qmlengine.cpp @@ -2167,6 +2167,10 @@ void QmlEnginePrivate::handleFrame(const QVariantMap &response) watchHandler->insertItem(item); evaluate(exp, -1, [this, iname, exp](const QVariantMap &response) { handleEvaluateExpression(response, iname, exp); + + // If there are no scopes, "this" may be the only thing to look up. + if (currentFrameScopes.isEmpty()) + checkForFinishedUpdate(); }); }