\brief Construct a view on a buffer at the given offset and length. This function cannot fail and does not check for errors (except in debug builds)
| 444 | /// |
| 445 | /// This function cannot fail and does not check for errors (except in debug builds) |
| 446 | static inline std::shared_ptr<Buffer> SliceBuffer(std::shared_ptr<Buffer> buffer, |
| 447 | const int64_t offset, |
| 448 | const int64_t length) { |
| 449 | return std::make_shared<Buffer>(std::move(buffer), offset, length); |
| 450 | } |
| 451 | |
| 452 | /// \brief Construct a view on a buffer at the given offset, up to the buffer's end. |
| 453 | /// |