Hy,

The integration of the MetadataResolver class is welcomed. However, I
want to point out two little issues concerning method resolving :

1. Resolving the constructor of an array (multidimensionnal array) do
not work as expected.

    Examples :
    ==> MethodRef :System.Random[0...,0...]::.ctor(int32, int32)
           Resolved method = null : This is okay since System.Array
doesn't contain a public constructor

    ==> MethodRef : System.Drawing.Point[0...,0...]::.ctor((int32,
int32)
           Resolved method : System.Drawing.Point::.ctor(int32,
int32) !!!!!!!
           This is because System.Drawing.Point has a public
constructor (Int32, Int32)

     Resolving from an array should always return null.

2. The Resolve method doesn't search in parent classes :

    Example :
    class C1
    {
          public virtual void MyMethod()
          {}
    }

    class C2 : C1
    {

    }

     Resolving a MethodReference such as : 'instance void C2::MyMethod
()' will return null.
     However, the CLR would resolve it as 'instance void C1::MyMethod
()'


--~--~---------~--~----~------------~-------~--~----~
--
mono-cecil
-~----------~----~----~----~------~----~------~--~---

Reply via email to