Esempio n. 1
0
            public override SyntaxNode VisitDelegateDeclaration(DelegateDeclarationSyntax node)
            {
                node = (DelegateDeclarationSyntax)base.VisitDelegateDeclaration(node);

                if (CrossArchSyntaxMap.IsPotentialCrossArch(node))
                {
                    var originalName = node.Identifier.ValueText;
                    var name         = originalName;
                    HandleArchSpecific(node, out var removeNode, out var attributeList, ref name);
                    if (removeNode)
                    {
                        return(null);
                    }

                    if (name != originalName)
                    {
                        node =
                            node.WithIdentifier(SyntaxFactory.ParseToken(name));
                    }

                    if (attributeList != null)
                    {
                        node = node.AddAttributeLists(attributeList);
                    }
                }

                return(node);
            }