Commit fe2b7915 authored by hjk's avatar hjk
Browse files

Debugger: Make QDateTime dumper work in release builds



Change-Id: I5f7b57385c77c4cd6bae9cf033bec91eeb984ac6
Reviewed-by: default avatarhjk <hjk121@nokiamail.com>
parent 553e3397
...@@ -355,17 +355,16 @@ def qdump__QTime(d, value): ...@@ -355,17 +355,16 @@ def qdump__QTime(d, value):
d.putNumChild(0) d.putNumChild(0)
# This relies on the Qt4/Qt5 internal structure layout:
# {sharedref(4), date(8), time(4+x)}
def qdump__QDateTime(d, value): def qdump__QDateTime(d, value):
try: intType = d.lookupType("int")
# Fails without debug info. intPtrType = intType.pointer()
p = value["d"]["d"].dereference() base = pointerValue(value.cast(intPtrType))
except: mds = int(createReferenceValue(value, base + intPtrType.sizeof + 8, intType))
d.putPlainChildren(value)
return
mds = int(p["time"]["mds"])
if mds >= 0: if mds >= 0:
d.putValue("%s/%s" % (int(p["date"]["jd"]), mds), jd = int(createReferenceValue(value, base + intPtrType.sizeof, intType))
JulianDateAndMillisecondsSinceMidnight) d.putValue("%s/%s" % (jd, mds), JulianDateAndMillisecondsSinceMidnight)
d.putNumChild(1) d.putNumChild(1)
if d.isExpanded(): if d.isExpanded():
# FIXME: This improperly uses complex return values. # FIXME: This improperly uses complex return values.
......
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