Reflector Not Decompiling 'System.Data.Entity.

2019-01-20 13:29发布

问题:

When looking at the System.Data.Entity.dll for .NET 4.0, no methods are being decompiled. I only see the method stubs. I tried re-installing reflector but it still didn't work. I am able to decompile other .NET assemblies just fine.

回答1:

I think your issue is that you've pointed Reflector at the metadata-only version of the assembly.

A number of assemblies are installed for use by VS 2010 that contain only the metadata, not the method's IL, of the original assembly. They did this for performance reasons and for multitargeting support.

If you check, you'll probably see that the assemblies you're looking at are under the "Reference Assemblies" directory in ProgramFiles. If you point to the same assemblies under windows\microsoft.net\framework... you'll see Reflector can disassemble this and all other BCL assemblies.



回答2:

Reflector does not decompile every assembly. It will not decompile assemblies which have been obfuscated in certain ways, nor portions of mixed mode assemblies (which contain native code).