mirror of
https://github.com/matrix-construct/construct
synced 2025-03-14 05:20:17 +01:00
ircd::mods: Minor move import member defs outside of class def.
This commit is contained in:
parent
03f9cea427
commit
75a05d864c
1 changed files with 69 additions and 17 deletions
|
@ -22,25 +22,77 @@ template<class T>
|
|||
struct ircd::mods::import
|
||||
:sym_ptr
|
||||
{
|
||||
template<class... args>
|
||||
auto operator()(args&&... a) const
|
||||
{
|
||||
return sym_ptr::operator()<T>(std::forward<args>(a)...);
|
||||
}
|
||||
template<class... args> auto operator()(args&&... a) const;
|
||||
template<class... args> auto operator()(args&&... a);
|
||||
|
||||
template<class... args>
|
||||
auto operator()(args&&... a)
|
||||
{
|
||||
return sym_ptr::operator()<T>(std::forward<args>(a)...);
|
||||
}
|
||||
const T *operator->() const;
|
||||
const T &operator*() const;
|
||||
operator const T &() const;
|
||||
|
||||
const T *operator->() const { return sym_ptr::operator-><T>(); }
|
||||
const T &operator*() const { return sym_ptr::operator*<T>(); }
|
||||
operator const T &() const { return sym_ptr::operator*<T>(); }
|
||||
|
||||
T *operator->() { return sym_ptr::operator-><T>(); }
|
||||
T &operator*() { return sym_ptr::operator*<T>(); }
|
||||
operator T &() { return sym_ptr::operator*<T>(); }
|
||||
T *operator->();
|
||||
T &operator*();
|
||||
operator T &();
|
||||
|
||||
using sym_ptr::sym_ptr;
|
||||
};
|
||||
|
||||
template<class T>
|
||||
ircd::mods::import<T>::operator T &()
|
||||
{
|
||||
return sym_ptr::operator*<T>();
|
||||
}
|
||||
|
||||
template<class T>
|
||||
T &
|
||||
ircd::mods::import<T>::operator*()
|
||||
{
|
||||
return sym_ptr::operator*<T>();
|
||||
}
|
||||
|
||||
template<class T>
|
||||
T *
|
||||
ircd::mods::import<T>::operator->()
|
||||
{
|
||||
return sym_ptr::operator-><T>();
|
||||
}
|
||||
|
||||
template<class T>
|
||||
ircd::mods::import<T>::operator
|
||||
const T &()
|
||||
const
|
||||
{
|
||||
return sym_ptr::operator*<T>();
|
||||
}
|
||||
|
||||
template<class T>
|
||||
const T &
|
||||
ircd::mods::import<T>::operator*()
|
||||
const
|
||||
{
|
||||
return sym_ptr::operator*<T>();
|
||||
}
|
||||
|
||||
template<class T>
|
||||
const T *
|
||||
ircd::mods::import<T>::operator->()
|
||||
const
|
||||
{
|
||||
return sym_ptr::operator-><T>();
|
||||
}
|
||||
|
||||
template<class T>
|
||||
template<class... args>
|
||||
auto
|
||||
ircd::mods::import<T>::operator()(args&&... a)
|
||||
{
|
||||
return sym_ptr::operator()<T>(std::forward<args>(a)...);
|
||||
}
|
||||
|
||||
template<class T>
|
||||
template<class... args>
|
||||
auto
|
||||
ircd::mods::import<T>::operator()(args&&... a)
|
||||
const
|
||||
{
|
||||
return sym_ptr::operator()<T>(std::forward<args>(a)...);
|
||||
}
|
||||
|
|
Loading…
Add table
Reference in a new issue