Skip to content

Add ... to the end of nodes with children when debug-printing #189

Description

@elenakrittik

Cost me a day to realize that my code wasn't actually bugged, it was just that i :?-printed the node tree instead of :#?-printing it, causing me to see

ROOT_NODE@0..41

instead of the full

ROOT_NODE@0..41
  BLOCK_STMTS_NODE@0..41
    STMT_NODE@0..41
      STMT_KIND_NODE@0..41
        EXPR_NODE@0..41
          IF_EXPR_NODE@0..41
            ...

I suggest changing the debug-print to output

ROOT_NODE@0..41 ...

when ROOT_NODE has children, instead.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions