tree-climber
tree-climber copied to clipboard
expressions inside statements
Add expressions inside statements to the CFG, such as if ((i = 0) == 0)
.
Some CFGs collapse all operations within a statement, line, or basic block into one node. In order to make our representation flexible for different uses, I want to represent each operation as its own node (fine-grained CFG) and optionally post-process nodes in the fine-grained CFG into basic blocks.
Currently these are not present in the CFG.
To do it, add a visitor method to CFGCreator https://github.com/bstee615/tree-sitter-cfg/blob/master/tree_sitter_cfg/cfg_creator.py#L9.