Quản lí bộ nhớ


there are several memory area in C++

Memory Area     Characteristics and Object Lifetimes
 --------------  ------------------------------------------------

 Const Data      The const data area stores string literals and
                 other data whose values are known at compile
                 time.  No objects of class type can exist in
                 this area.  All data in this area is available
                 during the entire lifetime of the program.

                 Further, all of this data is read-only, and the
                 results of trying to modify it are undefined.
                 This is in part because even the underlying
                 storage format is subject to arbitrary
                 optimization by the implementation.  For
                 example, a particular compiler may store string
                 literals in overlapping objects if it wants to.

Tiếp tục đọc