Search code examples
c#partialreflectordisassembly

How to restore information about partial class from DLL?


DLL contains partial class DisPart defined in two places:

public partial class DisPart
{
    public static string s;
}


public partial class DisPart
{
    public static int i;
}

Disassembling the DLL in Reflector results in:

public class DisPart
{
    public static int i;
    public static string s;
}

Is there any possibility to restore information:

1)whether the class was partial?

2)how the class's members definitions were divided ?


Solution

  • The PDB file would probably indicate both of these, as it will contain line number information - at least for the methods (and I'd expect for variables too). I don't expect it would be in the DLL itself. I also don't know how easy it would be to discover even if you had the PDB, to be honest - I don't know what the format of a PDB file is.