mirror of
https://github.com/RGBCube/serenity
synced 2025-07-26 04:07:35 +00:00
Meta: Generate bigints for i64 values in LibWasm test suite files
This commit is contained in:
parent
99199b9bfd
commit
e93c740df5
1 changed files with 6 additions and 3 deletions
|
@ -245,7 +245,10 @@ def genarg(spec):
|
||||||
return str(struct.unpack('>i', struct.pack('>Q', int(x, 16))[4:])[0])
|
return str(struct.unpack('>i', struct.pack('>Q', int(x, 16))[4:])[0])
|
||||||
|
|
||||||
# cast back to i64 to get the correct sign
|
# cast back to i64 to get the correct sign
|
||||||
return str(struct.unpack('>q', struct.pack('>Q', int(x, 16)))[0])
|
return str(struct.unpack('>q', struct.pack('>Q', int(x, 16)))[0]) + 'n'
|
||||||
|
if spec['type'] == 'i64':
|
||||||
|
# Make a bigint instead, since `double' cannot fit all i64 values.
|
||||||
|
return x + 'n'
|
||||||
return x
|
return x
|
||||||
|
|
||||||
if x == 'nan':
|
if x == 'nan':
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue