Use eq? instead of number= since we only ever have a fixnum here

db4
Slava Pestov 2008-12-08 13:59:59 -06:00
parent ca8091443c
commit 73b3cd6367
1 changed files with 1 additions and 1 deletions

View File

@ -41,7 +41,7 @@ M: fixnum bitnot fixnum-bitnot ;
M: fixnum bit? neg shift 1 bitand 0 > ; M: fixnum bit? neg shift 1 bitand 0 > ;
: fixnum-log2 ( x -- n ) : fixnum-log2 ( x -- n )
0 swap [ dup 1 number= not ] [ [ 1+ ] [ 2/ ] bi* ] [ ] while drop ; 0 swap [ dup 1 eq? not ] [ [ 1+ ] [ 2/ ] bi* ] [ ] while drop ;
M: fixnum (log2) fixnum-log2 ; M: fixnum (log2) fixnum-log2 ;