Pondering the possibility of using Prolog for bootstrapping a type theory + programming language implementation…
…though I'll probably reconsider once I start hitting all the type and mode errors. 😅
Conversation
One motivation is implementing my language in a way that is closer to the inference rules I might use for a specification.
The other is that it seems easier to implement a toy Prolog implementation (if you avoid some fancy features) than a toy version of GHC, OCaml, or Rust.
2
3
This sounds a lot like the approach taken by Shen: shenlanguage.org
I've never looked at it in detail, but always thought the idea of embedding prolog to write a fancy type system sounded interesting.
1
Replying to
Hmm, not sure, I think it's kind of the other way around? Ie. using prolog directly to implement a type system.
But I definitely think it's cool how you can port and implementation of Shen by implementing a bunch of primops. I think that's cool design there!
Replying to
i might have misunderstood what your plan is but either way i am here to blindly endorse all uses of prolog, because it is COOL
1

