forked from OSchip/llvm-project
[flang] Walk source member of Call and Designator
A `source` data member was added to `Call` and `Designator` so the parse tree visitor needs to visit them. Original-commit: flang-compiler/f18@0a620f1a5e Reviewed-on: https://github.com/flang-compiler/f18/pull/433 Tree-same-pre-rewrite: false
This commit is contained in:
parent
e51108c138
commit
876bf77a3c
|
@ -494,6 +494,34 @@ template<typename M> void Walk(Expr &x, M &mutator) {
|
|||
mutator.Post(x);
|
||||
}
|
||||
}
|
||||
template<typename V> void Walk(const Designator &x, V &visitor) {
|
||||
if (visitor.Pre(x)) {
|
||||
Walk(x.source, visitor);
|
||||
Walk(x.u, visitor);
|
||||
visitor.Post(x);
|
||||
}
|
||||
}
|
||||
template<typename M> void Walk(Designator &x, M &mutator) {
|
||||
if (mutator.Pre(x)) {
|
||||
Walk(x.source, mutator);
|
||||
Walk(x.u, mutator);
|
||||
mutator.Post(x);
|
||||
}
|
||||
}
|
||||
template<typename V> void Walk(const Call &x, V &visitor) {
|
||||
if (visitor.Pre(x)) {
|
||||
Walk(x.source, visitor);
|
||||
Walk(x.t, visitor);
|
||||
visitor.Post(x);
|
||||
}
|
||||
}
|
||||
template<typename M> void Walk(Call &x, M &mutator) {
|
||||
if (mutator.Pre(x)) {
|
||||
Walk(x.source, mutator);
|
||||
Walk(x.t, mutator);
|
||||
mutator.Post(x);
|
||||
}
|
||||
}
|
||||
template<typename V> void Walk(const PartRef &x, V &visitor) {
|
||||
if (visitor.Pre(x)) {
|
||||
Walk(x.name, visitor);
|
||||
|
|
Loading…
Reference in New Issue