Fix interactor-busy? handling
parent
c724d69d9f
commit
86d7553b9c
2
TODO.txt
2
TODO.txt
|
@ -27,7 +27,7 @@
|
||||||
- inspector where slot values can be changed
|
- inspector where slot values can be changed
|
||||||
- compiled call traces:
|
- compiled call traces:
|
||||||
- should be independent of whenever the runtime was built with
|
- should be independent of whenever the runtime was built with
|
||||||
-fomit-frame-pointer or not (ppc and amd64)
|
-fomit-frame-pointer on ppc
|
||||||
- we don't know if signal handlers run with the same stack or not
|
- we don't know if signal handlers run with the same stack or not
|
||||||
- use crc32 instead of modification date in reload-modules
|
- use crc32 instead of modification date in reload-modules
|
||||||
- models: don't do redundant work
|
- models: don't do redundant work
|
||||||
|
|
|
@ -32,12 +32,16 @@ M: interactor graft*
|
||||||
: add-interactor-history ( str interactor -- )
|
: add-interactor-history ( str interactor -- )
|
||||||
over empty? [ 2drop ] [ interactor-history push-new ] if ;
|
over empty? [ 2drop ] [ interactor-history push-new ] if ;
|
||||||
|
|
||||||
|
: interactor-continue ( obj interactor -- )
|
||||||
|
t over set-interactor-busy?
|
||||||
|
interactor-continuation schedule-thread-with ;
|
||||||
|
|
||||||
: interactor-finish ( obj interactor -- )
|
: interactor-finish ( obj interactor -- )
|
||||||
[ editor-string ] keep
|
[ editor-string ] keep
|
||||||
[ interactor-input. ] 2keep
|
[ interactor-input. ] 2keep
|
||||||
[ add-interactor-history ] keep
|
[ add-interactor-history ] keep
|
||||||
dup control-model clear-doc
|
dup control-model clear-doc
|
||||||
interactor-continuation continue-with ;
|
interactor-continue ;
|
||||||
|
|
||||||
: interactor-eval ( interactor -- )
|
: interactor-eval ( interactor -- )
|
||||||
[
|
[
|
||||||
|
@ -61,8 +65,7 @@ M: interactor stream-readln
|
||||||
] interactor-yield ;
|
] interactor-yield ;
|
||||||
|
|
||||||
: interactor-call ( quot interactor -- )
|
: interactor-call ( quot interactor -- )
|
||||||
2dup interactor-input.
|
2dup interactor-input. interactor-continue ;
|
||||||
interactor-continuation schedule-thread-with ;
|
|
||||||
|
|
||||||
M: interactor stream-read
|
M: interactor stream-read
|
||||||
swap dup zero?
|
swap dup zero?
|
||||||
|
|
Loading…
Reference in New Issue