back to parserlang

parserlang "history"

things you probably already know:

anyway, on to the things you may not know

things you may not know: pv

because i made it to write parsers, one of the features i have planned is simple backtracking

like when you're (i was) writing a recursive descent parser with parser combinators, the concat combinator is hard to write in a non recursive way (you have to write your own stack)

so that's one feature i planned

then to have backtracking in a "sane" way, the values have to be immutable

at some point i thought "oh jq does basically the same thing right?" and copied the entire jv (jq value) implementation and called it pv

(and quickly found out how much the different jv kinds (types) reference internal details)

so i just copied (most of) the header files and some of the implementation for the more complex kinds

but now i'm mostly done with rewriting jv in a way that i like

so it has immutable values like jv and 9 kinds: null, bool, int, double, string, array, object, iterator, function (i split number into int and double, and added iterator and function)

it also has some functions with single or double dispatch - equal, hash, to_string

pl

now on top of pv i made pl, which is a based stack vm (like lua)

it's not too unusual (i think) - there are a couple of opcode sections:

i currently have functional iteration and function calls - both as normal function and as generator

right now, though, i'm Rewriting (🦀 🦀🦀) It In Rust 🚀🚀 (🚀 (🦀)) TM R C frfr (🦀🚀🚀🚀🚀)
it's on github