Fix C# get_all_delegates
method for generic classes
#55563
Merged
get_all_delegates
method for generic classes
#55563