[#absl-Cord-Chars] = xref:absl.adoc[absl]::xref:absl/Cord.adoc[Cord]::Chars :relfileprefix: ../../ :mrdocs: Returns a `Cord::CharRange` for iterating over the characters of a `Cord` with a range‐based for‐loop. == Synopsis Declared in `<absl/strings/cord.h>` [source,cpp,subs="verbatim,replacements,macros,-callouts"] ---- xref:absl/Cord/CharRange.adoc[Cord::CharRange] Chars() const; ---- == Description For most character‐based iteration tasks on a Cord, use `Cord::Chars()` to retrieve this iterator. Example: void ProcessCord(const Cord& cord) { for (char c : cord.Chars()) { ... } } Note that the ordinary caveats of temporary lifetime extension apply: void Process() { for (char c : CordFactory().Chars()) { // The temporary Cord returned by CordFactory has been destroyed! } } == Return Value A range over the characters of the Cord. [.small]#Created with https://www.mrdocs.com[MrDocs]#