Abstract
The STL provides facilities for memory management. These include the allocator class, the raw storage iterator, temporary buffers, the auto_ptr, and some utility functions. The allocator class is a general-purpose allocator that is the default allocator used by all the STL containers. The raw storage iterator is an object that can write values to uninitialized memory by first constructing the required object and then assigning a value. auto_ptr is a smart pointer that can be wrapped around a pointer to dynamically allocated memory so that the dynamically allocated memory is freed when the scope in which the auto_ptr is allocated is destroyed.
Access this chapter
Tax calculation will be finalised at checkout
Purchases are for personal use only
Preview
Unable to display preview. Download preview PDF.
Author information
Authors and Affiliations
Rights and permissions
Copyright information
© 2000 Springer Science+Business Media New York
About this chapter
Cite this chapter
Robson, R. (2000). Memory Management. In: Using the STL. Springer, New York, NY. https://doi.org/10.1007/978-1-4612-1312-3_10
Download citation
DOI: https://doi.org/10.1007/978-1-4612-1312-3_10
Publisher Name: Springer, New York, NY
Print ISBN: 978-0-387-98857-3
Online ISBN: 978-1-4612-1312-3
eBook Packages: Springer Book Archive