diff --git a/TODO.txt b/TODO.txt index c01a6b2851..eec896c5b9 100644 --- a/TODO.txt +++ b/TODO.txt @@ -3,11 +3,12 @@ - callback scheduling issue - error popup obscures input area - ui docs -- calling 'see' with an nonexistent method should be an error -- grid-lines are rendered incorrectly +- vocab popup: sort + 0.88: +- calling 'see' with an nonexistent method should be an error +- grid-lines are rendered incorrectly - interactor: show stack effect for word at caret in status bar - lisppaste gui - growable data heap diff --git a/core/handbook/dataflow.facts b/core/handbook/dataflow.facts index 1d88257b4a..70015ec0b1 100644 --- a/core/handbook/dataflow.facts +++ b/core/handbook/dataflow.facts @@ -157,7 +157,7 @@ ARTICLE: "threads" "Multitasking" { $subsection run-queue } { $subsection sleep-queue } { $subsection schedule-thread } -{ $subsection idle-thread } ; +{ $subsection schedule-thread-with } ; ARTICLE: "continuations-internals" "Continuation implementation details" "A continuation is simply a tuple holding the contents of the five stacks:" diff --git a/core/listener.factor b/core/listener.factor index 235d78ec80..8b4402a5ff 100644 --- a/core/listener.factor +++ b/core/listener.factor @@ -10,11 +10,6 @@ SYMBOL: listener-hook GENERIC: parse-interactive ( stream -- quot/f ) -TUPLE: interactive-stream ; - -C: interactive-stream ( stream -- stream ) - [ set-delegate ] keep ; - : (parse-interactive) ( stream stack -- quot/f ) over stream-readln dup [ over push \ (parse) with-datastack @@ -27,7 +22,7 @@ C: interactive-stream ( stream -- stream ) 3drop f ] if ; -M: interactive-stream parse-interactive +M: line-reader parse-interactive [ [ V{ f } clone (parse-interactive) ] with-parser in get ] with-scope in set ; @@ -43,19 +38,16 @@ M: duplex-stream parse-interactive : listen ( -- ) [ stdio get parse-interactive [ call ] [ bye ] if* ] try ; -: (listener) ( -- ) +: listener ( -- ) quit-flag get [ quit-flag off ] - [ prompt. listener-hook get call listen (listener) ] if ; + [ prompt. listener-hook get call listen listener ] if ; : print-banner ( -- ) "Factor " write version write " on " write os write "/" write cpu print ; -: listener ( -- ) - print-banner use [ clone ] change (listener) ; - IN: shells : tty ( -- ) - stdio get [ listener ] with-stream* ; + print-banner use [ clone ] change listener ; diff --git a/core/threads.factor b/core/threads.factor index 507b22ec83..eb87387b62 100644 --- a/core/threads.factor +++ b/core/threads.factor @@ -46,6 +46,8 @@ namespaces queues sequences vectors ; stop ] callcc0 drop ; +IN: kernel-internals + : (idle-thread) ( fast? -- ) #! If fast, then we don't sleep, just select() sleep-queue* dup sleep-time dup zero? diff --git a/core/threads.facts b/core/threads.facts index 30d47b100a..7ad51cff03 100644 --- a/core/threads.facts +++ b/core/threads.facts @@ -1,4 +1,4 @@ -USING: help threads kernel io ; +USING: help threads kernel kernel-internals io ; HELP: run-queue { $values { "queue" "a queue" } } diff --git a/core/ui/gadgets/buttons.facts b/core/ui/gadgets/buttons.facts index 1fc803ca83..b957bf6932 100644 --- a/core/ui/gadgets/buttons.facts +++ b/core/ui/gadgets/buttons.facts @@ -35,7 +35,7 @@ HELP: HELP: { $values { "label" object } { "quot" "a quotation with stack effect " { $snippet "( button -- )" } } } { $description "Creates a new " { $link button } " with a shaded border which is always visible. The label is converted into a gadget by calling " { $link >label } ". The button appearance changes in response to mouse gestures using a " { $link button-paint } "." } -{ $see-also