From f04dff9d8dfcb1da5a4f90047f00c7ef7d4b3cf4 Mon Sep 17 00:00:00 2001 From: Simon Southwell Date: Sun, 28 Jan 2024 15:02:36 +0000 Subject: [PATCH] Removed unnecessary castings --- python/test/usercode/VUserMain0.py | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/python/test/usercode/VUserMain0.py b/python/test/usercode/VUserMain0.py index c97e812..fa6cfe9 100644 --- a/python/test/usercode/VUserMain0.py +++ b/python/test/usercode/VUserMain0.py @@ -102,21 +102,21 @@ def VUserMain0() : vpapi.tick(5) - rdata = c_uint32(vpapi.read(addr[0])).value + rdata = c_uint32(vpapi.read(addr[0])).value # Unsigned value if rdata == wdata[0] : - vpapi.VPrint("Read " + hex(c_uint32(rdata).value) + " from addr " + hex(addr[0])) + vpapi.VPrint("Read " + hex(rdata) + " from addr " + hex(addr[0])) else : - vpapi.VPrint("***ERROR: Read " + hex(c_uint32(rdata).value) + " from addr " + hex(addr[0]) + ", expected " + hex(wdata[0])) + vpapi.VPrint("***ERROR: Read " + hex(rdata) + " from addr " + hex(addr[0]) + ", expected " + hex(wdata[0])) vpapi.tick(3) - rdata = c_uint32(vpapi.read(addr[1])).value + rdata = c_uint32(vpapi.read(addr[1])).value # Unsigned value if rdata == wdata[1] : - vpapi.VPrint("Read " + hex(c_uint32(rdata).value) + " from addr " + hex(addr[1])) + vpapi.VPrint("Read " + hex(rdata) + " from addr " + hex(addr[1])) else : - vpapi.VPrint("***ERROR: Read " + hex(c_uint32(rdata).value) + " from addr " + hex(addr[1]) + ", expected " + hex(wdata[1])) + vpapi.VPrint("***ERROR: Read " + hex(rdata) + " from addr " + hex(addr[1]) + ", expected " + hex(wdata[1])) vpapi.VPrint("\nTests complete, stopping simulation\n") vpapi.tick(20)