Fix for VMTest parseHex in 32 bit

This commit is contained in:
coffeepots 2018-08-08 19:37:02 +01:00 committed by zah
parent a12b0771d6
commit 1bf432fd46
1 changed files with 5 additions and 2 deletions

View File

@ -120,5 +120,8 @@ proc verifyStateDB*(wantedState: JsonNode, stateDB: AccountStateDB) =
doAssert wantedBalance == actualBalance
doAssert wantedNonce == actualNonce
proc getHexadecimalInt*(j: JsonNode): int =
discard parseHex(j.getStr, result)
proc getHexadecimalInt*(j: JsonNode): int64 =
# parseutils.parseHex works with int which will overflow in 32 bit
var data: StUInt[64]
data = fromHex(StUInt[64], j.getStr)
result = cast[int64](data)