mdesk: at tree introspection

This commit is contained in:
ed
2025-02-08 12:41:07 -05:00
parent fb60578a42
commit cc5320450c
13 changed files with 152 additions and 171 deletions
+2 -2
View File
@@ -231,10 +231,10 @@ MD_ExprOprPush(arena, &list, MD_ExprOprKind_##k, p, MD_S8Lit(t), Op##e, 0);
}
// print the verbose parse results
for (MD_EachNode(root_it, list->first_child))
for (each_node(root_it, list->first_child))
{
Node *root = MD_ResolveNodeFromReference(root_it);
for (MD_EachNode(node, root->first_child))
for (each_node(node, root->first_child))
{
MD_ExprParseResult parse = MD_ExprParse(arena, &table, node->first_child, MD_NilNode());
+2 -2
View File
@@ -210,13 +210,13 @@ int main(int argc, char **argv)
}
// apply expression parsing to each top level node
for (MD_EachNode(root_it, list->first_child))
for (each_node(root_it, list->first_child))
{
// init eval map
eval_map = MD_MapMake(arena);
Node *root = MD_ResolveNodeFromReference(root_it);
for (MD_EachNode(node, root->first_child))
for (each_node(node, root->first_child))
{
// @notes An expression parse is an extra stage of analysis on top
// of the initial Metadesk parse. It takes in a range of Metadesk