mirror of
https://github.com/matrix-construct/construct
synced 2025-02-18 01:30:12 +01:00
ircd:Ⓜ️ Add overload for nothrow integral m::get w/ defaulting.
This commit is contained in:
parent
860087b6ce
commit
24325c8fc1
1 changed files with 15 additions and 0 deletions
|
@ -38,6 +38,21 @@ namespace ircd::m
|
||||||
template<class T>
|
template<class T>
|
||||||
typename std::enable_if<std::is_integral<T>::value, T>::type
|
typename std::enable_if<std::is_integral<T>::value, T>::type
|
||||||
get(const event::idx &, const string_view &key);
|
get(const event::idx &, const string_view &key);
|
||||||
|
|
||||||
|
template<class T>
|
||||||
|
typename std::enable_if<std::is_integral<T>::value, T>::type
|
||||||
|
get(std::nothrow_t, const event::idx &, const string_view &key, T ret);
|
||||||
|
}
|
||||||
|
|
||||||
|
template<class T>
|
||||||
|
typename std::enable_if<std::is_integral<T>::value, T>::type
|
||||||
|
ircd::m::get(std::nothrow_t,
|
||||||
|
const event::idx &event_idx,
|
||||||
|
const string_view &key,
|
||||||
|
T ret)
|
||||||
|
{
|
||||||
|
get(event_idx, key, ret);
|
||||||
|
return ret;
|
||||||
}
|
}
|
||||||
|
|
||||||
template<class T>
|
template<class T>
|
||||||
|
|
Loading…
Add table
Reference in a new issue