From c7b8ed520de587770a195e60df6a02ea86279dfa Mon Sep 17 00:00:00 2001 From: David Schulz Date: Mon, 19 Jun 2023 14:54:30 +0200 Subject: [PATCH] Debugger: avoid recursive pointer type lookup the std::nullptr_t gets reported as a pointer type with std::nullptr_t as the target type. In order to avoid a recursive lookup check whether the target type name is identical to the pointer type name. Fixes: QTCREATORBUG-29291 Change-Id: I25373bf56b5538b9e5c14c34b9a5e501b5803fea Reviewed-by: Christian Stenger --- share/qtcreator/debugger/cdbbridge.py | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/share/qtcreator/debugger/cdbbridge.py b/share/qtcreator/debugger/cdbbridge.py index f19d8dedf9b..a9d86e24ee1 100644 --- a/share/qtcreator/debugger/cdbbridge.py +++ b/share/qtcreator/debugger/cdbbridge.py @@ -147,11 +147,12 @@ class Dumper(DumperBase): code = nativeType.code() if code == TypeCode.Pointer: - if not nativeType.name().startswith(''): + if nativeType.name().startswith(''): + code = TypeCode.Function + elif nativeType.targetName() != nativeType.name(): targetType = self.lookupType(nativeType.targetName(), nativeType.moduleId()) - if targetType is not None: + if targetType is not None and targetType is not nativeType: return self.createPointerType(targetType) - code = TypeCode.Function if code == TypeCode.Array: # cdb reports virtual function tables as arrays those ar handled separetly by