mirror of
https://github.com/matrix-construct/construct
synced 2025-01-14 00:34:18 +01:00
ircd:Ⓜ️ ircd::buffer conversions for id::bufs.
This commit is contained in:
parent
a8f9b3b847
commit
2982166072
1 changed files with 10 additions and 0 deletions
|
@ -109,6 +109,16 @@ struct ircd::m::id::buf
|
|||
std::array<char, SIZE> b;
|
||||
|
||||
public:
|
||||
operator const_buffer() const
|
||||
{
|
||||
return b;
|
||||
}
|
||||
|
||||
operator mutable_buffer()
|
||||
{
|
||||
return b;
|
||||
}
|
||||
|
||||
template<class... args>
|
||||
buf(args&&... a)
|
||||
:T{b.data(), b.size(), std::forward<args>(a)...}
|
||||
|
|
Loading…
Reference in a new issue