What in your opinion possible to do only with reference type and no with value type without explicit boxing?
What the fact of derived from object that give all reference type some ability that value types don’t have?
You can say ToString method or GetHashCode or Equals or GetType but you actually know that you can do it also with value type via implicit boxing.
So maybe the ability to pass by reference? Also no. you can use the c# ref or out to pass value type by ref.
What about store value types on the heap? It’s not the programmer business at all where the memory allocated but anyway value types can be in the heap (actually most of your value type memory exist in the heap…)
So what I mean is of course using lock (Monitor). You can do it only with reference type and this is because the SyncBlock. (object header)
The SyncBlock is a four bytes that holds an index into SyncTableEntry table, that table contains several things like ComData, AppDomainID, Hashcode and Monitor.
Every time you do:
The SyncBlock structure is initialized and the object SyncBlock get an index to the table that contains the data.
When your thread blocked and wait there is an event handle associate with his SyncBlock and that why the SyncBlock is needed.