© 2026 Hedgehog Software, LLC

TwitterGitHubDiscord
More
CommunitiesDocsAboutTermsPrivacy
Search
Star
Setup for Free
C#C
C#•2y ago•
3 replies
SWEETPONY

✅ how to check attribute name?

I have following:
if (syntaxNode
    is RecordDeclarationSyntax
    and MemberDeclarationSyntax { AttributeLists.Count: > 0 } member)
{
    MemberSyntaxes.Add(member);
}
if (syntaxNode
    is RecordDeclarationSyntax
    and MemberDeclarationSyntax { AttributeLists.Count: > 0 } member)
{
    MemberSyntaxes.Add(member);
}


I want to check if member contains special attribute. How to do it?
C# banner
C#Join
We are a programming server aimed at coders discussing everything related to C# (CSharp) and .NET.
61,871Members
Resources
Recent Announcements

Similar Threads

Was this page helpful?

Similar Threads

Api Method Name Attribute
C#CC# / help
2y ago
✅ How do I set a struct attribute to its parameter name?
C#CC# / help
2y ago
how to check
C#CC# / help
3y ago
❔ It it possible to get name of attribute without reflection?
C#CC# / help
3y ago