Fix semaphores, fix docs
parent
d657821f3e
commit
cb1b19fa9b
|
|
@ -8,7 +8,7 @@ TUPLE: semaphore count threads ;
|
|||
|
||||
: <semaphore> ( n -- semaphore )
|
||||
dup 0 < [ "Cannot have semaphore with negative count" throw ] when
|
||||
0 <dlist> semaphore construct-boa ;
|
||||
<dlist> semaphore construct-boa ;
|
||||
|
||||
: wait-to-acquire ( semaphore timeout -- )
|
||||
>r semaphore-threads r> wait ;
|
||||
|
|
|
|||
|
|
@ -84,7 +84,6 @@ USING: concurrency.combinators
|
|||
concurrency.messaging
|
||||
concurrency.promises
|
||||
concurrency.futures
|
||||
concurrency.distributed
|
||||
concurrency.locks
|
||||
concurrency.semaphores
|
||||
concurrency.count-downs
|
||||
|
|
@ -102,12 +101,12 @@ $nl
|
|||
{ $subsection "concurrency.promises" }
|
||||
{ $subsection "concurrency.futures" }
|
||||
{ $subsection "concurrency.messaging" }
|
||||
{ $subsection "concurrency.distributed" }
|
||||
"Shared-state abstractions:"
|
||||
{ $subsection "concurrency.locks" }
|
||||
{ $subsection "concurrency.semaphores" }
|
||||
{ $subsection "concurrency.count-downs" }
|
||||
{ $subsection "concurrency.exchangers" } ;
|
||||
{ $subsection "concurrency.exchangers" }
|
||||
"Other concurrency abstractions include " { $vocab-link "concurrency.distributed" } " and " { $vocab-link "channels" } "." ;
|
||||
|
||||
ARTICLE: "objects" "Objects"
|
||||
"An " { $emphasis "object" } " is any datum which may be identified. All values are objects in Factor. Each object carries type information, and types are checked at runtime; Factor is dynamically typed."
|
||||
|
|
|
|||
Loading…
Reference in New Issue