Was looking forward to this. I was trying to figure out the Scott encoding for data since the original untyped calculus post, so it's nice to see it treated here.
I think there is a viable Scott encoding in the UCC with a single stack by utilising order of values on the stack. C'_i would then be a series of i - 1 `drop`s followed by N - i `nip`s and an `apply` (where `nip` is `swap drop`).
`quote_n` was already defined in the previous post (the one on UCC) which is enough to define Scott encoding on a single stack using an analogous method as the UMCC post.
I came to this post looking for a typing system for a concatenative language and I'm really looking forward to Scott explaining it.
I believe we're a long way from the global optimum programming language and associated tools. I've been brainstorming ideas for improving programming languages for years. Dawn is my attempt to distill all of that into a new language.
I thought I addressed that quite clearly in the post, did I not? Multistacks relieve much of the pain of stack shuffling while retaining the benefits of concatenative notation, e.g. refactorability. There are also other emergent benefits such as global variables without the drawbacks.
Good question! I've managed to pick it all up through various Wikipedia pages and journal articles on programming language theory and type theory. There's probably some good books and/or review articles that could take you through all of the foundations, but I don't know what they are.
All you really need to understand, though, is the syntax for describing syntax, small step semantics, and big step semantics, and what those mean. If you go back to the previous post on the UCC, I try to explain each of those in the context of that calculus. If you have any specific questions about things you find confusing or opaque, I'd be happy to answer them.
It might also help to read the source code for UCC and UMCC, if you're more familiar with code. But code tends to be much lower level, where it can be difficult to see the forest through the trees.