diff options
Diffstat (limited to 'absl')
-rw-r--r-- | absl/strings/escaping.h | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/absl/strings/escaping.h b/absl/strings/escaping.h index 05327e7c43a6..23444a987495 100644 --- a/absl/strings/escaping.h +++ b/absl/strings/escaping.h @@ -64,7 +64,10 @@ namespace absl { // Example: // // std::string s = "foo\\rbar\\nbaz\\t"; -// std::string unescaped_s = absl::CUnescape(s); +// std::string unescaped_s; +// if (!absl::CUnescape(s, &unescaped_s) { +// ... +// } // EXPECT_EQ(unescaped_s, "foo\rbar\nbaz\t"); bool CUnescape(absl::string_view source, std::string* dest, std::string* error); |