internal override SyntaxTreeNode AcceptVisitor(SyntaxTreeVisitor visitor) { if (visitor == null) { throw new ArgumentNullException("visitor"); } return(visitor.Visit(this)); }
public void DefaultVisitorModifiesNothing() { var tree = BBCodeTestUtil.GetAnyTree(); var tree2 = new SyntaxTreeVisitor().Visit(tree); Assert.IsTrue(ReferenceEquals(tree, tree2)); }
internal abstract SyntaxTreeNode AcceptVisitor(SyntaxTreeVisitor visitor);
internal override SyntaxTreeNode AcceptVisitor(SyntaxTreeVisitor visitor) { if (visitor == null) throw new ArgumentNullException("visitor"); return visitor.Visit(this); }
internal override SyntaxTreeNode AcceptVisitor(SyntaxTreeVisitor visitor) { visitor.ThrowIfNull(nameof(visitor)); return(visitor.Visit(this)); }