RSS 2.0 Feed
RSS 2.0


Atom 1.0 Feed
Atom 1.0

  Reflector. It's not just for breakfast anymore. 


So I have been using Lutz Roeder's .NET Reflector since it's first public release (when .NET was still in beta). It is a great tool. Since it's early releases Lutz added in functionality for decompiling .NET assemblies etc. I never really gave it any thought since I always used Anakrino for that.

Anakrino is a great tool. I've always loved it. However, someone mentioned to me some differences that Reflector has for decompiling - so I decided to take another look. Reflector's decompiling is far better than Anakrino.

The biggest difference is the variable naming. Anakrino names all local variables as local0, local1, etc. Reflector names locals depending on it's type. Much easier to read. Here's a sample (looking at the GetXml method of the DataSet):

Anakrino

public string GetXml() 
    StringWriter local0;
    XmlTextWriter local1;

    local0 = new StringWriter();
    if (local0 != null) {
        local1 = new XmlTextWriter(local0);
        local1.Formatting = 1;
        new XmlDataTreeWriter(this).Save(local1, false);
    }
    return local0.ToString();
}

Reflector

public string GetXml()
{  
    StringWriter writer1;
    XmlTextWriter writer2;

    writer1 = new StringWriter();
    if (writer1 != null)
    {
        writer2 = new XmlTextWriter(writer1);
        writer2.Formatting = 1;
        new XmlDataTreeWriter(this).Save(writer2, 0); 
    }
    return writer1.ToString(); 
}

Isn't that much easier to read? I mean, basically the decompiled code is the same, but having the variables named the way Reflector does makes things much easier to read. Not only that, Reflector is already a tool I use. No more need for Anakrino. Sorry, but gotta clean out the toolbox and Reflector wins for my decompiling tool.




                   

Comments have been closed on this topic.



 

News


Also see my CRM Developer blog

Connect:              


Sponsor

Sections