Lazy: “The function evaluation requires all threads to run”

前端 未结 5 2009
星月不相逢
星月不相逢 2020-12-05 10:46

I have a static class with some static properties. I initialized all of them in a static constructor, but then realized that it is wasteful and I should lazy-load each prope

5条回答
  •  暖寄归人
    2020-12-05 11:20

    Create a local variable and assign it the value you want to inspect.

    This will let you inspect it because the debugger doesn't have to worry about whether or not accessing the property will disturb your application, because it will have already accessed it when assigning it to the local variable.

提交回复
热议问题