1
0
mirror of https://github.com/godotengine/godot.git synced 2025-11-05 12:10:55 +00:00

C#: Add source generator for method list

This commit is contained in:
Ignacio Roldán Etcheverry
2022-07-28 17:41:48 +02:00
parent 97713ff77a
commit a9892f2571
10 changed files with 514 additions and 294 deletions

View File

@@ -0,0 +1,31 @@
using System.Diagnostics.CodeAnalysis;
namespace Godot.SourceGenerators.Sample;
[SuppressMessage("ReSharper", "RedundantNameQualifier")]
public partial class Methods : Godot.Object
{
private void MethodWithOverload()
{
}
private void MethodWithOverload(int a)
{
}
private void MethodWithOverload(int a, int b)
{
}
// Should be ignored. The previous one is picked.
// ReSharper disable once UnusedMember.Local
private void MethodWithOverload(float a, float b)
{
}
// Generic methods should be ignored.
// ReSharper disable once UnusedMember.Local
private void GenericMethod<T>(T t)
{
}
}