new accessors

db4
Doug Coleman 2008-08-29 17:07:30 -05:00
parent 7652c3ec95
commit e81d69ab34
2 changed files with 3 additions and 3 deletions

View File

@ -48,7 +48,7 @@ IN: heaps.tests
: test-entry-indices ( n -- ? ) : test-entry-indices ( n -- ? )
random-alist random-alist
<min-heap> [ heap-push-all ] keep <min-heap> [ heap-push-all ] keep
data>> dup length swap [ entry-index ] map sequence= ; data>> dup length swap [ index>> ] map sequence= ;
14 [ 14 [
[ t ] swap [ 2^ test-entry-indices ] curry unit-test [ t ] swap [ 2^ test-entry-indices ] curry unit-test

View File

@ -2,7 +2,7 @@
! See http://factorcode.org/license.txt for BSD license. ! See http://factorcode.org/license.txt for BSD license.
USING: threads kernel prettyprint prettyprint.config USING: threads kernel prettyprint prettyprint.config
io io.styles sequences assocs namespaces sorting boxes io io.styles sequences assocs namespaces sorting boxes
heaps.private system math math.parser math.order ; heaps.private system math math.parser math.order accessors ;
IN: tools.threads IN: tools.threads
: thread. ( thread -- ) : thread. ( thread -- )
@ -14,7 +14,7 @@ IN: tools.threads
] with-cell ] with-cell
[ [
thread-sleep-entry [ thread-sleep-entry [
entry-key millis [-] number>string write key>> millis [-] number>string write
" ms" write " ms" write
] when* ] when*
] with-cell ; ] with-cell ;