ICorDebugManagedCallback2::FunctionRemapOpportunity 方法
通知调试器代码执行已达到旧版已编辑函数中的序列点。
语法
HRESULT FunctionRemapOpportunity (
[in] ICorDebugAppDomain *pAppDomain,
[in] ICorDebugThread *pThread,
[in] ICorDebugFunction *pOldFunction,
[in] ICorDebugFunction *pNewFunction,
[in] ULONG32 oldILOffset
);
参数
pAppDomain
[in]指向 ICorDebugAppDomain 对象的指针,该对象表示包含已编辑函数的应用程序域。
pThread
[in]指向 ICorDebugThread 对象的指针,该对象表示遇到重新映射断点的线程。
pOldFunction
[in]指向 ICorDebugFunction 对象的指针,该对象表示当前在线程上运行的函数的版本。
pNewFunction
[in]指向表示函数最新版本的 ICorDebugFunction 对象的指针。
oldILOffset
[in]旧版函数中指令指针的公共中间语言 (CIL) 偏移量。
注解
此回叫使调试器有机会通过调用 ICorDebugILFrame2::RemapFunction 方法将指令指针重新映射到新版本指定函数的正确位置。 如果调试器在调用 ICorDebugController::Continue 方法之前未调用 RemapFunction
,则运行时将继续执行旧代码,并将在下一个序列点触发另一个 FunctionRemapOpportunity
回叫。
对于正在执行旧版本给定函数的每一帧,将调用此回叫,直到调试器返回 S_OK。
要求
平台:请参阅系统要求。
标头:CorDebug.idl、CorDebug.h
库:CorGuids.lib
.NET Framework 版本:自 2.0 起可用