influencing the behavior of live reptiles

submited by
Style Pass
2021-05-19 06:25:29

Here is an example for a silly little stack language with singleton sets (0 and 1), set union (|), set product (*) and dup (^, makes an extra copy of the top value on the stack).

This post gives an overview of some of the implementation challenges, a rough map of the possible solutions and then dives into a specific solution that I've been experimenting with lately that makes use of some interesting features in zig.

It's easy enough to implement a live repl using any old interpreter, but the interpreter in this demo has some properties that are a bit trickier:

The first property is easy to achieve - concurrency is a well understood problem. It's the interaction with the other two properties that make things interesting. We can reduce it to these two questions:

There are many possible approaches to this. I find it helpful in situations like this to try to find some sort of structure to the space of choices:

Leave a Comment