mirror of
https://github.com/matrix-construct/construct
synced 2025-02-18 09:40:12 +01:00
ircd::json: Simplify printer invocation template overloading.
This commit is contained in:
parent
013ba40eec
commit
ff1d2c938c
1 changed files with 0 additions and 17 deletions
17
ircd/json.cc
17
ircd/json.cc
|
@ -339,9 +339,6 @@ ircd::json::printer
|
|||
class... attr>
|
||||
void operator()(mutable_buffer &out, gen&&, attr&&...) const;
|
||||
|
||||
template<class gen>
|
||||
void operator()(mutable_buffer &out, gen&&) const;
|
||||
|
||||
printer()
|
||||
:printer::base_type{rule<>{}}
|
||||
{
|
||||
|
@ -499,20 +496,6 @@ const
|
|||
};
|
||||
}
|
||||
|
||||
template<class gen>
|
||||
[[using gnu: always_inline, gnu_inline, artificial]]
|
||||
extern inline void
|
||||
ircd::json::printer::operator()(mutable_buffer &out,
|
||||
gen&& g)
|
||||
const
|
||||
{
|
||||
if(unlikely(!ircd::generate(out, std::forward<gen>(g))))
|
||||
throw print_error
|
||||
{
|
||||
"Failed to generate JSON"
|
||||
};
|
||||
}
|
||||
|
||||
template<class it_a,
|
||||
class it_b,
|
||||
class closure>
|
||||
|
|
Loading…
Add table
Reference in a new issue