From 1473176c3ee73e6c91a54f0587cc06efa4c69cd6 Mon Sep 17 00:00:00 2001 From: Koichi Nakamura Date: Wed, 5 May 2021 23:19:02 +0900 Subject: [PATCH] Passed tests of bitscan-reverse --- lib/bitscan.fs | 1 + 1 file changed, 1 insertion(+) diff --git a/lib/bitscan.fs b/lib/bitscan.fs index 47d13e0..e51ba64 100644 --- a/lib/bitscan.fs +++ b/lib/bitscan.fs @@ -60,6 +60,7 @@ create msb-table \ If u == 0, returns -1 : bitscan-reverse ( u -- u ) dup 0xff u< if cells msb-table + @ exit then + 8 rshift recurse 8 + ; export }private