Changes to support building as a single library

Topics: Metadata Model, PDB Reader, PDB Writer, PE reader, PE Writer
Sep 24, 2011 at 3:10 PM
Edited Sep 24, 2011 at 3:13 PM

I'm building this (actually this and the AST stuff) as one single library (forked on github https://github.com/coapp/cci ), and there are a few things that I had to fix in order to have all the Metadata projects compile as one:

In ControlAndDataFlowGraph, you have a Stack class  that conflicts with the one in ILGenerator--If you could rename one of those, that would be awesome.

In PdbReader you have a UsedNamespace class that conflicts with the one in  ILGenerator--If you could rename one of those, that too would be awesome.

In PeReader\BinaryObjectModel.cs if you inserted a using SectionHeader = PEFile.SectionHeader; (inside the namespace) it would prevent a conflict the one in PEWriter .

In PEWriter\PEWriter.cs use of System.Collections.Generic.Stack has to be explict (around line 3136) due to conflicts with the other Stack class:

System.Collections.Generic.Stack scopeStack = new System.Collections.Generic.Stack();

In ReflectionEmitter\Emitter.cs if you inserted :

using ILGenerator = System.Reflection.Emit.ILGenerator;
using AssemblyName = System.Reflection.AssemblyName;

inside the namespace declaration it prevents conflicts with others.

In ReflectionEmitter\Mapper.cs if you inserted :

using AssemblyName = System.Reflection.AssemblyName;

inside the namespace declaration it prevents conflicts with others.

Thanks!

 

 

Coordinator
Sep 26, 2011 at 10:07 PM

Change Set 65561 will hopefully take care of your issue.

Sep 26, 2011 at 10:10 PM

AWESOMESAUCE!

Thanks! That's really great! I'll try those out this afternoon.

Sep 27, 2011 at 5:17 PM

I can confirm that this worked very well. THANKS!