From c46f531b6bb62d7dd947504a1c731efb5eb57ef5 Mon Sep 17 00:00:00 2001 From: Clyne Sullivan Date: Sat, 11 Mar 2023 16:32:48 -0500 Subject: u< um/mod --- forth/test/core.fr | 39 +++++++++++++++++++-------------------- 1 file changed, 19 insertions(+), 20 deletions(-) (limited to 'forth') diff --git a/forth/test/core.fr b/forth/test/core.fr index 519124d..42fff25 100644 --- a/forth/test/core.fr +++ b/forth/test/core.fr @@ -160,19 +160,18 @@ T{ 0 MIN-INT > -> }T T{ MAX-INT MIN-INT > -> }T T{ MAX-INT 0 > -> }T -." HEY! U< IS NOT IMPLEMENTED!" CR -\ T{ 0 1 U< -> }T -\ T{ 1 2 U< -> }T -\ T{ 0 MID-UINT U< -> }T -\ T{ 0 MAX-UINT U< -> }T -\ T{ MID-UINT MAX-UINT U< -> }T -\ T{ 0 0 U< -> }T -\ T{ 1 1 U< -> }T -\ T{ 1 0 U< -> }T -\ T{ 2 1 U< -> }T -\ T{ MID-UINT 0 U< -> }T -\ T{ MAX-UINT 0 U< -> }T -\ T{ MAX-UINT MID-UINT U< -> }T +T{ 0 1 U< -> }T +T{ 1 2 U< -> }T +T{ 0 MID-UINT U< -> }T +T{ 0 MAX-UINT U< -> }T +T{ MID-UINT MAX-UINT U< -> }T +T{ 0 0 U< -> }T +T{ 1 1 U< -> }T +T{ 1 0 U< -> }T +T{ 2 1 U< -> }T +T{ MID-UINT 0 U< -> }T +T{ MAX-UINT 0 U< -> }T +T{ MAX-UINT MID-UINT U< -> }T T{ 0 1 MIN -> 0 }T T{ 1 2 MIN -> 1 }T @@ -411,13 +410,13 @@ T{ MIN-INT MAX-INT M* MAX-INT SM/REM -> 0 MIN-INT }T T{ MAX-INT MAX-INT M* MAX-INT SM/REM -> 0 MAX-INT }T -\ T{ 0 0 1 UM/MOD -> 0 0 }T -\ T{ 1 0 1 UM/MOD -> 0 1 }T -\ T{ 1 0 2 UM/MOD -> 1 0 }T -\ T{ 3 0 2 UM/MOD -> 1 1 }T -\ T{ MAX-UINT 2 UM* 2 UM/MOD -> 0 MAX-UINT }T -\ T{ MAX-UINT 2 UM* MAX-UINT UM/MOD -> 0 2 }T -\ T{ MAX-UINT MAX-UINT UM* MAX-UINT UM/MOD -> 0 MAX-UINT }T +T{ 0 0 1 UM/MOD -> 0 0 }T +T{ 1 0 1 UM/MOD -> 0 1 }T +T{ 1 0 2 UM/MOD -> 1 0 }T +T{ 3 0 2 UM/MOD -> 1 1 }T +T{ MAX-UINT 2 UM* 2 UM/MOD -> 0 MAX-UINT }T +T{ MAX-UINT 2 UM* MAX-UINT UM/MOD -> 0 2 }T +T{ MAX-UINT MAX-UINT UM* MAX-UINT UM/MOD -> 0 MAX-UINT }T : IFFLOORED [ -3 2 / -2 = INVERT ] LITERAL IF POSTPONE \ THEN ; -- cgit v1.2.3