Remove useless with-scope and unneeded uses
parent
3fbb9f7081
commit
e6a5ac4acd
|
@ -1,7 +1,7 @@
|
||||||
! Copyright (C) 2008 Doug Coleman.
|
! Copyright (C) 2008 Doug Coleman.
|
||||||
! See http://factorcode.org/license.txt for BSD license.
|
! See http://factorcode.org/license.txt for BSD license.
|
||||||
USING: combinators io locals kernel math math.functions
|
USING: combinators kernel locals math math.functions math.ranges
|
||||||
math.ranges namespaces random sequences hashtables sets ;
|
random sequences sets ;
|
||||||
IN: math.miller-rabin
|
IN: math.miller-rabin
|
||||||
|
|
||||||
<PRIVATE
|
<PRIVATE
|
||||||
|
@ -37,7 +37,7 @@ PRIVATE>
|
||||||
{ [ dup 1 <= ] [ 3drop f ] }
|
{ [ dup 1 <= ] [ 3drop f ] }
|
||||||
{ [ dup 2 = ] [ 3drop t ] }
|
{ [ dup 2 = ] [ 3drop t ] }
|
||||||
{ [ dup even? ] [ 3drop f ] }
|
{ [ dup even? ] [ 3drop f ] }
|
||||||
[ [ drop (miller-rabin) ] with-scope ]
|
[ drop (miller-rabin) ]
|
||||||
} cond ;
|
} cond ;
|
||||||
|
|
||||||
: miller-rabin ( n -- ? ) 10 miller-rabin* ;
|
: miller-rabin ( n -- ? ) 10 miller-rabin* ;
|
||||||
|
|
Loading…
Reference in New Issue