MCPcopy Create free account
hub / github.com/cinder/Cinder / operator+

Function operator+

include/asio/buffer.hpp:650–661  ·  view source on GitHub ↗

Create a new modifiable buffer that is offset from the start of another. * @relates mutable_buffer */

Source from the content-addressed store, hash-verified

648 * @relates mutable_buffer
649 */
650inline mutable_buffer operator+(const mutable_buffer& b,
651 std::size_t n) ASIO_NOEXCEPT
652{
653 std::size_t offset = n < b.size() ? n : b.size();
654 char* new_data = static_cast<char*>(b.data()) + offset;
655 std::size_t new_size = b.size() - offset;
656 return mutable_buffer(new_data, new_size
657#if defined(ASIO_ENABLE_BUFFER_DEBUGGING)
658 , b.get_debug_check()
659#endif // ASIO_ENABLE_BUFFER_DEBUGGING
660 );
661}
662
663/// Create a new modifiable buffer that is offset from the start of another.
664/**

Callers

nothing calls this directly

Calls 4

mutable_bufferClass · 0.70
const_bufferFunction · 0.70
sizeMethod · 0.45
dataMethod · 0.45

Tested by

no test coverage detected