I know this attribute should work in C #, and yet, in my case, it is not. I have a class with the lazy property Kids. Access to this property can have a side effect when accessing the server. So naturally, I don’t want this to happen when I just watch it in the debugger viewport.
Omitting all the irrelevant details, the source looks quite ordinary:
[DebuggerDisplay("(Frozen) {m_children}")] public IList<IEntityBase> Children { get { if (m_children == null) { m_children = FetchChildrenFromDB(this); } return m_children; } }
And yet, when I observe the object and open this in the viewport, I do not see (frozen) the display, that is, the debugger simply ignores the attribute.

There really is an attribute, according to Reflector. I am using VS2008.
Any ideas?
source share