IN: concurrency.locks.tests\r
USING: tools.test concurrency.locks concurrency.count-downs\r
concurrency.messaging concurrency.mailboxes locals kernel\r
-threads sequences calendar ;\r
+threads sequences calendar accessors ;\r
\r
:: lock-test-0 ( -- )\r
[let | v [ V{ } clone ]\r
] ;\r
\r
[ lock-timeout-test ] [\r
- linked-error-thread thread-name "Lock timeout-er" =\r
+ linked-error-thread name>> "Lock timeout-er" =\r
] must-fail-with\r
\r
:: read/write-test ( -- )\r
GENERIC: send ( message thread -- )\r
\r
: mailbox-of ( thread -- mailbox )\r
- dup thread-mailbox [ ] [\r
- <mailbox> dup rot set-thread-mailbox\r
+ dup mailbox>> [ ] [\r
+ <mailbox> swap >>mailbox\r
] ?if ;\r
\r
M: thread send ( message thread -- )\r