[.NET] Add IgnoreMember attribute to exclude members from Godot

Co-authored-by: kkjinping <ygkn1992@vip.qq.com>
This commit is contained in:
Raul Santos
2026-05-25 15:43:35 +02:00
parent fa6cad230f
commit 0095a79869
14 changed files with 73 additions and 3 deletions
@@ -128,6 +128,8 @@ namespace Godot.SourceGenerators
var methodSymbols = members
.Where(s => s.Kind == SymbolKind.Method && !s.IsImplicitlyDeclared)
.Cast<IMethodSymbol>()
.Where(m => !m.GetAttributes()
.Any(a => a.AttributeClass?.IsGodotIgnoreMemberAttribute() ?? false))
.Where(m => m.MethodKind == MethodKind.Ordinary);
var godotClassMethods = methodSymbols.WhereHasGodotCompatibleSignature(typeCache)