summaryrefslogtreecommitdiff
path: root/absl/strings/str_cat.h
diff options
context:
space:
mode:
authorGravatar Phoebe Liang <phoebeliang@google.com>2022-11-02 15:27:54 -0700
committerGravatar Copybara-Service <copybara-worker@google.com>2022-11-02 15:28:46 -0700
commite6044634dd7caec2d79a13aecc9e765023768757 (patch)
tree3ffe2c00f4b5e49da4f4e7d9e50c64999f318408 /absl/strings/str_cat.h
parent1649c037c556bdaca7241bc0113275506bdb9638 (diff)
Support logging of user-defined types that implement `AbslStringify()`
If a user-defined type has `AbslStringify()` defined, it will always be used for logging over `operator<<`. `HasAbslStringify` now uses the empty class `UnimplementedSink` for its checks instead of `StringifySink` in order to make it work in cases involving other sinks. PiperOrigin-RevId: 485710377 Change-Id: Ibdd916151c7abc3269c35fbe79b772867f3d25e1
Diffstat (limited to 'absl/strings/str_cat.h')
-rw-r--r--absl/strings/str_cat.h1
1 files changed, 1 insertions, 0 deletions
diff --git a/absl/strings/str_cat.h b/absl/strings/str_cat.h
index 1a37faae..00af84ea 100644
--- a/absl/strings/str_cat.h
+++ b/absl/strings/str_cat.h
@@ -95,6 +95,7 @@
#include <vector>
#include "absl/base/port.h"
+#include "absl/strings/internal/has_absl_stringify.h"
#include "absl/strings/internal/stringify_sink.h"
#include "absl/strings/numbers.h"
#include "absl/strings/string_view.h"