diff --git a/include/slang/syntax/SyntaxVisitor.h b/include/slang/syntax/SyntaxVisitor.h index 5f3834359..82204dc56 100644 --- a/include/slang/syntax/SyntaxVisitor.h +++ b/include/slang/syntax/SyntaxVisitor.h @@ -115,7 +115,7 @@ class SyntaxRewriter : public SyntaxVisitor { commits.clear(); tempTrees.clear(); - tree->root().visit(*this); + tree->root().visit(*DERIVED); if (commits.empty()) return tree;