1 ! Copyright (C) 2004, 2006 Slava Pestov.
2 ! See http://factorcode.org/license.txt for BSD license.
3 USING: kernel math math.private ;
4 IN: math.floats.private
6 M: fixnum >float fixnum>float ;
7 M: bignum >float bignum>float ;
9 M: float >fixnum float>fixnum ;
10 M: float >bignum float>bignum ;
13 M: float hashcode* nip float>bits ;
14 M: float equal? over float? [ float= ] [ 2drop f ] if ;
15 M: float number= float= ;
27 M: float /i float/f >integer ;
28 M: float mod float-mod ;
30 M: real abs dup 0 < [ neg ] when ;