Copy a string: Difference between revisions

Content deleted Content added
Ce (talk | contribs)
→‎{{header|C}}: Another reference to an existing string
Ce (talk | contribs)
Line 99: Line 99:


=={{header|C++}}==
=={{header|C++}}==
=== Using only standard facilities ===

'''Libraries:''' C++ Standard Library
'''Libraries:''' C++ Standard Library
#include <string>
#include <string>
Line 157: Line 159:
// get rid of temporary buffer
// get rid of temporary buffer
free(cs); // delete or delete[] may not be used here
free(cs); // delete or delete[] may not be used here

=== Using string types supplied by specific compiler-provided or external libraries ===


'''Libraries:''' [[Qt]]
'''Libraries:''' [[Qt]]