Stream: API design

Topic: Best type for encoding into / decoding from


view this post on Zulip Jasper Woudenberg (Jul 16 2026 at 18:02):

I'm working on porting Rvn to the new compiler, and learning about the new encoding/decoding API. The new API leaves you free to pick what type you're encoding into / decoding from. That's awesome, I see many exciting uses for that.

Is there a consensus about the "best" option for a regular data format encoder (JSON/TOML/YAML/CSV)? I see Json in the standard library offers Str and List(U8) both. Does it make sense to offer Iter(List(U8)) to avoid doing lots of appends? I'm curious what thought folks might already have put to this.


Last updated: Jul 23 2026 at 13:15 UTC