mirror of
https://github.com/RGBCube/serenity
synced 2025-07-27 02:27:43 +00:00
AK: Move StandardFormatter argument into base class initializer
Subclasses of StandardFormatter don't need to use the formatter argument in their constructor, so move() it into the base class initializer.
This commit is contained in:
parent
74e8aa73e5
commit
2c4f7fae1e
1 changed files with 3 additions and 3 deletions
|
@ -294,7 +294,7 @@ template<typename T>
|
|||
struct Formatter<T, typename EnableIf<IsIntegral<T>>::Type> : StandardFormatter {
|
||||
Formatter() = default;
|
||||
explicit Formatter(StandardFormatter formatter)
|
||||
: StandardFormatter(formatter)
|
||||
: StandardFormatter(move(formatter))
|
||||
{
|
||||
}
|
||||
|
||||
|
@ -305,7 +305,7 @@ template<>
|
|||
struct Formatter<StringView> : StandardFormatter {
|
||||
Formatter() = default;
|
||||
explicit Formatter(StandardFormatter formatter)
|
||||
: StandardFormatter(formatter)
|
||||
: StandardFormatter(move(formatter))
|
||||
{
|
||||
}
|
||||
|
||||
|
@ -317,7 +317,7 @@ requires(HasFormatter<T>) struct Formatter<Vector<T>> : StandardFormatter {
|
|||
|
||||
Formatter() = default;
|
||||
explicit Formatter(StandardFormatter formatter)
|
||||
: StandardFormatter(formatter)
|
||||
: StandardFormatter(move(formatter))
|
||||
{
|
||||
}
|
||||
void format(FormatBuilder& builder, Vector<T> value)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue