Handbook
Glossary
each-line ( ... quot: ( ... line -- ... ) -- ... )
Factor handbook
»
Input and output
»
Streams
»
Stream utilities
Prev:
read-lines ( -- seq )
Next:
stream-contents ( stream -- seq )
Vocabulary
io
Inputs
quot
a
quotation
with stack effect
( ... line -- ... )
Outputs
None
Word description
Calls the quotation with successive lines of text, until the current
input-stream
is exhausted.
Definition
USING:
kernel
namespaces
;
IN:
io
:
each-line
( ... quot: ( ... line -- ... ) -- ... )
input-stream
get
swap
each-stream-line
;
inline