public void SetWriteableMetadataUpdateMode(WriteableMetadataUpdateMode mode) { if (obj is ICorDebugProcess7 p7) { int hr = p7.SetWriteableMetadataUpdateMode(mode); // 0x80131c4e: CORDBG_E_UNSUPPORTED // Not supported in V2 debuggers (when shim is used). Supported in V3, which we're // not using. } }
/// <summary> /// Configures how the debugger handles in-memory updates to metadata /// within the target process. /// /// [Supported in the .NET Framework 4.5.2 and later versions] /// </summary> /// <param name="flags"> /// A WriteableMetadataUpdateMode enumeration value that specifies whether /// in-memory updates to metadata in the target process are visible /// (<c>WriteableMetadataUpdateMode::AlwaysShowUpdates</c>) or not visible /// (<c>WriteableMetadataUpdateMode::LegacyCompatPolicy</c>) to the debugger. /// </param> /// <remarks> /// Updates to the metadata of the target process can come from Edit and Continue, /// a profiler, or <c>System.Reflection.Emit</c>. /// </remarks> public int SetWriteableMetadataUpdateMode(WriteableMetadataUpdateMode flags) { return(Calli(_this, This[0]->SetWriteableMetadataUpdateMode, (int)flags)); }