Exemplo n.º 1
0
 internal void WritePInvokeImpl(PInvokeImplementation implementation)
 {
     if (implementation.UpdateRowOnRebuild)
     {
         object[] parts = new object[]
         {
             (ushort)implementation.Attributes,
             GetCodedIndex(tablesHeap.MemberForwarded, implementation.Member),
             GetHeapOffset(newStringsHeap, newStringsHeap.GetStringOffset(implementation.Entrypoint)),
             GetMemberIndex(implementation.ImportScope),
         };
         implementation.MetaDataRow = new MetaDataRow(parts);
     }
     writer.Write(implementation.MetaDataRow.GenerateBytes());
 }
Exemplo n.º 2
0
 private void UpdatePInvokeImpl(Workspace workspace, PInvokeImplementation pinvokeImpl)
 {
     pinvokeImpl.MetaDataRow.Parts[1] = GetMemberIndex(workspace, Constructor.OriginalAssembly.NETHeader.TablesHeap.MemberForwarded, pinvokeImpl.Member);
     pinvokeImpl.MetaDataRow.Parts[2] = GetStringIndex(workspace, pinvokeImpl.Entrypoint);
     pinvokeImpl.MetaDataRow.Parts[3] = GetMemberIndex(workspace, pinvokeImpl.ImportScope);
 }