diff --git a/CHANGELOG.md b/CHANGELOG.md index 807d7ed1..bcaeefdd 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -2,11 +2,14 @@ Version 286: * Refactor multi_buffer * Refactor buffers_adapter +* Refactor static_buffer API Changes: -* multi_buffer::mutable_data_type is deprecated. Use multi_buffer::mutable_buffers_type instead -* buffers_adaptor::mutable_data_type is deprecated. Use buffers_adaptor::mutable_buffers_type instead +* multi_buffer::mutable_data_type is deprecated. Use multi_buffer::mutable_buffers_type instead. +* buffers_adaptor::mutable_data_type is deprecated. Use buffers_adaptor::mutable_buffers_type instead. +* static_buffer::mutable_data_type is deprecated. Use static_buffer::mutable_buffers_type instead. +* static_buffer_base::mutable_data_type is deprecated. Use static_buffer_base::mutable_buffers_type instead. -------------------------------------------------------------------------------- diff --git a/include/boost/beast/core/impl/static_buffer.ipp b/include/boost/beast/core/impl/static_buffer.ipp index b87d704b..e758adc5 100644 --- a/include/boost/beast/core/impl/static_buffer.ipp +++ b/include/boost/beast/core/impl/static_buffer.ipp @@ -56,7 +56,7 @@ data() const noexcept -> auto static_buffer_base:: data() noexcept -> - mutable_data_type + mutable_buffers_type { if(in_off_ + in_size_ <= capacity_) return { diff --git a/include/boost/beast/core/static_buffer.hpp b/include/boost/beast/core/static_buffer.hpp index c4ff534f..fd6c7f07 100644 --- a/include/boost/beast/core/static_buffer.hpp +++ b/include/boost/beast/core/static_buffer.hpp @@ -94,14 +94,15 @@ public: /// The ConstBufferSequence used to represent the readable bytes. using const_buffers_type = __implementation_defined__; - /// The MutableBufferSequence used to represent the readable bytes. - using mutable_data_type = __implementation_defined__; - /// The MutableBufferSequence used to represent the writable bytes. using mutable_buffers_type = __implementation_defined__; #else using const_buffers_type = detail::buffers_pair; + +#ifdef BOOST_BEAST_ALLOW_DEPRECATED using mutable_data_type = detail::buffers_pair; +#endif + using mutable_buffers_type = detail::buffers_pair; #endif @@ -140,7 +141,7 @@ public: /// Returns a mutable buffer sequence representing the readable bytes BOOST_BEAST_DECL - mutable_data_type + mutable_buffers_type data() noexcept; /** Returns a mutable buffer sequence representing writable bytes.