absl::StatusBuilder::ToString

Returns a string representation of the status this builder would produce.

Synopsis

Declared in <absl/status/status_builder.h>

std::string
ToString() const;

Description

This produces the same string as would converting to a Status and calling operator<<, but it does so without side effects (e.g., logging). Therefore, it is safe to use from within an adapter object passed into With().

Return Value

The string representation of the result status.