bablr-lang / bablr-vm

A VM for enforcing language rules on agAST trees
MIT License
40 stars 2 forks source link

Donut ranges #30

Closed conartist6 closed 1 year ago

conartist6 commented 1 year ago

I consider each node to have a "donut range": the node's outer range (with all possibly-associated trivia), and its inner range which contains no leading or trailing trivia. We will need the grammar to help use identify the donut range, which is essentially just the outer range with the inner range excluded.

To define donut ranges I expect to have to add four new commands:

conartist6 commented 1 year ago

It's not clear to me if this is a good idea, so I'm closing it for now.