Hi Timwi, Just like Jonathon said, you can see variable names in Reflector (and Cecil) if you've explicitly loaded the symbol files (pdb). Reflector does its own trick to guess at variable names when there's no pdb avaliable (mainly, if the variable type is SomeFoo it will be foo, if it's ints in loops it will be i,j,k, if it's a variable passed as an argument to a method, the variable will take the name of the argument, etc.) The guessing algorithm is so good it looks like actual code. But by default, in Cecil, no pdb means default variable names...
On May 9, 1:50 pm, Jonathon Rossi <[email protected]> wrote: > I thought the debug assemblies might have had some extra metadata embedded > somewhere, however when I remove the pdb Reflector goes back to using its > own generated variable names from the type names as I expected. > > Can you please check this again. > > > > On Sat, May 9, 2009 at 9:39 PM, Jonathon Rossi <[email protected]> wrote: > > Did you delete the pdb from a debug or release build? > > > You can checkout the source using a subversion client at: > >http://anonsvn.mono-project.com/source/trunk/cecil > > > On Sat, May 9, 2009 at 9:34 PM, Timwi <[email protected]> wrote: > > >> > You have to load the PDB before modifying the assembly and save it to > >> > disc with the assembly after modifying. > > >> Thanks for your reply, but I've tried this and this doesn't appear to > >> be true. .NET Reflector can read the variable names even if I delete > >> the .pdb file for the relevant assembly. Therefore, the information > >> must be in the assembly itself. But even so, suppose I wanted to try > >> your method... > > >> So I tried to find Mono.Cecil.Pdb on the web. Where can I download > >> this? The only place I could find is a SVN repository, so I would have > >> to either install SVN, or download every single .cs file individually. > >> Is there a proper source distribution for this? > > >> Thanks again for your help. > > >> Timwi > > > -- > > Jono > > -- > Jono --~--~---------~--~----~------------~-------~--~----~ -- mono-cecil -~----------~----~----~----~------~----~------~--~---
