29
CS269: HW/SW Engineering of Embedded Systems, Winter02
Steps to Write a Visitor
(2)
•
Which traversal method to use?
There are 3 types of traversal:
–
Useful when only a few nodes in the AST need to be
visited.
•
TM_CUSTOM
•
–
explicit calls need to be made to visit a
particular node