public override GreenNode VisitXmlDocument(XmlDocumentSyntax.Green node) { bool anyChanges = false; var newDeclaration = ((XmlDeclarationSyntax.Green)Visit(node.Prologue)); if (node.Prologue != newDeclaration) { anyChanges = true; } var newPrecedingMisc = VisitList <GreenNode>(node.PrecedingMisc); if (node.PrecedingMisc != newPrecedingMisc.Node) { anyChanges = true; } var newRoot = ((XmlNodeSyntax.Green)Visit(node.Body)); if (node.Body != newRoot) { anyChanges = true; } var newFollowingMisc = VisitList <GreenNode>(node.FollowingMisc); if (node.FollowingMisc != newFollowingMisc.Node) { anyChanges = true; } var newEof = VisitSyntaxToken(node.Eof); if (node.Eof != newEof) { anyChanges = true; } var newSkippedTokens = ((SkippedTokensTriviaSyntax.Green)VisitSkippedTokensTrivia(node.SkippedTokens)); if (node.SkippedTokens != newSkippedTokens) { anyChanges = true; } if (anyChanges) { return(new XmlDocumentSyntax.Green( newDeclaration, newPrecedingMisc.Node, newRoot, newFollowingMisc.Node, newSkippedTokens, newEof)); } else { return(node); } }
public virtual GreenNode VisitXmlDocument(XmlDocumentSyntax.Green node) { return(VisitXmlNode(node)); }