Пример #1
0
        /// <summary>
        /// Moves node to a new line, indents it and visit it using provided rewriter.
        /// </summary>
        protected SyntaxNode RewriteGenericNode(GenericNameSyntax node, BqlRewriterBase rewriter)
        {
            GenericNameSyntax newNode = OnNewLineAndIndented(node);

            if (newNode?.TypeArgumentList == null)
            {
                return(node);
            }

            TypeArgumentListSyntax newTypeArgsListNode = rewriter.Visit(newNode.TypeArgumentList) as TypeArgumentListSyntax;

            if (newTypeArgsListNode == null)
            {
                return(newNode);
            }

            return(newNode.WithTypeArgumentList(newTypeArgsListNode));
        }
Пример #2
0
        /// <summary>
        /// Moves node to a new line, indents it and visit it using provided rewriter.
        /// </summary>
        protected SyntaxNode RewriteGenericNode(GenericNameSyntax node, BqlRewriterBase rewriter)
        {
            var newNode = OnNewLineAndIndented(node);

            return(newNode.WithTypeArgumentList((TypeArgumentListSyntax)rewriter.Visit(newNode.TypeArgumentList)));
        }