diff options
Diffstat (limited to 'absl/status/internal/status_internal.h')
-rw-r--r-- | absl/status/internal/status_internal.h | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/absl/status/internal/status_internal.h b/absl/status/internal/status_internal.h index 1f82b8e4..279f8f55 100644 --- a/absl/status/internal/status_internal.h +++ b/absl/status/internal/status_internal.h @@ -36,6 +36,13 @@ using Payloads = absl::InlinedVector<Payload, 1>; // Reference-counted representation of Status data. struct StatusRep { + StatusRep(absl::StatusCode code, std::string message, + std::unique_ptr<status_internal::Payloads> payloads) + : ref(int32_t{1}), + code(code), + message(std::move(message)), + payloads(std::move(payloads)) {} + std::atomic<int32_t> ref; absl::StatusCode code; std::string message; |