Closed lorisleiva closed 1 month ago
Latest commit: fe76592d15d4d062b64e7c96c4edb427c8502a52
The changes in this PR will be included in the next version bump.
Not sure what this means? Click here to learn what changesets are.
Click here if you're a maintainer who wants to add another changeset to this PR
This PR adds a new visitor primitive called
interceptFirstVisitVisitor
.It works the same way as the
interceptVisitor
primitive but only intercepts the first visit of a node. This means that the provided function is called when visiting the specific node provided but not when visiting its children. The parameters are the same as for theinterceptVisitor
.For instance, the following visitor intercepts a
voidVisitor
and captures events only during the first visit.