Added thread-terminate!

This commit is contained in:
Justin Ethier 2016-02-18 23:03:01 -05:00
parent 41ff5a149b
commit b9978248b8
2 changed files with 4 additions and 3 deletions

1
TODO
View file

@ -1,7 +1,6 @@
Initiatives:
- srfi 18 - missing thread functions, more complex threading examples
- test on a 64-bit platform/vm
- api documentation
- syntax-rules integration (WIP, works sometimes but needs to compile smaller)
- r7rs missing features

View file

@ -18,7 +18,7 @@
thread-start!
thread-sleep!
thread-yield!
;; TODO: thread-terminate!
thread-terminate!
;; TODO: thread-join!
mutex?
@ -84,7 +84,9 @@
(mutator-id (Cyc-spawn-thread! thunk)))
(vector-set! t 2 mutator-id)))
(define (thread-yield!) (thread-sleep! 1))
; (define (thread-terminate!) (Cyc-end-thread!))
(define-c thread-terminate!
"(void *data, int argc, closure _, object k)"
" Cyc_end_thread(data); ")
;; TODO: thread-join!
(define-c thread-sleep!