[#absl-CopyCordToString] = xref:absl.adoc[absl]::CopyCordToString :relfileprefix: ../ :mrdocs: Copies the contents of a `src` Cord into a `*dst` string. == Synopsis Declared in `<absl/strings/cord.h>` [source,cpp,subs="verbatim,replacements,macros,-callouts"] ---- void CopyCordToString( xref:absl/Cord.adoc[Cord] const& src, std::string* dst); ---- == Description This function optimizes the case of reusing the destination string since it can reuse previously allocated capacity. However, this function does not guarantee that pointers previously returned by `dst‐>data()` remain valid even if `*dst` had enough capacity to hold `src`. If `*dst` is a new object, prefer to simply use the conversion operator to `std::string`. == Parameters [cols="1,4"] |=== | Name| Description | *src* | The Cord whose contents are copied. | *dst* | The string that receives the copied contents. |=== [.small]#Created with https://www.mrdocs.com[MrDocs]#