Debugger: Fix int casting for bitfields

Change-Id: Iea3647594ffa3b2024ae469d844fa73028a0ab62
Reviewed-by: hjk <hjk@qt.io>
This commit is contained in:
Orgad Shaneh
2017-02-08 17:40:22 +02:00
committed by Orgad Shaneh
parent a6f43e49b7
commit 2b50fec73b
+2
View File
@@ -2801,6 +2801,8 @@ class DumperBase:
def integer(self):
if self.type.code == TypeCodeTypedef:
return self.detypedef().integer()
elif self.type.code == TypeCodeBitfield:
return self.lvalue
unsigned = self.type.name.startswith('unsigned')
bitsize = self.type.bitsize()
return self.extractInteger(bitsize, unsigned)