.Net - what is an “unwind”?

风格不统一 提交于 2019-12-01 04:18:06

It's me!

No, in this context it typically refers to the process of stepping ("backwards"/"upwards") through a stack, removing successive frames until you've come back to the desired level. Typical stacks are (of course) very linear in their structure, frames are stacked end-to-end after each other, so there's not really much literal unwinding going on, but that's what it's called.

This Wikipedia page has more detail.

Unwinding is just moving back up the stack.

This where the CLR is 'unwinding' the stack in order to locate a method with a catch block that can handle the exception i.e. if the current method doesn't handle the exception it then returns to the method that called it to see if it will. This is repeated until it either finds a method to handle the exception or hits application level error handling.

It means there is a faulty thread or probably that is because the stack is full and no stack frame is created, the CLR as opts to UNWIND the current context in this situation.

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!