MCPcopy Create free account
hub / github.com/ElementsProject/elements / AsBytes

Function AsBytes

src/span.h:253–256  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

251// From C++20 as_bytes and as_writeable_bytes
252template <typename T>
253Span<const std::byte> AsBytes(Span<T> s) noexcept
254{
255 return {BytePtr(s.data()), s.size_bytes()};
256}
257template <typename T>
258Span<std::byte> AsWritableBytes(Span<T> s) noexcept
259{

Callers 12

ser_writedata8Function · 0.85
ser_writedata16Function · 0.85
ser_writedata16beFunction · 0.85
ser_writedata32Function · 0.85
ser_writedata32beFunction · 0.85
ser_writedata64Function · 0.85
SerializeFunction · 0.85
MakeByteSpanFunction · 0.85
CDataStreamMethod · 0.85
SerializeMethod · 0.85
CaptureMessageToFileFunction · 0.85
SerializeScriptCodeMethod · 0.85

Calls 2

BytePtrFunction · 0.85
dataMethod · 0.45

Tested by

no test coverage detected