Browse Source

Remove the now-unused IMemberReference interface

IdStringMemberReference was its only implementation and left with the
ID string grammar parser; unlike the NRefactory-era type system, IMember
does not extend IMemberReference here, so nothing in the library
produces or consumes it anymore.

Assisted-by: Claude:claude-fable-5:Claude Code
pull/3941/head
Siegfried Pammer 2 months ago committed by Siegfried Pammer
parent
commit
e22851bd66
  1. 22
      ICSharpCode.Decompiler/TypeSystem/IMember.cs
  2. 2
      ICSharpCode.Decompiler/TypeSystem/TypeSystemExtensions.cs

22
ICSharpCode.Decompiler/TypeSystem/IMember.cs

@ -22,28 +22,6 @@ using System.Collections.Generic; @@ -22,28 +22,6 @@ using System.Collections.Generic;
namespace ICSharpCode.Decompiler.TypeSystem
{
public interface IMemberReference
{
/// <summary>
/// Gets the declaring type reference for the member.
/// </summary>
ITypeReference DeclaringTypeReference { get; }
/// <summary>
/// Resolves the member.
/// </summary>
/// <param name="context">
/// Context to use for resolving this member reference.
/// Which kind of context is required depends on the which kind of member reference this is;
/// please consult the documentation of the method that was used to create this member reference,
/// or that of the class implementing this method.
/// </param>
/// <returns>
/// Returns the resolved member, or <c>null</c> if the member could not be found.
/// </returns>
IMember? Resolve(ITypeResolveContext context);
}
/// <summary>
/// Method/field/property/event.
/// </summary>

2
ICSharpCode.Decompiler/TypeSystem/TypeSystemExtensions.cs

@ -485,8 +485,6 @@ namespace ICSharpCode.Decompiler.TypeSystem @@ -485,8 +485,6 @@ namespace ICSharpCode.Decompiler.TypeSystem
return new ProjectedList<ITypeResolveContext, ITypeReference, IType>(context, typeReferences, (c, t) => t.Resolve(c));
}
// There is intentionally no Resolve() overload for IList<IMemberReference>: the resulting IList<Member> would
// contains nulls when there are resolve errors.
#endregion
#region IAssembly.GetTypeDefinition()

Loading…
Cancel
Save