forked from fmtlib/fmt
Fix invalid fmt::formatter<>::format return type (#3895)
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
This commit is contained in:
committed by
GitHub
parent
df6e7b22f7
commit
c17816cb4a
@ -140,7 +140,7 @@ without implementing them yourself. For example::
|
|||||||
// parse is inherited from formatter<string_view>.
|
// parse is inherited from formatter<string_view>.
|
||||||
|
|
||||||
auto format(color c, format_context& ctx) const
|
auto format(color c, format_context& ctx) const
|
||||||
-> format_parse_context::iterator;
|
-> format_context::iterator;
|
||||||
};
|
};
|
||||||
|
|
||||||
// color.cc:
|
// color.cc:
|
||||||
@ -148,7 +148,7 @@ without implementing them yourself. For example::
|
|||||||
#include <fmt/format.h>
|
#include <fmt/format.h>
|
||||||
|
|
||||||
auto fmt::formatter<color>::format(color c, format_context& ctx) const
|
auto fmt::formatter<color>::format(color c, format_context& ctx) const
|
||||||
-> format_parse_context::iterator {
|
-> format_context::iterator {
|
||||||
string_view name = "unknown";
|
string_view name = "unknown";
|
||||||
switch (c) {
|
switch (c) {
|
||||||
case color::red: name = "red"; break;
|
case color::red: name = "red"; break;
|
||||||
|
Reference in New Issue
Block a user