Beispiel #1
0
        private static CommonSyntaxNode TransformRootVisualBasic(Roslyn.Compilers.VisualBasic.SyntaxNode originalRoot)
        {
            var comments = originalRoot.DescendantTrivia().Where(t => t.Kind == Roslyn.Compilers.VisualBasic.SyntaxKind.CommentTrivia);
            var newRoot = originalRoot.ReplaceTrivia(comments, (t1, t2) => Roslyn.Compilers.VisualBasic.SyntaxTriviaList.Empty);

            return newRoot;
        }