On Mon, Feb 12, 2024 at 10:05:14AM -0800, Pedro Silvestre wrote:
> Hi Sven,
>
> Thank you for the help. I followed something similar to your advice.
> I'll report my attempt for future users searching for a similar solution.
> I'd also appreciate any input as to whether this is valid, or if I'm
> creating an invalid AST.
>
>
> 1. After obtaining a ScheduleTree, use map_schedule_node_bottom_up to
> modify it.
> 1. The callback should check for Set Nodes and use insert_mark to
> insert a mark above the Set nodes
I think it's safer to put the marks on the children (of the filter nodes),
as I suggested.
The AST generator could in theory exploit the set node and
overlap the children in any way it sees fit,
even though I don't think it currently does anything like that.
For example, it could (again, in theory) turn a set with sequence children
into a sequence with set children.
skimo