https://wiki.xxiivv.com/site/modal
@troethe @neauoire It does use DFS, but not as a lot of people know it.
Because we're representing trees as sequences of nested strings with start and end delimiters, we can perform a depth-first search on the entire tree by just scanning from left-to-right.
You can then just do linear rule matching at every point in the string, and if you fail to match something after trying every point, your program halts.
Not particularly efficient, but this was a prototype.
@troethe @neauoire Adding more context, this was prototyped and toyed with over a few months in 2018 and 2019. I've resurrected the old repository here.
After prototyping, I had my mind set on codifying the implementation into VHDL. I had a sketch of a machine model that would've allowed you to do tree/term rewriting in silicon.
I've similar ambitions with my latest language project. But this was an early prototype.