Overhead of try/finally in C#?

后端 未结 6 1253
有刺的猬
有刺的猬 2020-12-07 23:47

We\'ve seen plenty of questions about when and why to use try/catch and try/catch/finally. And I know there\

6条回答
  •  执念已碎
    2020-12-08 00:25

    In lower levels finally is just as expensive as an else if the condition not met. It is actually a jump in assembler (IL).

提交回复
热议问题