Monday, November 16, 2009

What happens in memory when you Box and Unbox a value-type?

Boxing converts a value-type to a reference-type, thus storing the object on the heap.  Unboxing converts a reference-type to a value-type, thus storing the value on the stack.

No comments:

Post a Comment

Disclaimer:- All articles are not written by me.i copied some useful definition and tutorials from others site, copied site location is shown in all articles bottom as source.