Stream: ideas

Topic: streams API


view this post on Zulip Jonathan (Dec 09 2025 at 11:16):

Michał Kowieski said:

Does Roc have while loop? I wonder if I can read lines from Stdin until the line is empty without using recursion?

Somewhat related - is a stream API off the books? I'm not sure if this is something that can be implemented in user space (I guess it could be in a platform?), but I often find streaming a simple / friendly way of lazy reading. Eg Elixir's Stream builtin that can be created with an IO.Stream for reading line by line. I don't like to make random language suggestions but I was just curious!

view this post on Zulip Richard Feldman (Dec 09 2025 at 12:26):

we don't have one yet but there's a general plan to have one!

view this post on Zulip Jonathan (Dec 09 2025 at 12:30):

Ah cool! Thank you. In the meantime it's a good excuse for me to try the while loops :smile:


Last updated: Jun 16 2026 at 16:19 UTC