diff options
| author | Lee *!* Clagett <code@leeclagett.com> | 2023-05-21 13:34:34 -0400 |
|---|---|---|
| committer | Lee *!* Clagett <code@leeclagett.com> | 2024-10-23 15:47:22 -0400 |
| commit | 3f3229a9a772bb1e0b421a3f20064957e56042b7 (patch) | |
| tree | 8842dd61c14bae87368e51b541568ad0ad2b0f94 /contrib | |
| parent | 58a1d54a4f90a235616ede3f8ebae2b8dca41589 (diff) | |
| download | monzero-core-3f3229a9a772bb1e0b421a3f20064957e56042b7.tar.gz monzero-core-3f3229a9a772bb1e0b421a3f20064957e56042b7.tar.xz monzero-core-3f3229a9a772bb1e0b421a3f20064957e56042b7.zip | |
Add byte_stream `value_type` and `data()`
Diffstat (limited to 'contrib')
| -rw-r--r-- | contrib/epee/include/byte_stream.h | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/contrib/epee/include/byte_stream.h b/contrib/epee/include/byte_stream.h index e7993133a..ec9e5cbca 100644 --- a/contrib/epee/include/byte_stream.h +++ b/contrib/epee/include/byte_stream.h @@ -74,6 +74,7 @@ namespace epee public: using char_type = std::uint8_t; using Ch = char_type; + using value_type = char_type; //! Increase internal buffer by at least `byte_stream_increase` bytes. byte_stream() noexcept @@ -86,6 +87,7 @@ namespace epee ~byte_stream() noexcept = default; byte_stream& operator=(byte_stream&& rhs) noexcept; + std::uint8_t* data() noexcept { return buffer_.get(); } const std::uint8_t* data() const noexcept { return buffer_.get(); } std::uint8_t* tellp() const noexcept { return next_write_; } std::size_t available() const noexcept { return end_ - next_write_; } |
