Conversation

putting words to my vague thoughts: we have lots of different types of strings but they're very ad hoc, e.g. "utf8 string", "ascii string", "bytestring", "valid identifier", "valid json string". these are all one-offs. is there a "string type family" that unifies all of these?
2
3
(usefully, i mean ... we could have a string type family indexed by a boolean predicates over bytestrings, but that seems not very helpful)
1
but also, viewing types semantically (and practically) as representations of prefix-free languages on bytestrings
1
1
Currently my main interest in this stuff is binary data descriptions. Currently maessing around with a DSL that's kind of inspired by the Power of Pi and Pads/DDC but not sure about the approach.
1
1
I am not sure tbh! 😳 I was thinking I would try to avoid exposing an eliminator of the format descriptions to users. Like, I have introductions for the format descriptions, and a primitive that gets the representation of the data descriptions, for data-dependent formats.
1
Thing I've been wondering about is stuff like escape hatches, and different ways of parsing - like sometimes you want to be able to stream stuff, sometimes you want to use the format like a random access database with caching… sometimes a combination
1
And yeah I'm worried about those operational concerns leaking into the more declarative descriptions that I was hoping for, and it's all tricky gah
2
IR is good at managing superficial data descriptions with a forgetful map to semantic data representations, in the presence of data dependency. Because if that ain’t respecting the semantics, you have bigger troubles.
1
1
Ohhhh so yeah I'm pretty sure my representation operation is defined inductive-recursively with the data descriptions. Pretty close to what is described in the Power of Pi, and looking at the Gentle art of Levitation at the end of last year I think there are similarities?
1
Show replies