Stream: beginners

Topic: ✔ Patterns for builders


view this post on Zulip Lukas Hermann (Aug 14 2026 at 18:16):

Hi all, since roc doesn’t have an Optional type, I was curious what the general pattern is for a data structure that has a a lot of optional fields. Thank you!

view this post on Zulip Lukas Hermann (Aug 14 2026 at 18:24):

I’m specifically interested in the serialization of these optionals, and mirroring the skip-if-none behavior of Serde

view this post on Zulip Richard Feldman (Aug 14 2026 at 19:03):

@Lukas Hermann it just landed recently and there's no documentation for it yet, but you can do optional record fields - there have been some discussions about it on Zulip, which is unfortunately the only documentation of it right now :sweat_smile:

view this post on Zulip Lukas Hermann (Aug 14 2026 at 19:36):

Thank you!

view this post on Zulip Notification Bot (Aug 14 2026 at 20:27):

Lukas Hermann has marked this topic as resolved.


Last updated: Sep 03 2026 at 15:16 UTC