stream-cons

[procedure] stream-cons obj stream

SRFI-40: Primitive constructor of streams. See also stream, stream-pair?.

Examples:

(stream-cons 'a stream-null)                => (stream 'a)
(stream-cons 'a (stream 'b 'c 'd))          => (stream 'a 'b 'c 'd)
(stream-cons "a" (stream 'b 'c))            => (stream "a" 'b 'c)
(stream-cons 'a 3)                          => error
(stream-cons (stream 'a 'b) (stream 'c))    => (stream (stream 'a 'b) 'c)