Hi, Cecil abstracts that away for you.
If you want raw access to the pdb data, you might as well simply use the API that we use from Mono.Cecil.Pdb. If not, you'll find sequence point information and document information in Cecil's method bodies. Jb On Wed, May 7, 2014 at 10:10 PM, graham walsh <[email protected]> wrote: > Hi, > > I've successfully read a pdb file and read the pdb symbols. > > var readerParameters = new ReaderParameters { ReadSymbols = true > }; > PdbReaderProvider provider = new PdbReaderProvider(); > ModuleDefinition module = > ModuleDefinition.ReadModule("MyCompany.Visitors.Data.dll"); > > Mono.Cecil.Pdb.PdbReader reader = ( Mono.Cecil.Pdb.PdbReader) > provider.GetSymbolReader(module, module.FullyQualifiedName); > module.ReadSymbols(reader) > > In the visual studio debugger, I can see the Mono.Cecil.Pdb.PdbReader > reader instance and can see all the functions it contains. Now I want to > get my hands on these functions however I'm not sure what interface/routine > to use. The functions (see below) are all private. > > I want to iterate over the functions and documents readonly private > attributes below. Can anybody tell me how to do this? > > public class PdbReader : ISymbolReader, IDisposable > { > private int age; > private readonly Dictionary<string, Document> documents = new > Dictionary<string, Document>(); > private readonly Dictionary<uint, PdbFunction> functions = new > Dictionary<uint, PdbFunction>(); > private Guid guid; > private readonly Stream pdb_file; > > internal PdbReader(Stream file) > { > this.pdb_file = file; > } > > ...... > } > > > thanks > > G > > -- > -- > -- > mono-cecil > --- > You received this message because you are subscribed to the Google Groups > "mono-cecil" group. > To unsubscribe from this group and stop receiving emails from it, send an > email to [email protected]. > For more options, visit https://groups.google.com/d/optout. -- -- -- mono-cecil --- You received this message because you are subscribed to the Google Groups "mono-cecil" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. For more options, visit https://groups.google.com/d/optout.
