Share via


ICorDebugManagedCallback2::FunctionRemapOpportunity Method

Notifies the debugger that code execution has reached a sequence point in an older version of an edited function.

HRESULT FunctionRemapOpportunity (
    [in] ICorDebugAppDomain   *pAppDomain,
    [in] ICorDebugThread      *pThread,
    [in] ICorDebugFunction    *pOldFunction,
    [in] ICorDebugFunction    *pNewFunction,
    [in] ULONG32              oldILOffset
);

Parameters

Parameter Description

pAppDomain

[in] A pointer to an ICorDebugAppDomain Interface object that represents the application domain containing the edited function.

pThread

[in] A pointer to an ICorDebugThread Interface object that represents the thread on which the remap breakpoint was encountered.

pOldFunction

[in] A pointer to an ICorDebugFunction Interface object that represents the version of the function currently running on the thread.

pNewFunction

[in] A pointer to an ICorDebugFunction Interface object that represents the latest version of the function.

oldILOffset

[in] The intermediate language (IL) offset of the instruction pointer in the old version of the function.

Remarks

This callback gives the debugger an opportunity to remap the instruction pointer to its proper place in the new version of the specified function by calling ICorDebugILFrame2::RemapFunction Method. If the debugger does not call ICorDebugILFrame2::RemapFunction Method before calling ICorDebugController::Continue Method, the runtime will continue to execute the old code and will fire another FunctionRemapOpportunity callback at the next sequence point.

This callback will be invoked for every frame that is executing an older version of the given function until the debugger returns S_OK.

Requirements

Platforms: Windows 2000, Windows XP, Windows Server 2003 family

Header: CorDebug.idl

Library: CorGuids.lib

.NET Framework Version: 2.0

See Also

Reference

ICorDebugManagedCallback2 Interface
ICorDebugManagedCallback Interface