Skip to main content

Memory Management

  • Chapter
Using the STL
  • 217 Accesses

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.

This is a preview of subscription content, log in via an institution to check access.

Access this chapter

Chapter
USD 29.95
Price excludes VAT (USA)
  • Available as PDF
  • Read on any device
  • Instant download
  • Own it forever
eBook
USD 84.99
Price excludes VAT (USA)
  • Available as PDF
  • Read on any device
  • Instant download
  • Own it forever
Softcover Book
USD 109.99
Price excludes VAT (USA)
  • Compact, lightweight edition
  • Dispatched in 3 to 5 business days
  • Free shipping worldwide - see info

Tax calculation will be finalised at checkout

Purchases are for personal use only

Institutional subscriptions

Preview

Unable to display preview. Download preview PDF.

Unable to display preview. Download preview PDF.

Author information

Authors and Affiliations

Authors

Rights and permissions

Reprints 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

Publish with us

Policies and ethics