Beispiel #1
0
        public override SyntaxNode VisitEndRegionDirectiveTrivia(EndRegionDirectiveTriviaSyntax node)
        {
            var region = _stack.Pop();

            if (region.IsDeclaration)
            {
                return(null);
            }
            region = _stack.Peek();
            if (region.Annotation != null)
            {
                return(node.WithAdditionalAnnotations(region.Annotation));
            }
            return(node);
        }