WriteSymbolFile() 공개 메소드

public WriteSymbolFile ( System.Guid guid ) : void
guid System.Guid
리턴 void
예제 #1
0
        internal static void Convert(AssemblyDefinition assembly, IEnumerable<PdbFunction> functions, MonoSymbolWriter mdb)
        {
            var converter = new Converter (mdb);

            foreach (var function in functions)
                converter.ConvertFunction (function);

            mdb.WriteSymbolFile (assembly.MainModule.Mvid);
        }
예제 #2
0
        public void Close()
        {
            var metadata = (MetadataBuilder)typeof(MetadataWriter).GetRuntimeFields().First((f) => f.Name == "metadata").GetValue(writer);

            Guid moduleVersionId = Guid.Empty;
            var  guidIndex       = (Dictionary <Guid, GuidHandle>) typeof(MetadataBuilder).GetRuntimeFields().First((f) => f.Name == "_guids").GetValue(metadata);

            foreach (var pair in guidIndex)
            {
                if (pair.Value.GetHashCode() == 1)                   // This is hack because GetHashCode() returns this._index
                {
                    moduleVersionId = pair.Key;
                    break;
                }
            }
            msw.WriteSymbolFile(moduleVersionId);
        }
예제 #3
0
        public void Close()
        {
            var heapBuilder = (MetadataHeapsBuilder)typeof(MetadataWriter).GetRuntimeFields().First((f) => f.Name == "heaps").GetValue(writer);

            Guid moduleVersionId = Guid.Empty;
            var  guidIndex       = (Dictionary <Guid, int>) typeof(MetadataHeapsBuilder).GetRuntimeFields().First((f) => f.Name == "_guids").GetValue(heapBuilder);

            foreach (var pair in guidIndex)
            {
                if (pair.Value == 1)
                {
                    moduleVersionId = pair.Key;
                    break;
                }
            }
            msw.WriteSymbolFile(moduleVersionId);
        }
예제 #4
0
		public void Close()
		{
			MonoSymbolWriter writer = new MonoSymbolWriter(moduleBuilder.FullyQualifiedName);

			foreach (Method method in methods.Values)
			{
				if (method.document != null)
				{
					if (method.document.source == null)
					{
						method.document.source = new SourceFileEntry(writer.SymbolFile, method.document.url);
					}
					ICompileUnit file = new CompileUnitEntry(writer.SymbolFile, method.document.source);
					SourceMethodBuilder smb = writer.OpenMethod(file, 0, method);
					for (int i = 0; i < method.offsets.Length; i++)
					{
						smb.MarkSequencePoint(method.offsets[i], method.document.source, method.lines[i], method.columns[i], false);
					}
					for (int i = 0; i < method.variables.Count; i++)
					{
						writer.DefineLocalVariable(i, method.variables[i]);
					}
					writer.CloseMethod();
				}
			}

			writer.WriteSymbolFile(moduleBuilder.ModuleVersionId);
		}
예제 #5
0
 public void Close()
 {
     msw.WriteSymbolFile(guid);
 }
예제 #6
0
 public void Close()
 {
     msw.WriteSymbolFile(mb.ModuleVersionId);
 }