standalone: Add float64 output tests

This commit is contained in:
David Mak 2023-09-29 15:06:56 +08:00
parent 8801fc63e1
commit c010fd9a09
1 changed files with 14 additions and 0 deletions

View File

@ -14,6 +14,10 @@ def output_uint32(x: uint32):
def output_uint64(x: uint64):
...
@extern
def output_float64(x: float):
...
@extern
def output_int32_list(x: list[int32]):
...
@ -38,6 +42,15 @@ def test_output_uint32():
def test_output_uint64():
output_uint64(uint64(256))
def test_output_float64():
output_float64(0.0)
output_float64(1.0)
output_float64(-1.0)
output_float64(128.0)
output_float64(-128.0)
output_float64(16.25)
output_float64(-16.25)
def test_output_asciiart():
for i in range(17):
output_asciiart(i)
@ -54,6 +67,7 @@ def run() -> int32:
test_output_int64()
test_output_uint32()
test_output_uint64()
test_output_float64()
test_output_asciiart()
test_output_int32_list()
test_output_str_family()