kc++

A (syntax-)tree-handling tool (term processor)

Install

All systems
curl cmd.cat/kc++.sh
Debian Debian
apt-get install kimwitu++
Ubuntu
apt-get install kimwitu++
Windows (WSL2)
sudo apt-get update sudo apt-get install kimwitu++
OS X
brew install kimwitu++
Raspbian
apt-get install kimwitu++

kimwitu++

A (syntax-)tree-handling tool (term processor)

Kimwitu++ is a system that supports the construction of programs that use trees or terms as their main data structure. It allows you to define, store and operate on trees with typed nodes. Each type of node has a specific number of sons, and expects these sons to have specific types. The most popular example of such trees are syntax trees. The nodes are defined in a Yacc-like fashion. The tree can be unparsed (ie. treewalk) and rewritten (ie. term substitution). Kimwitu++ gives you powerful pattern matching for specifying unparse and rewrite rules. Kimwitu++ is an extension to C++. It introduces Yacc-like node definitions, the unparse and rewrite rules, and extensions for pattern matching within functions. It will translate its input files into pure C++. To build the tree you might use a parser generated with Bison, but you are free to use other tools. There also exists Kimwitu (also packaged for Debian) which interfaces with C instead of C++ which can also be used in C++ projects, but Kimwitu++ has some extensions one might consider useful.