Пример #1
0
 PdbWriter(PdbState pdbState, MetaData metaData)
 {
     this.pdbState      = pdbState;
     this.metaData      = metaData;
     this.module        = metaData.Module;
     this.instrToOffset = new Dictionary <Instruction, uint>();
     this.customDebugInfoWriterContext = new PdbCustomDebugInfoWriterContext();
     this.localsEndScopeIncValue       = pdbState.GetCompiler(metaData.module) == Compiler.VisualBasic ? 1 : 0;
 }
Пример #2
0
		/// <summary>
		/// Constructor
		/// </summary>
		/// <param name="writer">Symbol writer</param>
		/// <param name="pdbState">PDB state</param>
		/// <param name="metaData">Meta data</param>
		public PdbWriter(ISymbolWriter2 writer, PdbState pdbState, MetaData metaData) {
			if (writer == null)
				throw new ArgumentNullException("writer");
			if (pdbState == null)
				throw new ArgumentNullException("pdbState");
			if (metaData == null)
				throw new ArgumentNullException("metaData");
			this.writer = writer;
			this.pdbState = pdbState;
			this.metaData = metaData;
			this.module = metaData.Module;
			writer.Initialize(metaData);
		}
Пример #3
0
 /// <summary>
 /// Constructor
 /// </summary>
 /// <param name="writer">Symbol writer</param>
 /// <param name="pdbState">PDB state</param>
 /// <param name="metaData">Meta data</param>
 public PdbWriter(ISymbolWriter3 writer, PdbState pdbState, MetaData metaData)
     : this(pdbState, metaData)
 {
     if (writer == null)
     {
         throw new ArgumentNullException("writer");
     }
     if (pdbState == null)
     {
         throw new ArgumentNullException("pdbState");
     }
     if (metaData == null)
     {
         throw new ArgumentNullException("metaData");
     }
     this.writer  = writer;
     this.writer3 = writer;
     writer.Initialize(metaData);
 }
Пример #4
0
 /// <summary>
 /// Constructor
 /// </summary>
 /// <param name="writer">Symbol writer</param>
 /// <param name="pdbState">PDB state</param>
 /// <param name="metaData">Meta data</param>
 public PdbWriter(ISymbolWriter2 writer, PdbState pdbState, MetaData metaData)
 {
     if (writer == null)
     {
         throw new ArgumentNullException("writer");
     }
     if (pdbState == null)
     {
         throw new ArgumentNullException("pdbState");
     }
     if (metaData == null)
     {
         throw new ArgumentNullException("metaData");
     }
     this.writer   = writer;
     this.pdbState = pdbState;
     this.metaData = metaData;
     this.module   = metaData.Module;
     writer.Initialize(metaData);
 }
Пример #5
0
 /// <summary>
 /// Constructor
 /// </summary>
 /// <param name="writer">Symbol writer, it should implement <see cref="ISymbolWriter3"/></param>
 /// <param name="pdbState">PDB state</param>
 /// <param name="metaData">Meta data</param>
 public PdbWriter(ISymbolWriter2 writer, PdbState pdbState, MetaData metaData)
     : this(pdbState, metaData)
 {
     if (writer == null)
     {
         throw new ArgumentNullException("writer");
     }
     if (pdbState == null)
     {
         throw new ArgumentNullException("pdbState");
     }
     if (metaData == null)
     {
         throw new ArgumentNullException("metaData");
     }
     this.writer  = writer;
     this.writer3 = writer as ISymbolWriter3;
     Debug.Assert(writer3 != null, "Symbol writer doesn't implement interface ISymbolWriter3");
     writer.Initialize(metaData);
 }