mirror of
https://github.com/matrix-construct/construct
synced 2024-12-29 17:04:03 +01:00
ircd::db: Inline trivial operator wrappers.
This commit is contained in:
parent
fb2693c0ff
commit
2741ab785c
4 changed files with 34 additions and 34 deletions
|
@ -133,3 +133,16 @@ ircd::db::operator<<(std::ostream &s, const cell &c)
|
|||
s << string_view{c};
|
||||
return s;
|
||||
}
|
||||
|
||||
inline ircd::db::cell::operator
|
||||
string_view()
|
||||
{
|
||||
return val();
|
||||
}
|
||||
|
||||
inline ircd::db::cell::operator
|
||||
string_view()
|
||||
const
|
||||
{
|
||||
return val();
|
||||
}
|
||||
|
|
|
@ -280,6 +280,20 @@ struct ircd::db::column::const_reverse_iterator
|
|||
using const_iterator_base::const_iterator_base;
|
||||
};
|
||||
|
||||
inline const ircd::db::column::const_iterator_base::value_type *
|
||||
ircd::db::column::const_iterator_base::operator->()
|
||||
const
|
||||
{
|
||||
return &operator*();
|
||||
}
|
||||
|
||||
inline bool
|
||||
ircd::db::column::const_iterator_base::operator!()
|
||||
const noexcept
|
||||
{
|
||||
return !static_cast<bool>(*this);
|
||||
}
|
||||
|
||||
inline ircd::db::column::const_iterator_base::operator
|
||||
gopts &()
|
||||
{
|
||||
|
|
|
@ -97,3 +97,10 @@ struct ircd::db::domain::const_reverse_iterator
|
|||
|
||||
using domain::const_iterator_base::const_iterator_base;
|
||||
};
|
||||
|
||||
inline const ircd::db::domain::const_iterator_base::value_type *
|
||||
ircd::db::domain::const_iterator_base::operator->()
|
||||
const
|
||||
{
|
||||
return &this->operator*();
|
||||
}
|
||||
|
|
34
ircd/db.cc
34
ircd/db.cc
|
@ -6011,19 +6011,6 @@ ircd::db::cell::operator()(const op &op,
|
|||
write(cell::delta{op, *this, val}, sopts);
|
||||
}
|
||||
|
||||
ircd::db::cell::operator
|
||||
string_view()
|
||||
{
|
||||
return val();
|
||||
}
|
||||
|
||||
ircd::db::cell::operator
|
||||
string_view()
|
||||
const
|
||||
{
|
||||
return val();
|
||||
}
|
||||
|
||||
ircd::string_view
|
||||
ircd::db::cell::val()
|
||||
{
|
||||
|
@ -6266,13 +6253,6 @@ const
|
|||
return val;
|
||||
}
|
||||
|
||||
const ircd::db::domain::const_iterator_base::value_type *
|
||||
ircd::db::domain::const_iterator_base::operator->()
|
||||
const
|
||||
{
|
||||
return &this->operator*();
|
||||
}
|
||||
|
||||
///////////////////////////////////////////////////////////////////////////////
|
||||
//
|
||||
// db/column.h
|
||||
|
@ -7411,20 +7391,6 @@ const
|
|||
return val;
|
||||
}
|
||||
|
||||
const ircd::db::column::const_iterator_base::value_type *
|
||||
ircd::db::column::const_iterator_base::operator->()
|
||||
const
|
||||
{
|
||||
return &operator*();
|
||||
}
|
||||
|
||||
bool
|
||||
ircd::db::column::const_iterator_base::operator!()
|
||||
const noexcept
|
||||
{
|
||||
return !static_cast<bool>(*this);
|
||||
}
|
||||
|
||||
ircd::db::column::const_iterator_base::operator bool()
|
||||
const noexcept
|
||||
{
|
||||
|
|
Loading…
Reference in a new issue