3 ms·
No, a record is a tagged (sequence of) value(s). <tag v1 v2 v3> If you put a single dictionary-valued "field" in a record, you get a variation with named fi
by tonyg 2y ago
No, a record is a tagged (sequence of) value(s).
<tag v1 v2 v3>
If you put a single dictionary-valued "field" in a record, you get a variation with named fields
<tag {
field1: value1
field2: value2
field3: value3
}>
Records have positional "fields" because of the Scheme heritage of the design.
--
Re bytestring -- yes there are some concessions to real machines/languages in there that aren't absolutely required. Other examples include booleans and strings, which could have been <true> and <false> and <string [65 66 67]> etc respectively.
There's a little more on this topic in footnote 2 on the "conventions" page: https://preserves.dev/conventions.html#fn:why-dictionaries https://preserves.dev/conventions.html#fn:why-dictionaries
- carterschonwald 2y agoLooks like a lot of excellent work! Are there any good examples of nontrivial schemas etc?
- tonyg 2y agoThanks. Yes there are: see sections 15, 16 and 17 of https://synit.org/book/ https://synit.org/book/, where Preserves, Preserves Schemas, and the Syndicated Actor Model make a reactive replacement system layer for linux (essentially an alternative to systemd)