Abstract
As we saw earlier, Value Types are allocated on the stack. There are times when they are present on the managed heap. For instance, when a method takes a System::Object (the mother of all managed types) as the parameter for, say, printing the contents, an object is allocated on the heap with the value of the Value Type copied to it. This process is called boxing.
Access this chapter
Tax calculation will be finalised at checkout
Purchases are for personal use only
Author information
Authors and Affiliations
Rights and permissions
Copyright information
© 2016 Vivek Ragunathan
About this chapter
Cite this chapter
Ragunathan, V. (2016). Boxing/Unboxing. In: C++/CLI Primer. Apress, Berkeley, CA. https://doi.org/10.1007/978-1-4842-2367-3_12
Download citation
DOI: https://doi.org/10.1007/978-1-4842-2367-3_12
Published:
Publisher Name: Apress, Berkeley, CA
Print ISBN: 978-1-4842-2366-6
Online ISBN: 978-1-4842-2367-3
eBook Packages: Professional and Applied ComputingProfessional and Applied Computing (R0)Apress Access Books